neo4j-contrib/neo4j-extensions-dependencies-parent

Name: neo4j-extensions-dependencies-parent

Owner: Neo4j Contrib

Description: parent pom / gradle files for up to date, common joint dependencies for non-conflicting neo4j-extensions and plugins

Created: 2017-01-25 23:12:22.0

Updated: 2017-01-26 01:07:57.0

Pushed: 2017-01-26 01:11:43.0

Homepage: null

Size: 80

Language: null

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Neo4j Extensions

The purpose of this project is to enable better dependency management across to support a higher degree of compatibility for simultaneous plugins deployments.

The primary artifact is the parent pom located in the parent module which is intended to be used by plugin developers as the highest maven parent.

Versioning

This project is version for close alignment with neo4j to ensure compatibility and limit overriding core neo4j jar versions.

Build & Deploy

The default neo4j home directory is:

4j.home>${project.build.directory}/neo4j</neo4j.home>

This is a very useful default for a build server to access jars that need distributed remotely.

To have maven copy build artifacts to your local Neo4j instance, modify your local maven settings with the profiles provides here:

s://github.com/neo4j-contrib/neo4j-extensions-dependencies-parent/blob/master/settings.xml

Update the path to point to your Neo4j home directory:

4j.home>/PATH/TO/NEO4J_HOME</neo4j.home>

To build and deploy jar artifacts simply run:

clean package

The process of building will automatically copy dependencies to ${neo4j.home}/plugins.

REST Configuration

In neo4j-server.properties set:

.unmanaged_extension_classes=org.neo4j.extensions.java=/extensions-java
.unmanaged_extension_classes=org.neo4j.extensions.spring=/extensions-spring

Test Extension Endpoints

Check status of java endpoint:

 -v -X GET http://localhost:7474/extensions-java/status

Create User with indexing off (default is on):

 -v -X POST -H "Accept: application/json" http://localhost:7474/extensions-java/user/create?indexingOn=false

Check status of spring endpoint:

 -v -X GET http://localhost:7474/extensions-spring/status

Create User with indexing off (default is on):

 -v -X POST -H "Accept: application/json" http://localhost:7474/extensions-spring/user/create?indexingOn=false

Test Plugin Endpoints

First, find all the nodes in your database. If you haven't created any friend nodes you should. To find all the nodes (don't do this on large data sets):

 -v -X POST http://localhost:7474/db/data/ext/GetAll/graphdb/get_all_nodes

Is important to use a POST method and NOT a GET. A GET will return details about the endpoint.

Second, find the shortest path between two nodes:

 -v -X POST http://localhost:7474/db/data/ext/ShortestPath/node/{{sourceNodeId}}/shortestPath \
-H "Accept: application/json" -H "Content-type: application/json" \
-d '{"target":"http://localhost:7474/db/data/node/{{targetNodeId}}","depth":"1","types":["FRIEND_OF"]}'

Pay attention to the two variable in the URLs: sourceNodeId - start from this node targetNodeId - find the shortest path to this node types - default is FRIEND_OF (if you created friend nodes above this will work)


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.