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

Remove wait_apply stage in disk snapshot restore #50312

Closed
YuJuncen opened this issue Jan 11, 2024 · 0 comments · Fixed by #50316
Closed

Remove wait_apply stage in disk snapshot restore #50312

YuJuncen opened this issue Jan 11, 2024 · 0 comments · Fixed by #50316

Comments

@YuJuncen
Copy link
Contributor

YuJuncen commented Jan 11, 2024

Enhancement

The wait_apply stage in disk snapshot restore was used for preparing "physical" flashback, which delete all entries committed after the flashback TS directly in each peers underlying storage (RocksDB), without any synchronization by raft.
For keeping the consistency of the raft state machine, we must wait all peers' state machine go to the same state.

But for now, the flashback implementation should be the same as FLASHBACK TABLE SQL statement, which will "logically" delete the keys needed to be flashed back by committing new writes with raft. Hence it is no need to wait all peers(but only leaders) apply to last index.

We can remove the useless step. Given it have brought other bugs, like make backup stuck if there are some stale peers.

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

Successfully merging a pull request may close this issue.

1 participant