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

documentation of DataWatcher state transition is misleading regarding auto watch reset on reconnect

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.0.0, 3.0.1
    • 3.1.0
    • documentation
    • None
    • Reviewed

    Description

      the example code has

      case SyncConnected:
      // Everything is happy. Lets kick things off
      // again by checking the existence of the znode
      break;

      this is misleading - it should indicate that the watches are automatically reset and therefor no call to exists is necessary

      also fix this in the same doc (looks like its old detail, no longer valid), indicate that autoreset will happen on reconnect.

      If the client-side ZooKeeper libraries can reestablish the communication channel to ZooKeeper, DataMonitor simply kicks everything off again with the call to ZooKeeper.exists(). If it gets an event for a znode, it calls ZooKeeper.exists() to find out what has changed.

      Attachments

        1. ZOOKEEPER-253.patch
          4 kB
          Patrick D. Hunt

        Activity

          People

            phunt Patrick D. Hunt
            phunt Patrick D. Hunt
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: