-
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
[Remote Store] Avoiding Translog Deletion in case of relocating shards. #9603
Conversation
Signed-off-by: Gaurav Bafna <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
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.
Looks good overall, lets add UTs/ITs. Thanks for the change.
.../src/internalClusterTest/java/org/opensearch/remotestore/RemoteIndexPrimaryRelocationIT.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/index/translog/RemoteFsTranslog.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Gaurav Bafna <[email protected]>
Gradle Check (Jenkins) Run Completed with:
|
Gradle Check (Jenkins) Run Completed with:
|
Failure not related to this change : #9580 |
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.
What if relocation is stuck and not all readers are needed, would we end up retaining readers for long? I would model this as a retention lease instead, the interface looks generic and cleaner that way
* | ||
* @opensearch.internal | ||
*/ | ||
static public class IndexShardConfigSupplier { |
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.
The structure seems to be force-fitting this very specific use case. We should model it more generically
This PR is stalled because it has been open for 30 days with no activity. |
Description
In Primary to Primary relocation , there can be concurrent upload and download of translog.
While translog files are getting downloaded by new primary, it might hence be deleted by the relocating primary
Hence we need to avoid to deletion when shard is in
RELOCATING
state .Related Issues
Resolves #9191
Check 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.