17683908932 opened a new issue #2251:
URL: https://github.com/apache/rocketmq/issues/2251
channel.writeAndFlush(request).addListener(new ChannelFutureListener() {
@Override
public void operationComplete(ChannelFuture f) throws
Exception {
if (f.isSuccess()) {
responseFuture.setSendRequestOK(true);
return;
}
requestFail(opaque);
log.warn("send a request command to channel <{}>
failed.", RemotingHelper.parseChannelRemoteAddr(channel));
}
});
question: the method scanResponseTable() has been callback the
responseFuture before f.isSuccess(), scanResponseTable() think the
responseFuture is error or timeout, but responseFuture is success.
suggestion: like requestFail(). from responseTable get it
if (f.isSuccess()) {
responseFuture.setSendRequestOK(true);
return;
}
replace::
if(f.isSuccess()) {
ResponseFuture responseFuture = responseTable.get(opaque);
if (responseFuture != null) {
responseFuture.setSendRequestOK(true);
}
}
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]