forked from samuel/go-zookeeper
-
Notifications
You must be signed in to change notification settings - Fork 129
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support persistent watches #89
Open
PapaCharlie
wants to merge
4
commits into
go-zookeeper:master
Choose a base branch
from
PapaCharlie:persistent
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PapaCharlie
force-pushed
the
persistent
branch
from
September 28, 2022 23:00
73b390f
to
db9d810
Compare
TestChildWatch was introduced to test what happens when the response is too large for the default allocated buffer size. It used to create 10k nodes which could take a very significant amount of time. The same effect can be achieved with far fewer nodes, significantly speeding up the test's runtime. The test now runs in 5s on my machine instead of sometimes multiple minutes... TestSetWatchers tested something similar, except that it checks that the outgoing setWatchers packet is broken up into multiple packets when it's too large. Using a similar trick we can generate names of specific lengths to test that the behavior is correct. It was also flaky because if your local ZK deployment is a little slow, deleting all the nodes can take longer than the session timeout, spuriously failing the test. This has also been fixed, and the test now runs in a little over 5 seconds as well, instead of failing. Finally, standardize the ZK server version checking to be a bit more flexible and friendlier towards future versions of ZooKeeper (note: the original implementation doesn't even work because the env variable name is incorrect... It `ZK_VERSION`, not `zk_version`)
PapaCharlie
force-pushed
the
persistent
branch
3 times, most recently
from
October 12, 2022 22:30
8c22a55
to
44b3748
Compare
PapaCharlie
force-pushed
the
persistent
branch
2 times, most recently
from
November 17, 2022 00:25
2c221f5
to
70046d1
Compare
PapaCharlie
force-pushed
the
persistent
branch
from
December 2, 2022 22:14
70046d1
to
743abb2
Compare
PapaCharlie
force-pushed
the
persistent
branch
from
December 15, 2022 20:48
743abb2
to
6c30aca
Compare
PapaCharlie
force-pushed
the
persistent
branch
3 times, most recently
from
March 14, 2023 19:26
f726810
to
1e58e2c
Compare
Implements the new persistent watch types introduced in 3.6, along with some utilities that are critical when implementing local caches.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implements the new persistent watch types introduced in 3.6, along with corresponding TreeCache and
NodeCache utilities that try to keep in sync with the remote state.
Depends on #88