Made a new theme on WordPress, the new theme is very similar to the old one, meaning there shouldn't be any major SQL queries change, probably less, but the website is slow and it seems it comes from varnish.
How do I debug varnish to see which queries are not getting a cache hit? I am suspecting it's some ajax call, but there are 100 of them, so I need to know which ajax is not getting cached. How do you do that?
Best Answer
For more information about debugging Varnish, I'd like to point to you to the following Varnish Developer Portal article: https://www.varnish-software.com/developers/tutorials/troubleshooting-varnish/#varnish-is-not-caching
In your specific case I'm going to assume the AJAX calls start with
/ajax/
. With that assumption, you can use the followingvarnishlog
command to debug this: