[WIP] admission: generalize store write admission control#75120
Closed
sumeerbhola wants to merge 1 commit intocockroachdb:masterfrom
Closed
[WIP] admission: generalize store write admission control#75120sumeerbhola wants to merge 1 commit intocockroachdb:masterfrom
sumeerbhola wants to merge 1 commit intocockroachdb:masterfrom
Conversation
The store write admission control path now uses a StoreWorkQueue which wraps a WorkQueue and provides additional functionality: - Work can specify WriteBytes and whether it is an IngestRequest. This is used to decide how many byte tokens to consume. - Done work specifies how many bytes were ingested into L0, so token consumption can be adjusted. The main framework change is that a single work item can consume multiple (byte) tokens, which ripples through the various interfaces including requester, granter. There is associated cleanup: kvGranter that was handling both slots and tokens is eliminated since in practice it was only doing one or the other. Instead for the slot case the slotGranter is reused. For the token case the kvStoreTokenGranter is created. The main logic change is in ioLoadListener which computes byte tokens and various estimates. There are TODOs to fix tests that will fail. Informs cockroachdb#75066 Release note: None
Member
Collaborator
Author
|
see comment in #75066 (comment) |
Contributor
|
I believe this work was done through #80480 (was reading through admission code and learning about inflight PRs, came across this). |
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.
The store write admission control path now uses a StoreWorkQueue
which wraps a WorkQueue and provides additional functionality:
This is used to decide how many byte tokens to consume.
token consumption can be adjusted.
The main framework change is that a single work item can consume
multiple (byte) tokens, which ripples through the various
interfaces including requester, granter. There is associated
cleanup: kvGranter that was handling both slots and tokens is
eliminated since in practice it was only doing one or the other.
Instead for the slot case the slotGranter is reused. For the token
case the kvStoreTokenGranter is created.
The main logic change is in ioLoadListener which computes byte
tokens and various estimates.
There are TODOs to fix tests that will fail.
Informs #75066
Release note: None