Is It Possible To Set A Timeout When Querying A Calendar ?

Home » Asterisk Users » Is It Possible To Set A Timeout When Querying A Calendar ?
Asterisk Users 1 Comment

Hello,

Asterisk offers several ways to query an external calendar. I’m wondering what could happen if an external calendar was down or very slow to respond.

Looking at wiki.asterisk.org, I didn’t find any timeout parameter in calendar functions, nor in calendar.conf (but I’m not too sure for the later case) ?

What would you suggest to protect your dialplan from a mis-behaving external calendar ?

Best regards

One thought on - Is It Possible To Set A Timeout When Querying A Calendar ?

  • 2016-06-21 12:18 GMT+02:00 Olivier :

    Maybe somebody else has a better pattern, but for now, I’ve implemented a middleware to fetch ics calendar and store that in folders served by a Nginx. Asterisk retrieves ical directly on localhost.

    Two advantages:
    1. Asterisk don’t waste CPU time to retrieve data.
    2. If the calendar source is down, it’s invisible from Asterisk.

    However, the main issue is that I didn’t find a way to force Asterisk to purge its cache and reload a specific calendar. I play with timeouts to avoid to be too much in delay with the latest version available of ical.

    Have a nice day.