MemoryCache class needs a Clear() method - by admac

Status : 

  Deferred<br /><br />
		The product team has reviewed this issue and has deferred it for consideration at a later time.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 723620 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 2/6/2012 5:06:52 AM
Access Restriction Public


The .NET 4 MemoryCache class in System.Runtime.Caching needs a Clear() method, to allow completely clearing the MemoryCache.Default cache. There is no such method.

You could get an enumerator and individually remove all keys, but the MSDN documentation says don't use the GetEnumerator method!

Sign in to post a comment.
Posted by Microsoft on 12/4/2012 at 9:23 AM
Closing this bug for now. Product team will take a look at this suggestion for future release.
Posted by Microsoft on 2/8/2012 at 3:14 PM
Thank you for the suggestion. We're tracking this internally for a future release.
Posted by MS-Moderator08 [Feedback Moderator] on 2/6/2012 at 6:51 PM
Thank you for submitting feedback on Visual Studio 2010 and .NET Framework. Your issue has been routed to the appropriate VS development team for investigation. We will contact you if we require any additional information.
Posted by MS-Moderator01 on 2/6/2012 at 5:41 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(