Skip to content

Commit

Permalink
[ISSUE apache#8599] Fix send fail without retry when get GO_AWAY twice (
Browse files Browse the repository at this point in the history
  • Loading branch information
qianye1001 authored Sep 5, 2024
1 parent 3368c06 commit 0b0f8ec
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,8 @@ public class DefaultMQProducer extends ClientConfig implements MQProducer {
ResponseCode.SYSTEM_BUSY,
ResponseCode.NO_PERMISSION,
ResponseCode.NO_BUYER_ID,
ResponseCode.NOT_IN_CURRENT_UNIT
ResponseCode.NOT_IN_CURRENT_UNIT,
ResponseCode.GO_AWAY
));

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,7 @@ public void assertTotalBatchMaxBytes() throws NoSuchFieldException, IllegalAcces
@Test
public void assertGetRetryResponseCodes() {
assertNotNull(producer.getRetryResponseCodes());
assertEquals(7, producer.getRetryResponseCodes().size());
assertEquals(8, producer.getRetryResponseCodes().size());
}

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,6 +278,7 @@ public void processRequestCommand(final ChannelHandlerContext ctx, final Remotin
"please go away");
response.setOpaque(opaque);
writeResponse(ctx.channel(), cmd, response);
log.info("proxy is shutting down, write response GO_AWAY. channel={}, requestCode={}, opaque={}", ctx.channel(), cmd.getCode(), opaque);
return;
}
}
Expand Down

0 comments on commit 0b0f8ec

Please sign in to comment.