0

I'm using AWS Neptune with nodejs gremlin driver. I'm sending gremlin queries that include a bunch of operations like addV, addE, etc in the same query.
Once in a while I see situations where only part of the query was executed.
For example, sending two addV but only one was created.
I was wondering if Neptune provides a "transaction" behavior for a single gremlin query sent to the server, or it is normal that only part of it is executed?

Avner Levy
  • 6,601
  • 9
  • 53
  • 92
  • Hey, how did you verify if the asked vertex were created ? by the response you got or by explicitly querying? So if you chain 2 addV then it ll return you the last vertex created, but would have created both. If you query individually and find asked vertex wasn't created, please reach out to AWS Customer support. – PrashantUpadhyay Dec 27 '21 at 18:13
  • I've checked it by querying afterward. – Avner Levy Dec 27 '21 at 19:03
  • Each query is treated as a single ACID transaction and will either commit or fully rollback should any part of the query fail. There is one case where you might see something that appears to be a partial create - namely if you try to create a vertex with an existing ID but add an additional label. Are you able to edit the question to share an example of a query that exhibits the behavior you are describing? – Kelvin Lawrence Dec 27 '21 at 20:17

0 Answers0