开发者

how to limit number of entries in a db of redis

开发者 https://www.devze.com 2023-04-12 18:51 出处:网络
I am running a redis instance and want to limit the number of keys in an DB of the instance. I checke the documentation and I 开发者_StackOverflow社区saw that we can limit the memory of a complete ins

I am running a redis instance and want to limit the number of keys in an DB of the instance. I checke the documentation and I 开发者_StackOverflow社区saw that we can limit the memory of a complete instance .Any way to do that on DB level?

Thanks in Advance.


No, Redis does not have a function that can limit the amount of keys in the database.

The closest thing I can think of is checking the key number in your script, and the preventing the query of there is too many keys in the databse

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号