I am using OpenJDK, Java 8, VisualVM 1.2.1 (same JDK for application being profiled). In VisualVM, under the Monitor
tab, we are able to see CPU usage
and % of GC Activity
. The issue is, % of GC Activity
is always 0 when VisualGC
is reporting GC activities as usual. I want to get stats on % of time spent on GC activity. How can I fix this or is there other ways to get this stat?
Asked
Active
Viewed 196 times
0

user_1357
- 7,766
- 13
- 63
- 106
-
2Your problem is that the garbage collection takes too little CPU time? – Holger Apr 19 '22 at 09:06
-
GC is happening so how can the metric always be 0%? – user_1357 Apr 20 '22 at 15:46
-
1Just rounded down. Having less than 1% is not unusual. – Holger Apr 20 '22 at 16:56