Banzai Page Caching - More Info?

The new page caching feature in Banzai ( sounds very promising, probably the most exciting part of the release for PractiFI.

I’ve been doing a little playing around with it, but can’t get my head around it just yet, so I have a few questions. My objective is to make our quite complex pages as blazingly fast as possible, whilst minimising the occurrences of stale data.

  1. What’s the technical difference between processing a model server side vs client side? If the models are processed client side, presumably the rest of the page XML is cached?
  2. How does caching work in conjunction with page includes? Are the contents of page includes cached? Should the included page itself have caching turned on, and its models set to load client side?
  3. Similarly, how does caching work in conjunction with tabs that are set to lazy load?
  4. Let’s say we have an account detail page in Skuid. Does caching speed up performance for every view of every account, or just every repeat view (within the timeout period) to a previously viewed account?
  5. Our Skuid pages are housed in Visualforce pages, and those Visualforce pages have caching turned on. That makes repeat views of previously viewed records super fast, but it creates problems with stale data (which we need to handle with clever model requerying in Skuid) and stale session cookies. If we use Banzai’s page caching to its fullest, I’m hoping we can turn off Visualforce caching. Does that sound feasible?
Thanks guys.

  1. When you choose to "Process a Model Client Side", Skuid does zero-parsing of a Model's XML on the server during initial page load --- rather, as soon as the page has done its initial bootstrap, Skuid will then parse the XML for the Model client-side and fetch necessary metadata / data from the server in a separate HTTP request. The end result Models should be identical, having the same metadata and data whether the Model was processed server-side on initial page load or processed immediately after page load on the client. The difference is that the "process client side" Models will not "delay" the initial page load, nor will they be counted as part of the initial page HTTP GET request. 

Will follow up with responses to 2-5 soon.

Can I give this a bump please Zach? I’m hugely keen to get PractiFI moving on this.

Zach … any news here mate?

On point 2, I’ve tried using caching with page includes and as far as I can see they’re not happy bedfellows. Every time I’ve tried, the include fails to load with a console error: “Uncaught TypeError: Cannot set property ‘doQuery’ of undefined”

Long overdue update:

  1. (Answered earlier)
  2. Page Include Caching currently does not work due to a bug that we are working to address in an upcoming Banzai update. Once the bugs are addressed, Page Include Caching should work as long as you are either viewing the parent page from /apex/skuid__UI, or, if you are using a local clone of the “Include” VF Page included in the Skuid package, you will need to add the attributes cache=“true” and expires=“600” (or whatever you’d like the cache expiration milliseconds to be) to your local clone of this VF Page. We will try to keep you updated on the Page Include caching bug.
  3. Same answer as point 2, since tab “lazy loading” leverages Page Includes.
  4. Currently, caching speeds up performance for every repeat view of a given page. Currently a “Page” is a unique URL, so if you’ve got an Account Tab page, each page view hits the same URL, so the same page gets cached. If you’ve got an Account Detail page, the URL is different for each Account so you would only be getting cached results if you’re viewing the same Account repeat times within the timeout period. 
  5. Current state, Skuid Page Caching is leveraging Visualforce caching - so you need to have the cache attribute on your custom VF override pages set to cache=“true” in order to use Skuid Page Caching. The approach we use may change in the future, but that’s what Banzai Page Caching is making use of. Regarding stale data — this can be avoided by selecting “Process model client-side”. Regarding stale session cookies - no recommended workarounds right now.

Thanks Zach, very useful.

On point 2, we already have a local clone of the Include VF page. But how do we configure the Skuid page include component to utilise it?

The fix to Page Include caching is now available from the Skuid Releases page in Banzai Update 6.

Glenn, to modify your local clone of the Include VF Page to utilize these utilities, do the following:

1. Install Banzai Update 6
2. Change the Skuid package API Version of your Include VF page to be 7.27
3. Re-copy the contents of the Include VF Page in the Skuid package into the contents of your local cloned Include VF Page.
4. Save.

Great. Giving this a try now. Thanks mate.