You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "chennaji9 (via GitHub)" <gi...@apache.org> on 2026/10/09 12:49:46 UTC

[I] [Bug] DLedger quick-start failover hardcodes port 30931 as the Leader, but the Leader is elected dynamically [rocketmq]

chennaji9 opened a new issue, #11334:
URL: https://github.com/apache/rocketmq/issues/11334

   ### Description
   
   The DLedger quick-start failover section (both `docs/cn/dledger/quick_start.md` and `docs/en/dledger/quick_start.md`) hardcodes which node is the Leader:
   
   > 部署成功,杀掉 Leader 之后(在上面的例子中,杀掉端口 30931 所在的进程)…
   > "kill Leader process (as the above example, kill process that binds port 30931)"
   
   Two problems:
   
   1. **The Leader is not fixed.** It is elected by DLedger/Raft at runtime; nothing in the preceding steps guarantees it is the node on port 30931 (broker-n2). A user who kills that process may be killing a follower, observes no leadership switch "about 10 seconds later", and concludes failover is broken.
   2. **The page already provides the right tool.** Two paragraphs above, the same page tells the user to run `mqadmin clusterList` and explains "BID 为 0 的表示 Master" (BID 0 = Master). The failover instruction should build on that instead of a hardcoded port — the configs in `distribution/conf/dledger/` use `listenPort` 30911 / 30921 / 30931 for broker-n0 / n1 / n2.
   
   ### Expected Behavior
   
   The instruction should say: use `clusterList` to identify the current Leader (BID 0), then kill that node's process, noting the three configured ports so users can map the clusterList row to a process; then re-check with `clusterList` to observe the switch.


-- 
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: commits-unsubscribe@rocketmq.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] DLedger quick-start failover hardcodes port 30931 as the Leader, but the Leader is elected dynamically [rocketmq]

Posted by "RockteMQ-AI (via GitHub)" <gi...@apache.org>.
RockteMQ-AI commented on issue #11334:
URL: https://github.com/apache/rocketmq/issues/11334#issuecomment-6110373482

   **Issue Evaluation**
   
   Category: `type/documentation` | Status: **Confirmed**
   
   The DLedger quick-start failover documentation in both `docs/cn/dledger/quick_start.md` and `docs/en/dledger/quick_start.md` hardcodes port 30931 as the Leader, but DLedger/Raft elects the Leader dynamically at runtime. The documentation should instruct users to identify the actual Leader (e.g., via the controller output or log) rather than assuming a fixed port.
   
   **Suggested fix:** Replace the hardcoded port reference with instructions to identify the current Leader from runtime output.
   
   ---
   *Automated evaluation by RocketMQ-AI*


-- 
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: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] DLedger quick-start failover hardcodes port 30931 as the Leader, but the Leader is elected dynamically [rocketmq]

Posted by "RockteMQ-AI (via GitHub)" <gi...@apache.org>.
RockteMQ-AI commented on issue #11334:
URL: https://github.com/apache/rocketmq/issues/11334#issuecomment-6095958116

   **Issue Evaluation**
   
   Category: `type/bug` | Status: **Confirmed**
   
   The DLedger quick-start failover example hardcodes port 30931 as the Leader, but JRaft elects the Leader dynamically. The documentation should reflect dynamic leader election rather than assuming a fixed port.
   
   **Impact:** Documentation accuracy, DLedger quick-start guide
   **Severity:** Low
   
   ---
   *Automated evaluation by RockteMQ-AI*


-- 
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: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org