Commit 22df19d7 authored by Rostislav Vatolin [SLB]'s avatar Rostislav Vatolin [SLB]
Browse files

Merge branch 'upgrade-gremlin' into 'master'

upgrade gremlin to 3.5.0

See merge request !76
parents d2ec7e5b 4bce0acc
Pipeline #40693 passed with stages
in 19 minutes and 2 seconds
......@@ -20,13 +20,15 @@ The following software have components provided under the terms of this license:
- ASM based accessors helper used by json-smart (from )
- Adapter: RxJava (from )
- Admin Directory API directory_v1-rev77-1.22.0 (from )
- Apache Commons BeanUtils (from http://commons.apache.org/proper/commons-beanutils/)
- Apache Commons Codec (from http://commons.apache.org/proper/commons-codec/)
- Apache Commons Codec (from http://commons.apache.org/proper/commons-codec/)
- Apache Commons Collections (from http://commons.apache.org/proper/commons-collections/)
- Apache Commons Configuration (from http://commons.apache.org/configuration/)
- Apache Commons Configuration (from http://commons.apache.org/proper/commons-configuration/)
- Apache Commons Lang (from http://commons.apache.org/proper/commons-lang/)
- Apache Commons Logging (from http://commons.apache.org/proper/commons-logging/)
- Apache Commons Pool (from http://commons.apache.org/proper/commons-pool/)
- Apache Commons Text (from http://commons.apache.org/proper/commons-text/)
- Apache Groovy (from http://groovy-lang.org)
- Apache Groovy (from http://groovy-lang.org)
- Apache Groovy (from http://groovy-lang.org)
......@@ -61,7 +63,6 @@ The following software have components provided under the terms of this license:
- Cloud Storage JSON API v1-rev58-1.21.0 (from )
- Commons IO (from http://commons.apache.org/io/)
- Commons IO (from http://commons.apache.org/io/)
- Commons Lang (from http://commons.apache.org/lang/)
- Converter: Jackson (from )
- Core functionality for the Reactor Netty library (from https://github.com/reactor/reactor-netty)
- Expression Language 3.0 (from https://projects.eclipse.org/projects/ee4j.el)
......@@ -145,8 +146,8 @@ The following software have components provided under the terms of this license:
- Microsoft Azure Java Core Library (from https://github.com/Azure/azure-sdk-for-java)
- Microsoft Azure Netty HTTP Client Library (from https://github.com/Azure/azure-sdk-for-java)
- Microsoft Azure SDK for SQL API of Azure Cosmos DB Service (from https://github.com/Azure/azure-sdk-for-java)
- Mockito (from http://mockito.org)
- Mockito (from http://www.mockito.org)
- Mockito (from http://mockito.org)
- Netty Reactive Streams Implementation (from )
- Netty/All-in-One (from )
- Netty/Buffer (from http://netty.io/)
......@@ -463,7 +464,6 @@ GPL-2.0-only
========================================================================
The following software have components provided under the terms of this license:
- Commons Lang (from http://commons.apache.org/lang/)
- JavaBeans Activation Framework (from )
- javax.annotation-api (from http://jcp.org/en/jsr/detail?id=250)
- tomcat-embed-core (from http://tomcat.apache.org/)
......@@ -523,7 +523,6 @@ LGPL-2.1-only
========================================================================
The following software have components provided under the terms of this license:
- Commons Lang (from http://commons.apache.org/lang/)
- Java Native Access (from https://github.com/java-native-access/jna)
- Java Native Access Platform (from https://github.com/java-native-access/jna)
- Javassist (from http://www.javassist.org/)
......
......@@ -14,7 +14,7 @@
<properties>
<core-lib-azure.version>0.9.0-rc2</core-lib-azure.version>
<gremlin.version>3.4.10</gremlin.version>
<gremlin.version>3.5.0</gremlin.version>
<redisson.version>3.15.3</redisson.version>
<resilience4j.version>1.7.0</resilience4j.version>
<embedded-resdis.version>0.7.1</embedded-resdis.version>
......
......@@ -33,7 +33,7 @@ public class GraphTraversalSourceUtilService {
traversal = traversal.property(entry.getKey(), entry.getValue());
}
}
traversal = traversal.to(graphTraversalSource.V().has(VertexPropertyNames.NODE_ID, addEdgeDto.getToNodeId())
traversal = traversal.to(__.V().has(VertexPropertyNames.NODE_ID, addEdgeDto.getToNodeId())
.has(VertexPropertyNames.DATA_PARTITION_ID, addEdgeDto.getDpOfToNodeId()));
gremlinConnector.addEdge(traversal);
}
......
......@@ -121,7 +121,7 @@ public class ClusterGremlinConnector implements GremlinConnector {
}
private List<Result> submitTraversalAsQueryString(Traversal<?, ?> traversal) {
String query = GroovyTranslator.of(G).translate(traversal.asAdmin().getBytecode());
String query = GroovyTranslator.of(G).translate(traversal.asAdmin().getBytecode()).getScript();
return getResultList(client.submit(query));
}
......
......@@ -84,6 +84,7 @@ public class GraphTraversalSourceUtilServiceTest {
.dpOfToNodeId("dp2")
.dpOfFromNodeId("dp")
.edgeProperties(Collections.singletonMap(EdgePropertyNames.ROLE, Role.OWNER.getValue()))
.edgeLabel("edge-label")
.build();
graphTraversalSourceUtilService.addEdge(addEdgeDto);
......@@ -124,6 +125,7 @@ public class GraphTraversalSourceUtilServiceTest {
.dpOfToNodeId("dp")
.dpOfFromNodeId("dp")
.edgeProperties(Collections.singletonMap(EdgePropertyNames.ROLE, Role.OWNER.getValue()))
.edgeLabel("edge-label")
.build();
graphTraversalSourceUtilService.addEdge(addEdgeDto);
......@@ -162,6 +164,7 @@ public class GraphTraversalSourceUtilServiceTest {
.dpOfToNodeId("dp")
.dpOfFromNodeId("dp")
.edgeProperties(Collections.singletonMap(EdgePropertyNames.ROLE, Role.MEMBER.getValue()))
.edgeLabel("edge-label")
.build();
graphTraversalSourceUtilService.addEdge(addEdgeDto);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment