Working on a legacy ASP.NET application we’ve found that ASP.NET session gets used for caching some objects, but for some objects Microsoft.Practices.EnterpriseLibrary.Caching gets used.
Is there any reason to use Microsoft.Practices.EnterpriseLibrary.Caching over standard ASP.NET Session?
Edit
In my scenario, the Enterprise Library caching is actually being used to cache per-user data by appending the ASP.NET Session ID to the cached item’s key.
Session and Cache are different concepts.
If you want to share the object between all users of your site you should use Cache while Session is for storing user specific data.
So your question should not be:
but:
and the answer to this question as always is: it depends on your scenario. This article provides an overview of where can the Caching Application Block be used and what issues does it try to resolve.