This section describes how to open a Bolt connector to your embedded instance to get GUI administration and other benefits.
The Neo4j Browser and the official Neo4j Drivers use the Bolt database protocol to communicate with Neo4j. By default, Neo4j Embedded does not expose a Bolt connector, but you can enable one. Doing so allows you to connect the services Neo4j Browser to your embedded instance.
It also gives you a way to incrementally transfer an existing Embedded application to use Neo4j Drivers instead. Migrating to Neo4j Drivers means you can run Neo4j Embedded or Neo4j Server, without having to change your application code.
To add a Bolt Connector to your embedded database, you must add the Bolt extension to your class path. This is done by adding an additional dependency to your project:
<project> ... <dependencies> <dependency> <groupId>org.neo4j</groupId> <artifactId>neo4j-bolt</artifactId> <version>4.0.3</version> </dependency> ... </dependencies> ... </project>
With this dependency in place, you can configure Neo4j to enable a Bolt connector:
DatabaseManagementService managementService = new DatabaseManagementServiceBuilder( DB_PATH ) .setConfig( BoltConnector.enabled, true ) .setConfig( BoltConnector.listen_address, new SocketAddress( "localhost", 7687 ) ) .build();