Skip to content
Commitwise
Menu

Heap dump

A snapshot of every object in the JVM heap, used to find what keeps memory alive.

Definition

Taken with jcmd <pid> GC.heap_dump or automatically on OutOfMemoryError, and opened in Eclipse MAT or VisualVM. The dominator tree shows which objects retain the most memory, and the path to GC roots shows why they are still reachable. Dumps can contain personal data and secrets, so treat them like production data.

In practice

A dump shows one ConcurrentHashMap in an exchange-rate service retaining 1.2 GB through 8 million entries.

Related terms

Esc

Type to search the whole site.