Purge cache for this page only not working
-
Hi,
For the last day or so, updated pages don’t refresh. I also can’t purge single pages either via the plugin or the CF dashboard.
The only way I can refresh any changes I make to individual pages is to do a full purge.
I’m pretty certain it is not a plugin issue. But how can I check if it’s an issue with Cloudflare?
I’ve tried the CF community forum for ideas, but with no luck.
-
Hi @diriras,
I see this respnse:
Response: {"result":null,"success":false,"errors":[{"code":10000,"message":"Unauthorized"}],"messages":[]}
So, you can see that the API returned success false with the reason that you are unauthorized to perform the taste. Are you using Global API or API Token?But when you purged the whole cache you got this response :
Response: { "result": { "id": "7554b4a746bb264a5b2336ea7f30524a" }, "success": true, "errors": [], "messages": [] }
As you can see it clearly states that the API request successfully received by Cloudflare API.
Also when I try to setup the plugin with Cloudflare API Token I got the:
Unauthorized to access requested resource (err code: 9109)– Maybe you didn’t allow all the permissions that are necessary for the plugin to work.
So actually this still doesn’t work as it suppose to be with this plugin.
The plugin doesn’t purge cache when single post is published. I have to do it manually. After post publish I have to go to plugin settings and purge whole cache. Then it works, my site refreshes (miuipolska.pl). Without manual purge my site can have old content for at least 12 hours or more.Or at least it doesn’t purge home page (would be nice to have an option for purging home page)
Hi @bfeltman,
You can take advantage ofswcfpc_post_related_url_init
filter if you like: https://wordpress.org/support/topic/main-page-doesnt-update-when-publish-a-page-or-post/page/2/#post-14733840Hello,
I had to change back from workers mode to page rules because of the high cost!
To my surprise now the caching is working for my first domain, and it works faster than ever.
Now I am afraid to touch anything else in the plugin or for example restart the Database because I don’t want to mess it up again.The bizarre is that my new second domain is using the same WordPress Template the same VPS and exactly the same Hardware software settings with the same settings in the caching plugin, BUT it only caches the Homepage not the Categories or Tags. I can not see anything strange in the logs and I can upload them if needed!
Can you share the URL of the second domain so that I can look at the full response headers?
Sure, the second domain is https://nealive.gr
The first one that its working, just to compare is https://sportlive.grHi,
I see a perfect cache hit on your second domain (on the category pages):Yes sorry wrong description.
It IS caching but not updating the Categories and Tags with new posts…
Its caching AND updating ONLY the HomepageYou can understand this if you see the time of the posts in Categories and compare it with the time in posts at Homepage!
Again, you need to check the Cloudflare response headers in the logs. If you see a successful response without any error in the logs but still cache is not clearing, that means the plugin send the request to cloudflare properly and it received it well. But for some reason didn’t process it. In that case the best option is to open a support ticket with Cloudflare and talk to them asking why cache is not clearing respite successful API response?
So now for me single page post/Category purge works fine!
The issue I have is that in the website for example we have this post
https://nealive.gr/ellada/eortologio-noemvrioy-poioi-giortazoyn-simera-triti-1-11/
but in the logs I see this one:For some reason it puts some posts in uncategorized value of categories (even though they do have a category) that is why its not clearing the correct categories, instead its clearing the uncategorized
Do you have any clue about this one?
Also I found out that plugin is not smart enough to purge a category inside a category for example a new post here
Does not purge https://nealive.gr/athlitismos/ category in order to show it
- This reply was modified 2 years, 1 month ago by diriras.
- This reply was modified 2 years, 1 month ago by diriras.
- This reply was modified 2 years, 1 month ago by diriras.
- This reply was modified 2 years, 1 month ago by diriras.
- This reply was modified 2 years, 1 month ago by diriras.
- This reply was modified 2 years, 1 month ago by diriras.
Also in logs, time is 2 hours behind my ETC setup in WordPress
`[2022-11-01 08:40:26] [preloader::task]
I don’t know how to fix this
Hi,
https://nealive.gr/ellada/eortologio-noemvrioy-poioi-giortazoyn-simera-triti-1-11/
– This link gives 404 for me. So, I can’t see anything.Also I found out that plugin is not smart enough to purge a category inside a category
– No, it can’t cause the system cannot understand the hierarchy. It can only understand the main taxonomy pages, not the sub ones.
Also, please stop using preloader, at this point it will not give you any extra benefit as Cloudflare AI might not cache the content if it sees the request is coming via cURL instead of an actual browser. So, using preloader will take a lot of server resource without giving that high value. Also your site has good traffic, so don’t use preloader. You can use the prefetch, but I will not recommend using the preloader.
I am using the preloader to check the post category updates, I send you what I saw in logs, the new posts appears in homepage but not in Categories.
The difference between my 2 domains is:1. in the first I can see in the logs the full path of the post WITH the category
2. In the second in the new posts (majority) I only see https://****.gr/uncategorized/post_nameThat is why Categories are not getting updated!
I ‘ve tried to change the default Post Category in WordPress Writing settings but I have the same issue in logs, meaning I cannot see the correct post category but now instead of /uncategorized I see /nealiveThe result is not different even if I use preloader or not.
For example in this new post:
https://nealive.gr/ellada/kriti-cheiropedes-se-52chrono-endooikogeneiaki-via/Try to find it in the debug logs to see what is mean! It only appears at /nealive Category!
I don’t see how that’s a plugin problem. I mean the plugin only acts on the data it receives, so somehow the plugin is receiving the data as uncategorized category.
I don’t see how it is not however, because Cloudflare cache is now working but false data have been sent to purge.
And now after 2-3 hours some Categories were purged without me doing anything! So the intermediate must be the plugin.
If needed I can provide WordPress access because there is a change to discover a bug or something!
- The topic ‘Purge cache for this page only not working’ is closed to new replies.