vergilyn opened a new issue, #4602: URL: https://github.com/apache/rocketmq/issues/4602
### FEATURE REQUEST #### 1. Please describe the feature you are requesting. 提供一种方式,获取所有在 `ConsumeMessageOrderlyService / ConsumeMessageConcurrentlyService` 中创建的 `consumeExecutor`(ThreadPoolExecutor)。 #### 2. Provide any additional detail on your proposed use case for this feature. 期望:在应用关闭时,能判断是否还有消费任务正在执行(或者等待执行)。 有时在业务需求上,希望强制等到所有消费任务都正常执行完,再关闭应用。 **特别:** 消费逻辑中可能还需要依赖其它资源,参考: - issue#2085: [Support graceful shutdown for push consumer](https://github.com/apache/rocketmq/issues/2085) - pull#2084: [[ISSUE#2085]support graceful shutdown push consumer](https://github.com/apache/rocketmq/pull/2084) 但是,如果通过简单设置`awaitTerminationMillisWhenShutdown`不能达到所有消费任务正常执行完的需求。 #### 3. Indicate the importance of this issue to you (blocker, must-have, should-have, nice-to-have). Are you currently using any workarounds to address this issue? **nice-to-have.** 考虑业务系统中监听 spring `ConextClosedEvent`,但是很难拿到所有的 consumerExecutor's(目前想到的只有反射的方式), 导致无法通过 `ThreadPoolExecutor#isTerminated()` 判断是否提交的任务都执行完成。 #### 4. If there are some sub-tasks using -[] for each subtask and create a corresponding issue to map to the sub task: No -- 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: dev-unsubscr...@rocketmq.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org