0

I find the G1 GC log to be somewhat cryptic and I wanted to ask can the log file itself be used to understand the total "stop the world" time for a specific time window that was used for GC?

Also , how is a full gc cycle specified for G1 collector? I see a lot of GC pause(young) but nothing equivalent for a full GC. Of course it could be because none has occurred yet but I can't say for sure.

Any feedback would be greatly appreciated.

Regards, Bob

bob dabelina
  • 507
  • 5
  • 20

1 Answers1

1

I see a lot of GC pause(young) but nothing equivalent for a full GC

Full GCs should ideally never occur in G1 and it will try to perform mixed collections (young regions + a few old regions) instead, they'll show up as something like [GC pause (mixed), ...]

A full GC will also state its cause [Full GC (Allocation Failure), ...]

I wanted to ask can the log file itself be used to understand the total "stop the world" time for a specific time window that was used for GC?

You can try GCViewer to visualize the logs. Although it won't give you a fine-grained breakdown of what exactly is happening during STW, for that you'll need to read the verbose logs, which are explained here

the8472
  • 40,999
  • 5
  • 70
  • 122
  • Thank you for the tip , I will try to use GCViewer. On a different note I am noticing one to two young generation collections per second. Is that excessive? What would be a normal young generation collection rate for a JVM? Thanks, Bob – bob dabelina Feb 19 '15 at 04:11
  • Also, does anyone know if the VisualGC plugin of VisualVM also spit out the total "stop-the-world" time? – bob dabelina Feb 19 '15 at 05:08