You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by GitBox <gi...@apache.org> on 2020/04/20 12:58:23 UTC

[GitHub] [kafka] chia7712 commented on a change in pull request #8506: Minor: avoid duplicate unwrapping when end of stream has been reached

chia7712 commented on a change in pull request #8506:
URL: https://github.com/apache/kafka/pull/8506#discussion_r411355668



##########
File path: clients/src/main/java/org/apache/kafka/common/network/SslTransportLayer.java
##########
@@ -293,6 +293,11 @@ public void handshake() throws IOException {
                 updateBytesBuffered(true);
         } catch (SSLException e) {
             maybeProcessHandshakeFailure(e, true, null);
+        } catch (EOFException e) {
+            // it is impossible to complete handshake successfully due to end-of-stream. Hence, it should throw either
+            // EOFException or SslAuthenticationException directly.
+            maybeThrowSslAuthenticationException();
+            throw e;

Review comment:
       @rajinisivaram thanks for the feedback. This optimization is trivial and there is no strong reason for it. So I'm going to close this PR :)




----------------------------------------------------------------
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:
users@infra.apache.org