Posted onby admin

I had to figure out what impact my change would have on the memory usage of the application.

  1. JProfiler shows you how your profiling settings will impact performance and offers you templates to quickly select profiling settings for common use cases. The powerful CPU profiler Fixing performance bottlenecks is the most frequent use case for a profiler.
  2. This screencast shows the JProfiler plugin for IntelliJ IDEA. A run configuration is profiled, source code navigation is discussed and the call graph data di.
  3. JProfiler (Used by 25.7% of respondents) JProfiler is a comprehensive Java code profiling tool for Java SE and Java EE applications with plugins for all major IDEs which provides enhanced analysis of the collected profile data. As with any profiler, the CPU profiling is perhaps the most important and useful thing you can get from JProfiler.

With my workspace setup, where I have a main method I could call the class in Eclipse, I’ve installed Jprofiler( on my machine, which profiles the java metrics, which is good for cpu or memory analysis. I’ve installed the plugin as documented for Eclipse and started using it.

JProfiler is a commercially licensed Java profiling tool developed by ej-technologies GmbH, targeted at Java EE and Java SE applications. Features edit This section contains content that is written like an advertisement.

Jprofiler is super easy and intuitive to use- If you are running anything on jvms, it’ll detect it on your host machine, show you the list of jvms and all you need to do is to click on it and set some options for the data dashboard.

The one thing I wanted to talk about is how to use this for the app that are deployed on a container.

In my case, I’ve had a Dockerfile for building an application. In the Dockerfile, I’ve added the following line to install Jprofiler inside the container.

Make an edit for the version you’re actually using!!!

RUN wget -P /tmp/ &&
tar -xzf /tmp/jprofiler_linux_10_0_4.tar.gz -C /usr/local &&
rm /tmp/jprofiler_linux_10_0_4.tar.gz


ENV JPAGENT_PATH='-agentpath:/usr/local/jprofiler10/bin/linux-x64/'

What it does is that it downloads the jprofiler linux version from ej-technologies unpack the tar expose the port that I'll later map to my host machine for the Jprofiler GUI connection.

In my docker-compose.yml file (because I used docker-compose for running the orchestration, if you are not using the orchestration, you can do so by adding parameters in docker run command) I've added the CATALINA_OPTS environment

CATALINA_OPTS: '-agentpath:/usr/local/jprofiler10.0.4/bin/linux-x64/'

10.0.4 is the latest version I can now use, but if you wish to use a different version, you can adjust it accordingly.

And one last thing, you'll have to expose the port to your host machine (This is all true when using the Docker for Mac) because you'll attach your host machine's Jprofiler to the container using 'localhost.'


So it'll be

ports: '8849:8849'

The number for the port can be configurable, and I just chose to use the 8849 due to many examples I found online.

Once that is done, you'll start the container by docker-compose or docker run and finally have Jprofiler up. On this screen, configure the field as accordingly. For example,

Jprofiler crack

If you click on start, your container will start the process and Jprofiler will show you a set of graphs you'll find useful.


Current Java SDK versions are delivered with some tools promising to find performance problems in Java applications. In addition to the well-known JConsole, the development kit is served with VisualVM, a plugin-capable tool showing memory graphs as well as CPU profiling information.

Other market players offer complex profiling tools especially designed to analyse performance problems in Java applications. What is the difference between these tools?

There exist many causes for performance issues, so in our quick overview we are going to qualify our analysis to 5 important spots in using profiling technology:

  • IDE integration
  • memory + memory leak analysis
  • CPU profiling
  • database statement monitoring
  • remote profiling

First of all the famous profiling tools JProfiler and YourKit both come with an integration in the most important IDE’s. Which means that it is possible to start debugging sessions directly from your IDE project as well as jump back from the profiler to the source code. This means that if you have found a hotspot in your application you can show the source-code-snippet in your IDE and start fixing. This can ease your working process in comparison to the build-in tools.

For VisualVM there exists plugins for eclipse and IntelliJ IDEA which enable you to launch the tool together with your application from the IDE and directly jumps to your application. NetBeans IDE already contains a built-in profiler providing the same profiling features.

Memory + Memory Leak Analysis

Many performance problems in enterprise or web applications result from memory (garbage collector) or database access issues. In case of common memory issues, all tools provide good and similar solutions.

A very comfortable way of showing memory samples can be seen in YourKit which provides the relevant sampled information cumulated in one graph with the possibility to simply mark a time range via mouse to inspect allocations and calls.

But a similar view can be found in all of the profilers. This views are a great help in optimizing memory usage and tune your application for targets like best throughput.

To find memory leaks, a good starting point is to compare two memory snapshots to find the difference after garbage collection is done. In general VisualVM, shipped with the Java SDK, is enough to create such a report. The heap viewer comes with the ability to shows references, computing retained sizes and paths to GC roots. So you are well equipped.

Helpful in finding memory leaks is the facility to view the GC-path based on any class.

In JProfiler we find an intuitive way to navigate from the point where we have found memory leaking classes or objects down to exactly the point where the instance is getting created or their references are hold. In combination with the IDE support, this makes it very easy to fix memory-leak problems because you can drill down the problem down to the problem causing sourceline in your favourite IDE and directly fix it at the point where the problem occurred. The YourKit-profiler is equipped with similar views.

At this point, in my opinion, the JProfiler user interface is much more intuitive than the YourKit user interface but this is certainly just a matter of taste. On the other hand we have some great performance graphs in YourKit showing many information stacked in one view which gives a great overview about in which shape the system is.

With all profiling tools including VisualVM you can analyse method calls and the cpu-time needed to perform the operations. So it’s possible to find the hotspots in execution. An important basic functionality for profiling your application. Also there are specialized views directly visualizing the hotspots.

So what are the real differences? One very useful information which is shown in JProfiler is the count how often an event occurred in the period of measurement time.


Why this is important? Imagine some very short running sql-statements as an example. This statements won’t appear in the statistics of long-running statements on database side, but anyway can cause a performance issue when getting called in loop. Beside of caching data which results from this statements, to improve performance another possible solution should be to dissolve such iterations to a simpler flat execution path like one database query or another algorithm. The same applies to very frequently called expensive java operations.

3 Database Statement Monitoring

Another useful feature of JProfiler when using JPA in an application, is to track JPQL queries and cumulate them with the provider-generated JDBC statements in the view. (As long as showing the JPA and JDBC hotspot statements) This is helpful to identify the called JPQL query and on the other side to see wether loading of an entity results in a join-statement or is done in subselects. It also helps to see unnecessary eager loading or lazy loading annotations.

YourKit also comes with the ability to trace jdbc statements and identify hotspots but won’t show the original JPQL query, but surely you can guess from the JDBC query. So it’s also possible to find long running statements and database bottlenecks with YourKit.

VisualVM doesn’t provide such ability.

Another important feature in profilers is the ability to sample data from remote running applications. In VisualVM it’s possible to connect to a remote running application using JMX or java’s jstatd demon and collect necessary information about the running java process like memory usage and also cpu samples. And all this out-of-the-box. It is also possible to trigger the GC and to create a heap dump of the running application on the remote machine which is saved on the remote machine.

Both JProfiler and YourKit scores here with easy to install agents which allow you to profile remote applications and servers.

Beside of manually installing the agents, you can use wizards to prepare most of the famous JEE servers to accept connections from the profiling tools. This is done by duplicating the startup script of your server and insert parameters to load the profiling-agent-dll during start up (java instrumentation agent). A very simple process with minimal impact on the startup process itself.

Jprofiler Tutorial

But also in sceneries where no wizard is available, it’s easy to install the required platform dependent agent by using a startup parameter of the JVM.

5 Summary

VisualVM hasn’t all the features provided by the commercial profiling tools, but also provides all basic features necessary for memory analysis and runtime analysis. And it’s shipped with the java sdk so it’s an instrument always available.

Jprofiler With Eclipse Video Youtube

JProfiler and YourKit are both superior products with great profiling features serving all the needs which outruns the basic requirements. It is a matter of taste which of them to use and worth to evaluate both when looking for a profiling tool.

Jprofiler Crack

My personal decision ? Well I prefer JProfiler ’cause of the JPA and call-count feature but also in cause of the intuitive user interface with a low learning curve. But as I told this is just a matter of taste.


Jprofiler Free


Jprofiler Overview

Short URL for this post: