Skip to content

Commit

Permalink
RESP2/RESP3 reply unification and minor fixes (#211)
Browse files Browse the repository at this point in the history
This allows to merge more of the RESP2/RESP3 command replies.

Signed-off-by: Simon Baatz <[email protected]>
  • Loading branch information
gmbnomis authored Jan 16, 2025
1 parent c71ba8a commit fffb5dd
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 38 deletions.
34 changes: 17 additions & 17 deletions resp2_replies.json
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@
"[Simple string reply](../topics/protocol.md#simple-strings): `OK` if the command was accepted and a manual failover is going to be attempted. An error if the operation cannot be executed, for example if the client is connected to a node that is already a primary."
],
"CLUSTER FLUSHSLOTS": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`"
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
],
"CLUSTER FORGET": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK` if the command was executed successfully. Otherwise an error is returned."
Expand Down Expand Up @@ -310,7 +310,7 @@
"[Array reply](../topics/protocol.md#arrays): a map, as a flattened array, where each key is a command name, and each value is the documentary information."
],
"COMMAND GETKEYS": [
"[Array reply](../topics/protocol.md#arrays): list of keys from the given command."
"[Array reply](../topics/protocol.md#arrays): a list of keys from the given command."
],
"COMMAND GETKEYSANDFLAGS": [
"[Array reply](../topics/protocol.md#arrays): a list of keys from the given command and their usage flags."
Expand Down Expand Up @@ -363,7 +363,7 @@
],
"DUMP": [
"One of the following:",
"* [Bulk string reply](../topics/protocol.md#bulk-strings): The serialized value of the key.",
"* [Bulk string reply](../topics/protocol.md#bulk-strings): the serialized value of the key.",
"* [Nil reply](../topics/protocol.md#bulk-strings): the key does not exist."
],
"ECHO": [
Expand Down Expand Up @@ -431,7 +431,7 @@
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
],
"FUNCTION HELP": [
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions"
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions."
],
"FUNCTION KILL": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
Expand Down Expand Up @@ -460,7 +460,7 @@
"[Array reply](../topics/protocol.md#arrays): an array where each element is the Geohash corresponding to each member name passed as an argument to the command."
],
"GEOPOS": [
"[Array reply](../topics/protocol.md#arrays): An array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as [Nil reply](../topics/protocol.md#bulk-strings) elements of the array."
"[Array reply](../topics/protocol.md#arrays): an array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as [Nil reply](../topics/protocol.md#bulk-strings) elements of the array."
],
"GEORADIUS": [
"One of the following:",
Expand Down Expand Up @@ -563,7 +563,7 @@
"[Bulk string reply](../topics/protocol.md#bulk-strings): the value of the field after the increment operation."
],
"HKEYS": [
"[Array reply](../topics/protocol.md#arrays): a list of fields in the hash, or an empty list when the key does not exist"
"[Array reply](../topics/protocol.md#arrays): a list of fields in the hash, or an empty list when the key does not exist."
],
"HLEN": [
"[Integer reply](../topics/protocol.md#integers): the number of fields in the hash, or 0 when the key does not exist."
Expand Down Expand Up @@ -598,7 +598,7 @@
"[Integer reply](../topics/protocol.md#integers): the string length of the value associated with the _field_, or zero when the _field_ isn't present in the hash or the _key_ doesn't exist at all."
],
"HVALS": [
"[Array reply](../topics/protocol.md#arrays): a list of values in the hash, or an empty list when the key does not exist"
"[Array reply](../topics/protocol.md#arrays): a list of values in the hash, or an empty list when the key does not exist."
],
"INCR": [
"[Integer reply](../topics/protocol.md#integers): the value of the key after the increment."
Expand Down Expand Up @@ -708,10 +708,10 @@
"[Bulk string reply](../topics/protocol.md#bulk-strings): a memory problems report."
],
"MEMORY HELP": [
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions"
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions."
],
"MEMORY MALLOC-STATS": [
"[Bulk string reply](../topics/protocol.md#bulk-strings): the memory allocator's internal statistics report"
"[Bulk string reply](../topics/protocol.md#bulk-strings): the memory allocator's internal statistics report."
],
"MEMORY PURGE": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
Expand Down Expand Up @@ -781,7 +781,7 @@
"[Nil reply](../topics/protocol.md#bulk-strings): if _key_ doesn't exist."
],
"OBJECT HELP": [
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions"
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions."
],
"OBJECT IDLETIME": [
"One of the following:",
Expand Down Expand Up @@ -875,12 +875,12 @@
"When successful, this command doesn't return anything. Instead, for each pattern, one message with the first element being the string `punsubscribe` is pushed as a confirmation that the command succeeded."
],
"QUIT": [
"[Simple string reply](../topics/protocol.md#simple-strings): OK."
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
],
"RANDOMKEY": [
"One of the following:",
"* [Nil reply](../topics/protocol.md#bulk-strings): when the database is empty.",
"* [Bulk string reply](../topics/protocol.md#bulk-strings): a random key in database."
"* [Bulk string reply](../topics/protocol.md#bulk-strings): a random key in the database."
],
"READONLY": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
Expand Down Expand Up @@ -1127,7 +1127,7 @@
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
],
"WAIT": [
"[Integer reply](../topics/protocol.md#integers): the command returns the number of replicas reached by all the writes performed in the context of the current connection."
"[Integer reply](../topics/protocol.md#integers): the number of replicas reached by all the writes performed in the context of the current connection."
],
"WAITAOF": [
"[Array reply](../topics/protocol.md#arrays): The command returns an array of two integers:",
Expand Down Expand Up @@ -1190,8 +1190,8 @@
],
"XINFO STREAM": [
"One of the following:",
"* [Array reply](../topics/protocol.md#arrays): when the _FULL_ argument is used, a list of information about a stream in summary form.",
"* [Array reply](../topics/protocol.md#arrays): when the _FULL_ argument is used, a list of information about a stream in extended form."
"* [Array reply](../topics/protocol.md#arrays): when the _FULL_ argument was not given, a list of information about a stream in summary form.",
"* [Array reply](../topics/protocol.md#arrays): when the _FULL_ argument was given, a list of information about a stream in extended form."
],
"XLEN": [
"[Integer reply](../topics/protocol.md#integers): the number of entries of the stream at _key_."
Expand Down Expand Up @@ -1306,10 +1306,10 @@
"[Integer reply](../topics/protocol.md#integers): the number of members removed."
],
"ZREVRANGE": [
"* [Array reply](../topics/protocol.md#arrays): a list of members in the specified range, optionally with their scores if _WITHSCORE_ was used."
"* [Array reply](../topics/protocol.md#arrays): a list of the members in the specified range, optionally with their scores if _WITHSCORE_ was used."
],
"ZREVRANGEBYLEX": [
"[Array reply](../topics/protocol.md#arrays): a list of members in the specified score range."
"[Array reply](../topics/protocol.md#arrays): a list of the members in the specified score range."
],
"ZREVRANGEBYSCORE": [
"* [Array reply](../topics/protocol.md#arrays): a list of the members and, optionally, their scores in the specified score range."
Expand Down
42 changes: 21 additions & 21 deletions resp3_replies.json
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@
"[Array reply](../topics/protocol.md#arrays): a list of subcommands and their descriptions."
],
"CLUSTER INFO": [
"[Bulk string reply](../topics/protocol.md#bulk-strings): A map between named fields and values in the form of <field>:<value> lines separated by newlines composed by the two bytes CRLF"
"[Bulk string reply](../topics/protocol.md#bulk-strings): A map between named fields and values in the form of `<field>:<value>` lines separated by newlines composed by the two bytes `CRLF`."
],
"CLUSTER KEYSLOT": [
"[Integer reply](../topics/protocol.md#integers): The hash slot number for the specified key"
Expand Down Expand Up @@ -457,10 +457,10 @@
"* [Bulk string reply](../topics/protocol.md#bulk-strings): distance as a double (represented as a string) in the specified units."
],
"GEOHASH": [
"[Array reply](../topics/protocol.md#arrays): An array where each element is the Geohash corresponding to each member name passed as an argument to the command."
"[Array reply](../topics/protocol.md#arrays): an array where each element is the Geohash corresponding to each member name passed as an argument to the command."
],
"GEOPOS": [
"[Array reply](../topics/protocol.md#arrays): An array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as [Null reply](../topics/protocol.md#nulls) elements of the array."
"[Array reply](../topics/protocol.md#arrays): an array where each element is a two elements array representing longitude and latitude (x,y) of each member name passed as argument to the command. Non-existing elements are reported as [Null reply](../topics/protocol.md#nulls) elements of the array."
],
"GEORADIUS": [
"One of the following:",
Expand Down Expand Up @@ -512,7 +512,7 @@
"GET": [
"One of the following:",
"* [Bulk string reply](../topics/protocol.md#bulk-strings): the value of the key.",
"* [Null reply](../topics/protocol.md#nulls): key does not exist."
"* [Null reply](../topics/protocol.md#nulls): if the key does not exist."
],
"GETBIT": [
"The bit value stored at _offset_, one of the following:",
Expand All @@ -537,7 +537,7 @@
"* [Null reply](../topics/protocol.md#nulls): if the key does not exist."
],
"HDEL": [
"[Integer reply](../topics/protocol.md#integers): The number of fields that were removed from the hash, excluding any specified but non-existing fields."
"[Integer reply](../topics/protocol.md#integers): the number of fields that were removed from the hash, excluding any specified but non-existing fields."
],
"HELLO": [
"[Map reply](../topics/protocol.md#maps): a list of server properties.",
Expand All @@ -560,13 +560,13 @@
"[Integer reply](../topics/protocol.md#integers): the value of the field after the increment operation."
],
"HINCRBYFLOAT": [
"[Bulk string reply](../topics/protocol.md#bulk-strings): The value of the field after the increment operation."
"[Bulk string reply](../topics/protocol.md#bulk-strings): the value of the field after the increment operation."
],
"HKEYS": [
"[Array reply](../topics/protocol.md#arrays): a list of fields in the hash, or an empty list when the key does not exist."
],
"HLEN": [
"[Integer reply](../topics/protocol.md#integers): the number of the fields in the hash, or 0 when the key does not exist."
"[Integer reply](../topics/protocol.md#integers): the number of fields in the hash, or 0 when the key does not exist."
],
"HMGET": [
"[Array reply](../topics/protocol.md#arrays): a list of values associated with the given fields, in the same order as they are requested."
Expand Down Expand Up @@ -711,7 +711,7 @@
"[Array reply](../topics/protocol.md#arrays): a list of sub-commands and their descriptions."
],
"MEMORY MALLOC-STATS": [
"[Bulk string reply](../topics/protocol.md#bulk-strings): The memory allocator's internal statistics report."
"[Bulk string reply](../topics/protocol.md#bulk-strings): the memory allocator's internal statistics report."
],
"MEMORY PURGE": [
"[Simple string reply](../topics/protocol.md#simple-strings): `OK`."
Expand Down Expand Up @@ -820,7 +820,7 @@
"* [Integer reply](../topics/protocol.md#integers): `0` if no HyperLogLog internal registers were altered."
],
"PFCOUNT": [
"[Integer reply](../topics/protocol.md#integers): the approximated number of unique elements observed via `PFADD`"
"[Integer reply](../topics/protocol.md#integers): the approximated number of unique elements observed via `PFADD`."
],
"PFDEBUG": [],
"PFMERGE": [
Expand Down Expand Up @@ -943,7 +943,7 @@
"* The second element is an [Array reply](../topics/protocol.md#arrays) with the names of scanned keys."
],
"SCARD": [
"[Integer reply](../topics/protocol.md#integers): The cardinality (number of elements) of the set, or 0 if the key does not exist."
"[Integer reply](../topics/protocol.md#integers): the cardinality (number of elements) of the set, or `0` if the key does not exist."
],
"SCRIPT": [],
"SCRIPT DEBUG": [
Expand Down Expand Up @@ -1074,10 +1074,10 @@
"[Set reply](../topics/protocol.md#sets): the resulting set."
],
"SINTERCARD": [
"[Integer reply](../topics/protocol.md#integers): the number of the elements in the resulting intersection."
"[Integer reply](../topics/protocol.md#integers): the number of elements in the resulting intersection."
],
"SINTERSTORE": [
"[Integer reply](../topics/protocol.md#integers): the number of the elements in the result set."
"[Integer reply](../topics/protocol.md#integers): the number of elements in the resulting set."
],
"SISMEMBER": [
"One of the following:",
Expand Down Expand Up @@ -1133,15 +1133,15 @@
"* [Array reply](../topics/protocol.md#arrays): when the optional _count_ argument is passed, the command returns an array of members, or an empty array when _key_ doesn't exist."
],
"SREM": [
"[Integer reply](../topics/protocol.md#integers): Number of members that were removed from the set, not including non existing members."
"[Integer reply](../topics/protocol.md#integers): the number of members that were removed from the set, not including non existing members."
],
"SSCAN": [
"[Array reply](../topics/protocol.md#arrays): specifically, an array with two elements:",
"* The first element is a [Bulk string reply](../topics/protocol.md#bulk-strings) that represents an unsigned 64-bit number, the cursor.",
"* The second element is an [Array reply](../topics/protocol.md#arrays) with the names of scanned members."
],
"SSUBSCRIBE": [
"When successful, this command doesn't return anything. Instead, for each shard channel, one message with the first element being the string 'ssubscribe' is pushed as a confirmation that the command succeeded. Note that this command can also return a -MOVED redirect."
"When successful, this command doesn't return anything. Instead, for each shard channel, one message with the first element being the string `ssubscribe` is pushed as a confirmation that the command succeeded. Note that this command can also return a -MOVED redirect."
],
"STRLEN": [
"[Integer reply](../topics/protocol.md#integers): the length of the string stored at key, or 0 when the key does not exist."
Expand All @@ -1156,7 +1156,7 @@
"[Set reply](../topics/protocol.md#sets): the resulting set."
],
"SUNIONSTORE": [
"[Integer reply](../topics/protocol.md#integers): Number of the elements in the resulting set."
"[Integer reply](../topics/protocol.md#integers): the number of elements in the resulting set."
],
"SUNSUBSCRIBE": [
"When successful, this command doesn't return anything. Instead, for each shard channel, one message with the first element being the string `sunsubscribe` is pushed as a confirmation that the command succeeded."
Expand Down Expand Up @@ -1362,19 +1362,19 @@
"[Integer reply](../topics/protocol.md#integers): the number of members removed from the sorted set, not including non-existing members."
],
"ZREMRANGEBYLEX": [
"[Integer reply](../topics/protocol.md#integers): Number of members removed."
"[Integer reply](../topics/protocol.md#integers): the number of members removed."
],
"ZREMRANGEBYRANK": [
"[Integer reply](../topics/protocol.md#integers): Number of members removed."
"[Integer reply](../topics/protocol.md#integers): the number of members removed."
],
"ZREMRANGEBYSCORE": [
"[Integer reply](../topics/protocol.md#integers): Number of members removed."
"[Integer reply](../topics/protocol.md#integers): the number of members removed."
],
"ZREVRANGE": [
"* [Array reply](../topics/protocol.md#arrays): a list of members in the specified range, optionally with their scores if _WITHSCORE_ was used."
"* [Array reply](../topics/protocol.md#arrays): a list of the members in the specified range, optionally with their scores if _WITHSCORE_ was used."
],
"ZREVRANGEBYLEX": [
"[Array reply](../topics/protocol.md#arrays): List of the elements in the specified score range."
"[Array reply](../topics/protocol.md#arrays): a list of the members in the specified score range."
],
"ZREVRANGEBYSCORE": [
"* [Array reply](../topics/protocol.md#arrays): a list of the members and, optionally, their scores in the specified score range."
Expand All @@ -1393,7 +1393,7 @@
"ZSCORE": [
"One of the following:",
"* [Double reply](../topics/protocol.md#doubles): the score of the member (a double-precision floating point number).",
"* [Nil reply](../topics/protocol.md#bulk-strings): if _member_ does not exist in the sorted set, or the key does not exist."
"* [Null reply](../topics/protocol.md#nulls): if _member_ does not exist in the sorted set, or the key does not exist."
],
"ZUNION": [
"[Array reply](../topics/protocol.md#arrays): the result of the union with, optionally, their scores when _WITHSCORES_ is used."
Expand Down

0 comments on commit fffb5dd

Please sign in to comment.