Open mbautista opened 4 months ago
Disabling the object cache for a specific site in a network is not something that should really be supported IMHO.
The reason is that WordPress has two different levels of cache - Per site cache groups, and global cache groups.
The global cache groups are shared between all sites on the network, and per-site caches are specific to the individual site.
Disabling the cache for a specific site would require keeping the global cache active, as otherwise any changes to network-data would change the DB without updating the cache, causing issues for other sites which retrieve it from the cache instead.
Perhaps the better question is, what's the use-case for disabling it for a specific site? Once that's answered we might be able to suggest ways forward.
Hello @dd32 Thank you for the answer. I agree with you in absolute three is no good reason for disabling the object cache.
But unfortunately I already found 2 plugins that do not work well with object cache :
These plugins are buggy and should be fixed or replaced, but unfortunately it's not always possible quickly, so as a temporary solution I found this filter to disable the object cache for the websites using these plugins on our wp network.
But I agree it's more a hack than a feature, besides without object caching these websites are much more slower :/ Mathieu.
Hello, Thank you for this module, it rocks :)
Is it possible to disable the cache object on a specific website in a wordpress network ? Is there any constant and/or filter we could use ?
As I could not find it I added a filter in the object-cache.php but I'm not sure if it's required and/or in the right place :
Thank you very much :) Mathieu.