到期缓存对象 [英] expire cache object
本文介绍了到期缓存对象的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
使用以下命令
using below command
N ew-cache CACHE1 -Expirable True -TimeToLive 2
我创建了一个缓存对象CACHE1过期时间为2分钟
所以,2分钟后,我执行了Get-Cache命令,那时我可以看到CACHE1仍在服务器上,为什么它不会过期?
一段时间后如何使对象过期?
先谢谢,Jeyaseelan
Thanks In Advance, Jeyaseelan
推荐答案
为了清楚起见:CACHE1是缓存的名称。缓存不可过期。只有缓存中的项目会过期。因此Get-Cache将继续显示Cache1。如果使用DataCache成员在CACHE1中添加内容,则该项目将在2分钟后过期。
Just to be clear: CACHE1 is the name of your cache. Caches are not expirable. Only items within a cache expire. So Get-Cache will continue to show Cache1. If you add something inside CACHE1 using the DataCache members, that item should expire in 2 minutes.
一般来说,通过查看
效果指标。
这篇关于到期缓存对象的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文