How can I debug the unmanaged server extensions in Neo4j 3.
I have quite a complicated plugin which I'm migrating from Neo4j 2 to Neo4j 3.
When I add the plugin to the plugin folder and start Neo4j after several seconds I see a message
Starting Neo4j failed: org.neo4j.server.web.NeoServletContainer-20bef39e@312b9bee==org.neo4j.server.web.NeoServletContainer,-1,false
So, let’s get to the bottom of this: Neo4j is just a big Java application.
neo4j-harnessto your project.
After this, you can debug your extension and Neo4j itself as standard Java application.
I will copy code sample from docs here, just to have all information in one place:
serverControls = TestServerBuilders.newInProcessBuilder() .withExtension(EXTENSION_MOUNT_POINT, ResourcesRootMarker.class) .newServer(); // EXTENSION_MOUNT_POINT - where to mount your extension, e.g. - "/myextension" // ResourcesRootMarker.class - this class is located in the same package with JAX-RS resources