Skip to content
Martin Price edited this page Jul 5, 2023 · 1 revision

Gist Filter for Backdrop CMS adds enhancements to the caching functionality to minimize unnecessary calls to the GitHub API.

Own cache

The Drupal 7 version used the general cache, which meant that clearing the caches would also clear out any cached gists, even if there were no changes. Now Gist Filter creates its own cache table so it can be cleared independently if necessary but kept intact during normal cache clear operations.

However, there is an option (disabled by default) to clear this cache with the other caches when running 'Flush all caches'.

Permanent cache

This recognises that gists can often have a very long time between edits so there is no need to regularly empty the cache. In theory a gist could stay in the cache for ever, even if it is no longer embedded in a page.

There is both a menu item to clear the Gist cache and a button on the configuration page to clear the cache.

Update changed Gists

When the page cache is refreshed then the module checks the cached gist against the live gist but only returning data if there is an update. This prevents unnecessary calls to the GitHub API.

Clone this wiki locally