• Resolved MikeShand

    (@mikeshand)


    Recently i’m having trouble with events not refreshing. I have it set to look ahead 9 days. I originally had the cache duration set to 12 hours, and have tried reducing this to 3 hours, but I am not seeing new dates appear. However, bizarrely, dates which have passed ARE being removed. The feed is at http://www.standrewsoxshott.org.uk/worship-learning/services/

    I’ve just refreshed the cache, so it is showing correctly, but just before I did that it was only showing up to 10am on Weds 30 Sept.

    What could be causing this? It used to work perfectly. Not quite sure when it stopped, but it could have been an update or two ago.

    https://ww.wp.xz.cn/plugins/google-calendar-events/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter MikeShand

    (@mikeshand)

    Well I tried deleting the feed and re-creating it, but it is still not refreshing automatically. I have to click “clear cache” every day to get it to update, which kind of defeats the point of it all (but as I said, it removes past entries without needing that).

    Perhaps, I’ll just have to wait until v3 is ready for prime time, and see if that fixes it.

    Thread Starter MikeShand

    (@mikeshand)

    In case you ask, I’m running v2.4 of Gcal and wordpress 4.3.1

    I see that this issue was supposed to be fixed in 2.0.3.1, so there must be some peculiarity about my setup that still provokes the issue. I can’t believe that everyone is affected.

    expand recurring events: Yes
    multiple day events : NOT ticked
    display mode: grouped list
    events per page: number of days:8
    display start date offeset: number of days back:0
    earliest feed event date: number of days back:0
    latest feed event date: number of days forward:8
    cache duration: 20000

    Plugin Contributor Fulvio Notarstefano

    (@nekojira)

    Hi Mike,

    sorry for late reply

    how are you creating those lists on that page? through shortcodes I may assume – can you paste the shortcodes content here please?

    if it’s a caching issue, you might want to check also with the cache time of your host or installation configuration, maybe it’s caching the page too aggressively?

    Thread Starter MikeShand

    (@mikeshand)

    Yes, using a shortcode

    [gcal id=”3994″]

    The pages ARE cached by ZenCache (6 hours), but clearing the Zencache does NOT result in the feed being refreshed, and in any case ZenCache disables caching for logged in users, and again the feed is not updated for logged in users.

    The only thing that causes it to update is doing a “clear cache” in Gcal.

    Plugin Contributor Fulvio Notarstefano

    (@nekojira)

    Currently it works like this.

    When you create a ‘feed’ post type, it fetches the events from Google according to the specified Google Calendar ID and other settings. The events returned by Google are stored in a WordPress transient. Transients in WordPress area bit like options (they end up in the wp_options table) but unlike options they have a max expiration time (e.g. if you set 12 hours, it’s guaranteed that the transient will be wiped *within* 12 hours *or* before that, but not later). Then the frontend uses this transient to display the Calendar (if the transient has not been set yet or has expired, it will query Google and set a new transient and use that).

    So your WordPress installation doesn’t receive push notifications from Google when a new event is updated in Google and it will take a while to update. I’ve recently rewrote the plugin (there’s a new 3.0 beta available) to work a bit differently, but it still uses that system for the calendars. In the future I want to move away from that model and try to not cache anything at all with transients.

    I’m not sure why it doesn’t work well in your installation. If a transient is expired, it should do a new query and return an updated feed. I’m not entirely clear about the ‘events removed’ part in your OP. It could be the way it calculates the ‘start’ of the list. I have also changed this in the upcoming version to make it more precise and allow for more granualr control.

    If you are a developer and want to try the beta:
    https://ww.wp.xz.cn/support/topic/simple-calendar-30-beta-now-available?replies=14
    (but mind it’s a beta I wouldn’t recommend you install it on a live site yet)

    Thread Starter MikeShand

    (@mikeshand)

    Thanks for the detailed reply. I removed and re-installed the plugin and it SEEMS to be working OK again. Thanks for your help anyway.

    I’ll give the beta a go in my sandbox when I have some time to check it out.

    Plugin Contributor Fulvio Notarstefano

    (@nekojira)

    great thank you,

    please let me know if it doesn’t work as it should

    you can let me have your feedback about the beta here: https://ww.wp.xz.cn/support/topic/simple-calendar-30-beta-now-available?replies=17

    or even by chat with Gitter https://gitter.im/moonstonemedia/Simple-Calendar?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge

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

The topic ‘cache not refreshing’ is closed to new replies.