Uploaded image for project: 'Apache Curator'
  1. Apache Curator
  2. CURATOR-164

curator-x-discovery: unregisterService is not guaranteed to remove the service, due to reconnectListener concurrency issue

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • 2.7.0
    • 2.8.0
    • Framework
    • None

    Description

      In ServiceDiscoveryImpl:
      When unregistering a service, the reconnect listener might fire while deleting the path.
      This can cause a condition where the delete finishes successfully, the service is removed from services, and then the reRegisterServices completes successfully and the service is added back in ZK and in services, end result being that the service was not removed, even though unregisterService did not throw any exceptions.

      Essentially the use of the internal 'services' cache makes for a nightmare of concurrency issues. I put this as critical as the library it's really not usable IMO.

      Attachments

        Issue Links

          Activity

            People

              randgalt Jordan Zimmerman
              rbp.tradeshift Rasmus Berg Palm
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: