Add process.getHeapStatistics() (#13183)

This commit is contained in:
Milan Burda 2018-06-10 14:00:36 +02:00 committed by Samuel Attard
parent 1b8790aeb2
commit 6ad0a22602
6 changed files with 64 additions and 0 deletions

View file

@ -106,6 +106,22 @@ Returns [`CPUUsage`](structures/cpu-usage.md)
Returns [`IOCounters`](structures/io-counters.md)
### `process.getHeapStatistics()`
Returns `Object`:
* `totalHeapSize` Integer
* `totalHeapSizeExecutable` Integer
* `totalPhysicalSize` Integer
* `totalAvailableSize` Integer
* `usedHeapSize` Integer
* `heapSizeLimit` Integer
* `mallocedMemory` Integer
* `peakMallocedMemory` Integer
* `doesZapGarbage` Boolean
Returns an object with V8 heap statistics. Note that all statistics are reported in Kilobytes.
### `process.getProcessMemoryInfo()`
Returns `Object`: