Fully featured low overhead profiler for Java EE and Java SE platforms.
Ultimate profiling and monitoring solution for Gradle, Maven, Ant, JUnit and TestNG.
Easy to use performance and memory profiler for .NET framework.

What is shutdown snapshot?

Moderators: Vladimir Kondratyev, Anton Katilin

What is shutdown snapshot?

Postby igor.rudyak » Thu Dec 28, 2017 8:53 pm

I have such YourKit triggers specified:

Code: Select all
TimerListener delay=0ms maxTriggerCount=1
  EnableExceptionTelemetry
  EnableStackTelemetry
  StartAllocationRecording sizeLimit=4096 recordEach=10 sampledAllocationRecording=false
  StartCPUTracing
  StartMonitorProfiling
TimerListener delay=5m maxTriggerCount=1
  CapturePerformanceSnapshot fileName={date}-{pid}
  StopCPUProfiling
  StopAllocationRecording
  StopMonitorProfiling
  DisableExceptionTelemetry
  DisableStackTelemetry
JVMExitListener maxTriggerCount=1
  CapturePerformanceSnapshot fileName={date}-{pid}-exit


Thus I am expecting that after 5 minutes it will be created performance snapshot and at the JVM exit it should be created another snapshot.

However, in addition to two mentioned snapshots from time to time I see some strange snapshots named like {date}-{pid}-shutdown.snapshot which are rather big (like 815MB).

What's the idea of these shutdown snapshots?
igor.rudyak
 
Posts: 3
Joined: Thu Dec 28, 2017 8:41 pm

Re: What is shutdown snapshot?

Postby Anton Katilin » Fri Dec 29, 2017 9:27 am

Did you try opening that snapshot? Perhaps it's a memory snapshot which is automatically captured on exit because object allocation recording is still running at the moment. If this is the case, it is not related with your trigger (i.e. it would be captured even if there was no JVMExitListener). Please see description of "onexit=memory" and "onexit=snapshot" at https://www.yourkit.com/docs/java/help/ ... ptions.jsp

Try using

StopCPUProfiling
StopAllocationRecording
StopMonitorProfiling

in the JVMExitListener trigger to ensure no automatic on-exit snapshot is captured.
Anton Katilin
 
Posts: 5648
Joined: Wed Aug 11, 2004 8:37 am

Re: What is shutdown snapshot?

Postby igor.rudyak » Thu Jan 04, 2018 10:28 pm

Yes, it's memory snapshot. Thanks for the clarification.
igor.rudyak
 
Posts: 3
Joined: Thu Dec 28, 2017 8:41 pm

Re: What is shutdown snapshot?

Postby igor.rudyak » Fri Jan 05, 2018 6:28 pm

Even after these options were added to JVMExitListener:

StopCPUProfiling
StopAllocationRecording
StopMonitorProfiling

it still creates shutdown snapshot.
igor.rudyak
 
Posts: 3
Joined: Thu Dec 28, 2017 8:41 pm

Re: What is shutdown snapshot?

Postby Anton Katilin » Sun Jan 07, 2018 2:13 pm

Hi,

It seems we've found why Stop* actions in the exit trigger do not affect the "...-shutdown" snapshot.

Could you please contact support@yourkit.com
We'll provide you with a test build to ensure the proposed fix works.

Best regards,
Anton
Anton Katilin
 
Posts: 5648
Joined: Wed Aug 11, 2004 8:37 am


Return to Java Profiler

Who is online

Users browsing this forum: No registered users and 5 guests