Hi,
I am trying to attach YourKit version 2018.04-b88 with glassfish (payara41).
Can you please help me with the startup configuration file changes for glassfish server so that I can attach YourKit at the time of starting glassfish server.
Thanks,
Dev
Modify glassfish startup files to attach YourKit 2018.04-b88
-
- Posts: 15
- Joined: Tue Jul 18, 2017 9:14 am
-
- Posts: 15
- Joined: Tue Jul 18, 2017 9:14 am
Re: Modify glassfish startup files to attach YourKit 2018.04
In continuation to my previous post, please find below what I am trying to do while configuring yourkit in glassfish server:
In startserv.bat file:
java -jar "%~dp0..\modules\admin-cli.jar" start-domain -agentpath:"D:\YourKit2018.04-b88\bin\win64\yjpagent.dll"=disablestacktelemetry,exceptions=disable,delay=10000,sessionname=JBoss -Dexport.method.list.cpu -Dexport.csv -Djboss.modules.system.pkgs=com.yourkit -Dtracing_settings_path=D:/Users/vishal_m/.yjp/tracing.txt --verbose %*
In domain.xml file, added following lines in <domain> tree:
<profiler native-library-path="" classpath="" name="YourKit">
<jvm-options>-agentpath:"D:\YourKit2018.04-b88\bin\win64\yjpagent.dll"=disablestacktelemetry,exceptions=disable,delay=10000,sessionname=Glassfish</jvm-options>
<jvm-options>-Dcom.sun.enterprise.server.ss.ASQuickStartup=false</jvm-options>
</profiler>
However, I get the following error when I try to start the yourkit profiler via my Java code application:
[2019-08-22T17:25:10.369+0530] [glassfish 4.1] [WARNING] [] [javax.enterprise.web] [tid: _ThreadID=27 _ThreadName=http-listener-1(1)] [timeMillis: 1566474910369] [levelValue: 900] [[
StandardWrapperValve[tracing]: Servlet.service() for servlet tracing threw exception
java.lang.ClassNotFoundException: com.yourkit.api.Controller
at org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1783)
at org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1633)
at com.hcl.nexgen.icbt.yourkit.instrumentation.service.TracingManagerImpl.startProfiling(TracingManagerImpl.java:46)
at com.hcl.nexgen.icbt.yourkit.instrumentation.controller.TracingController.startProfiling(TracingController.java:98)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Requesting you to please guide me so that yourkit gets configured via the config files of glassfish server.
Thanks in Advance
Dev
In startserv.bat file:
java -jar "%~dp0..\modules\admin-cli.jar" start-domain -agentpath:"D:\YourKit2018.04-b88\bin\win64\yjpagent.dll"=disablestacktelemetry,exceptions=disable,delay=10000,sessionname=JBoss -Dexport.method.list.cpu -Dexport.csv -Djboss.modules.system.pkgs=com.yourkit -Dtracing_settings_path=D:/Users/vishal_m/.yjp/tracing.txt --verbose %*
In domain.xml file, added following lines in <domain> tree:
<profiler native-library-path="" classpath="" name="YourKit">
<jvm-options>-agentpath:"D:\YourKit2018.04-b88\bin\win64\yjpagent.dll"=disablestacktelemetry,exceptions=disable,delay=10000,sessionname=Glassfish</jvm-options>
<jvm-options>-Dcom.sun.enterprise.server.ss.ASQuickStartup=false</jvm-options>
</profiler>
However, I get the following error when I try to start the yourkit profiler via my Java code application:
[2019-08-22T17:25:10.369+0530] [glassfish 4.1] [WARNING] [] [javax.enterprise.web] [tid: _ThreadID=27 _ThreadName=http-listener-1(1)] [timeMillis: 1566474910369] [levelValue: 900] [[
StandardWrapperValve[tracing]: Servlet.service() for servlet tracing threw exception
java.lang.ClassNotFoundException: com.yourkit.api.Controller
at org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1783)
at org.glassfish.web.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1633)
at com.hcl.nexgen.icbt.yourkit.instrumentation.service.TracingManagerImpl.startProfiling(TracingManagerImpl.java:46)
at com.hcl.nexgen.icbt.yourkit.instrumentation.controller.TracingController.startProfiling(TracingController.java:98)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Requesting you to please guide me so that yourkit gets configured via the config files of glassfish server.
Thanks in Advance
Dev
-
- Posts: 6172
- Joined: Wed Aug 11, 2004 8:37 am
Re: Modify glassfish startup files to attach YourKit 2018.04
Version 2018.04 is no longer supported. Please use the latest version 2019.8 instead.
Please use "Profile local EE server or application" from the profiler's Welcome screen to let the wizard make necessary changes for you.
For a remote server use this instead:
https://www.yourkit.com/docs/java/help/ ... remote.jsp
Please use "Profile local EE server or application" from the profiler's Welcome screen to let the wizard make necessary changes for you.
For a remote server use this instead:
https://www.yourkit.com/docs/java/help/ ... remote.jsp