I would like to persist some cache items so I set EnableCachePersistence=true in my web config. DNN is set to use file based caching. Now the portal will not load because it hits the following error trying to load the portal dictionary: Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NotSupportedException: The type System.Collections.Generic.Dictionary`2[[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] is not supported because it implements IDictionary.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. |
Stack Trace:
[NotSupportedException: The type System.Collections.Generic.Dictionary`2[[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] is not supported because it implements IDictionary.]
System.Xml.Serialization.TypeScope.GetDefaultIndexer(Type type, String memberInfo) +833810
System.Xml.Serialization.TypeScope.ImportTypeDesc(Type type, MemberInfo memberInfo, Boolean directReference) +860
System.Xml.Serialization.TypeScope.GetTypeDesc(Type type, MemberInfo source, Boolean directReference, Boolean throwOnError) +150
System.Xml.Serialization.ModelScope.GetTypeModel(Type type, Boolean directReference) +82
System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping(Type type, XmlRootAttribute root, String defaultNamespace) +59
System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace) +320
System.Xml.Serialization.XmlSerializer..ctor(Type type) +6
DotNetNuke.Common.Utilities.XmlUtils.Serialize(Object obj) +60
DotNetNuke.Services.Cache.FileBasedCachingProvider.FBCachingProvider.CreateCacheFile(String FileName, Object ObjectToPersist) +18
DotNetNuke.Services.Cache.FileBasedCachingProvider.FBCachingProvider.Insert(String CacheKey, Object objObject, Boolean PersistAppRestart) +88
DotNetNuke.Entities.Portals.PortalController.GetPortalDictionary() +100
DotNetNuke.Entities.Portals.PortalController.GetPortal(Int32 PortalId) +289
DotNetNuke.Entities.Portals.PortalSettings.GetPortalSettings(Int32 TabId, PortalAliasInfo objPortalAliasInfo) +121
DotNetNuke.Entities.Portals.PortalSettings..ctor(Int32 tabId, PortalAliasInfo objPortalAliasInfo) +83
DotNetNuke.HttpModules.UrlRewriteModule.OnBeginRequest(Object s, EventArgs e) +5773
System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +92
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64
|
Server Error in '/Dotnetnuke' Application.
The type System.Collections.Generic.Dictionary`2[[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] is not supported because it implements IDictionary.
Have I done something wrong here? Has anyone else had success with persistent file based caching?