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

[NEW] Support min-slaves-to-write like redis #439

Open
ShooterIT opened this issue Dec 30, 2021 · 0 comments
Open

[NEW] Support min-slaves-to-write like redis #439

ShooterIT opened this issue Dec 30, 2021 · 0 comments

Comments

@ShooterIT
Copy link
Member

The problem/use-case that the feature addresses

Redis provide these configs to make it is possible for a master to stop accepting writes if there are less than N replicas connected, having a lag less or equal than M seconds. But kvrocks can't.

min-replicas-to-write 3
min-replicas-max-lag 10

Description of the feature

The N replicas need to be in "online" state.

The lag in seconds, that must be <= the specified value, is calculated from the last ping received from the replica, that is usually sent every second.

This option does not GUARANTEE that N replicas will accept the write, but will limit the window of exposure for lost writes in case not enough replicas are available, to the specified number of seconds.

Alternatives you've considered

We may want to support semi-sync like MySQL, so we should also think it is worth implementing this feature.

Additional information

NULL

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