Hot questions for Using Neo4j in eclipse
I am trying to add Neo4j dependencies into a maven project that I have created in Eclipse Kepler. I am following the steps mentioned at the link:
However, I am not getting the Neo4j pulgin from the repository. I am stuck at the following step:
What should I do for this?
I don't know why the search is not working but here what's you can do.
1) On your
pom.xml add below code :
<dependencies> <dependency> <groupId>org.neo4j</groupId> <artifactId>neo4j</artifactId> <version>your version</version> </dependency> </dependencies>
2) On that dialog just fill the
Group Id, Artifact Id and Version and click
ok and then save your
Maven will download the dependencies.
It seems that you can find the dependency on that search box only when that dependency is present on your local repo. So, for the first time you have to take one of the above approaches.
I am just starting out with Neo4j and this is my first stackoverflow question!
I tried to run the Hello-World example in Eclipse with the user library of Neo4j. ( https://github.com/neo4j/neo4j/blob/2.2.2/community/embedded-examples/src/main/java/org/neo4j/examples/EmbeddedNeo4j.java)
I only changed the
DB_PATH='data/graph.db' ( because in my neo4j-server.properties :
The output I got in the console is:
Hello, brave Neo4j World! Shutting down database ...
I shut down the neo4j server using
/etc/init.d/neo4j-service stop, then ran eclipse and got the output as provided above.I started the neo4j server again and checked localhost:7474 through the browser. There were no rows added to the database.
Is there an error in my DB_PATH? I even tried neoeclipse but did not get any output.
That example creates and then deletes the data so that is one reason why your graph is empty.
Another observation is your
DB_PATH. If you've set
DB_PATH='data/graph.db', then that path is relative to your project path. If your code is located in
/projects/example then this embedded database should be created in
If that's the case, then the Neo4j server which is configured to look for the database as
org.neo4j.server.database.location=data/graph.db will look for
data/graph.db relative to your neo4j installation.
So you can either fix the path in your code (full path to the db), or change the path in