On Thursday, December 8, 2011 2:48:59 AM UTC-6, Dmytrii Nagirniak wrote: Unfortunately I couldn't see a lot of value in the REST API either. The core operations that are taken for granted with native bindings (traversals using poor Ruby constructs) would require to execute HTTP request (that's what SELECT N+1 in SQL world is). Or otherwise I would have to wrap all the logic in the traversal queries. It would significantly overcomplicate the system with HTTP handling logic.
Hi Dmytrii - Neo4j Server has a built-in Gremlin scripting engine that enables REST clients to execute transactions in a single HTTP request. Gremlin is a domain-specific language for graphs written in Groovy. If you were using a relational database, you would use its domain-specific language, which is SQL. Same idea. For the last few weeks, I have been working on Bulbs 0.3, which is a Python REST client for Neo4j Server, and it has a library of Gremlin templates in a YAML file. The Python methods do named variable substitution on the Gremlin templates and then execute them via the Neo4j Server Gremlin extension. Here's an example: gremlin.yaml https://gist.github.com/1450859 element.py https://gist.github.com/1450871 You can see the create_indexed_vertex Gremlin script has JSON args. Python lists and dicts are converted to JSON, and then on the server side, the Gremlin script converts them into Groovy maps and lists. Marko is working on adding the JSONSlurper library import to Gremlin so you won't have to do the import each time (https://github.com/tinkerpop/gremlin/issues/259). > So I decided to write another REST library > (http:://github.com/dnagir/morpheus), > but then gave up realising that you just cannot have a proper abstraction > over HTTP. > (I'll probably kill off that repo). Groovy is pretty simple. Consider reviving Morpheus and using Gremlin for scripting -- you'll get all the power of native Ruby and Neo4j without the Java. When Bulbs 0.3 is released, I'll post the full gremlin.yaml, and you should be able to use it in Ruby without any mods since it's just YAML. - James -- View this message in context: http://neo4j-community-discussions.438527.n3.nabble.com/Neo4j-Feedback-after-evaluation-tp3569774p3572548.html Sent from the Neo4j Community Discussions mailing list archive at Nabble.com. _______________________________________________ NOTICE: THIS MAILING LIST IS BEING SWITCHED TO GOOGLE GROUPS, please register and consider posting at https://groups.google.com/forum/#!forum/neo4j Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user