質問

does someone know a good beginner tutorial for getting started with Neo4j? I downloaded the hello-world and cineast from neo4j examples, but I just can't make it run. I got AspectJ errors and spring errors and everytime I fix an error, a new one appears. I think, the problem is, that I don't really understand, how I have to structure a neo4j-spring-data project correctly. Could you tell me, what would be the best way to get a running example for neo4j?

Maybe some could post a working pom.xml configuration. I tried the configs from the neo4j examples and got exceptions. When I change the aspectj version from 1.6.? to RELEASE I can make the project but then I get a exception in glassfish (I deploy the webapp).

EDIT

So! Finally I made it working! Here some tipps for other neo4j-newbies:

  1. Use Java 7! I'm not sure if it was me or java, but it didn't work with java 8 for me!
  2. Since spring-data 3.0 there is the strict checking (see: http://blog.neo4j.org/2014/03/spring-data-neo4j-progress-update-sdn-3.html), so you have to define the package of the repositories in the spring config xml! I did it like this:

applicationContext-graph.xml

<neo4j:repositories base-package="org.neo4j.app.todos"/>

<neo4j:config graphDatabaseService="graphDatabaseService" base-package="org.neo4j.app.todos" />
<bean id="graphDatabaseService" 
  class="org.springframework.data.neo4j.rest.SpringRestGraphDatabase">
  <constructor-arg index="0" value="http://localhost:7474/db/data/" />
</bean>
  1. Use the todo-example from the neo4j-examples, it's in my opinion the simplest of them.

I hope this helps someone.

Best regards

役に立ちましたか?

解決

Lots of ways to learn, and you'll probably get lots of opinions (which could mean this question gets closed). But... you're really trying to make lots of things work at once.

f you really want to start learning Neo4j, Neo Technologies has a free online training course (which you can get to from their neo4j.org homepage, under Learn) that doesn't require anything to be installed, and you'll focus on core features of Neo4j (and Cypher), without worrying about coding frameworks or installing the database engine itself.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top