Open draftpin opened 1 week ago
Describe the bug If you set HEXPIRE on key, then it is not removed automatically until HGET / HGETALL is called
To Reproduce Steps to reproduce the behavior:
redis-cli HSET testSet test testValue HEXPIRE testSet 5 FIELDS 1 test (integer) 1 HLEN testSet (integer) 1 HLEN testSet (integer) 1 HLEN testSet (integer) 1 ... will show 1 infinitely until HGET / HGETALL will called HGETALL testSet (empty array) HLEN testSet (integer) 0
Expected behavior Should automatically remove key when timeout is triggered, after that HLEN should return 0
Screenshots No need, easy to reproduce
Environment (please complete the following information):
Reproducible Code Snippet
# See above
Additional context On native Redis server (redis_version:7.4.1) there is no such problem:
127.0.0.1:6379> HSET testSet test testValue (integer) 1 127.0.0.1:6379> HEXPIRE testSet 5 FIELDS 1 test 1) (integer) 1 127.0.0.1:6379> HLEN testSet (integer) 1 127.0.0.1:6379> HLEN testSet (integer) 1 127.0.0.1:6379> HLEN testSet (integer) 1 127.0.0.1:6379> HLEN testSet (integer) 0 127.0.0.1:6379> HLEN testSet (integer) 0
Hi @draftpin, thank you for reporting. That's a limitation of the current implication and I am not sure when this will be planned.
cc @romange
Describe the bug If you set HEXPIRE on key, then it is not removed automatically until HGET / HGETALL is called
To Reproduce Steps to reproduce the behavior:
Expected behavior Should automatically remove key when timeout is triggered, after that HLEN should return 0
Screenshots No need, easy to reproduce
Environment (please complete the following information):
Reproducible Code Snippet
Additional context On native Redis server (redis_version:7.4.1) there is no such problem: