Is it possible to do a rolling of garbage collector logs in Sun JVM?
Currently I generate logs using:
-XX:+PrintGCDetails -XX:+PrintGCTimeStamps -XX:
I ended up solving this problem by spawning a new thread in my application and sending jcmd log-rotate command periodically (based on a cron expression).
This is an unconventional approach as you will be using Oracle's Attach API, although the approach served our use case of rotating GC logs hourly.