Skip to content

Commit

Permalink
Adapt hugegraph-client 1.6.9 and upgrade some vulnerable dependencies (
Browse files Browse the repository at this point in the history
  • Loading branch information
Linary authored and zhoney committed Mar 22, 2019
1 parent 19671ee commit eedcf87
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 23 deletions.
11 changes: 3 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,10 @@
<compiler.target>1.8</compiler.target>
<log4j2.version>2.8.2</log4j2.version>
<junit.version>4.12</junit.version>
<hugegraph.client.version>1.6.9</hugegraph.client.version>
<guava.version>21.0</guava.version>
<commons.lang3.version>3.6</commons.lang3.version>
<tomcat.version>8.5.2</tomcat.version>
<tomcat.version>8.5.34</tomcat.version>
<spring.version>4.1.5.RELEASE</spring.version>
</properties>

Expand All @@ -36,19 +37,14 @@
<dependency>
<groupId>com.baidu.hugegraph</groupId>
<artifactId>hugegraph-client</artifactId>
<version>1.6.4</version>
<version>${hugegraph.client.version}</version>
</dependency>

<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
<version>${tomcat.version}</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-logging-juli</artifactId>
<version>${tomcat.version}</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-jasper</artifactId>
Expand All @@ -70,7 +66,6 @@
<version>${tomcat.version}</version>
</dependency>
</dependencies>

</dependencyManagement>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ private QueryResult queryAdjacentVertices(Board board, HugeClient client,
List<Edge> edges = queryResult.getGraph().getEdges();
vertices.forEach(v -> vertexIds.add(v.id()));
edges.forEach(e -> {
if (e.source().equals(transformedVertexId) ||
e.target().equals(transformedVertexId)) {
if (e.sourceId().equals(transformedVertexId) ||
e.targetId().equals(transformedVertexId)) {
visitedEdgeIds.add(e.id());
}
});
Expand Down Expand Up @@ -519,8 +519,8 @@ private List<Vertex> getVertexFromEdge(HugeClient client,
}
Set<Object> vertexIds = new HashSet<>();
edges.forEach(e -> {
vertexIds.add(e.source());
vertexIds.add(e.target());
vertexIds.add(e.sourceId());
vertexIds.add(e.targetId());
});
return getVertices(client, new ArrayList<>(vertexIds));

Expand Down Expand Up @@ -567,8 +567,8 @@ private List<Edge> getEdgeFromVertex(HugeClient client,
* vertexIds. Hence, just reserve the edge which that
* the target in the set of vertexIds.
*/
Object target = edge.target();
Object source = edge.source();
Object target = edge.targetId();
Object source = edge.sourceId();
if (vertexIds.contains(target) &&
vertexIds.contains(source)) {
Integer count = edgesNumPerVertex.get(source);
Expand Down Expand Up @@ -640,8 +640,8 @@ private List<Vertex> getVertexFromPath(HugeClient client,
vertexIds.add(vertex.id());
} else if (obj instanceof Edge) {
Edge edge = (Edge) obj;
vertexIds.add(edge.source());
vertexIds.add(edge.target());
vertexIds.add(edge.sourceId());
vertexIds.add(edge.targetId());
}
}));
return getVertices(client, new ArrayList<>(vertexIds));
Expand Down
4 changes: 0 additions & 4 deletions studio-dist/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-logging-juli</artifactId>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-jasper</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ vertex.vis.scaling.max=30
vertex.vis.shape=dot
vertex.vis.color=[\
{"default":"#ED5736","hover":"#312520","highlight":"#ED5736"},\
{"default":"#48C0A3","hover":"#312520","highlight":"#48C0A3"},\
{"default":"#F47983","hover":"#312520","highlight":"#F47983"},\
{"default":"#4C8DAE","hover":"#312520","highlight":"#4C8DAE"},\
{"default":"#FF8C31","hover":"#312520","highlight":"#FF8C31"},\
{"default":"#F47983","hover":"#312520","highlight":"#F47983"},\
{"default":"#48C0A3","hover":"#312520","highlight":"#48C0A3"},\
{"default":"#3B2E7E","hover":"#312520","highlight":"#3B2E7E"},\
{"default":"#60281E","hover":"#312520","highlight":"#60281E"},\
{"default":"#B36D61","hover":"#312520","highlight":"#B36D61"},\
Expand Down
2 changes: 1 addition & 1 deletion studio-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"style-loader": "^0.18.1",
"url-loader": "^0.5.8",
"webpack": "^2.6.0",
"webpack-dev-server": "^2.5.1",
"webpack-dev-server": "^3.1.11",
"whatwg-fetch": "^2.0.3"
},
"dependencies": {
Expand Down

0 comments on commit eedcf87

Please sign in to comment.