Skip to content
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

backport-2.1: storage: use FIFO order in queues on equal priorities #32414

Merged
merged 2 commits into from
Nov 19, 2018

Conversation

tbg
Copy link
Member

@tbg tbg commented Nov 16, 2018

Backport 2/2 commits from #32053.

/cc @cockroachdb/release


When priorities are equal, the priority queue naively performs close to
LIFO which is not what we want as it allows starvation of items backed into
the queue. This poses a big problem for the Raft snapshot queue when put
under pressure.

See
#31947 (comment).

Release note (bug fix): Avoid a stall in the processing of Raft snapshots
when many snapshots are requested at the same time.

This is a refactor without functional changes, in preparation for adding
a sequence number generator into the priority queue.

Release note: None
When priorities are equal, the priority queue naively performs close to
LIFO which is not what we want as it allows starvation of items backed
into the queue. This poses a big problem for the Raft snapshot queue
when put under pressure.

See
cockroachdb#31947 (comment).

Release note (bug fix): Avoid a stall in the processing of Raft
snapshots when many snapshots are requested at the same time.
@tbg tbg requested review from petermattis and a team November 16, 2018 11:57
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Collaborator

@petermattis petermattis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained

@tbg tbg merged commit 04ee376 into cockroachdb:release-2.1 Nov 19, 2018
@tbg tbg deleted the backport2.1-32053 branch November 19, 2018 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants