Over a million developers have joined DZone.

Using JMX to Profile Neo4j Via JDK and VIsualVM

· Database Zone

Build fast, scale big with MongoDB Atlas, a hosted service for the leading NoSQL database. Try it now! Brought to you in partnership with MongoDB.

It might be necessary to use JMX to profile neo4j, which we are currently doing to address performance issues with Neo4j in combination with Windows Azure.

The first thing you will need to configure is additional switches in the neo4j-wrapper.conf file, here are mine:


Notice, that I am using a port number here, and this will allow remote JMX profiling, the reason for this is that in azure, the neo4j instance runs in a different user context than the remote desktop user, so we need a way to attach to the process, with VisualVM, we can do this via remote JMX.

Just add the neo4j JMX listener as a remote host. Then, if using the azure cloud:

  • Remote desktop into the worker role hosting Neo4j
  • Install the JDK
  • Install VisualVM
  • Configure the JMX Connectionas outlined below
    Right click Local and click Add JMX Connection:




From here we can now do profiling of the Neo4j application.


Now it's easier than ever to get started with MongoDB, the database that allows startups and enterprises alike to rapidly build planet-scale apps. Introducing MongoDB Atlas, the official hosted service for the database on AWS. Try it now! Brought to you in partnership with MongoDB.


Published at DZone with permission of Romiko Derbynew, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}