mklzl opened a new issue, #1918:
URL: https://github.com/apache/incubator-hugegraph/issues/1918

   ### Bug Type (问题类型)
   
   others (please edit later)
   
   ### Before submit
   
   - [X] 我已经确认现有的 [Issues](https://github.com/hugegraph/hugegraph/issues) 与 
[FAQ](https://hugegraph.github.io/hugegraph-doc/guides/faq.html) 中没有相同 / 重复问题
   
   ### Environment (环境信息)
   
   - Server Version: v0.12
   - Backend: hbase
   - OS:  Centos 7.6
   - Data Size:  100W Vertex
   
   ### Expected & Actual behavior (期望与实际表现)
   
   ## java code :
   
       HugeGraphSink ==> invoke(String value, Context context) 
   
   
       Vertex afterVertex = new Vertex("用户").property("用户ID", 
after_friend_user_id_str)
                       .property("姓名", after_friend_name)
                       .property("头像", after_friend_head);
   
   
               Vertex afterSourceVertex = new Vertex("用户").property("用户ID", 
after_baseId)
                       .property("姓名", "未知")
                       .property("头像", "未知");
   
   
               Edge edge = new 
Edge("关注").source(afterSourceVertex).target(afterVertex);
   
   
               graph.addVertex(afterVertex);
   
               graph.addVertex(afterSourceVertex);
   
               graph.addEdge(edge);
   
   ##    Expected:
   
        Vertex  and  edge  add successful
   
   ## Actual :
   
       Vertex  and edge add error 
   
   ## Solution:
   
       change fastjson version from  1.2.75   to 1.2.28  #5
   
   ## There are still problems:
   
       edge add error
   
   ##  Error info:
   
       Caused by: com.baidu.hugegraph.exception.ServerException: Expect source 
vertex id
        at 
com.baidu.hugegraph.exception.ServerException.fromResponse(ServerException.java:47)
 ~[hugegraph-client-2.0.1.jar:2.0.1.0]
        at 
com.baidu.hugegraph.client.RestClient.checkStatus(RestClient.java:93) 
~[hugegraph-client-2.0.1.jar:2.0.1.0]
        at 
com.baidu.hugegraph.rest.AbstractRestClient.post(AbstractRestClient.java:231) 
~[hugegraph-common-2.0.1.jar:2.0.1.0]
        at 
com.baidu.hugegraph.rest.AbstractRestClient.post(AbstractRestClient.java:205) 
~[hugegraph-common-2.0.1.jar:2.0.1.0]
        at com.baidu.hugegraph.api.graph.EdgeAPI.create(EdgeAPI.java:50) 
~[hugegraph-client-2.0.1.jar:2.0.1.0]
        at 
com.baidu.hugegraph.driver.GraphManager.addEdge(GraphManager.java:217) 
~[hugegraph-client-2.0.1.jar:2.0.1.0]
        at sink.HugeGraphSink.invoke(HugeGraphSink.java:69) ~[classes/:?]
        at sink.HugeGraphSink.invoke(HugeGraphSink.java:12) ~[classes/:?]
        at 
org.apache.flink.streaming.api.operators.StreamSink.processElement(StreamSink.java:54)
 ~[flink-streaming-java_2.11-1.13.5.jar:1.13.5]
        at 
org.apache.flink.streaming.runtime.tasks.CopyingChainingOutput.pushToOperator(CopyingChainingOutput.java:71)
 ~[flink-streaming-java_2.11-1.13.5.jar:1.13.5]
        ... 15 more
   
   ### Vertex/Edge example (问题点 / 边数据举例)
   
   ```javascript
   target 用户ID: 24687777
       target 姓名: Pernille Vermund
       target 头像: /xxxx/xxxx/xxx/28/0A/xxxx.jpg
   
       source 用户ID: 1015524717040
       source 姓名: 未知
       source 头像: 未知
   ```
   
   
   ### Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)
   
   ```javascript
   schema.vertexLabel("用户").properties("用户ID", "姓名", 
"头像").primaryKeys("用户ID").ifNotExist().create();
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to