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

Check if the checkpoint seq is in the WAL boundary before using #1320

Merged
merged 1 commit into from
Mar 17, 2023
Merged

Check if the checkpoint seq is in the WAL boundary before using #1320

merged 1 commit into from
Mar 17, 2023

Conversation

git-hulk
Copy link
Member

This closes #1319

@git-hulk git-hulk marked this pull request as ready for review March 17, 2023 03:29
@git-hulk
Copy link
Member Author

This boundary check looks necessary but I can't reproduce this issue on my side.

torwig
torwig previously approved these changes Mar 17, 2023
Copy link
Contributor

@torwig torwig left a comment

Choose a reason for hiding this comment

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

LGTM

caipengbo
caipengbo previously approved these changes Mar 17, 2023
@git-hulk git-hulk dismissed stale reviews from caipengbo and torwig via ed1ddbf March 17, 2023 12:13
@git-hulk
Copy link
Member Author

git-hulk commented Mar 17, 2023

@torwig @caipengbo I extended the sequence limitation to require the checkpoint sequence must be greater or equal to the WAL sequence instead of strictly matching.

  if (seq < wal_seq) {
    return {Status::NotOK, fmt::format("checkpoint seq: {} is smaller than the WAL seq: {}", seq, wal_seq)};
  }

And I have tested if this check works correctly on my side.

@git-hulk
Copy link
Member Author

Thanks all, merging...

@git-hulk git-hulk merged commit 6f722d9 into apache:unstable Mar 17, 2023
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.

Instantly a large number of writes may cause the slave to enter an infinite loop of full sync
4 participants