Protocol support: RESP3 by mgravell · Pull Request #2396 · StackExchange/StackExchange.Redis (original) (raw)

Hey @mgravell - I've been asking around a lot the last couple of days to see what I could pull together for you, the best resource I've found comes from @chayim - for background, Chayim is the engineering lead in charge of managing the clients team, so they've been doing most of the RESP2-> RESP3 upgrades for the clients Redis maintains, as you might imagine, they've been contending with these issues as well. He had a document his team pulled together from their collective wisdom that is a possibly incomplete list of the response changes when migrating from RESP2 -> RESP3. I've taken out the key table that we're most interested in, I've also shared a copy of the document in google drive - but I don't think anything else is super relevant to us here (I'll add the caveats from the document above the table here so it's clear).

@uglide is going to work on compiling a comprehensive list.

Caveats from the document

Table

Command RESP2 Reply RESP3 Reply
Connection Management
CLIENT INFO BlobString VerbatimString
CLIENT LIST BlobString VerbatimString
Server Management
MODULE LIST Array<[BlobString<‘name’>, BlobString, BlobString<‘version’>, number]> Array<{ name: BlobString, version: number }>
MEMORY STATS Array Map
ACL LOG [..., ‘age-seconds’, BlobString, …] { …, ‘age-seconds’: Double }
COMMAND INFO
Cluster Management
CLUSTER SLOTS Array<[number, number, ...[BlobString, number, BlobString, Array]]> Array<[number, number, ...[BlobString, number, BlobString, Map<BlobString, BlobString>]]>
Generic
RANDOMKEY BlobString null
String
LCS IDX Array Map
Hash
HGETALL Array Map
HRANDFIELD WITHVALUE Array Array<[BlobString, BlobString]>
Sorted Set
ZADD INCR BlobString Double
ZDIFF WITHSCORES Array Array<[BlobString, Double]>
ZINCRBY BlobString Double
ZINTER WITHSCORES Array Array<[BlobString, Double]>
ZMPOP null [BlobString, Array<[BlobString, BlobString]>]
ZMSCORE Array<null BlobString>
ZRANDMEMBER WITHSCORES Array Array<[BlobString, Double]>
ZSCORE BlobString Double
ZUNION WITHSCORES Array Array<[BlobString, Double]>
ZRANK WITHSCORE [number, BlobString] [number, Double]
ZREVRANK WITHSCORE [number, BlobString] [number, Double]
ZRANGE WITHSCORES Array Array<[BlobString, Double]
ZRANGEBYSCORE WITHSCORES Array Array<[BlobString, Double]
ZMPOP [BlobString, Array<[BlobString, BlobString]>] [BlobString, Array<[BlobString, Double]>]
BZPOPMAX null [BlobString, BlobString, BlobString]
BZPOPMIN null [BlobString, BlobString, BlobString]
ZPOPMIN null [BlobString, BlobString]
ZPOPMAX null [BlobString, BlobString]
Geo
GEORADIUS WITHCOORD [..., BlobString] [..., Double]
GEORADIUSBYMEMBER WITHCOORD [..., BlobString] [..., Double]
GEOSEARCH WITHCOORD [..., BlobString] [..., Double]
Streams
XINFO CONSUMERS Array Map
XINFO GROUPS Array Map
XINFO STREAM Array Map
XREAD Array<[BlobString, [BlobString, Array<[BlobString, BlobString]>]]> Map<BlobString, [BlobString, Array<[BlobString, BlobString]>]>
XREADGROUP Array<[BlobString, [BlobString, Array<[BlobString, BlobString]>]]> Map<BlobString, [BlobString, Array<[BlobString, BlobString]>]>
Functions
FUNCTION LIST Array<[‘library_name’, BlobString, ‘engine’, BlobString, ‘functions’, Array<[‘name’, BlobString, ‘description’, BlobString null, ‘flags’, Array]>]>
FUNCTION LIST WITHCODE Array<[‘library_name’, BlobString, ‘engine’, BlobString, ‘functions’, Array<[‘name’, BlobString, ‘description’, BlobString null, ‘flags’, Array]>, ‘library_code’, BlobString]>