You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using the MEMORY STATS command, older clients use db.x to recognize a substructure related to a specific database. Like db.0 has values containing overhead.hashtable.main and overhead.hashtable.expires.
Unfortunately, a new metric named db.dict.rehashing.count breaks older clients due to the prefix of db.. This makes it impossible to execute MEMORY STATS from these clients.
Specifically, in python-redis, in function parse_memory_stats, a line of code was changed:
if key.startswith("db."): # OLD
if key.startswith("db.") and isinstance(value, list): # NEW
Recommend renaming this metric to avoid the use of db. as a prefix.
To reproduce
Use an older version of python-redis and execute: client.memory_stats(). It will throw an exception.
Expected behavior
No exception
The text was updated successfully, but these errors were encountered:
Yeah, it was also a change we inherited from Redis: redis/redis#12913. I'm not sure we can easily diverge at this point. It's probably we could we remember this to avoid doing this in the future, but I agree I think we need to keep it.
Describe the bug
Using the
MEMORY STATS
command, older clients usedb.x
to recognize a substructure related to a specific database. Likedb.0
has values containingoverhead.hashtable.main
andoverhead.hashtable.expires
.Unfortunately, a new metric named
db.dict.rehashing.count
breaks older clients due to the prefix ofdb.
. This makes it impossible to executeMEMORY STATS
from these clients.Specifically, in
python-redis
, in functionparse_memory_stats
, a line of code was changed:Recommend renaming this metric to avoid the use of
db.
as a prefix.To reproduce
Use an older version of
python-redis
and execute:client.memory_stats()
. It will throw an exception.Expected behavior
No exception
The text was updated successfully, but these errors were encountered: