-
Notifications
You must be signed in to change notification settings - Fork 7.2k
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
ZOOKEEPER-4479: C tests: Avoid some jitter which results in flaky tests #1827
Closed
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
…itter Without this, the actual result depends on the time elapsed between the initialization of the time mock and the call to forceConnected.
eolivelli
approved these changes
Mar 1, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great!
eolivelli
pushed a commit
that referenced
this pull request
Mar 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes #1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations (cherry picked from commit 640b6dd) Signed-off-by: Enrico Olivelli <eolivelli@apache.org>
eolivelli
pushed a commit
that referenced
this pull request
Mar 11, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes #1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations (cherry picked from commit 640b6dd)
rahulrane50
pushed a commit
to rahulrane50/zookeeper
that referenced
this pull request
Sep 26, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Oct 31, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
added a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Oct 31, 2022
…ts (#14) With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations Co-authored-by: Damien Diederen <ddiederen@apache.org>
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Oct 31, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Oct 31, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
added a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Oct 31, 2022
…ts (#16) With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations Co-authored-by: Damien Diederen <ddiederen@apache.org>
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
added a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
…ts (#28) With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations Co-authored-by: Damien Diederen <ddiederen@apache.org>
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
pushed a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anuragmadnawat1
added a commit
to anuragmadnawat1/zookeeper
that referenced
this pull request
Nov 1, 2022
…ts (#42) With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations Co-authored-by: Damien Diederen <ddiederen@apache.org>
anurag-harness
pushed a commit
to anurag-harness/zookeeper
that referenced
this pull request
Jan 13, 2023
With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations
anurag-harness
added a commit
to anurag-harness/zookeeper
that referenced
this pull request
Jan 13, 2023
…ts (#9) With these commits, the various tests in `TestOperations.cc` set the `last_sent` and `last_recv` fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock). When that value is not specified, these fields get set to the "real" time at the end of the `forceConnected` function, which can be sufficiently different from the value held in the mock for some of the tests to fail. Author: Damien Diederen <ddiederen@apache.org> Reviewers: Enrico Olivelli <eolivelli@apache.org> Closes apache#1827 from ztzg/ZOOKEEPER-4479-flaky-c-test-operations Co-authored-by: Damien Diederen <ddiederen@apache.org>
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.
With these commits, the various tests in
TestOperations.cc
set thelast_sent
andlast_recv
fields of the "force-connected" ZooKeeper handle to deterministic values (which match the initial value of the time mock).When that value is not specified, these fields get set to the "real" time at the end of the
forceConnected
function, which can be sufficiently different from the value held in the mock for some of the tests to fail.