-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Fix race conditions in ManagerV2 tests #36185
Fix race conditions in ManagerV2 tests #36185
Conversation
This pull request doesn't have a |
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
d34c645
to
37b14a1
Compare
37b14a1
to
8aee56c
Compare
8aee56c
to
687baf9
Compare
This pull request is now in conflicts. Could you fix it? 🙏
|
This commit fixes a number of race conditions in the ManagerV2 tests. Most of them were due to the use of Testify's Eventually function to read some values while some callbacks from the manager would also modify those values. The simplest solution was to use the atomic values on those cases. One test (TestInputReload) had a race condition between the test and the manager itself, so it was removed. There is an integration tests that covers the same functionality. There are also some minor clean up regarding logging on tests.
687baf9
to
51d6a16
Compare
Rebase onto |
Needs to be backported to 8.10 this is failing there as well #36449 (comment) |
This commit fixes a number of race conditions in the ManagerV2 tests. Most of them were due to the use of Testify's Eventually function to read some values while some callbacks from the manager would also modify those values. The simplest solution was to use the atomic values on those cases. One test (TestInputReload) had a race condition between the test and the manager itself, so it was removed. There is an integration tests that covers the same functionality. Closes #36192 (cherry picked from commit 818c72d)
This commit fixes a number of race conditions in the ManagerV2 tests. Most of them were due to the use of Testify's Eventually function to read some values while some callbacks from the manager would also modify those values. The simplest solution was to use the atomic values on those cases. One test (TestInputReload) had a race condition between the test and the manager itself, so it was removed. There is an integration tests that covers the same functionality. Closes #36192 (cherry picked from commit 818c72d) Co-authored-by: Tiago Queiroz <[email protected]>
This commit fixes a number of race conditions in the ManagerV2 tests. Most of them were due to the use of Testify's Eventually function to read some values while some callbacks from the manager would also modify those values. The simplest solution was to use the atomic values on those cases. One test (TestInputReload) had a race condition between the test and the manager itself, so it was removed. There is an integration tests that covers the same functionality. Closes elastic#36192
What does this PR do?
This PR fixes a number of race conditions in the ManagerV2
tests. Most of them were due to the use of Testify's Eventually
function to read some values while some callbacks from the manager
would also modify those values. The simplest solution was to use the
atomic values on those cases.
One test (TestInputReload) had a race condition between the test and
the manager itself, so it was removed. There is an integration tests
that covers the same functionality.
Why is it important?
It fixes some race conditions and #36192
Checklist
- [ ] I have made corresponding changes to the documentation- [ ] I have made corresponding change to the default configuration files- [ ] I have added tests that prove my fix is effective or that my feature worksCHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.## Author's ChecklistHow to test this PR locally
All tests must pass and there should be no race condition.
Related issues
## Use cases## Screenshots## Logs