This is an automated email from the ASF dual-hosted git repository.
shoothzj pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git
The following commit(s) were added to refs/heads/master by this push:
new bd827978ca [Client] Deduplicate error log for SSLException (#3320)
bd827978ca is described below
commit bd827978ca7c72ad74ba5efc014f59aea3e6706c
Author: Michael Marshall <[email protected]>
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
---
.../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 35c3c5fb11..f798e8001a 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
@@ -1289,6 +1289,7 @@ public class PerChannelBookieClient extends
ChannelInboundHandlerAdapter {
if (c != null) {
closeChannel(c);
}
+ return;
}
if (cause instanceof IOException) {