Cache clear after updates




Wordpress LScache Plugin: Cache clear after updates

Last Updated on: Wed, 15 Apr 2026 00:00:02
Hi, After I update our sites via WP-CLI and clear the beaver builder and litespeed caches, some sites are 404ing on some css files namely in this directory: /wp-content/uploads/bb-plugin/cache/8-layout.css?ver=9747db8d5ed9539653709916180ee4ae The only thing that solves it is clearing the ls cache again but I was wondering whats happening here. What causes the files to get created on a ls clear? The files that get created always have the same name of the ones that were 404ing including the ver=. This is the wpcli code I use: wp core update && wp plugin update --all && wp theme update --all wp core language update && wp language plugin update --all && wp language theme update --all sleep 10 wp beaver clearcache && wp litespeed-purge all Hi, due the way how LSCache engine works (as it is integrated in the webserver) , it needs a targeted domain know to know which (sites) page to purge when you run everything in command line , as no HTTP request is involved, that means no webserver is involved , and since cache engine is not involved , it doesnt know what to purge for command line initiated task , there is a delay purge added into database cache queue that will be triggered next time PHP is triggered , but sometimes it does not respond in time try , after your wp command lines , then run a curl with random query string , like https://youdomain.com/?123 to bypass cache and hit PHP , see if it purges properly Thanks for your reply it turned out to be the beaver builder plugin clearing its cache. When BB clears its cache our sites always get 404s on files from /wp-content/uploads/bb-plugin/cache. Purging the litespeed cache solves it. Unfortunately updating the version of bb also causes it to do a cache clear the next time the back end is loaded. So the sites will always break eventually once they are logged in. (if litespeed is not purged at the same time) if BB has some kind of hook you can use when it updates , you can hook it with do_action( litespeed_purge_all ) to tell LSCWP to purge it Thanks for this Ill bare it in mind. Weve just written something into our update routines to make bb skip the extra cache clear when logging into the back end. Beaver Builder does not do anything special with LS, we used to but LS added thier own support a couple of years ago: https://github.com/litespeedtech/lscache_wp/blob/master/thirdparty/beaver-builder.cls.php You should be able to use the upgrader_process_complete action to see when a plugin has updated: https://developer.wordpress.org/reference/hooks/upgrader_process_complete/



LiteCache Rush: Speed comes from using less, not from doing it faster



Reference