You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@zookeeper.apache.org by GitBox <gi...@apache.org> on 2019/11/13 19:34:40 UTC

[GitHub] [zookeeper] eolivelli commented on a change in pull request #1115: ZOOKEEPER-3574: Close quorum socket asynchronously to avoid server sh…

eolivelli commented on a change in pull request #1115: ZOOKEEPER-3574: Close quorum socket asynchronously to avoid server sh…
URL: https://github.com/apache/zookeeper/pull/1115#discussion_r345958735
 
 

 ##########
 File path: zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/Learner.java
 ##########
 @@ -705,12 +712,28 @@ boolean isRunning() {
     }
 
     void closeSocket() {
-        try {
-            if (sock != null) {
+        if (closeSocketAsync) {
+            new Thread(new Runnable() {
 
 Review comment:
   What about giving a meaningful name to the thread and making it a daemon thread?

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


With regards,
Apache Git Services