neo4j-contrib / spatial

Neo4j Spatial is a library of utilities for Neo4j that faciliates the enabling of spatial operations on data. In particular you can add spatial indexes to already located data, and perform spatial operations on the data like searching for data within specified regions or within a specified distance of a point of interest. In addition classes are provided to expose the data to geotools and thereby to geotools enabled applications like geoserver and uDig.
http://neo4j-contrib.github.io/spatial
Other
778 stars 192 forks source link

Not compatible with the semantic plugin #362

Open Kiyoaki-w opened 4 years ago

Kiyoaki-w commented 4 years ago

Hi! I am working on a project where some RDF and spatial things are involved. When I tried to take the advantage of your plugin and the semantic plugin neosemantics, some crash happened.

The crash log:

2019-12-18 08:25:53.778+0000 INFO ======== Neo4j 3.5.12 ======== 2019-12-18 08:25:53.784+0000 INFO Starting... 2019-12-18 08:25:57.603+0000 ERROR Failed to start Neo4j: Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@41576e84' was successfully initialized, but failed to start. Please see the attached cause exception "Cannot inherit from final class". Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@41576e84' was successfully initialized, but failed to start. Please see the attached cause exception "Cannot inherit from final class". org.neo4j.server.ServerStartupException: Starting Neo4j failed: Component 'org.neo4j.server.database.LifecycleManagingDatabase@41576e84' was successfully initialized, but failed to start. Please see the attached cause exception "Cannot inherit from final class". at org.neo4j.server.exception.ServerStartupErrors.translateToServerStartupError(ServerStartupErrors.java:45) at org.neo4j.server.AbstractNeoServer.start(AbstractNeoServer.java:187) at org.neo4j.server.ServerBootstrapper.start(ServerBootstrapper.java:124) at org.neo4j.server.ServerBootstrapper.start(ServerBootstrapper.java:91) at org.neo4j.server.CommunityEntryPoint.main(CommunityEntryPoint.java:32) Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.server.database.LifecycleManagingDatabase@41576e84' was successfully initialized, but failed to start. Please see the attached cause exception "Cannot inherit from final class". at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:473) at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:111) at org.neo4j.server.AbstractNeoServer.start(AbstractNeoServer.java:180) ... 3 more Caused by: java.lang.RuntimeException: Error starting org.neo4j.graphdb.facade.GraphDatabaseFacadeFactory, /var/lib/neo4j/data/databases at org.neo4j.graphdb.facade.GraphDatabaseFacadeFactory.initFacade(GraphDatabaseFacadeFactory.java:232) at org.neo4j.graphdb.facade.GraphDatabaseFacadeFactory.newFacade(GraphDatabaseFacadeFactory.java:148) at org.neo4j.server.database.CommunityGraphFactory.newGraphDatabase(CommunityGraphFactory.java:41) at org.neo4j.server.database.LifecycleManagingDatabase.start(LifecycleManagingDatabase.java:90) at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:452) ... 5 more Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.kernel.impl.proc.Procedures@731ccdfc' was successfully initialized, but failed to start. Please see the attached cause exception "Cannot inherit from final class". at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:473) at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:111) at org.neo4j.graphdb.facade.GraphDatabaseFacadeFactory.initFacade(GraphDatabaseFacadeFactory.java:227) ... 9 more Caused by: java.lang.VerifyError: Cannot inherit from final class at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:468) at java.net.URLClassLoader.access$100(URLClassLoader.java:74) at java.net.URLClassLoader$1.run(URLClassLoader.java:369) at java.net.URLClassLoader$1.run(URLClassLoader.java:363) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:362) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:411) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.neo4j.kernel.impl.proc.ProcedureJarLoader$1.fetchNextOrNull(ProcedureJarLoader.java:161) at org.neo4j.kernel.impl.proc.ProcedureJarLoader$1.fetchNextOrNull(ProcedureJarLoader.java:138) at org.neo4j.collection.PrefetchingRawIterator.peek(PrefetchingRawIterator.java:50) at org.neo4j.collection.PrefetchingRawIterator.hasNext(PrefetchingRawIterator.java:36) at org.neo4j.kernel.impl.proc.ProcedureJarLoader.loadProcedures(ProcedureJarLoader.java:111) at org.neo4j.kernel.impl.proc.ProcedureJarLoader.loadProceduresFromDir(ProcedureJarLoader.java:85) at org.neo4j.kernel.impl.proc.Procedures.start(Procedures.java:323) at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:452) ... 11 more 2019-12-18 08:25:57.603+0000 INFO Neo4j Server shutdown initiated by request

My environment:

When I tried to remove either the semantic or spatial plugin, it works. So I think maybe there is a plugin incompatibility. Do you have any solution? Thanks.

craigtaverner commented 4 years ago

It seems likely that neosemantics has a third-party dependency that overlaps with, but is incompatible with, a third-party dependency of neo4j-spatial. I have no experience with neosemantics, so do not know the dependencies list. If we are lucky, we just need to update to newer libraries that are compatible. If you have experience with neosemantics, could you provide the dependency list?

craigtaverner commented 4 years ago

I did a quick peek at neosemantics, and found something a little odd. neo4j-spatial has a dependency on the jackson library version 1.9.13 as a transient dependency on the neo4j-server:3.5.2 artifact. But neosemantics seems to depend on three different versions of jackson:

I think mixing org.codehaus and com.fasterxml sounds risky to me. I've not reviewed the complete list of possible dependency conflicts, but this one stood out and might be worth discussing with the developers of neosemantics.