Hey,

if you've seen the blog post: 
http://blog.neo4j.org/2014/03/spring-data-neo4j-progress-update-sdn-3.html

It explains the issue:

Neo4j 2.0 introduced the requirement separately manage schema and data 
transactions. We tried several approaches to handle this automatically, none of 
which worked in a satisfactory manner. This has resulted in a few breaking 
changes which needed to be introduced in order to cater for this and is 
detailed below.
Important
So we had to make the entity metadata handling an explicit step in the 
lifecycle and decided to change thebase-package attribute for neo4j:config to 
be mandatory. It allows for one or more (comma separated) package names to be 
scanned for entities.
<neo4j:config storeDir="graph.db" base-package="com.example.domain"/>
<neo4j:repositories base-package="com.example.repositories"/>
Or in your @Configuration (which will change to a nicer way soon, tacked to 
@EnableNeo4jRepositories):
@Configuration
@EnableNeo4jRepositories(basePackage="com.example.repositories")
static class TestConfig extends Neo4jConfiguration {
    TestConfig() {
        setBasePackage("com.example.domain");
    }


Am 17.03.2014 um 12:07 schrieb Grégoire Colbert <[email protected]>:

> Hi Mike,
> 
> I have the same issue when trying to use 3.0.1 with code that works with 
> 3.0.0. So I guess it's a bug.
> 
> About the "No index name allowed on label based indexes" error, this is 
> because you still have the old index system around in your database. You can 
> see it using ":GET /db/data/labels" in Neo4J's browser, it is called 
> "__types__" if I remember correctly. Unfortunately, there is no migration 
> tool yet to use the new (label-based) index system. I raised an issue about 
> this at https://jira.spring.io/browse/DATAGRAPH-437.
> 
> Grégoire
> 
> Le lundi 17 mars 2014 09:16:14 UTC+1, Mike Holdsworth a écrit :
> I'm giving 3.0.1 a spin but it's throwing a MappingException on the first 
> @NodeEntity I try to create. It's failing in 
> AbstractMappingContext.getPersistentEntity
>       
> if (strict) {
>  throw new MappingException("Unknown persistent entity " + type);
>  }
> 
> 
> It had been working fine in 3.0.0-RC1. I have changed nothing in my 
> configuration except bumping the dependency to 3.0.1. Neo4j2.0.0 on OSX Java 
> 7 
> 
> This person is reporting a similar issue. 
> http://forum.spring.io/forum/spring-projects/data/nosql/746297-spring-data-neo4j-fails-on-upgrade-to-3-0-1
> 
> In 3.0.0 it appears to work when calling findByPropertyValue. In 3.0.1 the 
> function fails with the exception. Likewise calling findBySchemaPropertyValue 
> (which looks to be the replacement for findByPropertyValue) also fails. Seems 
> the persistent entities are not being registered by the Neo4jMappingContext
> 
> Any configuration things we need to be aware of? Is there a guide to how 
> @Indexed annotations can be configured to avoid "No index name allowed on 
> label based indexes.."?
> 
> @NodeEntity
> @TypeAlias(value ="ABCompany")
> public class CompanyNode implements Company {
>     @GraphId
>     Long id;
> 
>     @Indexed
>     private String name;
> 
>     @Indexed(unique = true)
>     private String code;.....
> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Neo4j" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to