How can I add a restriction like clients can't add elements to Redis List if size of the redis list is greater than number? -


my use case redis client should not allowed add new elements in redis list if size of redis list greater number. basically, want make bounded list.

i can 2 redis commands. first, execute llen command length of list , allowed add element if length not maxed.

can using 1 command (atomic operation) instead of two?


Comments

Popular posts from this blog

ZeroMQ on Windows, with Qt Creator -

unity3d - Unity SceneManager.LoadScene quits application -

python - Error while using APScheduler: 'NoneType' object has no attribute 'now' -