We’ve made two significant improvements to SmartCache to make it smarter and reduce its performance footprint.
Automatic refresh of cached pages
Each retrieval of the dynamic areas of a “smartcached” page consists of retrieving the entire page from the origin and then separating the private part from the public part. The private part is then sent to the browser.
The public part was previously unused; it is now cached.
This change brings a very important feature: passive refreshment of cached pages. This avoids the need to manually purge the cache each time a product page is updated. In fact, as the same page is visited again and again, it is continually placed in the cache.
Loading private zones in JSONP
This change is technically more complex. Hang in there :).
Until now, the retrieval of a page’s private zone was done using AJAX. The browser could then download CSS, JS and images while waiting for the private area to be retrieved. As soon as the private elements were retrieved in AJAX and integrated into the DOM, the page was considered coherent, and execution of the JS was triggered via DeferJS.
The HTML preloader
For several years now, browsers have been equipped with a pre-loader that allows you to discover all the page’s static resources by analyzing the attributes of tags containing URLs. Knowing all the resources on the page enables them to apply prioritization rules to the download queue.

Here’s an example from one of our customers. The smartcache request is request 22, which is triggered around 600ms after the HTML has been retrieved.




Future developments
We still have lots of ideas for improving SmartCache.
In future developments, we’d like to give the origin the option of directly supplying the JSON of private elements, so as not to download the whole page at origin, in order to reduce the load at origin as much as possible. We’re also looking into the possibility of managing ESI tags for origins that support them.
Another area of improvement will be to rewrite the engine so as not to apply optimizations to the HTML code before dynamic zones are extracted. This will reduce Fasterize’s processing time and improve the engine’s resilience. Today, pages are optimized before dynamic zones are retrieved.
Finally, we’re looking into the possibility of specifying optional dynamic zones when defining the smartcache. This is often the case for banners for admin users or for new users without cookies.