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

Fixed taking snapshot in rm_stm #12155

Merged
merged 2 commits into from
Jul 20, 2023
Merged

Conversation

mmaslankaprv
Copy link
Member

@mmaslankaprv mmaslankaprv commented Jul 17, 2023

This change fixes an issue where a snapshot might
have been created with offset lower from the offset of a snapshot that
was already applied.

Fixes: #11659

Backports Required

  • none - not a bug fix
  • none - this is a backport
  • none - issue does not exist in previous branches
  • none - papercut/not impactful enough to backport
  • v23.2.x
  • v23.1.x
  • v22.3.x
  • v22.2.x

Release Notes

Improvements

  • reduces amount of data read while bootstrapping rm_stm

src/v/cluster/rm_stm.cc Show resolved Hide resolved
@BenPope
Copy link
Member

BenPope commented Jul 17, 2023

Any other backports required here?

@mmaslankaprv
Copy link
Member Author

/ci-repeat 4
skip-units
debug
dt-repeat=100
tests/rptest/tests/partition_movement_test.py::SIPartitionMovementTest.test_cross_shard

1 similar comment
@mmaslankaprv
Copy link
Member Author

/ci-repeat 4
skip-units
debug
dt-repeat=100
tests/rptest/tests/partition_movement_test.py::SIPartitionMovementTest.test_cross_shard

@mmaslankaprv
Copy link
Member Author

/ci-repeat 4
skip-units
release
dt-repeat=100
tests/rptest/tests/partition_movement_test.py::SIPartitionMovementTest.test_cross_shard

1 similar comment
@mmaslankaprv
Copy link
Member Author

/ci-repeat 4
skip-units
release
dt-repeat=100
tests/rptest/tests/partition_movement_test.py::SIPartitionMovementTest.test_cross_shard

@rystsov rystsov dismissed their stale review July 18, 2023 22:57

the issue was fixed

@mmaslankaprv
Copy link
Member Author

/ci-repeat 1

@mmaslankaprv mmaslankaprv marked this pull request as ready for review July 19, 2023 06:21
@mmaslankaprv mmaslankaprv requested review from bharathv and ztlpn July 19, 2023 06:21
src/v/cluster/persisted_stm.cc Show resolved Hide resolved
When snapshot is applied on startup by the persisted stm
it should not be the stm implementer responsibility to store
`_last__snapshot_offset`.

Signed-off-by: Michal Maslanka <michal@redpanda.com>
Signed-off-by: Michal Maslanka <michal@redpanda.com>
@mmaslankaprv
Copy link
Member Author

/ci-repeat 1

@mmaslankaprv
Copy link
Member Author

ci failure: #12275

@mmaslankaprv mmaslankaprv merged commit 40d0a10 into redpanda-data:dev Jul 20, 2023
@mmaslankaprv mmaslankaprv deleted the fix-11659 branch July 20, 2023 13:03
@vbotbuildovich
Copy link
Collaborator

/backport v23.2.x

@vbotbuildovich
Copy link
Collaborator

/backport v23.1.x

@vbotbuildovich
Copy link
Collaborator

Failed to run cherry-pick command. I executed the commands below:

git checkout -b backport-pr-12155-v23.1.x-335 remotes/upstream/v23.1.x
git cherry-pick -x 127521f987219eab442327b7e211e8bf01cda4d0 d57a5323f8fb7fe56bfc89c646570c031331a03c

Workflow run logs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI Failure (assert target_offset <= _insync_offset) in SIPartitionMovementTest.test_cross_shard
5 participants