Ok, there's an explanation. Interestingly, I'm testing using 2.1.8, and the cypher query works !
Maybe a change in the mecanism of class loading with this version ? Le mardi 12 janvier 2016 15:12:31 UTC+1, Michael Hunger a écrit : > > Oh an eclipse plugin ... that explains it. > > The problem is that the classloading from eclipse interferes with the Java > ServiceLoader, we use that mechanism in several places to load classes > which are indirectly used or have multiple implementations. > > So the problem is class visibility which is not given in this context. > There are certainly ways to work around it, but I am a bit out of my league > here. > > Perhaps Lars could help with a tip? > > Cheers, Michael > > > Am 12.01.2016 um 14:59 schrieb Pierre-Alexandre Voye <[email protected] > <javascript:>>: > > Micheal, > > It's difficult to share the whole project, because I'm embedding the code > in a Eclipse plugin (!). The amount of node will be limited (less than 30K > node and edge) > I use maven to build the Eclipse Plugin. It's pretty complex because we > embed our lib in it. > However, here the gist of an extract of one of my pom file, which list all > the dependency : https://gist.github.com/ontologiae/74915b2739c2cd34ec2c > Like I said, I carefully verified that all the needed jar are available in > the produced plugin, including verifying it in the final jar (the plugin > jar) > > I created a gist with the code in its context : > https://gist.github.com/ontologiae/5513f18aa3d0b484bc3c > It works perfectly until line 61, where it fails with > "java.lang.UnsupportedOperationException: No query engine installed." > > Here my stacktrace (in the bottom of the Eclipse plugin stacktrace): > > Caused by: java.lang.UnsupportedOperationException: No query engine > installed. > at > org.neo4j.kernel.impl.query.NoQueryEngine.noQueryEngine(NoQueryEngine.java:56) > at > org.neo4j.kernel.impl.query.NoQueryEngine.executeQuery(NoQueryEngine.java:33) > at > org.neo4j.kernel.impl.factory.GraphDatabaseFacade.execute(GraphDatabaseFacade.java:333) > at > org.neo4j.kernel.impl.factory.GraphDatabaseFacade.execute(GraphDatabaseFacade.java:323) > at > com.greenspector.plugins.eclipse.greenspectorplugin.Activator.testStartDb(Activator.java:176) > at > com.greenspector.plugins.eclipse.greenspectorplugin.Activator.start(Activator.java:222) > at > org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:771) > at > org.eclipse.osgi.internal.framework.BundleContextImpl$3.run(BundleContextImpl.java:1) > at java.security.AccessController.doPrivileged(Native Method) > at > org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:764) > ... 131 more > > > I have the same stacktrace in version 2.3.1 and 2.2.8 > > > > > Thank you for your help > > Le mardi 12 janvier 2016 13:17:24 UTC+1, Michael Hunger a écrit : >> >> Would you be able to share your setup / example project? >> >> Usually having the dependencies being handled by a build tool like maven >> or gradle is the easiest way. >> >> Can you also share the full stack trace? >> >> Michael >> >> Am 12.01.2016 um 11:37 schrieb Pierre-Alexandre Voye <[email protected] >> >: >> >> Hi everyone, >> >> I'm trying to run a Cypher query in an embedded neo4j. The initialization >> works fine, but the code throw an error on this line >> >> Result result = mGraphDb.execute( "match (n {name: 'Duane Nickull, I >> Braineater'}) return n, n.name" ); >> >> I get a "java.lang.UnsupportedOperationException: No query engine >> installed." error. >> >> I spent HOURS to verify that all my dependencies are absolutely surely >> right. I verified it again before writing this message. >> I tried with two versions : 2.3.1 and 2.2.8 and I get the same behavior. >> >> >> Question 1 : is there a version not so old, but older (nevermind) which >> works better ? >> Question 2 : is there a subtle thing I missed for versions 2.2.8 or 2.3.1 >> ? >> >> FYI, here's my dependency for 2.3.1 version : >> neo4j-io(2.3.1) >> neo4j-consistency-check(2.3.1) >> neo4j-consistency-check-legacy(2.3.1) >> neo4j-lucene-index(2.3.1) >> neo4j-kernel(2.3.1) >> neo4j-jmx(2.3.1) >> asm(5.0.2) >> neo4j-primitive-collections(2.3.1) >> neo4j-logging(2.3.1) >> neo4j-unsafe(2.3.1) >> neo4j-graph-algo(2.3.1) >> commons-lang3(3.0) >> neo4j-udc(2.3.1) >> neo4j-graph-matching(2.3.1) >> neo4j-cypher(2.3.1) >> opencsv(2.3) >> neo4j-csv(2.3.0) >> neo4j-cypher-compiler-2.3(2.3.1) >> neo4j-cypher-compiler-2.2_2.11(2.2.6) >> neo4j-cypher-compiler-1.9_2.11(2.0.5) >> neo4j-cypher-frontend-2.3(2.3.1) >> concurrentlinkedhashmap-lru(1.4.2) >> neo4j-codegen(2.3.1) >> neo4j-function(2.3.1) >> parboiled-scala_2.11(1.1.7) >> parboiled-core(1.1.7) >> scala-library(2.11.7) >> scala-reflect(2.11.7) >> scala-parser-combinators_2.11(1.0.4) >> >> >> In advance, thank you >> >> P-A >> >> -- >> 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] <javascript:>. > 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.
