1

I am building a web application where users are creating graph data. This data is stored in arangodb after a while, after several documents and relations between new and existing documents have been created in the application.

What would be the best way to handle the creation of key/id in that case?

Can I rely on some client-side ID generation algorithm ( any recommended?) or is it possible to 'book' a set of generated keys from ArangoDB before the creation of those new documents/relations on the client?

Thanks !

Salavat2
  • 63
  • 6

1 Answers1

1

You can use a separate collection in ArangoDB; You save document into it and fetch the id afterwards.

You could also write a simple Foxx service doing that for you

Otoh, there are reliable client side id generators available

Community
  • 1
  • 1
dothebart
  • 5,972
  • 16
  • 40