Skip to content
Alternative Caching engine for Pods, for cases where object caching is not available or hosting limits how much can be utilized
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
classes/Pods/Alternative Fix fallback return when cached value does not exist Feb 16, 2019
.gitattributes Add package, add export-ignore lines Oct 23, 2018
composer.json Pods Alt Cache 2.0.1 Jul 13, 2016
license.txt Initial plugin code Jan 29, 2014
package.json Set version to 2.0.6 Feb 16, 2019


=== Pods Alternative Cache ===
Contributors: sc0ttkclark
Donate link:
Tags: pods, cache, wpengine
Requires at least: 3.8
Tested up to: 5.1
Stable tag: 2.0.6
License: GPLv2 or later
License URI:

Pods Alternative Cache is a file-based or database-based caching solution for hosts that have limitations on object caching.

== Description ==

Pods Alternative Cache provides optimal performance with Pods sites on hosts with no object caching or low limits. It was developed for and tested on the WPEngine platform to improve performance of cached objects generated from Pods, but it works on numerous other hosting providers.

Pods Alternative Cache is a great addition to a site already utilizing Object Caching, it further separates and allows Pods to utilize more consistent persistent caching without affecting other plugins and WordPress caching objects. Especially when utilizing larger configurations, this plugin improves performance by ensuring other necessary objects are not removed by the server to make room for Pods cached objects.

This plugin requires the [Pods Framework]( version 2.4 or later to run.

For more information on how to use this plugin, see [](

== Installation ==

1. Unpack the entire contents of this plugin zip file into your `wp-content/plugins/` folder locally
1. Upload to your site
1. Navigate to `wp-admin/plugins.php` on your site (your WP Admin plugin page)
1. Activate this plugin

OR you can just install it with WordPress by going to Plugins >> Add New >> and type this plugin's name

== Contributors ==

Check out our GitHub for a list of contributors, or search our GitHub issues to see everyone involved in adding features, fixing bugs, or reporting issues/testing.


== FAQ ==

= Why an Alternative Cache? =

Hosts like WPEngine have limits set on their object caching engine that are based on what they find optimal for their environment. Sometimes, plugins, themes, and even WordPress core can utilize object cache to the point where it gets too full. When that happens, certain caching engines like APC can remove objects from their cache and that can cause what appears to be random numbers of queries on each page load.

What Pods Alternative Cache does is store all of the Pods objects that need caching, separate from the default object caching engine. Depending on the environment or site, this may still not be optimal. You'll want to test things out and keep an eye on your site's performance to see if it's the right fit for you.

= What options are available? =

In your wp-config.php, or prior to the `plugins_loaded` action, you can define other constants to change how the plugin works.

Change the storage type (be sure to deactivate/activate between storage type switches):

`define( 'PODS_ALT_CACHE_TYPE', 'db' ); // Default is 'file', you can choose 'memcached' too`

Change the path to the File cache folder:

`define( 'PODS_ALT_FILE_CACHE_DIR', 'path/to/folder' ); // Default is 'wp-content/podscache'`

Set Memcached Server host or IP address

`define( 'PODS_ALT_CACHE_MEMCACHED_SERVER', '' ); // Default is 'localhost'`

Set Memcached Server PORT number

`define( 'PODS_ALT_CACHE_MEMCACHED_PORT', 11211 ); // Default is 11211`

Disable Pods Alternative Cache:

`define( 'PODS_ALT_CACHE', false ); // Default is true`

Disable object cache fallback, when File writes fail:

`define( 'PODS_ALT_CACHE_FALLBACK', false ); // Default is true`

== Changelog ==

= [2.0.6] March 2nd, 2019 =
* Fixed caching issues with fallback cache
* Added more tests to improve stability

= [2.0.5] November 15th, 2018 =
* Fix PHP notices when handling fallback values

= [2.0.4] October 26th, 2018 =
* Added a new object cache fallback for File storage (default alt cache) so if any writes fail it will save them to the normal object cache; You can disable this by setting `define( 'PODS_ALT_CACHE_FALLBACK', false );`

= [2.0.3] October 23rd, 2018 =
* Fixed cases where transients/object cache could be used by Pods before Pods Alt Cache fully loads
* Updated WP compatibility version
* PHPCS fixes

= [2.0.2] June 2nd, 2017 =
* Revamped branding assets
* Fixed php notice
* Fixed usage of Memcached port to be an integer

= [2.0.1] July 13th, 2016 =
* Fixed cache file/folder deleting bug that wouldn't let Pods clear / preload caches properly
* Typo fix (props @szepeviktor)

= [2.0] June 23rd, 2016 =
* Added support for a Memcache caching (props @shaer)
* Added support for WP_Filesystem usage instead of using PHP directly
* Added additional WPEngine compatibility
* Refactored into a better OO pattern so the code is easier to use and extend
* Added ability to create custom storage types through the `pods_alternative_cache_storage_types` filter, `return $storage_types;` where you've set `$storage_types[ 'your_type' ] = 'Your_Class';`
* File storage now uses md5-based folder structure to avoid issues on sites with a large amount of cached objects to avoid having folders with too many files in them which could cause issues with certain hosts
* Found a bug? Have a great feature idea? Get on GitHub and tell us about it and we'll get right on it: [](

= [1.0] April 16th, 2014 =
* First official release!
You can’t perform that action at this time.