[Asterisk-Dev] SIP failover using Asterisk and openais
Kristian Nielsen
kn at sifira.dk
Wed Sep 28 23:57:26 MST 2005
Steven Dake <sdake at mvista.com> writes:
> Finally in do_monitor, I notice there is a ast_sched_wait, followed by
> an ast_io_wait. ast_io_wait appears to dispatch any pending i/o events
> as derived from poll. I need to plug in here with an ast_io_add to add
> my "healthchecking" for the SIP server. My question is with
> ast_sched_wait.. Will it timeout immediately if there is I/O waiting?
The ast_sched_wait() function doesn't actually wait, it just calculates
the number of milliseconds until the next timer timeout, and returns
that immediately. This is then used to provide a timeout for
ast_io_wait() in case no I/O occurs before timer timeout.
So the name is somewhat misleading.
- Kristian.
--
Kristian Nielsen kn at sifira.dk
Development Manager, Sifira A/S
More information about the asterisk-dev
mailing list