mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
res_calendar: Add support for fetching calendars when reloading
We use a lot res_calendar, we are very happy with that, especially because you use libical, the almost alone opensource library that supports really ical format with all types of recurrency. Nevertheless, some features are missed for our business use cases. This first patch adds a new option in calendar.conf: fetch_again_at_reload. Be my guest for a better name. If it's true, when you'll launch "module reload res_calendar.so", Asterisk will download again the calendar. The business use case is that we have a WebUI with a scheduler planner, we know when the calendars are modified. For now, we need to define 1 minute of timeout to have a chance that our user doesn't wait too long between the modification and the real test. But it generates a lot of useless HTTP traffic. ASTERISK-26422 #close Change-Id: I384b02ebfa42b142bbbd5b7221458c7f4dee7077
This commit is contained in:
committed by
Joshua Colp
parent
2d2a8944be
commit
9f62feca60
@@ -129,6 +129,7 @@ struct ast_calendar {
|
||||
int autoreminder; /*!< If set, override any calendar_tech specific notification times and use this time (in mins) */
|
||||
int notify_waittime; /*!< Maxiumum time to allow for a notification attempt */
|
||||
int refresh; /*!< When to refresh the calendar events */
|
||||
int fetch_again_at_reload; /*!< To reload the calendar content when the module is reloaded */
|
||||
int timeframe; /*!< Span (in mins) of calendar data to pull with each request */
|
||||
pthread_t thread; /*!< The thread that the calendar is loaded/updated in */
|
||||
ast_cond_t unload;
|
||||
|
Reference in New Issue
Block a user