I recently swapped a client project over to use the new cache tags â following the setup in this repo:
But it doesnât always work, (notably when updates are being made to existing content) e.g.
My client makes an update to a blog post, publishes and on occasion it doesnât update, but then if I go in make a content change and publish it shows the updated content
Client updates a âfeaturedâ article content type, publishes and on occasion, it doesnât update
Client publishes a new article but the listing on the homepage doesnât always update to show the new blog in the list
Sorry that your post was accidentally flagged by the spam bot at first. (It said you typed too quickly â probably copied & pasted? Iâve disabled that rule to be safe.)
Anyway, if Iâm understanding you right, the cache tags work fine as long as youâre the one doing the edits, but not if your client does the same edits? i.e. it doesnât matter what model theyâre working on, or what kind of edits they make, etc⌠as long as you go in after them into the same record to make some minor tweak (like adding/removing a space or whatever), THEN the cache tags work?
Hmm I wonder if it might be some sort of roles/permissions/API key type thing, where their Dato user isnât triggering the same invalidation workflow as your user wouldâŚ?
Could you please send us the actual project URL (either in a reply post, or in a DM to me, or via email at support@datocms.com â whichever you prefer) so we can take a look at the specific setup and webhook activities log in there?
Edit: Also, can we please see the source code of your invalidate tags webhooks receiver? Not the âinvalidate everythingâ one, but the one thatâs supposed to invalidate just the affected tags.
Itâs definitely not supposed to! A cache-hit ratio of over 90% means that the caching is working well (when itâs working right). But that should NOT mean that invalidations are difficult. The whole point of the cache tags is to make the invalidations simpler
Definitely not! Itâs supposed to work the way you envisioned (i.e., either of you make an edit, webhook gets fired, published page updates a few seconds later). If itâs not doing that, itâs either a bug on our part or perhaps a subtle issue in the implementation somewhere? Once you send us the project URL we can take a look together