Reputation: 4470
I have apache tomcat 7 running on local and a web application deployed as .war file to this server. I am trying to use visualvm to profile the application but so far I am only able to profile tomcat itself.
I am able to see everything about tomcat in the interface and there are absolutely no problems. I am able to see indvidiual tomcat functions as well which are of no meaning to me.
What I want to see is the execution time of the functions of my deployed web application, in other words my own code. But I am unable to do that? Has anyone ever managed to do this profiling? Do I need to set a JMX connections or something with my deployed application? Below you can find my screen which I am able to profile tomcat functions.
Upvotes: 6
Views: 7160
Reputation: 1466
You can filter methods displayed in "profiler". but what you want is "sampler".
Here is what you should do.
Before you run sampler. You must check the "settings" checkbox on right of profiling window.
It will show you settings where you can write what packages should be profiled.
for example:
com.myCompany.module.*
Upvotes: 9