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

log truncate callback for storage trait #321

Open
Licenser opened this issue Nov 12, 2019 · 0 comments
Open

log truncate callback for storage trait #321

Licenser opened this issue Nov 12, 2019 · 0 comments

Comments

@Licenser
Copy link

Is your feature request related to a problem? Please describe.
This is related to #314 - the raft-rs callbacks do not include logic to truncate logs that the Leader knows to be applied to all followers. In combination with #320 this forces full snapshot replication to be the only viable form of catching up leaders.

Describe the solution you'd like
The leader keeps track of the last 'good' log on all followers, it seems sensible for the leader to truncate logs that are know to be replicated and applied to all Followers. A callback in the Storage trait seems to be useful.

Describe alternatives you've considered
Exposing all the needed information on the leader to introspect follower indexes and commits to manually implement truncation.

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

No branches or pull requests

1 participant