Commit 72935b9d authored by Vitaly Arbuzov's avatar Vitaly Arbuzov
Browse files

Merge branch 'unstable' into dict-split-by-slot

parents 6baf20af 6948daca
...@@ -32,6 +32,10 @@ ...@@ -32,6 +32,10 @@
} }
} }
], ],
"reply_schema": {
"description": "The cardinality (number of elements) of the sorted set, or 0 if key does not exist",
"type": "integer"
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -33,6 +33,10 @@ ...@@ -33,6 +33,10 @@
} }
} }
], ],
"reply_schema": {
"description": "The number of elements in the specified score range",
"type": "integer"
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -33,6 +33,36 @@ ...@@ -33,6 +33,36 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"description": "A list of members. Returned in case `WITHSCORES` was not used.",
"type": "array",
"items": {
"type": "string"
}
},
{
"description": "Members and their scores. Returned in case `WITHSCORES` was used. In RESP2 this is returned as a flat array",
"type": "array",
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"description": "Member",
"type": "string"
},
{
"description": "Score",
"type": "number"
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "numkeys", "name": "numkeys",
......
...@@ -52,6 +52,10 @@ ...@@ -52,6 +52,10 @@
} }
} }
], ],
"reply_schema": {
"description": "Number of elements in the resulting sorted set at `destination`",
"type": "integer"
},
"arguments": [ "arguments": [
{ {
"name": "destination", "name": "destination",
......
...@@ -35,6 +35,10 @@ ...@@ -35,6 +35,10 @@
} }
} }
], ],
"reply_schema": {
"description": "The new score of `member`",
"type": "number"
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -33,6 +33,36 @@ ...@@ -33,6 +33,36 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"description": "Result of intersection, containing only the member names. Returned in case `WITHSCORES` was not used.",
"type": "array",
"items": {
"type": "string"
}
},
{
"description": "Result of intersection, containing members and their scores. Returned in case `WITHSCORES` was used. In RESP2 this is returned as a flat array",
"type": "array",
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"description": "Member",
"type": "string"
},
{
"description": "Score",
"type": "number"
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "numkeys", "name": "numkeys",
......
...@@ -33,6 +33,11 @@ ...@@ -33,6 +33,11 @@
} }
} }
], ],
"reply_schema": {
"description": "Number of elements in the resulting intersection.",
"type": "integer",
"minimum": 0
},
"arguments": [ "arguments": [
{ {
"name": "numkeys", "name": "numkeys",
......
...@@ -52,6 +52,11 @@ ...@@ -52,6 +52,11 @@
} }
} }
], ],
"reply_schema": {
"description": "Number of elements in the resulting sorted set.",
"type": "integer",
"minimum": 0
},
"arguments": [ "arguments": [
{ {
"name": "destination", "name": "destination",
......
...@@ -33,6 +33,11 @@ ...@@ -33,6 +33,11 @@
} }
} }
], ],
"reply_schema": {
"description": "Number of elements in the specified score range.",
"type": "integer",
"minimum": 0
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -34,6 +34,45 @@ ...@@ -34,6 +34,45 @@
} }
} }
], ],
"reply_schema": {
"oneOf": [
{
"description": "No element could be popped.",
"type": "null"
},
{
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Name of the key that elements were popped."
},
{
"type": "array",
"description": "Popped elements.",
"items": {
"type": "array",
"uniqueItems": true,
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Name of the member."
},
{
"type": "number",
"description": "Score."
}
]
}
}
]
}
]
},
"arguments": [ "arguments": [
{ {
"name": "numkeys", "name": "numkeys",
......
...@@ -33,6 +33,22 @@ ...@@ -33,6 +33,22 @@
} }
} }
], ],
"reply_schema": {
"type": "array",
"minItems": 1,
"items": {
"oneOf": [
{
"type": "number",
"description": "The score of the member (a double precision floating point number). In RESP2, this is returned as string."
},
{
"type": "null",
"description": "Member does not exist in the sorted set."
}
]
}
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -34,6 +34,45 @@ ...@@ -34,6 +34,45 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"type": "array",
"description": "List of popped elements and scores when 'COUNT' isn't specified.",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Popped element."
},
{
"type": "number",
"description": "Score."
}
]
},
{
"type": "array",
"description": "List of popped elements and scores when 'COUNT' is specified.",
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Popped element."
},
{
"type": "number",
"description": "Score."
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -34,6 +34,45 @@ ...@@ -34,6 +34,45 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"type": "array",
"description": "List of popped elements and scores when 'COUNT' isn't specified.",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Popped element."
},
{
"type": "number",
"description": "Score."
}
]
},
{
"type": "array",
"description": "List of popped elements and scores when 'COUNT' is specified.",
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Popped element."
},
{
"type": "number",
"description": "Score."
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -35,6 +35,44 @@ ...@@ -35,6 +35,44 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"type": "null",
"description": "Key does not exist."
},
{
"type": "string",
"description": "Randomly selected element when 'COUNT' is not used."
},
{
"type": "array",
"description": "Randomly selected elements when 'COUNT' is used.",
"items": {
"type": "string"
}
},
{
"type": "array",
"description": "Randomly selected elements when 'COUNT' and 'WITHSCORES' modifiers are used.",
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "string",
"description": "Element."
},
{
"type": "number",
"description": "Score."
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -38,6 +38,38 @@ ...@@ -38,6 +38,38 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"description": "A list of member elements",
"type": "array",
"uniqueItems": true,
"items": {
"type": "string"
}
},
{
"description": "Members and their scores. Returned in case `WITHSCORES` was used. In RESP2 this is returned as a flat array",
"type": "array",
"uniqueItems": true,
"items": {
"type": "array",
"minItems": 2,
"maxItems": 2,
"items": [
{
"description": "Member",
"type": "string"
},
{
"description": "Score",
"type": "number"
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -37,6 +37,14 @@ ...@@ -37,6 +37,14 @@
} }
} }
], ],
"reply_schema": {
"type": "array",
"description": "List of elements in the specified score range.",
"uniqueItems": true,
"items": {
"type": "string"
}
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -43,6 +43,40 @@ ...@@ -43,6 +43,40 @@
} }
} }
], ],
"reply_schema": {
"anyOf": [
{
"type": "array",
"description": "List of the elements in the specified score range, as not WITHSCORES",
"uniqueItems": true,
"items": {
"type": "string",
"description": "Element"
}
},
{
"type": "array",
"description": "List of the elements and their scores in the specified score range, as WITHSCORES used",
"uniqueItems": true,
"items": {
"type": "array",
"description": "Tuple of element and its score",
"minItems": 2,
"maxItems": 2,
"items": [
{
"description": "element",
"type": "string"
},
{
"description": "score",
"type": "number"
}
]
}
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
...@@ -51,6 +51,10 @@ ...@@ -51,6 +51,10 @@
} }
} }
], ],
"reply_schema": {
"type": "integer",
"description": "Number of elements in the resulting sorted set."
},
"arguments": [ "arguments": [
{ {
"name": "dst", "name": "dst",
......
...@@ -39,6 +39,32 @@ ...@@ -39,6 +39,32 @@
} }
} }
], ],
"reply_schema": {
"oneOf": [
{
"type": "null",
"description": "Key does not exist or the member does not exist in the sorted set."
},
{
"type": "integer",
"description": "The rank of the member when 'WITHSCORES' is not used."
},
{
"type": "array",
"description": "The rank and score of the member when 'WITHSCORES' is used.",
"minItems": 2,
"maxItems": 2,
"items": [
{
"type": "integer"
},
{
"type": "number"
}
]
}
]
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
...@@ -57,4 +83,4 @@ ...@@ -57,4 +83,4 @@
} }
] ]
} }
} }
\ No newline at end of file
...@@ -39,6 +39,11 @@ ...@@ -39,6 +39,11 @@
} }
} }
], ],
"reply_schema": {
"description": "The number of members removed from the sorted set, not including non existing members.",
"type": "integer",
"minimum": 0
},
"arguments": [ "arguments": [
{ {
"name": "key", "name": "key",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment