缓存数据.Net 4.0 (Asp.NET)
有人能详细解释一下什么是“CacheSpecificEviction
”以及如何避免它吗?
我在 CacheEntryRemovedArguments.RemovedReason 中得到了这个。
Can anybody explane me what is "CacheSpecificEviction
" in detail and how to avoid it?
I am geting this in CacheEntryRemovedArguments.RemovedReason
.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
CacheSpecificEviction 作为删除缓存条目的原因意味着“该项目已被删除,因为缓存提供程序的驱逐策略确定它应该被删除” - 我知道,它非常不具体,但它很难更具体,因为有许多可能的缓存引擎实现及其不同的驱逐策略(通常是可配置的,例如在 AppFabric Cache 又名 Velocity 中)。一般来说,驱逐意味着“好吧,存在内存不足的风险,我们应该删除一些项目 - 例如这些最近最少使用的(LRE 驱逐策略),或者可能是动态老化中最不频繁使用的(LFDA)等。” 。因此,为了摆脱驱逐问题,您应该检查缓存内存使用情况和限制、驱逐配置选项......
CacheSpecificEviction as reason for removing cache entry means "the item was removed, because the cache provider's eviction policy determined it should be removed" - I know, it is pretty unspecific, but it hardly can be more specific, because of many possible cache-engine implementations and their different eviction policies (often configurable, for example in AppFabric Cache aka Velocity). In generel, eviction means "ok, there are risk of running out of memory, we should remove some items - for example these Least Recently Used (LRE eviction policy), or maybe Least Frequently Used with Dynamic Aging (LFDA), etc.". So to get rid of eviction problems, you sould check your cache memory usage and limits, eviction configuration options...