shirenchuang opened a new issue, #7232: URL: https://github.com/apache/rocketmq/issues/7232
### Before Creating the Enhancement Request - [X] I have confirmed that this should be classified as an enhancement rather than a bug/feature. ### Summary The defaultMQProducer attribute of MQClientInstance, at present, its function is to use the internal CLIENT_INNER_PRODUCER default producer to send back messages when the consumer fails to consume; But the producer does not need this internal object; resulting in the creation of an internal DefaultMQProducer idle; I hope that the code can be optimized here. If it is a producer client, there is no need to create this internal object or start; MQClientInstance的defaultMQProducer属性,目前看来,它的作用是在 消费者消费失败的时候,用这个内部的CLIENT_INNER_PRODUCER 默认生产者回发消息; 但是生产者却并不需要这个内部对象;导致会多创建一个内部的DefaultMQProducer闲置; 希望这里可以代码优化一下, 如果是生产者客户端的时候, 不需要创建这个内部对象,也不需要start;  下面的几个应该都只是消费者才需要的; The following should only be needed by consumers; ```java // Start pull service this.pullMessageService.start(); // Start rebalance service this.rebalanceService.start(); // Start push service this.defaultMQProducer.getDefaultMQProducerImpl().start(false); ``` ### Motivation 。 ### Describe the Solution You'd Like 。 ### Describe Alternatives You've Considered 。 ### Additional Context _No response_ -- 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]
