0

I am using spring-boot to create a rest api. So I am sending data over api which will run 24/7.

I configured cluster, client and GraphTraversalSource with remote connection once. using @Inject annotation.

When the method is called from the controller, I am sending two objects.

User and Movie and craeted pipeline like this.

g.addV("USER").property(T.id,"userid1").addV("MOVIE").property(T.id,"movie1").next()

this stores both vertexes.

Now I call the api again with different user and different movie.

g.addV("USER").property(T.id,"userid2").addV("MOVIE").property(T.id,"movie2").next()

even both vertexes ids are different, I still get error for the "userid1". I don't understand, why I am getting the error for "userid"

org.apache.tinkerpop.gremlin.driver.exception.ResponseException: {"requestId":"965ffcdc-204f-4c2d-989b-108f4f2fd53c","detailedMessage":"Vertex with id already exists: userid1","code":"ConstraintViolationException"}

at org.apache.tinkerpop.gremlin.driver.Handler$GremlinResponseHandler.channelRead0(Handler.java:259) ~[gremlin-driver-3.4.2.jar:3.4.2]

at org.apache.tinkerpop.gremlin.driver.Handler$GremlinResponseHandler.channelRead0(Handler.java:198) ~[gremlin-driver-3.4.2.jar:3.4.2]

at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at org.apache.tinkerpop.gremlin.driver.Handler$GremlinSaslAuthenticationHandler.channelRead0(Handler.java:124) ~[gremlin-driver-3.4.2.jar:3.4.2]

at org.apache.tinkerpop.gremlin.driver.Handler$GremlinSaslAuthenticationHandler.channelRead0(Handler.java:68) ~[gremlin-driver-3.4.2.jar:3.4.2]

at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:102) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:360) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:352) ~[netty-all-4.1.36.Final.jar:4.1.36.Final]

at org.apach
sms_1190
  • 1,267
  • 2
  • 12
  • 24

0 Answers0