fix wait for replica inactivity and retry SYSTEM DROP REPLICA#2047
Open
bhardwajparth51 wants to merge 1 commit into
Open
fix wait for replica inactivity and retry SYSTEM DROP REPLICA#2047bhardwajparth51 wants to merge 1 commit into
bhardwajparth51 wants to merge 1 commit into
Conversation
…PLICA on Code 305 (Altinity#1943) Fixes issue Altinity#1943 where scaling down replicas causes SYSTEM DROP REPLICA to fail with Code: 305, Can't drop replica ... because it's active when executed before ZooKeeper session timeout expires. - Extracts ISchemer interface for dependency injection and testability. - Adds waitHostReplicaInactive polling until ZooKeeper session expires. - Adds retryDropReplica with linear backoff on Code 305 errors. - Adds getCoordinatorHost fallback helper for single-replica shard drops. - Adds comprehensive unit test suite in worker-deleter_test.go. Signed-off-by: Parth Bhardwaj <196071556+bhardwajparth51@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1943 where scaling down replicas causes
SYSTEM DROP REPLICAto fail withCode: 305, Can't drop replica ... because it's activewhen executed before ZooKeeper session timeout expires.ISchemerinterface for dependency injection and testability.waitHostReplicaInactivepolling until ZooKeeper session expires.retryDropReplicawith linear backoff on Code 305 errors.getCoordinatorHostfallback helper for single-replica shard drops.worker-deleter_test.go.Signed-off-by: Parth Bhardwaj 196071556+bhardwajparth51@users.noreply.github.com
Important items to consider before making a Pull Request
next-releasebranch, not intomasterbranch.