apache / incubator-hugegraph

A graph database that supports more than 100+ billion data, high performance and scalability (Include OLTP Engine & REST-API & Backends)
https://hugegraph.apache.org
Apache License 2.0
2.65k stars 518 forks source link

数据量很大,loader报这种问题真的很痛苦? #1321

Closed 597477803 closed 3 years ago

597477803 commented 3 years ago

非ssd hbase+ssd hadoop的后端,10亿节点20亿关系,插入速度估计就每秒几百,好痛苦?改成ssd cassandra是否会好一点?日志如下: java.util.concurrent.CompletionException: class com.baidu.hugegraph.backend.BackendException: Exception in backend at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273) ~[?:1.8.0_251] at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280) [?:1.8.0_251] at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1643) [?:1.8.0_251] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_251] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_251] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_251] Caused by: com.baidu.hugegraph.exception.ServerException: Exception in backend at com.baidu.hugegraph.exception.ServerException.fromResponse(ServerException.java:44) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.client.RestClient.checkStatus(RestClient.java:100) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.rest.RestClient.post(RestClient.java:156) ~[hugegraph-common-1.6.11.jar:1.6.11.0] at com.baidu.hugegraph.rest.RestClient.post(RestClient.java:138) ~[hugegraph-common-1.6.11.jar:1.6.11.0] at com.baidu.hugegraph.api.graph.VertexAPI.create(VertexAPI.java:56) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.driver.GraphManager.addVertices(GraphManager.java:83) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.loader.task.BatchInsertTask.addBatch(BatchInsertTask.java:90) ~[hugegraph-loader-0.10.0.jar:?] at com.baidu.hugegraph.loader.task.BatchInsertTask.run(BatchInsertTask.java:59) ~[hugegraph-loader-0.10.0.jar:?] at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1640) ~[?:1.8.0_251] ... 3 more Caused by: com.baidu.hugegraph.exception.ServerException$ServerCause: java.io.InterruptedIOException 2020-12-29 10:16:47 [batch-worker-7] [ERROR] com.baidu.hugegraph.loader.task.TaskManager [] - Batch insert has been retried more than 0 times 2020-12-29 10:16:47 [batch-worker-7] [WARN ] com.baidu.hugegraph.loader.task.TaskManager [] - Batch insert VERTEX error, try single insert java.util.concurrent.CompletionException: class com.baidu.hugegraph.backend.BackendException: Exception in backend at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:273) ~[?:1.8.0_251] at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:280) [?:1.8.0_251] at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1643) [?:1.8.0_251] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_251] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_251] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_251] Caused by: com.baidu.hugegraph.exception.ServerException: Exception in backend at com.baidu.hugegraph.exception.ServerException.fromResponse(ServerException.java:44) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.client.RestClient.checkStatus(RestClient.java:100) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.rest.RestClient.post(RestClient.java:156) ~[hugegraph-common-1.6.11.jar:1.6.11.0] at com.baidu.hugegraph.rest.RestClient.post(RestClient.java:138) ~[hugegraph-common-1.6.11.jar:1.6.11.0] at com.baidu.hugegraph.api.graph.VertexAPI.create(VertexAPI.java:56) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.driver.GraphManager.addVertices(GraphManager.java:83) ~[hugegraph-client-1.8.0.jar:1.8.0.0] at com.baidu.hugegraph.loader.task.BatchInsertTask.addBatch(BatchInsertTask.java:90) ~[hugegraph-loader-0.10.0.jar:?] at com.baidu.hugegraph.loader.task.BatchInsertTask.run(BatchInsertTask.java:59) ~[hugegraph-loader-0.10.0.jar:?] at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1640) ~[?:1.8.0_251] ... 3 more Caused by: com.baidu.hugegraph.exception.ServerException$ServerCause: java.io.InterruptedIOException

Linary commented 3 years ago

@597477803 这问题应该是hbase自己的写入太慢了导致insert请求超时中断了。你可以参考一下其他关于hbase的issue,比如:https://github.com/hugegraph/hugegraph/issues/1083