rac2,replica_rac2: add ForceFlushIndexChangedLocked to Processor, Ran…#136321
rac2,replica_rac2: add ForceFlushIndexChangedLocked to Processor, Ran…#136321craig[bot] merged 1 commit intocockroachdb:masterfrom
Conversation
|
Your pull request contains more than 1000 changes. It is strongly encouraged to split big PRs into smaller chunks. 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
2b1cfc9 to
a06a931
Compare
kvoli
left a comment
There was a problem hiding this comment.
Reviewed 7 of 7 files at r1, all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @pav-kv and @sumeerbhola)
pkg/kv/kvserver/kvflowcontrol/replica_rac2/processor.go line 612 at r1 (raw file):
// ForceFlushIndexChangedLocked implements Processor. func (p *processorImpl) ForceFlushIndexChangedLocked(ctx context.Context, index uint64) {
Also here, we could add an assertion on the respective mutexes.
pkg/kv/kvserver/kvflowcontrol/rac2/range_controller.go line 1534 at r1 (raw file):
// ForceFlushIndexChangedLocked implements RangeController. func (rc *rangeController) ForceFlushIndexChangedLocked(ctx context.Context, index uint64) {
We could assert on raftMu and replMu being held here as well.
pkg/kv/kvserver/kvflowcontrol/rac2/range_controller.go line 2571 at r1 (raw file):
// needed to rely on this force-flush until the send-queue was empty. That // knowledge will become known in the next // rangeController.handleRaftEvent*, which will happen at the next tick.
What does the * indicate after handleRaftEvent?
…geController This is used to set the highest index up to which all send-queues in pull mode must be force-flushed. Informs cockroachdb#135601 Epic: CRDB-37515 Release note: None
sumeerbhola
left a comment
There was a problem hiding this comment.
TFTR!
Reviewable status:
complete! 1 of 0 LGTMs obtained (waiting on @kvoli and @pav-kv)
pkg/kv/kvserver/kvflowcontrol/rac2/range_controller.go line 1534 at r1 (raw file):
Previously, kvoli (Austen) wrote…
We could assert on raftMu and replMu being held here as well.
Done
pkg/kv/kvserver/kvflowcontrol/rac2/range_controller.go line 2571 at r1 (raw file):
Previously, kvoli (Austen) wrote…
What does the * indicate after handleRaftEvent?
Laziness :)
Fixed.
pkg/kv/kvserver/kvflowcontrol/replica_rac2/processor.go line 612 at r1 (raw file):
Previously, kvoli (Austen) wrote…
Also here, we could add an assertion on the respective mutexes.
Done
kvoli
left a comment
There was a problem hiding this comment.
Reviewed 2 of 2 files at r2, all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @pav-kv)
|
bors r=kvoli |
Now that `Subsume` is required to force flush all replication streams up to the lease applied index it froze the range at (cockroachdb#136321), `SubsumeRequest` also needs to be marked as a write in order to pass through the replication code path, which updates the range controller force flush index and replicates the force flush index. Part of: cockroachdb#132614 Release note: None
…geController
This is used to set the highest index up to which all send-queues in pull mode must be force-flushed.
Informs #135601
Epic: CRDB-37515
Release note: None