keva-dev / keva-dev/keva-sentinel

[Feature] SENTINEL SUBCOMMANDS

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
2
Forks
1
PR merge metrics
No merged PRs in 30d

Description

Sentinels have those commands
- [ ] SENTINEL masters, provides a list of configured masters.
- [ ] SENTINEL slaves , provides a list of slaves for the master with the specified name.
- [ ] SENTINEL sentinels , provides a list of sentinels for the master with the specified name.
- [x] SENTINEL is-master-down-by-addr , returns a two elements multi bulk reply where the first element is :0 or :1, and the second is the Subjective Leader for the failover.
- [ ] CKQUORUM , Check if the current Sentinel configuration is able to reach the quorum needed to failover a master and the majority needed to authorize the failover.
- [ ] CONFIG SET , Set a global Sentinel configuration parameter.
- [ ] CONFIG GET Get global Sentinel configuration parameter.
- [x] GET-MASTER-ADDR-BY-NAME Return the ip and port number of the master with that name.
- [ ] FAILOVER Manually failover a master node without asking for agreement from other Sentinels
- [ ] FLUSHCONFIG Force Sentinel to rewrite its configuration on disk, including the current Sentinel state
- [ ] MONITOR name ip port quorum , Start monitoring a new master with the specified name, ip, port and quorum.
- [ ] MYID Return the ID of the Sentinel instance.
- [ ] REMOVE master-name Remove master from Sentinel's monitor list.
- [ ] REPLICAS Show a list of replicas for this master and their state.
- [ ] RESET Reset masters for specific master name matching this pattern.
- [ ] SENTINELS Show a list of Sentinel instances for this master and their state.
- [ ] SET Set configuration parameters for certain masters.
- [ ] SIMULATE-FAILURE (CRASH-AFTER-ELECTION|CRASH-AFTER-PROMOTION|HELP) Simulate a Sentinel crash.

Cmds that are important:
- [x] SENTINEL is-master-down-by-addr , returns a two elements multi bulk reply where the first element is :0 or :1, and the second is the Subjective Leader for the failover.
- [x] GET-MASTER-ADDR-BY-NAME Return the ip and port number of the master with that name.
- [ ] MONITOR \ \ \ \ Start monitoring a new master with the specified name, ip, port and quorum.
- [ ] SENTINELS Show a list of Sentinel instances for this master and their state.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the existing handlers for SENTINEL is-master-down-by-addr and GET-MASTER-ADDR-BY-NAME, then trace how Sentinel commands are registered and tested. Implement the unchecked commands listed in the issue, prioritizing MONITOR and SENTINELS, and verify that each command returns the behavior described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend, distributed-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.