-
Notifications
You must be signed in to change notification settings - Fork 54
FAQs
Why is application stopped time output (-XX:+PrintGCApplicationStoppedTime) a standard recommended option?
This option used to only include garbage collection time, was not accurate, and garbagecat ignored it. However, beginning in JDK7/8, it started including stopped time for the other JVM operations performed at safepoint (e.g. ThreadDump, HeapDumper, GetAllStackTrace, PrintThreads, PrintJNI, RevokeBias, Deoptimization, FindDeadlock). Therefore, it is now a required logging option to determine overall throughput and identify pause and throughput issues not related to garbage collection.
garbagecat is designed to parse gc logging using standard options with file rotation. There should not be a use case for parsing gc logging that is on the order of hundreds of MBs or larger in size. Consider moving to standard logging options that will remove logging events that do not contribute to analysis. For example, and logging event that implements ThrowAwayEvent is not used by garbagecat.
If you have verbose logging that you would like to parse quickly, you could manually remove the logging that is thrown away.
For example, you could use the following in vim to remove ClassHistogram logging:
:g/^ \d:.*$/d
:g/^ \d\d:.*$/d
:g/^ \d\d\d:.*$/d
:g/^\d\d\d\d:.*$/d
:g/^\d\d\d\d\d:.*$/d
:g/^ num.*/d
And the following to remove Tenuring Distribution logging:
:g/^-.*$/d
:g/^Desired.*$/d
Best though is to implement logging options and file rotation so this is not necessary, as there is always some risk that manually editing files could introduce issues.