Skip Navigation

[Resolved] New Views version -Improved the front-end caching system for Views and archives

This support ticket is created 4 years, 10 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

Tagged: 

This topic contains 5 replies, has 2 voices.

Last updated by bobA-2 4 years, 10 months ago.

Assisted by: Christian Cox.

Author
Posts
#1503591

Is there somewhere where I can read more about the Improved the front-end caching system for Views and archives introduced in Views 3.1.0?

How does it work? After I updated from 3.0.2 today I noticed a new post not showing up and I needed to clear the frontend view cache manually for it show up for logged in user. I then again had to clear WP Rocket cache for it to show up for users not logged in.

I hope I do not have to do this from now on? Can it be turned off or do I have to go back to 3.0.2 where it worked fine.

#1503839

Hi, I just checked our internal tickets about this changelog entry. The Views caching mechanism was improved to add WPML support and caching in all languages. You can also see caching information about each View by going to Toolset > Views. There is a column in the listing that explains whether or not the View's information has been cached. The Views cache should now be invalidated when:
- creating, deleting or editing an object from the family of the ones returned by the View. For example, if a View lists posts of the custom type book, when a new book is created, or one is edited or deleted; likewise, when listing categories, or when lsiting users with a role of administrator.
- editing the View itself.
- clicking the admin listing page column button that offers to just do that cache cleaning.

You can manually turn off Views caching for any View by adding cached="off" to the shortcode:

[wpv-view name="Your View name" cached="off"]

Caching by WP Rocket is completely independent of Views caching, so you would have to refer to their documentation to understand when caches are cleared and when you must manually clear them.

#1503855

Thanks for your reply. The new version does not seem invalidate the cache from the family of the ones returned by the View for me. Even when WP Rocket is not active. Adding cached="off" seems like a lot of work as I use many views on different posts...

My clone site does not seem to have the issue. So I will investigate further.

#1503875

I will stand by for your update.

#1504133

After some extended testing it turned out to be something to do with transients in the DB. I was able to reproduce after a new clone of my production site. Then I did a DELETE FROM `wp_options` WHERE `option_name` LIKE ('%\_transient\_%') on the production site db. After that I have tested several times and new posts end edit posts are reflected in the view unlike before.

#1504135

My issue is resolved now. Thank you!