kunal
kunal

Reputation: 429

Unable to change graph.set-vertex-id property

I am using JanusGraph embedded in my Java Application, now when I create the graph with the property graph.set-vertex-id=true, it says you should set it using the Management Interface.

JanusGraph graph = JanusGraphFactory.build()
                    .set("storage.backend", "cql")
                    .set("storage.cql.keyspace", "janusgraph_new")
                    .set("storage.hostname", "127.0.0.1")
                    .set("storage.port", "9042").open()

When I try to set it through the management interface like this,

JanusGraphManagement management = graph.openManagement();
management.set("graph.set-vertex-id", true);
management.commit();

It says, Errorjava.lang.IllegalArgumentException: Cannot change the fixed configuration option: root.graph.set-vertex-id

How am I supposed to set this property ?

I have looked at this discussion, https://groups.google.com/g/janusgraph-users/c/JCsnpHMnKeg

but I am not sure how would I restart this embedded JanusGraph ? I have tried to use a new keyspace, still it fails with the same error.

I have gone through the answer, Janusgraph doesn't allow to set vertex Id even after setting this property `graph.set-vertex-id=true`

but I am not sure if I am using embedded JanusGraph, then how can I start a new cluster ?

I am using the dependency,

<dependency>
      <groupId>org.janusgraph</groupId>
      <artifactId>janusgraph-core</artifactId>
      <version>0.6.3</version>
</dependency>

Upvotes: 2

Views: 69

Answers (1)

Boxuan Li
Boxuan Li

Reputation: 373

Please upgrade to JanusGraph 1.0.0. Prior to 1.0.0, "graph.set-vertex-id" was a fixed option that cannot be altered.

Upvotes: 3

Related Questions