public interface IJavetNearHeapLimitCallback
This callback is triggered when V8 heap usage approaches its memory limit. The callback should return a new heap limit (in bytes) to either increase the limit or maintain the current limit.
Modifier and Type | Field and Description |
---|---|
static long |
INITIAL_HEAP_LIMIT
The constant INITIAL_HEAP_LIMIT.
|
Modifier and Type | Method and Description |
---|---|
long |
callback(long currentHeapLimit,
long initialHeapLimit)
Callback method invoked when V8 heap usage approaches its limit.
|
default long |
getDefaultHeapLimit()
Gets default heap limit.
|
static final long INITIAL_HEAP_LIMIT
long callback(long currentHeapLimit, long initialHeapLimit)
currentHeapLimit
- the current heap limit in bytesinitialHeapLimit
- the initial heap limit in bytesdefault long getDefaultHeapLimit()