Neo4j Version: 2.0.0 Cytoscape Version: 3.0.1 Maven: 3.1.1 Java: 1.7.0_45 OpenJDK Runtime Environment (IcedTea 2.4.3) (ArchLinux build 7.u45_2.4.3-1-x86_64) Eclipse: 4.3.1
GOAL: The goal is to create an app for cytoscape 3.x (curr 3.0.1) that is able to connect to an instance of neo4j. APPROACH: 1. create a cytoscape 3.0.1 app based on the cytoscape tutorial from http://opentutorials.cgl.ucsf.edu/index.php/Tutorial:Create_a_Bundle_App_Using_IDE 2. make some menu entry that uses the EmbeddedGraphDatabaseService to connect to an instance. 3. add neo4j dependency to the pom.xml of the app > <dependency> > <groupId>org.neo4j</groupId> <artifactId>neo4j</artifactId> > <version>2.0.0</version> > </dependency> 4. mvn clean install 5. launch the app in Cytoscape RESULT: Cytoscape 3 can not resolve the dependency and the app will not start. Suggested FIX 1: http://wiki.cytoscape.org/Cytoscape_3/AppDeveloper/Cytoscape_3_App_Cookbook#Embedding_Dependencies Use <Embed-Dependency> > <!-- Generates the OSGi metadata based on the osgi.bnd file. --> > <plugin> > <groupId>org.apache.felix</groupId> > <artifactId>maven-bundle-plugin</artifactId> > <version>2.3.7</version> > <extensions>true</extensions> > <configuration> > <instructions> > <Bundle-SymbolicName>${bundle.symbolicName}</Bundle-SymbolicName> > <Bundle-Version>${project.version}</Bundle-Version> > <Export-Package>${bundle.namespace}</Export-Package> > <Private-Package>${bundle.namespace}.internal.*</Private-Package> > > <Bundle-Activator>${bundle.namespace}.internal.CyActivator</Bundle-Activator> > <!-- <Embed-Dependency>neo4j*;scope=compile|runtime</Embed-Dependency> --> > <!-- <Embed-Transitive>true</Embed-Transitive> --> > </instructions> > </configuration> > </plugin> RESULT: While a neo4j jar is put into the app, the neo4j jar is empty and does not resolve the dependencies. Naive Fix 2: Normally one has to add more than one lib to the eclipse project. So I tried that. > <dependency> > <groupId>org.neo4j</groupId> > <artifactId>neo4j-udc</artifactId> > <version>2.0.0</version> > </dependency> > <dependency> > <groupId>org.neo4j</groupId> > <artifactId>neo4j-kernel</artifactId> > <version>2.0.0</version> > </dependency> > <dependency> > <groupId>org.neo4j</groupId> > <artifactId>neo4j-lucene-index</artifactId> > <version>2.0.0</version> > </dependency> > <dependency> > <groupId>org.neo4j</groupId> > <artifactId>neo4j-graph-algo</artifactId> > <version>2.0.0</version> > </dependency> And so on. Embedding them as suggested in Fix 1 as well. > > <Embed-Dependency>lucene-core,geronimo-jta_1.1_spec,scala-library,neo4j*,parboiled-scala_2.10,parboiled-core,concurrentlinkedhashmap-lru;scope=compile|runtime</Embed-Dependency> All these sources are then included in the jar and when I deploy the app in Cytoscape are recognized. Why does it not fix the problem? Well Cytoscape demands more dependencies. At the point of of it asking for org.apache.ant and javax.jms I stopped. The <Embed-Transitive>true</Embed-Transitive> directive should take care of that. So I am a bit stuck. Does anyone have an idea how to make an Cytoscape 3 App depending on Neo4j? Georg -- 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 neo4j+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.