Improve the debug help command message (#9098)

cleanups:
1: Re-introduce debug leak subcommand in help text.
Mistankenly deleted in https://github.com/redis/redis/pull/5531

2: Formatted the text.
Some text lacks commas resulting in no line breaks.

3: Supplementary debug restart command descriptions of delay arg.
This commit is contained in:
Binbin 2021-06-20 14:46:27 +08:00 committed by GitHub
parent 89152f8e41
commit 561c69c285
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 7 deletions

View File

@ -389,14 +389,14 @@ void debugCommand(client *c) {
" Server will sleep before flushing the AOF, this is used for testing.",
"ASSERT",
" Crash by assertion failed.",
"CHANGE-REPL-ID"
"CHANGE-REPL-ID",
" Change the replication IDs of the instance.",
" Dangerous: should be used only for testing the replication subsystem.",
"CONFIG-REWRITE-FORCE-ALL",
" Like CONFIG REWRITE but writes all configuration options, including",
" keywords not listed in original configuration file or default values.",
"CRASH-AND-RECOVER <milliseconds>",
" Hard crash and restart after a <milliseconds> delay.",
"CRASH-AND-RECOVER [<milliseconds>]",
" Hard crash and restart after a <milliseconds> delay (default 0).",
"DIGEST",
" Output a hex signature representing the current DB content.",
"DIGEST-VALUE <key> [<key> ...]",
@ -404,6 +404,8 @@ void debugCommand(client *c) {
"ERROR <string>",
" Return a Redis protocol error with <string> as message. Useful for clients",
" unit tests to simulate Redis errors.",
"LEAK <string>",
" Create a memory leak of the input string.",
"LOG <message>",
" Write <message> to the server log.",
"HTSTATS <dbid>",
@ -430,7 +432,7 @@ void debugCommand(client *c) {
"POPULATE <count> [<prefix>] [<size>]",
" Create <count> string keys named key:<num>. If <prefix> is specified then",
" it is used instead of the 'key' prefix.",
"DEBUG PROTOCOL <type>",
"PROTOCOL <type>",
" Reply with a test value of the specified type. <type> can be: string,",
" integer, double, bignum, null, array, set, map, attrib, push, verbatim,",
" true, false.",
@ -438,7 +440,7 @@ void debugCommand(client *c) {
" Save the RDB on disk and reload it back to memory. Valid <option> values:",
" * MERGE: conflicting keys will be loaded from RDB.",
" * NOFLUSH: the existing database will not be removed before load, but",
" conflicting keys will generate an exception and kill the server."
" conflicting keys will generate an exception and kill the server.",
" * NOSAVE: the database will be loaded from an existing RDB file.",
" Examples:",
" * DEBUG RELOAD: verify that the server is able to persist, flush and reload",
@ -447,8 +449,8 @@ void debugCommand(client *c) {
" existing RDB file.",
" * DEBUG RELOAD NOSAVE NOFLUSH MERGE: add the contents of an existing RDB",
" file to the database.",
"RESTART",
" Graceful restart: save config, db, restart.",
"RESTART [<milliseconds>]",
" Graceful restart: save config, db, restart after a <milliseconds> delay (default 0).",
"SDSLEN <key>",
" Show low level SDS string info representing `key` and value.",
"SEGFAULT",