Fix flaky test SlowIntegrationTests.testDelayInSecurityIndexInitialization#3763
Fix flaky test SlowIntegrationTests.testDelayInSecurityIndexInitialization#3763peternied merged 11 commits intoopensearch-project:mainfrom
Conversation
…ation Signed-off-by: Craig Perkins <cwperx@amazon.com>
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 |
DarshitChanpura
left a comment
There was a problem hiding this comment.
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 <cwperx@amazon.com>
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 <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
|
@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 <cwperx@amazon.com>
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 <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
|
@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. |
|
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.xThen, create a pull request where the |
|
I will create a manual backport |
…ation (opensearch-project#3763) Signed-off-by: Craig Perkins <cwperx@amazon.com> (cherry picked from commit 7498eb0)
…ation (opensearch-project#3763) Signed-off-by: Craig Perkins <cwperx@amazon.com>
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.