• Resolved zapappa

    (@lesarnott)


    Your settings and documentation refer to preload creating “N pages per minute” and preload runs by default every 5 minutes. But what I see happening is that “N pages” are created every time the wp_fastest_cache_Preload preload job runs. With the default timer of 5 minutes this means that “N pages are created every 5 minutes”.

    This is just using different words to describe what is happening but I do find the “pages per minute” misleading, what do you think?

    Now to my real problem…

    If I manually delete the cache the preload cron job starts and a few cache pages are created every 5 minutes or so.

    However, I have a nightly Timeout Rule that starts at 2am and automatically clears the cache. When that kicks off the preload cron job it does not regularly run at 5 minute intervals. Last night it ran at:

    2.07
    2.42
    3.38
    3.43
    5.02
    5.30
    5.41
    6.02

    which means it took 4 hours instead of under an hour.

    Can you suggest a reason for this and how do I fix it?

    • This topic was modified 4 years, 1 month ago by zapappa.
    • This topic was modified 4 years, 1 month ago by zapappa.
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Emre Vona

    (@emrevona)

    You can set a cronjob as below to speed up the preload as below.
    https://www.wpfastestcache.com/features/manually-preload-with-cron-jobs/

    Thread Starter zapappa

    (@lesarnott)

    Yes, I know I can do that but that wasn’t my question. My question was why does preload run every 5 minutes after I delete the cache manually but runs at random intervals when I delete the cache with a configured Timeout Rule?

    I am quite content with the preload running every 5 minutes but why does it not run every 5 minutes when it is started by the Timeout Rule? Putting it another way, can you confirm that it should be running every 5 minutes?

    Plugin Author Emre Vona

    (@emrevona)

    I cannot confirm that it works every 5 minutes.The action will trigger when someone visits your WordPress site if the scheduled time has passed.
    https://developer.wordpress.org/reference/functions/wp_schedule_event/

    Thread Starter zapappa

    (@lesarnott)

    Thanks for the explanation. So there is no difference between deleting manually and deleting with the Timeout Rule as both use wp_schedule_event? And preload will only run when there is user input which means at random intervals greater than 5 minutes?

    In Clear Cache via URL you say “you can clear cache via cron job (type=clearcache)”. I presume that it will also kick off preload after deleting the cache, is that right?

    And the final question: is there any difference between clearing the cache with a Timeout Rule and setting up a cron job to clear the cache (apart from being able to specify the times to run the cron)?

    Plugin Author Emre Vona

    (@emrevona)

    Thanks for the explanation. So there is no difference between deleting manually and deleting with the Timeout Rule as both use wp_schedule_event?

    yes, the preload starts working after clearing cache.

    And preload will only run when there is user input which means at random intervals greater than 5 minutes?

    yes.

    In Clear Cache via URL you say “you can clear cache via cron job (type=clearcache)”. I presume that it will also kick off preload after deleting the cache, is that right?

    Exactly.

    And the final question: is there any difference between clearing the cache with a Timeout Rule and setting up a cron job to clear the cache (apart from being able to specify the times to run the cron)?

    no, the preload starts working after clearing cache.

    • This reply was modified 4 years, 1 month ago by Emre Vona.
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Preload timing’ is closed to new replies.