• Resolved roam92

    (@roam92)


    Hi, I’m wondering if koko_analytics_aggregate_stats needs to run every minute (as scheduled by default in the cron jobs) and what happens if it doesn’t…?

    I’m looking at changing how cron runs on my site to increase overall performance:

    https://kinsta.com/knowledgebase/disable-wp-cron/

    If I do this, and the koko_analytics_aggregate_stats process ends up running only once every 15 minutes (instead of every 1 minute), is that a problem?

    Will any visits or pageviews get missed?

    (I don’t care if counting is delayed or not realtime; I just care about accuracy.)

    Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter roam92

    (@roam92)

    PS – My site is using Koko’s optimized tracking endpoint, and usually gets multiple visits per minute.

    Plugin Author Danny van Kooten

    (@dvankooten)

    Hello @roam92,

    It’s not necessarily a problem, but it may decrease overall performance as it would mean there is a lot more work to do since any scheduled actions only get a chance to run every 15 minutes.

    I would definitely recommend disabling WP Cron and going for a proper server-side cronjob but at the same time I would not make it run any less than once every 5 minutes. A minute is already a really long time for a computer. Also, the job will simply quit immediately if there is no work to do.

    Either way, it shouldn’t cause any missed pageviews or visits. The job that aggregates these stats also runs whenever you visit the Koko Analytics dashboard page, so even if your cronjob is somehow not working the plugin will deal with it properly.

    I hope that clarifies. If not, let us know please!

    Thread Starter roam92

    (@roam92)

    Wow, a perfect answer and completely helpful – thanks @dvankooten !

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Does koko_analytics_aggregate_stats need to run every minute?’ is closed to new replies.