Reputation: 30097
I can attach VisualVM to a running application, then start profiling.
All this time while I am performing manual operations, the target application is running and statistics is loosing.
How to begin collecting statistic exactly at the same moment application starts?
UPDATE
With Profile Startup
what is the way to set which class to run?
Very small cell for application setup says
-agentpath:D:/Apps/visualvm_138/profiler/lib/deployed/jdk16/windows-amd64/profilerinterface.dll=D:\Apps\visualvm_138\profiler\lib,5140
i.e. contains no clues to application location.
Upvotes: 5
Views: 2879
Reputation: 2076
You can try the startup profiler plugin:
https://visualvm.java.net/startupprofiler.html
Upvotes: 2