|
jabberd14 1.6.2
|
functions used to register other functions to be called regularily More...
#include "jabberd.h"Data Structures | |
| struct | beat_struct |
Typedefs | |
| typedef struct beat_struct * | beat |
| typedef struct beat_struct | _beat |
Functions | |
| void * | heartbeat (void *arg) |
| beat | _new_beat (void) |
| void | register_beat (int freq, beathandler f, void *arg) |
| void | heartbeat_birth (void) |
| void | heartbeat_death (void) |
Variables | |
| beat | heartbeat__ring = NULL |
functions used to register other functions to be called regularily
| typedef struct beat_struct _beat |
| typedef struct beat_struct * beat |
private heartbeat ring struct
| beat _new_beat | ( | void | ) |
allocate memory for a new heartbeat
References beat_struct::p, pmalloco(), and pool_new.
Referenced by heartbeat_birth(), and register_beat().
| void* heartbeat | ( | void * | arg | ) |
this thread continuously checks if a function, that is registered to be called regularly using register_beat() has to be called again
| arg | unused/ignored |
References beat_struct::arg, beat_struct::f, beat_struct::freq, beat_struct::last, beat_struct::next, beat_struct::p, pool_free(), beat_struct::prev, and r_UNREG.
Referenced by heartbeat_birth().
| void heartbeat_birth | ( | void | ) |
start up the heartbeat
References _new_beat(), heartbeat(), heartbeat__ring, beat_struct::next, and beat_struct::prev.
Referenced by main().
| void heartbeat_death | ( | void | ) |
stop calling hearbeat functions
References heartbeat__ring, beat_struct::next, beat_struct::p, pool_free(), and beat_struct::prev.
Referenced by main().
| void register_beat | ( | int | freq, |
| beathandler | f, | ||
| void * | arg | ||
| ) |
register a function to receive heartbeats
References _new_beat(), beat_struct::arg, beat_struct::f, beat_struct::freq, heartbeat__ring, beat_struct::last, beat_struct::next, and beat_struct::prev.
Referenced by dialback(), dnsrv(), jsm(), main(), mio_connect(), mio_init(), mod_stat(), pthsock_client(), xmppd::instance_base::set_heartbeat_interval(), xdb_cache(), and xdb_file().
| beat heartbeat__ring = NULL |
master hook for the ring
Referenced by heartbeat_birth(), heartbeat_death(), and register_beat().
1.7.4