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

[v23.1.x] raft: reject linearizable_barrier if not is_leader() #10990

Merged

Conversation

vbotbuildovich
Copy link
Collaborator

Backport of PR #10921
Fixes #10989,

A test noticed that a Kafka ListOffsets request issued
concurrently with raft election could return a commit_index
lower than the last message committed on the previous leader.

To the client this looks like time travel on their topic's HWM.

We could special case this for ListOffsets, but linearizable_barrier
is used lots of places, and probably none of them actually want to run
in this brief millisecond between leader election and is_leader()
becoming true.

Fixes redpanda-data#10885

(cherry picked from commit d170fc6)
@vbotbuildovich vbotbuildovich added this to the v23.1.x-next milestone May 24, 2023
@vbotbuildovich vbotbuildovich added the kind/backport PRs targeting a stable branch label May 24, 2023
@jcsp jcsp marked this pull request as ready for review May 24, 2023 16:29
@jcsp jcsp merged commit 5992166 into redpanda-data:v23.1.x May 24, 2023
23 checks passed
@vshtokman vshtokman modified the milestones: v23.1.x-next, v23.1.11 May 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/redpanda kind/backport PRs targeting a stable branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants