RockteMQ-AI commented on issue #10515: URL: https://github.com/apache/rocketmq/issues/10515#issuecomment-4709870057
**Issue Evaluation** Category: `type/enhancement` | Status: **Evaluated** **Feasibility:** Feasible **Scope:** `ConsumerOffsetManager`, `PullRequestHoldService`, `TransactionMetricsFlushService` **Compatibility:** No breaking changes — internal caching with same external behavior. Well-motivated with JFR profiling evidence. The three changes are independent and each is low-risk: 1. **ConsumerOffsetManager key caching** — Sound approach. The set of (topic, group) pairs is bounded and stable. Consider using a single `ConcurrentHashMap<String, String>` with a composite key instead of a 2-level map to reduce memory overhead. 2. **PullRequestHoldService buildKey caching** — `String[]` indexed by queueId is efficient. Ensure cache invalidation on topic deletion. 3. **TransactionMetricsFlushService busy-spin fix** — This is actually a **correctness bug** (CPU waste from missing `waitForRunning()` in the else branch). Should be straightforward to fix. The enhancement and bug fix parts could be split into separate PRs for easier review. --- *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]
