Uploaded image for project: 'ZooKeeper'
  1. ZooKeeper
  2. ZOOKEEPER-4525

Thread leaks occur when resolve address failed.

VotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • 3.6.3
    • None
    • java client
    • None

    Description

      In version 3.6. When connecting zookeeper using domain name with Netty. If the domain name failed to resolve, calling Zookeeper::close cannot close the EventThread. It will cause thread leaks.

       

      When resolve address failed, the connect thread in ClientCnxn throws an UnknownHostException. ClientCnxnSocketNetty.firstConnect has not been initialized.

       

      When the close method is called, it calls firstConnect.countDown().It will throw a NullPointerException and the thread cannot be closed properly.

       

       

      Attachments

        1. stacktrace.txt
          8 kB
          houshuai

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            houshuai houshuai
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment