KVRocks (not clustered mode) does not support the FAILOVER command from Redis
- Dominant language
- C++
- Stars
- 4.4k
- Forks
- 658
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 10
Description
### Search before asking
- [x] I had searched in the [issues](https://github.com/apache/kvrocks/issues) and found no similar issues.
### Motivation
Redis has a [FAILOVER](https://redis.io/docs/latest/commands/failover/) command which can be used to gracefully switch which node is the master node in a multi-node (non-cluster) setup.
The details are [described in the documentation](https://redis.io/docs/latest/commands/failover/), but the gist is that it will gracefully pauses writes on the master until at least one replica catches up, then make that replica a master and make the old master into a replica of it.
A command like this is necessary for doing per-node maintenance windows in a rolling fashion, keeping high availability with minimum downtime, and most importantly, _without losing acknowledged writes_.
Apache KVRocks advertises that you can operate it in high availability mode with Redis Sentinel, so I was quite surprised to see that this feature doesn't exist. I can't really treat this as a high availability system without this feature, as there is no clean way to take down a node for maintenance without causing potential loss of acknowledged writes.
### Solution
Implement a Redis-compatible `FAILOVER` command.
### Are you willing to submit a PR?
- [ ] I'm willing to submit a PR!
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.