redis可以存儲多少key?
官方說單例能處理key:2.5億個,參考鏈接:https://Redis.io/topics/faq,以下是原話:What is the maximum number of keys a single Redis instance can hold? and what the max number of elements in a Hash, List, Set, Sorted Set?
Redis can handle up to 2^32 keys, and was tested in practice to handle at least 250 million keys per instance.
Every hash, list, set, and sorted set, can hold 2^32 elements.
In other words your limit is likely the available memory in your system.
不同的數據類型存儲量會有差異:
原文地址:https://redis.io/topics/data-types
Strings類型:一個String類型的value最大可以存儲512M
Lists類型:list的元素個數最多為2^32-1個,也就是4294967295個。
Sets類型:元素個數最多為2^32-1個,也就是4294967295個。
Hashes類型:鍵值對個數最多為2^32-1個,也就是4294967295個。
Sorted sets類型:跟Sets類型相似。
上一篇NET發展前景如何