views:

21

answers:

0

We have some problem with dissapearing content in UserControl when OutputCache used.

Sometimes it just does not display.

And it displayed again when cache duration expired.

When we restart application pool it become noramaly for a few time.

We cache news with: <%@ OutputCache Duration="300" VaryByParam="none" VaryByCustom="NewsControlList" %>

and in Global.asax: public override string GetVaryByCustomString(HttpContext context, string custom) { switch (custom) { .... case "NewsControlList": return string.Format( "ImportNewsControlList_{0}Domain{1}ShowAllNews{2}" // custom key , LanguagesUtility.UserLanguageId // current site language, (multi-language site) , WebSite.SubDomain // depend on current domain , context.Request["showallnews"].NotIsNullOrEmpty() && context.Request["showallnews"] == "1" ? "1" : "0" // param in request ); ...

Does anyone had a similar problem?