[Bug] 使用cassandra作为后端,持久化配置后,容器重建无法完全加载
- Dominant language
- Java
- Stars
- 3.2k
- Forks
- 636
- Avg merge
- 3d 11h
- Merged PRs (30d)
- 14
Description
### Bug Type (问题类型)
server status (启动/运行异常)
### Before submit
- [X] 我已经确认现有的 [Issues](https://github.com/apache/hugegraph/issues) 与 [FAQ](https://hugegraph.apache.org/docs/guides/faq/) 中没有相同 / 重复问题 (I have confirmed and searched that there are no similar problems in the historical issue and documents)
### Environment (环境信息)
- Server Version: 1.5.0
- Backend: cassandra 4
- OS: docker
- Data Size: 100以内
### Expected & Actual behavior (期望与实际表现)
2024-12-24 07:20:12 [main] [INFO] o.a.h.c.GraphManager - Graph 'hugegraph2' was successfully configured via './conf/graphs/hugegraph2.properties'
2024-12-24 07:20:12 [main] [INFO] o.a.h.c.GraphManager - Graph 'hugegraph' was successfully configured via './conf/graphs/hugegraph.properties'
2024-12-24 07:20:12 [main] [INFO] o.a.h.c.GraphManager - RpcServer is not enabled, skip starting rpc service
2024-12-24 07:20:12 [main] [INFO] o.a.h.c.GraphManager - RpcServer is not enabled, skip wait graphs ready
2024-12-24 07:20:12 [main] [INFO] o.a.h.c.GraphManager - Check backend version
2024-12-24 07:20:12 [main] [ERROR] o.a.h.b.s.BackendStoreInfo - The backend driver version '1.11' is inconsistent with the data version 'null' of backend store for graph 'hugegraph2'
2024-12-24 07:20:12 [main] [INFO] o.a.h.StandardHugeGraph - Close graph standardhugegraph[hugegraph]
2024-12-24 07:20:18 [main] [INFO] o.a.h.StandardHugeGraph - Close graph standardhugegraph[hugegraph2]
2024-12-24 07:20:24 [main] [ERROR] o.a.h.d.HugeGraphServer - HugeRestServer start error:
org.apache.hugegraph.backend.BackendException: The backend store version is inconsistent
at org.apache.hugegraph.core.GraphManager.checkBackendVersionOrExit(GraphManager.java:456) ~[hugegraph-api-1.5.0.jar:0.71.0.0]
at org.apache.hugegraph.core.GraphManager.init(GraphManager.java:124) ~[hugegraph-api-1.5.0.jar:0.71.0.0]
at org.apache.hugegraph.server.ApplicationConfig$GraphManagerFactory$1.onEvent(ApplicationConfig.java:143) ~[hugegraph-api-1.5.0.jar:0.71.0.0]
at org.glassfish.jersey.server.internal.monitoring.CompositeApplicationEventListener.onEvent(CompositeApplicationEventListener.java:49) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.server.internal.monitoring.MonitoringContainerListener.onStartup(MonitoringContainerListener.java:56) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.server.ApplicationHandler.onStartup(ApplicationHandler.java:711) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.start(GrizzlyHttpContainer.java:330) ~[jersey-container-grizzly2-http-3.0.3.jar:?]
at org.glassfish.grizzly.http.server.HttpHandlerChain.start(HttpHandlerChain.java:376) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at org.glassfish.grizzly.http.server.HttpServer.setupHttpHandler(HttpServer.java:268) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at org.glassfish.grizzly.http.server.HttpServer.start(HttpServer.java:245) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at org.apache.hugegraph.server.RestServer.start(RestServer.java:70) ~[hugegraph-api-1.5.0.jar:0.71.0.0]
at org.apache.hugegraph.server.RestServer.start(RestServer.java:177) ~[hugegraph-api-1.5.0.jar:0.71.0.0]
at org.apache.hugegraph.dist.HugeRestServer.start(HugeRestServer.java:31) ~[hugegraph-dist-1.5.0.jar:1.5.0]
at org.apache.hugegraph.dist.HugeGraphServer.(HugeGraphServer.java:61) ~[hugegraph-dist-1.5.0.jar:1.5.0]
at org.apache.hugegraph.dist.HugeGraphServer.main(HugeGraphServer.java:127) ~[hugegraph-dist-1.5.0.jar:1.5.0]
2024-12-24 07:20:24 [main] [INFO] o.a.h.HugeFactory - HugeFactory shutdown
2024-12-24 07:20:24 [hugegraph-shutdown] [INFO] o.a.h.HugeFactory - HugeGraph is shutting down
t(RestServer.java:70)
at org.apache.hugegraph.server.RestServer.start(RestServer.java:177)
at org.apache.hugegraph.dist.HugeRestServer.start(HugeRestServer.java:31)
at org.apache.hugegraph.dist.HugeGraphServer.(HugeGraphServer.java:61)
at org.apache.hugegraph.dist.HugeGraphServer.main(HugeGraphServer.java:127)
### Docker Compose 配置
```
version: "3"
services:
server:
image: hugegraph/hugegraph
container_name: cas-server
ports:
- 8080:8080
restart: always
environment:
hugegraph.gremlin.graph: org.apache.hugegraph.HugeFactory
hugegraph.backend: cassandra
hugegraph.serializer: cassandra
hugegraph.cassandra.host: cas-cassandra
hugegraph.cassandra.port: 9042
PASSWORD: ABCD123
volumes:
- ./hugegraph/conf:/hugegraph-server/conf/graphs
networks:
- ca-network
depends_on:
- cassandra
healthcheck:
test: ["CMD", "bin/gremlin-console.sh", "--" ,"-e", "scripts/remote-connect.groovy"]
interval: 10s
timeout: 30s
retries: 3
cassandra:
image: cassandra:4
container_name: cas-cassandra
ports:
- 7000:7000
- 9042:9042
restart: always
security_opt:
- seccomp:unconfined
volumes:
- ./cassandra/config/cassandra.yaml:/etc/cassandra/cassandra.yaml
- ./cassandra/data:/var/lib/cassandra
networks:
- ca-network
healthcheck:
test: ["CMD", "cqlsh", "--execute", "describe keyspaces;"]
interval: 10s
timeout: 30s
retries: 5
#loader:
# image: hugegraph/loader
# container_name: hugegraph_loader
# restart: always
# volumes:
# - /root/hugegraph/hugegraph-dataset:/loader/dataset
# networks:
# - ca-network
hubble:
image: hugegraph/hubble
container_name: hugegraph_hubble
ports:
- 8088:8088
restart: always
networks:
- ca-network
networks:
ca-network:
```
Contributor guide
Assessment
This issue has not been assessed yet.