Michael Hunger wrote: > > What one could do at a lower level is to create operations like > db.obtainUniqueNode(Map properties,String...idProperties); > node.obtainUniqueRelationship(dir, type, props, String...idProperties); > node.obtainUniqueRelationship(dir, type, targetNode, props, > String...idProperties); > > which handle the lock, index lookup and property-update in one go. > > That operation can be exposed on the REST layer. >
Hi Michael - Yes, ultimately you would have a "create or update" REST endpoint that would do something like that. BTW I re-read my previous post and realized I may have jumped from discussing the unique index to the "create or update" endpoint in a confusing way so let me clarify: On Rexster and/or Neo4j Server, there would be a "create or update" endpoint that does a silent update if the node already exists. The question then would be is how do you enforce the unique property on operations that don't use the endpoint and how do you (potentially) allow for versioning of the node. - James -- View this message in context: http://neo4j-community-discussions.438527.n3.nabble.com/Are-Unique-Indices-in-the-Works-tp3229971p3231501.html Sent from the Neo4j Community Discussions mailing list archive at Nabble.com. _______________________________________________ Neo4j mailing list User@lists.neo4j.org https://lists.neo4j.org/mailman/listinfo/user