Fragment Cache questions???
-
Does anybody have experiences with Fragment cache? I have some trouble here... Basically, I have 3 dropdownlists, ddlAccountGroupType, ddlGroupName and ddlAccountID in a user control. The reason I use cache varybycontrol because ddlAccountID could contain over 8000 accounts. Once the selected index is changed in ddlAccountID, it will raise event handler to trigger the parent page to retrieve Order list and allow user to edit the order details. So, I have <%@OutputCache duration="600" varybycontrol="ddlAccountGroupType;ddlGroupName;ddlAccountID" %> on my .ascx file. The problem is , sometimes, when parent page do a postback, the second dropdownlist ddlGroupname become empty when it was supposed to have one single item "--ALL--". I couldn't figure out why it happens. I read about some discussion said, under memory pressure, the cached data could be removed before it reaches its expire date. Did anyone have similiar issue? I know you can set programmatic cache NotRemovable. Is there a way to set fragement cache NotRemovable? By the way, I read something about Cache does not work with Web Farms. Although my problem happens on my local development server, but my production server does use web farm. Do anyone have any thoughts or suggestions about this? Any help would be very appreciated! Thanks in advance!
-
Does anybody have experiences with Fragment cache? I have some trouble here... Basically, I have 3 dropdownlists, ddlAccountGroupType, ddlGroupName and ddlAccountID in a user control. The reason I use cache varybycontrol because ddlAccountID could contain over 8000 accounts. Once the selected index is changed in ddlAccountID, it will raise event handler to trigger the parent page to retrieve Order list and allow user to edit the order details. So, I have <%@OutputCache duration="600" varybycontrol="ddlAccountGroupType;ddlGroupName;ddlAccountID" %> on my .ascx file. The problem is , sometimes, when parent page do a postback, the second dropdownlist ddlGroupname become empty when it was supposed to have one single item "--ALL--". I couldn't figure out why it happens. I read about some discussion said, under memory pressure, the cached data could be removed before it reaches its expire date. Did anyone have similiar issue? I know you can set programmatic cache NotRemovable. Is there a way to set fragement cache NotRemovable? By the way, I read something about Cache does not work with Web Farms. Although my problem happens on my local development server, but my production server does use web farm. Do anyone have any thoughts or suggestions about this? Any help would be very appreciated! Thanks in advance!