This is an automated email from the ASF dual-hosted git repository.

lizhimin pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/rocketmq.git


The following commit(s) were added to refs/heads/develop by this push:
     new c1ccc3ce00 [ISSUE #9914] Simplify isolation logic when updating fault 
item in sendKernelImpl (#9915)
c1ccc3ce00 is described below

commit c1ccc3ce008ce04381a3779c5d0d5810cfa4ec06
Author: yx9o <[email protected]>
AuthorDate: Thu Dec 18 20:48:08 2025 +0800

    [ISSUE #9914] Simplify isolation logic when updating fault item in 
sendKernelImpl (#9915)
---
 .../rocketmq/client/impl/producer/DefaultMQProducerImpl.java   | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git 
a/client/src/main/java/org/apache/rocketmq/client/impl/producer/DefaultMQProducerImpl.java
 
b/client/src/main/java/org/apache/rocketmq/client/impl/producer/DefaultMQProducerImpl.java
index b6af66b67b..d0bd064981 100644
--- 
a/client/src/main/java/org/apache/rocketmq/client/impl/producer/DefaultMQProducerImpl.java
+++ 
b/client/src/main/java/org/apache/rocketmq/client/impl/producer/DefaultMQProducerImpl.java
@@ -816,13 +816,9 @@ public class DefaultMQProducerImpl implements 
MQProducerInner {
                         continue;
                     } catch (RemotingException e) {
                         endTimestamp = System.currentTimeMillis();
-                        if (this.mqFaultStrategy.isStartDetectorEnable()) {
-                            // Set this broker unreachable when detecting 
schedule task is running for RemotingException.
-                            this.updateFaultItem(mq.getBrokerName(), 
endTimestamp - beginTimestampPrev, true, false);
-                        } else {
-                            // Otherwise, isolate this broker.
-                            this.updateFaultItem(mq.getBrokerName(), 
endTimestamp - beginTimestampPrev, true, true);
-                        }
+                        // Set this broker unreachable when detecting schedule 
task is running for RemotingException.
+                        // Otherwise, isolate this broker.
+                        this.updateFaultItem(mq.getBrokerName(), endTimestamp 
- beginTimestampPrev, true, !this.mqFaultStrategy.isStartDetectorEnable());
                         log.warn("sendKernelImpl exception, resend at once, 
InvokeID: {}, RT: {}ms, Broker: {}", invokeID, endTimestamp - 
beginTimestampPrev, mq, e);
                         if (log.isDebugEnabled()) {
                             log.debug(msg.toString());

Reply via email to