GitHub user athanatos opened a pull request: https://github.com/apache/bookkeeper/pull/193
BOOKKEEPER-1086: ZkUnderreplicationManager cache watcher Previously, getLedgerToReplicate left watches each time it traversed the tree until it found a suitable replication target. Since we don't have a way of canceling watches, these watches tended to get abandoned, particularly on interior nodes, which aren't changed much. Thus, over time, some nodes would build up a very large number of watch. Instead, introduce a caching mechanism to remember outstanding watches and avoid ever creating two watches on the same node. Author: Samuel Just <sj...@salesforce.com> You can merge this pull request into a Git repository by running: $ git pull https://github.com/athanatos/bookkeeper forupstream/BOOKKEEPER-1098 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/bookkeeper/pull/193.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #193 ---- commit cb3c7a2f4e256de00268740c37fc2a2ecd9b4e31 Author: Samuel Just <sj...@salesforce.com> Date: 2017-03-29T19:06:56Z BOOKKEEPER-1086: ZkUnderreplicationManager cache watcher Previously, getLedgerToReplicate left watches each time it traversed the tree until it found a suitable replication target. Since we don't have a way of canceling watches, these watches tended to get abandoned, particularly on interior nodes, which aren't changed much. Thus, over time, some nodes would build up a very large number of watch. Instead, introduce a caching mechanism to remember outstanding watches and avoid ever creating two watches on the same node. Author: Samuel Just <sj...@salesforce.com> ---- --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---