Save cached versions of data, set an expiration time, and help limit the amount of requests per page.
This allows you to save data into the database, but also tie it to an expiration date. This module has built in functions very similar to how Miva's custom fields functions work and allows you to set and get transients from Miva. Common use cases are to "cache" dynamic content from a 3rd party source such as Twitter, Facebook or Instagram. Instead of making a call to them, each page load you can do it once and cache the data for a specific time period. This gives you an easy way to use dynamic content from 3rd party sources without the overhead of getting the content on each page load
Save Cached versions of data, set an expiration time, and limit the amount of requests per page.
Storing data from an API can help reduce page load times.
Twitter(OAuth/API) + Instagram(API) = 3.28s
Twitter(Transient) + Instagram(API) = 2.95s
Twitter(Transient) + Instagram(Transient) = 2.45s
The time below was recorded with all APIs "transiented". (Aka: called from the database, instead of 3 calls to apis)
2.22s (That saved 1.06 seconds of load time!)
Instead of making 3 calls per page load to Twitter (2 calls) and Instagram (1 call), we can store the data we retrieve from the call, save it for about an hour, and save page load time.
Be the first to rate this item!
Professional Services Lead Web Developer