Opened 3 years ago
Last modified 3 years ago
#16 new enhancement
Implement an enable() / disable() feature for memcached based object-cache
| Reported by: | Denis-de-Bernardy | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Keywords: | needs-patch | Cc: | westi |
Description
I've a plugin (XML Sitemaps) that does a few mass queries through the WP API, but it does so while stripping out a bunch of fields from the main query:
http://plugins.trac.wordpress.org/browser/xml-sitemaps/trunk/xml-sitemaps.php?181000#L132
This is in order to avoid using more memory than is actually needed. The downside is that it ends up poisoning whatever is in memcached, so I end up flushing the mess before and after working on the sitemap.
I'm investigating alternative means to do this without needing to flush the whole thing.
At the moment, I'm leaning towards adding the posts, postmeta, etc. groups as non-persistent before generating the sitemap. What would be much better, however, would be an enable()/disable() feature. When disabled, the object cache would not send anything to memcached when the add()/set()/replace()/delete() methods are used.
Attachments (1)
Change History (5)
comment:1 Changed 3 years ago by Denis-de-Bernardy
comment:2 Changed 3 years ago by westi
- Cc westi added
As I said on the WP Ticket I am unsure this is the right solution at the moment.
comment:3 Changed 3 years ago by Denis-de-Bernardy
Cross-referencing the WP ticket: http://core.trac.wordpress.org/ticket/11405
comment:4 Changed 3 years ago by Denis-de-Bernardy
- Keywords needs-patch added

#15 is obviously related. :-)