I'm currently trying to access an ArangoDB database by using Bulbs and Rexster. I need to do that because I want to use Bulbs (http://bulbflow.com) to launch some gremlin queries from Python. (I really like AQL and arangosh but I already have a lot of working gremlin scripts)
Here is what I did before trying to use Rexster from Bulbs :
I then faced several issues :
1st, (not an Bulbs issue) I didn't succeed in making ArangoDB work correctly with current version of Gremlin (2.4.0) and/or Rexster (2.4.0)
In gremlin 2.4 :
gremlin> import com.tinkerpop.blueprints.impls.arangodb.*
[...]
gremlin> g = ArangoDBGraphFactory.createArangoDBGraph();
==>arangodbgraph[{"_id":"_graphs\/factory_graph","_rev":"20228207","_key":"factory_graph","vertices":"factory_vertices","edges":"factory_edges"}]
gremlin> g.E.count()
Not supported yet.
Display stack trace? [yN]
In bash, while launching Rexster 2.4 :
Exception in thread "main" java.lang.NoSuchFieldError: isRDFModel
at com.tinkerpop.blueprints.impls.arangodb.ArangoDBGraph.<clinit>(ArangoDBGraph.java:44)
at com.tinkerpop.blueprints.impls.arangodb.utils.ArangoDBConfiguration.configureGraphInstance(ArangoDBConfiguration.java:60)
at com.tinkerpop.rexster.config.GraphConfigurationContainer.getGraphFromConfiguration(GraphConfigurationContainer.java:119)
at com.tinkerpop.rexster.config.GraphConfigurationContainer.<init>(GraphConfigurationContainer.java:54)
at com.tinkerpop.rexster.server.XmlRexsterApplication.reconfigure(XmlRexsterApplication.java:99)
at com.tinkerpop.rexster.server.XmlRexsterApplication.<init>(XmlRexsterApplication.java:47)
at com.tinkerpop.rexster.Application.<init>(Application.java:96)
at com.tinkerpop.rexster.Application.main(Application.java:188)
Seing some examples using version 2.2 of both Gremlin and Rexster, I downloaded them and installed again arangodb blueprint driver
This time, it worked in both Gremlin 2.2 and Rexster 2.2 :
BUT, the 2nd issue is that the following Python code :
from bulbs.rexster import Graph
from bulbs.config import Config
config = Config('http://localhost:8182/graphs/arangodb')
g = Graph(config)
returned :
({'status': '500', 'transfer-encoding': 'chunked', 'server': 'grizzly/2.2.18', 'connection': 'close', 'date': 'Wed, 08 Jan 2014 17:30:29 GMT', 'access-control-allow-origin': '*', 'content-type': 'application/json'}, '{"message":"","error":"javax.script.ScriptException: groovy.lang.MissingMethodException: No signature of method: groovy.lang.MissingMethodException.rollback() is applicable for argument types: () values: []\\nPossible solutions: collect(), collect(groovy.lang.Closure), collect(java.util.Collection, groovy.lang.Closure)","api":{"description":"evaluate an ad-hoc Gremlin script for a graph.","parameters":{"rexster.returnKeys":[...]
I don't know how this could be fixed (I'm not a Java programmer, btw)
Here is my env :
Here is my Arango config in rexster.xml (which let me access arangodb from Rexster REST API) :
[...]
<graph>
<graph-name>arangodb</graph-name>
<graph-type>com.tinkerpop.blueprints.impls.arangodb.utils.ArangoDBConfiguration</graph-type>
<properties>
<graph-name>arangodb-rexster-graph</graph-name>
<vertex-name>arangodb-rexster-graph-vertices</vertex-name>
<edge-name>arangodb-rexster-graph-edges</edge-name>
<host>localhost</host>
<port>8529</port>
</properties>
</graph>
[...]
Thanks in advance for any ideas/help :)
I've not used the ArangoDB Blueprints implementation, but you definitely have some versioning issues contributing to the problem. According to the pom, it looks like the 1.0.4-SNAPSHOT works with TinkerPop 2.3.0. I would start by making sure you use Gremlin/Rexster 2.3.0 as a first step to solving this problem. As a second step, make sure that the Rexster is serving properly prior to trying Bulbs. In other words, executing a few scripts through Rexster's Gremlin Extension and validating the results would be a good start to ensuring Bulbs works nicely when you try to connect via Python.
Concerning the rexster 2.4 problem: You can find a 2.4-branch in https://github.com/triAGENS/blueprints-arangodb-graph, that should work with rexster/gremlin 2.4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With