Oliver Wetterau
Oliver Wetterau

Reputation: 55

debugging an unmanaged Neo4j extension

I just started developing an unmanaged extension for Neo4j server using the Graphaware framework. Everything is fine so far. Even unit tests are working. But I would like to actually debug the extension running the Neo4j server from within Intellij.

Can anybody give me a hint on how to do that?

Many thanks in advance, Oliver

PS: This extension is being called via rest interface from a separate web server providing hosting the actual web application.

Upvotes: 2

Views: 1082

Answers (2)

salvador
salvador

Reputation: 1089

For neo4j 3.0 you have to amend this line to conf/neo4j-wrapper.conf.

dbms.jvm.additional=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005

Upvotes: 3

Stefan Armbruster
Stefan Armbruster

Reputation: 39925

You need to enable jvm remote debugging in conf/neo4j-wrapper.conf. Amend a new line to this file:

wrapper.java.additional=-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005 -Xdebug-Xnoagent-Djava.compiler=NONE-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005

In case you want to debug the startup sequence as well, use set suspend=y above.

In your debugger setup a remote debugging session to localhost:5005 or myhostname:5005.

Upvotes: 3

Related Questions