-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
storage: eager GC for replicas blocking snapshots
Consider the following situation on a Range X: - the range lives on nodes 1,2,3 - gets rebalanced to nodes 1,2,4 while node 3 is down - node 3 restarts, but the (now removed) replica remains - quiescent - the range splits - the right hand side of the split gets rebalanced to - nodes 1,2,3. In order to receive a snapshot for in the last step, node 3 needs to have garbage-collected its old pre-split replica. If it weren't for node 3's downtime this would normally happen eagerly as its peers will inform it of its fate. In this scenario however, one would have to wait until a) a client request creates the Raft group (which is unlikely as it isn't being addressed any more) or b) a queue picks it up (which can take a long time). Instead, when returning an overlap and the overlap appears to be inactive, we add to the GC queue (which in turn activates the replica). For the situation above, we could also hope to only create the Raft group (as that would likely, but not necessarily, bring it into contact with its ex-peers). However, none of the old members may still be around in larger clusters, so going for the GC queue directly is the better option.
- Loading branch information
1 parent
7dde9b4
commit 6f66401
Showing
2 changed files
with
91 additions
and
2 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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