Github user sohami commented on a diff in the pull request:
https://github.com/apache/drill/pull/950#discussion_r140623048
--- Diff:
exec/java-exec/src/main/java/org/apache/drill/exec/rpc/user/UserClient.java ---
@@ -102,19 +115,78 @@
// these are used for authentication
private volatile List<String> serverAuthMechanisms = null;
private volatile boolean authComplete = true;
+ private SSLConfig sslConfig;
+ private Channel sslChannel;
--- End diff --
I don't think you have to store the sslChannel reference explicitly here to
make sure it's closed. The connection wrapper like AbstractRemoteConnection
will already have reference to channel object and will take care of closing it.
Also that path is taking care of channel close both in graceful (explicitly
close being called on client) and failure scenario (in which case Netty
channelClosedHandler will be invoked).
Same for server side.
---