There are two ways to use NEO4J: The embedding mode embedded and the server mode standalone, the bridge between the two is the neo4j-community-1.8.m03-windows\neo4j-community-1.8.m03\ The graph.db in data, which is replaced by the generated database folder in embedded mode, can be accessed from a generated database by 127.0.0.1:7474/webadmin in server mode.
NEO4J can be embedded in your application, run as a standalone server or deploy to Ha cluster mode to provide good performance services.
Table 20.1. NEO4J deployment options
| single
Instance |
multiple Instances |
Embedded |
Embeddedgraphdatabase |
Highlyavailablegraphdatabase |
Standalone |
Neo4j Server |
NEO4J Server High Availability mode |
20.1.1. Server Mode
neo4j is accessed half as a standalone server, either directly through a rest interface or a driver based on the specified language. For information about the neo4j server, refer to: Chapter 17th NEO4J Server. To run the server in Ha mode, refer to: Chapter 22nd high Availability mode. 20.1.2. Embedding mode
By introducing a proper Java library, you can introduce neo4j into your application. When coding, you can participate in GRAPHDATABASESERVICEAPI. To switch from Singleton mode to multi-performance multi-mode, simply embeddedgraphdatabase to Highlyavailablegraphdatabase is required.
Use the following query method to search and browse data in the database
===========================================================================
NEO4J provides local services by default, which can only be accessed with localhost:7474 or 127.0.0.1:7474, but is modified
The line in Conf/neo4j-server.properties: After org.neo4j.server.webserver.address=0.0.0.0, the graphical interface and the rest interface can be accessed through ip:7474.
In cmd, you can see through the Netstat-an command:
Protocol local address external address state
TCP 10.xx.xx.170:7474 10.xx.xx.170:33034 established
TCP 10.xx.xx.170:7474 10.xx.xx.170:33036 established
TCP 10.xx.xx.170:7474 10.xx.xx.170:33037 established
Then, by Url:http://10.xx.xx.170:7474/db/data/node/1171/relationships/all/contains
You can see the retrieved JSON results