mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 00:28:26 -05:00
re-add SENTINEL SLAVES command, missing in redis 7.0 (#10723)
Alias was mistakenly forgotten when the sub commands introduced as json files.
This commit is contained in:
parent
135998ed8d
commit
acd517c883
@ -3951,6 +3951,20 @@ struct redisCommandArg SENTINEL_SIMULATE_FAILURE_Args[] = {
|
|||||||
{0}
|
{0}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/********** SENTINEL SLAVES ********************/
|
||||||
|
|
||||||
|
/* SENTINEL SLAVES history */
|
||||||
|
#define SENTINEL_SLAVES_History NULL
|
||||||
|
|
||||||
|
/* SENTINEL SLAVES tips */
|
||||||
|
#define SENTINEL_SLAVES_tips NULL
|
||||||
|
|
||||||
|
/* SENTINEL SLAVES argument table */
|
||||||
|
struct redisCommandArg SENTINEL_SLAVES_Args[] = {
|
||||||
|
{"master-name",ARG_TYPE_STRING,-1,NULL,NULL,NULL,CMD_ARG_NONE},
|
||||||
|
{0}
|
||||||
|
};
|
||||||
|
|
||||||
/* SENTINEL command table */
|
/* SENTINEL command table */
|
||||||
struct redisCommand SENTINEL_Subcommands[] = {
|
struct redisCommand SENTINEL_Subcommands[] = {
|
||||||
{"ckquorum","Check for a Sentinel quorum",NULL,"2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_CKQUORUM_History,SENTINEL_CKQUORUM_tips,sentinelCommand,3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_CKQUORUM_Args},
|
{"ckquorum","Check for a Sentinel quorum",NULL,"2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_CKQUORUM_History,SENTINEL_CKQUORUM_tips,sentinelCommand,3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_CKQUORUM_Args},
|
||||||
@ -3973,6 +3987,7 @@ struct redisCommand SENTINEL_Subcommands[] = {
|
|||||||
{"sentinels","List the Sentinel instances","O(N) where N is the number of Sentinels","2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SENTINELS_History,SENTINEL_SENTINELS_tips,sentinelCommand,3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SENTINELS_Args},
|
{"sentinels","List the Sentinel instances","O(N) where N is the number of Sentinels","2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SENTINELS_History,SENTINEL_SENTINELS_tips,sentinelCommand,3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SENTINELS_Args},
|
||||||
{"set","Change the configuration of a monitored master","O(1)","2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SET_History,SENTINEL_SET_tips,sentinelCommand,-5,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SET_Args},
|
{"set","Change the configuration of a monitored master","O(1)","2.8.4",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SET_History,SENTINEL_SET_tips,sentinelCommand,-5,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SET_Args},
|
||||||
{"simulate-failure","Simulate failover scenarios",NULL,"3.2.0",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SIMULATE_FAILURE_History,SENTINEL_SIMULATE_FAILURE_tips,sentinelCommand,-3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SIMULATE_FAILURE_Args},
|
{"simulate-failure","Simulate failover scenarios",NULL,"3.2.0",CMD_DOC_NONE,NULL,NULL,COMMAND_GROUP_SENTINEL,SENTINEL_SIMULATE_FAILURE_History,SENTINEL_SIMULATE_FAILURE_tips,sentinelCommand,-3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SIMULATE_FAILURE_Args},
|
||||||
|
{"slaves","List the monitored slaves","O(N) where N is the number of slaves","2.8.0",CMD_DOC_DEPRECATED,"`SENTINEL REPLICAS`","5.0.0",COMMAND_GROUP_SENTINEL,SENTINEL_SLAVES_History,SENTINEL_SLAVES_tips,sentinelCommand,3,CMD_ADMIN|CMD_SENTINEL|CMD_ONLY_SENTINEL,0,.args=SENTINEL_SLAVES_Args},
|
||||||
{0}
|
{0}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
27
src/commands/sentinel-slaves.json
Normal file
27
src/commands/sentinel-slaves.json
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
"SLAVES": {
|
||||||
|
"summary": "List the monitored slaves",
|
||||||
|
"complexity": "O(N) where N is the number of slaves",
|
||||||
|
"group": "sentinel",
|
||||||
|
"since": "2.8.0",
|
||||||
|
"arity": 3,
|
||||||
|
"container": "SENTINEL",
|
||||||
|
"function": "sentinelCommand",
|
||||||
|
"deprecated_since": "5.0.0",
|
||||||
|
"replaced_by": "`SENTINEL REPLICAS`",
|
||||||
|
"doc_flags": [
|
||||||
|
"DEPRECATED"
|
||||||
|
],
|
||||||
|
"command_flags": [
|
||||||
|
"ADMIN",
|
||||||
|
"SENTINEL",
|
||||||
|
"ONLY_SENTINEL"
|
||||||
|
],
|
||||||
|
"arguments": [
|
||||||
|
{
|
||||||
|
"name": "master-name",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user