horizonzy commented on code in PR #3528:
URL: https://github.com/apache/bookkeeper/pull/3528#discussion_r995273995


##########
bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PacketProcessorBase.java:
##########
@@ -119,12 +121,17 @@ protected void sendResponse(int rc, Object response, 
OpStatsLogger statsLogger)
         }
 
         if (channel.isActive()) {
-            channel.writeAndFlush(response, channel.voidPromise());
+            ChannelPromise promise = channel.newPromise().addListener(future 
-> {
+                if (!future.isSuccess()) {
+                    logger.debug("Netty channel write exception. ", 
future.cause());

Review Comment:
   When this error occurs, it means that the client has already close. Log 
error is unnecessary, the other log will show the connection already close.



-- 
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]

Reply via email to