The Netbeans memory monitoring tool (which is actually the built-in VisualVm tool that VisualVm does) has an interesting metric for tracking memory leaks: a label for surviving generations.
A definition of this indicator can be found at oracle.com:
- Generation is a collection of instances created within the same GC interval (between two garbage collections)
- A surviving generation is a generation that survives in at least one garbage collection. The number of surviving garbage collectors - the age of generations - is its unique identifier.
- The value of surviving generations (metrics) is the number of different surviving generations that are currently alive on the heap (number of generations with different generations)
I have a question about the second definition. I know what this means for an instance to survive in the garbage collection. But I'm not sure what it means for a generation to survive in a garbage collection. Does this mean that at least one generation instance survives in garbage collection?
source
share