I have a scenario where content can be updated via a SurfaceController.
Am using the ContentService and setting appropriate values, then saving with SaveAndPublishWithStatus(content)
In the backoffice the content get's updated however on the frontend is still showing the old version, either after refresh. Appears to be a caching issue and I'm assuming we're still seeing the XML cached version because if we then re-publish via the backoffice then the changes are reflected on the frontend.
We've tried a variety of SaveAndPublishWithStatus/PublishWithStatus and also legacy methods to force refresh of the cache but nothing appears to be working
SaveAndPublishWithStatus not updating XML cache?
I have a scenario where content can be updated via a SurfaceController.
Am using the ContentService and setting appropriate values, then saving with SaveAndPublishWithStatus(content)
In the backoffice the content get's updated however on the frontend is still showing the old version, either after refresh. Appears to be a caching issue and I'm assuming we're still seeing the XML cached version because if we then re-publish via the backoffice then the changes are reflected on the frontend.
We've tried a variety of SaveAndPublishWithStatus/PublishWithStatus and also legacy methods to force refresh of the cache but nothing appears to be working
Hello,
Had a look around and found an article on Stack overflow that had been answered which looks like the same issue as yours:
http://stackoverflow.com/questions/21681631/umbraco-contentservice-not-updating-checboxlist-in-document-cache
also : https://our.umbraco.org/documentation/reference/management/services/contentservice
Hope that helps! It looks like contentService.Publish(document); might do it?
Cheers, J
Thanks James,
It was a weird one and we tried all varieties of solutions because from what we could see, the code "should have" worked.
After closing VS and rebooting the machine it magically started working!
If in doubt switch it off and back on again.... !
is working on a reply...