Convert HttpContext current cache to LINQ
I am trying to find a specific key within the current Cache. Problem is, my key in the cache are composite, and I would like to run like a Linq Where expression.
Is this possible? if so - 开发者_如何学Chow? does it reduce performance on the server?
Thanks
The whole idea behind a key is that it enables direct lookup of the item. If you have to scan all the items in the cache to find what you're looking for that's not going to perform very well at all. If you're using AppFabric Caching you can "tag" similar items with the same tag and then pull back all the items from the cache with that "tag" with a single call, but there is no such concept in the built in standard ASP.NET caching classes.
精彩评论