Cannot turn off User caching

Jaroslav Šebok asked on June 29, 2018 15:02

Hi, I want to turn off user caching or caching in general. I tried:

  • Setting cms.user|all in my custom webpart in the Partial cache dependencies property with the Use default cache dependencies unchecked also Partial cache minutes set to 0
  • Calling CacheHelper.Remove("cms.user|all"); in OnLoad method of the custom web part (its a webpart for loging in)
  • Setting everything to zero in Settings->System->Performance than setting everything to 1 minute as well

When I set everything to zero in Settings->System->Performance it takes 2 minutes to take effect.

The field that I always need to be updated from the database is UserEnabled.

Recent Answers


Brenden Kehren answered on June 29, 2018 15:24

Couple things, I suggest leaving the Settings properties as they are or you'll mess up the rest of the site's performance.

On your "custom" web part:

  • remove any custom caching API code
  • set the partial cache dependencies property to 0
  • ensure you custom code is implemented properly in the web part, meaning you're not loading data on the page load or pre-render. You need to implement it like the other web parts have it implemented or like the documentation shows.
0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.