• Resolved Reuhno

    (@laboiteare)


    Hi,

    Systematically, and regardless of the cache lifetime setting on WP-Rocket, a cron event is scheduled every hour:

    rocket_purge_time_event

    Even if the cache is disabled on WP-Rocket side, it triggers a rocket_after_automatic_cache_purge_dir event

    This has the effect of triggering a purge of Cloudflare every hour. Which doesn’t make sense.

    I don’t know why WP Rocket systematically triggers this event, but maybe on your side it would be wise to uncheck this box by default:
    ‘ WP Rocket flushes cache directories – (recommended)’

    What do you think about it?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor iSaumya

    (@isaumya)

    Hi,
    Have you tried the method mentioned here: https://gist.github.com/isaumya/d5990b036e0ed2ac55631995f862f4b8
    on order to use WP Rocket with this plugin? If not, please try it and let me know if that helps.

    Thread Starter Reuhno

    (@laboiteare)

    Hi @isaumya,

    Yes, the behaviour I describe is the one after applying your method, which otherwise works very well.

    However, before I unchecked your checkbox ‘WP Rocket flushes cache directories – (recommended)’ in your plugin, I can assure you that I systematically had a flush with an EXPIRED header response + a complete preload every hour.

    As it is, everything works fine on my site, but my remark could be useful to other people who might have the same concern (It is a pity when the site is static that it is emptied unnecessarily).

    #####
    More precision :

    If you look at this file (Wp Rocket Core) : https://github.com/wp-media/wp-rocket/blob/aea8f96b0725f900deaa337af2f87c37277676ff/inc/Engine/Cache/PurgeExpired/PurgeExpiredCache.php

    rocket_after_automatic_cache_purge_dir is always triggered, even if $cache_enabled variable is false

    Plugin Contributor iSaumya

    (@isaumya)

    This is why for static file optimizations I generally recommend other plugins which are dedicated to static file (CSS/JS) optimization e.g. Autoptimize.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Wp Rocket suggested default configuration’ is closed to new replies.