-
Notifications
You must be signed in to change notification settings - Fork 274
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 flaky test SlowIntegrationTests.testDelayInSecurityIndexInitialization #3763
Conversation
…ation Signed-off-by: Craig Perkins <[email protected]>
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #3763 +/- ##
==========================================
- Coverage 65.27% 65.25% -0.03%
==========================================
Files 298 298
Lines 21159 21159
Branches 3455 3455
==========================================
- Hits 13812 13807 -5
- Misses 5653 5656 +3
- Partials 1694 1696 +2 |
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.
ty @cwperks! This will resolve a big CI blocker.
Can we confirm the fix by running across multiple CI runs?
Signed-off-by: Craig Perkins <[email protected]>
src/test/java/org/opensearch/security/SlowIntegrationTests.java
Outdated
Show resolved
Hide resolved
FYI @DarshitChanpura this passed the 10x check. I will remove the line to repeat the test. |
Signed-off-by: Craig Perkins <[email protected]>
Signed-off-by: Craig Perkins <[email protected]>
@peternied @DarshitChanpura This PR adds back in the SlowIntegrationTests.testDelayInSecurityIndexInitialization that was removed in #3706, but updates the test to make it stable. IMO I would like to keep the test in, but have it been a reliable test. |
Signed-off-by: Craig Perkins <[email protected]>
src/test/java/org/opensearch/security/SlowIntegrationTests.java
Outdated
Show resolved
Hide resolved
src/test/java/org/opensearch/security/SlowIntegrationTests.java
Outdated
Show resolved
Hide resolved
src/test/java/org/opensearch/security/SlowIntegrationTests.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Craig Perkins <[email protected]>
Signed-off-by: Craig Perkins <[email protected]>
Signed-off-by: Craig Perkins <[email protected]>
Signed-off-by: Craig Perkins <[email protected]>
@peternied Can I get another review of this? All comments have been addressed. This will re-instate a (flaky) test that was recently removed, but stabilizes the test. |
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.
Thanks Craig
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/security/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/security/backport-2.x
# Create a new branch
git switch --create backport/backport-3763-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 7498eb00679c307b75db80f54476a01ace48fae9
# Push it to GitHub
git push --set-upstream origin backport/backport-3763-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/security/backport-2.x Then, create a pull request where the |
I will create a manual backport |
…ation (opensearch-project#3763) Signed-off-by: Craig Perkins <[email protected]> (cherry picked from commit 7498eb0)
…ation (opensearch-project#3763) Signed-off-by: Craig Perkins <[email protected]> Signed-off-by: Prabhas Kurapati <[email protected]>
…ation (opensearch-project#3763) Signed-off-by: Craig Perkins <[email protected]>
Description
Explicitly adds a command after setup to create an index and wait for cluster green which produces the expected IOException.
The pseudo code of this test is:
I believe this test is not succeeding, because the cluster is coming up as green initially since there is no data (and hence no shards) in the cluster. By adding an explicit command to create an index, the test ensures that the shards are not being allocated and cluster is indeed red.
Test Fix
Issues Resolved
SlowIntegrationTests.testDelayInSecurityIndexInitialization
#2230Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.