Feed Cache
-
Hello there,
I’ve been reviewing the cache invalidation logic in
Cache_Invalidation_Hooks.php(get_post_related_links()), and noticed that when a post is published, updated, or deleted, the plugin purges the taxonomy term link, but does not also purge the corresponding feed URL.For comparison, the code does explicitly purge:
get_author_feed_link()for the post authorget_post_type_archive_feed_link()for the post type archive
But there’s no equivalent added for taxonomy term feeds.
My use case: I have a setup where one site fetches a tag feed from another site every minute via RSS. This feed is currently excluded from caching entirely, which causes frequent DB queries and occasional timeouts under load. I’d like to cache this feed, but only if it gets purged automatically when a relevant post is published/updated – otherwise it would serve stale content indefinitely (since the cache never expires by TTL in our config).
Questions:
- Is this an intentional omission, or an oversight?
- Is there a recommended way to extend the purge list to include taxonomy term feed URLs?
- Would this be considered for inclusion in the default purge list in a future release?
Thanks!
You must be logged in to reply to this topic.