Unable to Use Custom Long IDs in JanusGraph: Validity Constraints and Workarounds #4738
Unanswered
MateusMelloSouza
asked this question in
Q&A
Replies: 1 comment 2 replies
-
Please, check the following limitations: https://docs.janusgraph.org/advanced-topics/technical-limitations/#size-limitation When you are creating your Long vertex ID you should follow the following rules:
You was trying to use value I believe we should clarify this in documentation. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm working with JanusGraph and encountering challenges when attempting to use custom Long-type IDs for vertices. Here's a detailed breakdown of my situation:
What I Want to Do:
I aim to add at least 3 billion vertex nodes, each with a unique custom ID of type
Long
, into JanusGraph. My setup includes:The goal is to utilize custom Long IDs to efficiently manage and reference a large number of vertices within this environment.
What I've Done and the Problems Encountered:
Configuration Adjustments:
graph.set-vertex-id=true
in the JanusGraph configuration.cluster.max-partitions
andids.authority.conflict-avoidance-bitwidth
.Adding Vertices with Gremlin:
Successfully added vertices with smaller Long IDs:
Encountered errors when adding certain Long IDs:
Error:
Handling IDs Beyond Long Range:
Attempted to add a vertex with an ID exceeding the
Long
range:Error:
Tried using
graph.getIDManager().toVertexId()
with aBigInteger
:Error:
Used
toVertexId
with along
suffix:Error:
Tried a slightly smaller
Long
:Error:
How Can I Overcome These Issues?
5678
is rejected while2048
and123456
are accepted), what defines a valid Long ID in JanusGraph? Are there hidden constraints or required configurations that I'm missing?cluster.max-partitions
andids.authority.conflict-avoidance-bitwidth
), are there other settings or strategies that can help accommodate the required number of unique Long IDs?Any insights, recommendations, or best practices to resolve these ID-related challenges in JanusGraph would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions