Is there a tool which could be used to analyse the objects being created between two separate garbage collection run (= number of objects created and their type) ?
Heapdumps dont really work here as they perform a GC when they’re invoked (or at least that’s what I observed everytime so far), and I want to see which objects are collected by the GC, not which objects are left after the GC run, if that makes sense.
First, when you always observe a full garbage collection before each heap dump, you probably called it like this:
If that’s the case, just leave out the
:live, which will suppress the explicit garbage collection.In addition, the Sun JVM knows the following command line options:
That should be pretty much what you want.