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

Tracing a Java Agent?

Moderators: Vladimir Kondratyev, Anton Katilin

Tracing a Java Agent?

Postby rstheo » Wed Oct 02, 2019 2:58 pm

Is it possible to trace the execution of the premain method of a Java Agent using YourKit? I tried this and it looked like the YourKit native agent and the Java Agent (specified by -javaagent:<agent.jar>) I wanted to trace came up at the same time and the Java Agent premain execution was skipped.

This is how I specified the yourkit commandline options:

-agentpath:/path/libyjpagent.so=port=10000,sessionname=prov,dir=/path/,tracing

Is there another way I can configure the YourKit agent so that execution of the Java Agent's premain method can be traced?
rstheo
 
Posts: 1
Joined: Wed Oct 02, 2019 2:51 pm

Re: Tracing a Java Agent?

Postby Anton Katilin » Thu Oct 03, 2019 6:47 am

Exactly what method you want to trace?

The agent cannot trace all methods during JVM initialization because it is not possible to resolve dependencies. Instead, tracing actually starts at some later phase. There are no other profiler agent configuration options to let tracing start earlier.
Anton Katilin
 
Posts: 5826
Joined: Wed Aug 11, 2004 8:37 am


Return to Java Profiler

Who is online

Users browsing this forum: No registered users and 22 guests

cron

YourKit uses cookies and other tracking technologies to improve your browsing experience on our website, to show you personalized content and targeted ads, to analyze our website traffic, and to understand where our visitors are coming from.

By browsing our website, you consent to our use of cookies and other tracking technologies in accordance with the Privacy Policy.