You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by yo...@apache.org on 2022/08/01 13:45:01 UTC
[bookkeeper] 15/17: [Client] Deduplicate error log for SSLException (#3320)
This is an automated email from the ASF dual-hosted git repository.
yong pushed a commit to branch branch-4.15
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git
commit 02ca2176057553013dceb73598e156379f52e9ca
Author: Michael Marshall <mm...@apache.org>
AuthorDate: Thu Jun 9 00:08:07 2022 -0500
[Client] Deduplicate error log for SSLException (#3320)
### Motivation
While testing #3310, I noticed that the `PerChannelBookieClient#exceptionCaught` logic contains redundant logs when the exception is an `SSLException`. This PR removes a redundant log from client.
Based on reading through the rest of the method, this should be a trivial change with no other side effects. My one question is how closing a channel and closing the context differ. Technically, returning early skips the `ctx.close()`, which could change the behavior.
### Changes
* Return early to prevent a redundant log
(cherry picked from commit bd827978ca7c72ad74ba5efc014f59aea3e6706c)
---
.../main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java | 1 +
1 file changed, 1 insertion(+)
diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java
index 169307123c..0592378731 100644
--- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java
+++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java
@@ -1297,6 +1297,7 @@ public class PerChannelBookieClient extends ChannelInboundHandlerAdapter {
if (c != null) {
closeChannel(c);
}
+ return;
}
if (cause instanceof IOException) {