How to specify clustering key in Gremlin Vertex

9 views
Skip to first unread message

Praveen Banthia

unread,
Sep 17, 2023, 9:27:56 PM9/17/23
to Gremlin-users
Hi,
Just started playing with gremlin via Janus graph in java backed by cassandra. One thing I notice is that I create a vertex e.g 
Label: Country
Properties
    name: 'USA'
I see that duplicates are being generated . Is gremlin how do I indicate that a subset of properties are the unique key and if they need to be updated if they are passed in multiple times.

Stephen Mallette

unread,
Sep 20, 2023, 6:17:17 AM9/20/23
to gremli...@googlegroups.com
Gremlin doesn't have knowledge of the graph's schema so it doesn't apply any sort of uniqueness constraints on properties. It's up to you to handle that sort of thing yourself or it is delegated to the features of the underlying graph database. There are some capabilities with JanusGraph that allow for uniqueness using its indexing functions: 



--
You received this message because you are subscribed to the Google Groups "Gremlin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gremlin-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/be700480-f8e7-45fd-b0f4-dc6314a672c6n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages