GridGain内存不足异常

时间:2014-07-10 12:17:54

标签: out-of-memory heap-memory gridgain

我正在尝试在GridGain缓存中加载大约600MB的数据,我正在尝试使用交换空间来减少RAM上的负载。我正在从CSV文件加载数据。我在内存中加载前10000个密钥,然后在交换空间中加载其余的密钥。我能够加载1350000键,但之后我收到以下错误:

[16:58:34,701][SEVERE][exchange-worker-#54%null%][GridWorker] Runtime error caught during grid runnable execution: GridWorker [name=partition-exchanger, gridName=null, finished=false, isCancelled=false, hashCode=20495511, interrupted=false, runner=exchange-worker-#54%null%]
java.lang.OutOfMemoryError: Java heap space
    at java.util.HashMap.resize(HashMap.java:559)
    at java.util.HashMap.addEntry(HashMap.java:851)
    at java.util.HashMap.put(HashMap.java:484)
    .
    .
    .
    at java.lang.Thread.run(Thread.java:722)

GridGain node stopped OK [uptime=00:21:14:384]

Exception in thread "main" java.lang.OutOfMemoryError: Java heap space

1 个答案:

答案 0 :(得分:0)

我认为你显然已经没有了Heap空间。为了利用交换空间,您应该配置驱逐策略。有关如何配置Swap和OffHeap空间的更多信息,请参阅OffHeap Memory文档。

此外,本文还有一些关于内存利用率的解释:Can I reduce the space of my cache memory?