RockteMQ-AI commented on issue #10850: URL: https://github.com/apache/rocketmq/issues/10850#issuecomment-5225267690
**Issue Evaluation** Category: `type/bug` | Status: **Confirmed** The issue is valid. Multiple `mqadmin` commands use `(int)(a - b)` comparators for `long` values (consumer lag, tag counts, store timestamps). When the difference exceeds `Integer.MAX_VALUE`, ordering is reversed. **Root Cause:** Subtraction-based `Comparator` narrowing `long` difference to `int` in `consumerProgress`, `printMessageByQueue`, and `queryMsgByUniqueKey`. **Impact:** Admin tools — output ordering is incorrect for large values, misleading operators. **Severity:** low-medium **Recommended fix:** Replace all affected comparators with `Long.compare(a, b)`. An automated fix proposal can be generated. Reply `/approve` to proceed with PR generation. --- *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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
