redis提供的6种数据淘汰策略

1.volatile-lru: 从已设置过期时间的数据集(server.db[i].expire)中挑选最近最少使用的数据淘汰。

1.volatile-ttl: 从已设置过期时间的数据集(server.db[i].expire)中挑选将要过期的数据淘汰。 

1.volatile-random: 从已设置过期时间的数据集(server.db[i].expire)中任意数据淘汰。 

1.allkeys-lru:从数据集(server.db[i].dict)中挑选最近最少使用的数据淘汰。 

1.allkeys-random: 从数据集(server.db[i].dict)中挑选任意选择数据淘汰。

1.no-enviction(驱逐): 禁止驱逐数据

猜你喜欢

转载自blog.csdn.net/LQzhang_11/article/details/81173114