imbajin opened a new issue, #2999:
URL: https://github.com/apache/hugegraph/issues/2999

   ### Bug Type (问题类型)
   
   server status (启动/运行异常)
   
   ### Before submit
   
   - [x] 我已经确认现有的 [Issues](https://github.com/apache/hugegraph/issues) 与 
[FAQ](https://hugegraph.apache.org/docs/guides/faq/) 中没有相同 / 重复问题
   
   ### Environment (环境信息)
   
   - Server Version: 1.7.0 (latest master)
   - Backend: RocksDB (standalone, default)
   - OS: macOS / Linux (Docker)
   - Image: `hugegraph/hugegraph:latest` built from 
`hugegraph-server/Dockerfile`
   
   ### Expected & Actual behavior (期望与实际表现)
   
   **Expected:** 使用 `hugegraph-server/Dockerfile` 构建的单机版镜像,`docker run` 
后应直接启动成功,可正常使用。
   
   **Actual:** 服务启动后(HTTP 已监听 8080),持续打印 `Waiting for partition assignment...` 
约 120 秒才超时结束:
   
   
![image](https://github.com/user-attachments/assets/waiting-partition-screenshot)
   
   ```
   INFO: Started listener bound to [0.0.0.0:8080]
   INFO: [HttpServer] Started.
   Started [pid 1017]
   Waiting for partition assignment...
   Waiting for partition assignment...
   Waiting for partition assignment...
   Waiting for partition assignment...
   Waiting for partition assignment...
   ```
   
   **Root Cause:**
   
   PR #2952 (`0154c064`) 重构 docker-compose 时,在 `docker-entrypoint.sh` 
中**无条件**添加了 `wait-partition.sh` 调用:
   
   ```bash
   # Line 84-90 in docker-entrypoint.sh
   STORE_REST="${STORE_REST:-store:8520}"
   export STORE_REST
   ./bin/start-hugegraph.sh -j "${JAVA_OPTS:-}" -t 120
   ./bin/wait-partition.sh || log "WARN: partitions not assigned yet"
   ```
   
   `wait-partition.sh` 会轮询 `http://store:8520` 查找 `"partitionCount":[1-9]` —— 
这仅在 hstore 分布式模式下有意义。单机 rocksdb 模式下没有 Store 服务,因此循环 120 秒后超时。
   
   对比 `wait-storage.sh` 则正确地做了判断:当没有设置 hstore 相关环境变量时会跳过等待。
   
   ### Vertex/Edge example (问题点 / 边数据举例)
   
   _N/A - this is a Docker startup issue, not a data issue._
   
   ### Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)
   
   _N/A_


-- 
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