-
Notifications
You must be signed in to change notification settings - Fork 1.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
Add integration tests for remote store restore flow #8484
Add integration tests for remote store restore flow #8484
Conversation
8162027
to
63ce4c7
Compare
Gradle Check (Jenkins) Run Completed with:
|
Gradle Check (Jenkins) Run Completed with:
|
08efbd9
to
0361ada
Compare
Gradle Check (Jenkins) Run Completed with:
|
Gradle Check (Jenkins) Run Completed with:
|
Resolved, |
…CommitDeletionWithoutInvokeFlush Signed-off-by: Bhumika Saini <[email protected]>
Signed-off-by: Bhumika Saini <[email protected]>
Signed-off-by: Bhumika Saini <[email protected]>
4dce9ef
to
6f3b206
Compare
Gradle Check (Jenkins) Run Completed with:
|
Signed-off-by: Bhumika Saini <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
Signed-off-by: Bhumika Saini <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
@BhumikaSaini-Amazon Based on the analysis that I did, this is what I have found. This issue would not happen for indexes with just 1 shard as the node that holds the shard is stopped and there is no history of retention leases (of the shard that was residing on the stopped node) after we close index and start the remote store restore. For the indexes that have more than 1 shard, this issue happens when the syncRetentionLeases async task (that runs periodically) persists the retention leases to the local disk. OpenSearch/server/src/main/java/org/opensearch/index/seqno/RetentionLeaseSyncAction.java Lines 184 to 196 in 83a4b6e
Afterwards, on cluster state update for restoring the remote index, IndexShard is created and then recovery starts on the newly created IndexShard object. OpenSearch/server/src/main/java/org/opensearch/indices/IndicesService.java Lines 930 to 967 in 83a4b6e
During the recovery from remote store, the innerOpenEngineAndTranslog method of IndexShard is invoked where the retentionLeases are restored from the local disk back to in-memory replication tracker.OpenSearch/server/src/main/java/org/opensearch/index/shard/IndexShard.java Lines 2310 to 2325 in 83a4b6e
This issue is flaky due to the nature of async sync retention leases. As for now, I am creating an issue to remove retention leases when index has remote translog enabled. Meanwhile, we can safely override the expectEmptyRetentionLeases of RemoteStoreRecoverySource class.
|
Signed-off-by: Bhumika Saini <[email protected]>
…es once opensearch-project#8795 is resolved Signed-off-by: Bhumika Saini <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
Signed-off-by: Bhumika Saini <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/backport-2.x
# Create a new branch
git switch --create backport/backport-8484-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 27a14c7c811f930b2b36c13f20e1371c6206dd51
# Push it to GitHub
git push --set-upstream origin backport/backport-8484-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/backport-2.x Then, create a pull request where the |
…ct#8484) --------- Signed-off-by: Bhumika Saini <[email protected]> (cherry picked from commit 27a14c7)
…ct#8484) --------- Signed-off-by: Bhumika Saini <[email protected]> (cherry picked from commit 27a14c7)
…ct#8484) --------- Signed-off-by: Bhumika Saini <[email protected]>
--------- Signed-off-by: Bhumika Saini <[email protected]>
…ct#8484) Add integration tests for remote store restore flow (opensearch-project#8484) --------- Signed-off-by: Bhumika Saini <[email protected]>
…ct#8484) Add integration tests for remote store restore flow (opensearch-project#8484) --------- Signed-off-by: Bhumika Saini <[email protected]> Signed-off-by: Kaushal Kumar <[email protected]>
…ct#8484) Add integration tests for remote store restore flow (opensearch-project#8484) --------- Signed-off-by: Bhumika Saini <[email protected]> Signed-off-by: Ivan Brusic <[email protected]>
…ct#8484) Add integration tests for remote store restore flow (opensearch-project#8484) --------- Signed-off-by: Bhumika Saini <[email protected]> Signed-off-by: Shivansh Arora <[email protected]>
Description
Add the following test scenarios to the suite:
Related Issues
#8483
Check List
Commit changes are listed out in CHANGELOG.md file (See: Changelog)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.