Announcement Announcement Module
Collapse
No announcement yet.
Use of ImpermanentGraphDatabase throws NoSuchFieldError ephemeral Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Use of ImpermanentGraphDatabase throws NoSuchFieldError ephemeral

    Hi,

    I am trying to use ImpermanentGraphDatabase with spring-data-neo4j 2.2.0.RELEASE and Oracle JDK 1.7.0_21, but I am getting exception:

    java.lang.IllegalStateException: Failed to load ApplicationContext
    at org.springframework.test.context.CacheAwareContext LoaderDelegate.loadContext(CacheAwareContextLoader Delegate.java:99)
    at org.springframework.test.context.TestContext.getAp plicationContext(TestContext.java:122)
    :
    :
    Caused by: org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'roadMapService': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Could not autowire field: private xyz.roadMap.domain.CityRepository xyz.roadMap.domain.RoadMapService.cityRepository; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'cityRepository': Cannot resolve reference to bean 'neo4jTemplate' while setting bean property 'neo4jTemplate'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'org.springframework.data.neo4j.config.Neo4jConfig uration#0': Cannot resolve reference to bean 'graphDatabaseService' while setting bean property 'graphDatabaseService'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'graphDatabaseService' defined in class path resource [testRoadMapContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationExcepti on: Could not instantiate bean class [org.neo4j.test.ImpermanentGraphDatabase]: Constructor threw exception; nested exception is java.lang.NoSuchFieldError: ephemeral


    Here's relevant information of my set-up:
    Oracle JDK 1.7.0_21
    spring-data-neo4j ver. 2.2.0.RELEASE
    neo4j-kernel test-jar ver. 1.9 >> UPDATE << All works fine with kernel test-jar ver. 1.8.1 and 1.8.2
    spring-test ver. 3.2.2.RELEASE


    Embedded (i.e., <neo4j:config storeDirectory="target/xyz-neo4j-db" />) and Server modes (i.e., <bean id="graphDatabaseService" class="org.springframework.data.neo4j.rest.SpringR estGraphDatabase"> etc) work fine - it is only the ImpermanentGraphDatabase that I am unable to set-up with Spring Data Neo4J.

    Thanks,
    Vishal
    Last edited by vishalsp; Jun 19th, 2013, 12:17 AM. Reason: info on older jar versions

  • #2
    Can you do
    Code:
    mvn dependency:tree
    on your project ? I think you have a version conflict.

    You probably have to exclude some Neo4j dependencies to make it a clean 1.9.2 project.

    Comment

    Working...
    X