Reputation: 80192
Spring Boot exposes the following 4 metrics related to GC. I am configuring Nagios to send two alerts (Warning and Critical) when they reach certain value. I am wondering what that thresholds should be? I have a 16GB heap.
Upvotes: 1
Views: 752
Reputation: 48387
Old question found on Google today. Unfortunately these metrics are not very helpful for tracking JVM health. The values are cumulative - so you need to retain the previous reading along with the time of the previous reading and subtract them from current to get the (proportion of) time spent in GC and the number of cycles since the last polling event. IME the counts are not very helpful - but the percentage time spent in GC is useful - particularly the marksweep.
As to what you should set your thresholds to, I use 10%/30% for marksweep and 5%/10% for scavenge.
Upvotes: 0