Output cache not used. Reason: User can view an unpublished version of the current page
I was trying to enable output caching on an authenticated MOSS site and followed the below steps:
- Site Actions -> Modify Site Settings -> Modify All Site Settings
- Site Collection Administration -> Site Collection Output Cache
- In here, I enabled the cache profile, disabled anonymous cache profile, set the authenticated cache profile to Extranet(Published Site)
- I also enabled the "Enable debug cache information on Pages" to check if the caching was working as expected
- Now, I logged in as the site administrator and checked the html source of the page. Instead of seeing the following message: "Rendered using cache profile:Extranet (Published Site) at: 2008- 02-24T10:08:03", this message came up : "8 Output cache not used. Reason: User can view an unpublished version of the current page".
- The above was expected because, I was logged in as a site collection administrator. I logged off and logged in as a different user(reader access) and still was seeing the same message : "8 Output cache not used. Reason: User can view an unpublished version of the current page. "
- I tried using different user id's but was still the same error message.
- So, I went back to the site collection output cache profiles page and modified the Extranet(Published Site) property as shown below:
- After this is done, I logged in as a reader and behold ! It works as expected spitting out a cached version of the page.
- But the downside to the above setting is that the writers will be seeing a cached version of the page. I still need to figure out why the readers were able to see a unpublished version of the page.
1 comment:
I had the same problem, it appears that if your users can edit ANYTHING underneath the root of the site then you'll get this debug response, what a pain.
Post a Comment