apache / rocketmq

Apache RocketMQ is a cloud native messaging and streaming platform, making it simple to build event-driven applications.
https://rocketmq.apache.org/
Apache License 2.0
21.19k stars 11.67k forks source link

[Bug] rocketmq-spring自定义sendMessageHook的sendMessageAfter被执行多次 #7519

Open dousp opened 12 months ago

dousp commented 12 months ago

Before Creating the Bug Report

Runtime platform environment

win & centos7

RocketMQ version

JDK Version

jdk8

Describe the Bug

发送异步数据时发现z自定义hook中的方法被调用多次,打印了多次日志

Steps to Reproduce

rocketMQTemplate.asyncSend(....)

What Did You Expect to See?

没有重复调用的日志

What Did You See Instead?

出现了重复调用打印的日志

Additional Context

讨论

drpmma commented 11 months ago

Maybe it is more appropriate to address this issue in rocketmq-spring repo.

dousp commented 11 months ago

Maybe it is more appropriate to address this issue in rocketmq-spring repo.

MQClientAPIImpl and DefaultMQProducerImpl belong to rocketmq-client-x.x.x.jar

Do you think rocketmq-spring repo will care about this when it comes to integration???

I have time to read the source code carefully, it may not be so simple, anyway, if there is an official check here, I think it is worth it.

leizhiyuan commented 8 months ago

see https://github.com/apache/rocketmq/discussions/7518