1

How to add dependency for neo4j-spatial in Play! Framework build.scala ?

I as using the following resolver in Build.scala to import Neo4j:

libraryDependencies += "com.github.tuxBurner" %% "play-neo4jplugin" % "1.3.5"

resolvers += "Neo4j" at "http://m2.neo4j.org/content/repositories/releases/"

How should I include Neo4j-Spatial? I want to use something like the following in my Java code:

SpatialDatabaseService spatialService = new SpatialDatabaseService(database);

SpatialDatabaseService is currently unresolved. (I am using Play 2.2.2)

Coding Elements
  • 1,000
  • 10
  • 14

1 Answers1

0

You probably should compile the neo4j Spatial libs for yourself with

git clone git@github.com:neo4j-contrib/spatial.git
cd spatial
mvn install -DskipTests

And then add the neo4j spatial dependencies,

libraryDependencies += "org.neo4j" %% "neo4j-spatial" % "0.13-neo4j-2.1.1"

HTH

Peter Neubauer
  • 6,311
  • 1
  • 21
  • 24
  • Thank you Peter. The following also worked for me... Add the following to **build.sbt** (Change the version to your liking) libraryDependencies += "org.neo4j" % "neo4j-spatial" % "0.13-neo4j-2.0.1" – Coding Elements Jun 27 '14 at 21:04
  • Add resolvers to your **Build.scala**... resolvers += "Open Geo" at "http://repo.opengeo.org/", resolvers += "OS Geo" at "http://download.osgeo.org/webdav/geotools/" ...Note that I am using a plugin from _com.github.tuxBurner_. – Coding Elements Jun 27 '14 at 21:07