176 .requires =
"res_statsd" const char * stasis_message_type_name(const struct stasis_message_type *type)
Gets the name of a given message type.
struct ast_channel_snapshot_base * base
Asterisk main include file. File version handling, generic pbx functions.
static int unload_module(void)
#define ast_test_flag(p, flag)
static void update(int code_size, int y, int wi, int fi, int dq, int sr, int dqsez, struct g726_state *state_ptr)
Time-related functions and macros.
int stasis_message_router_add(struct stasis_message_router *router, struct stasis_message_type *message_type, stasis_subscription_cb callback, void *data)
Add a route to a message router.
char * ast_str_buffer(const struct ast_str *buf)
Returns the string buffer within the ast_str buf.
void stasis_message_router_unsubscribe_and_join(struct stasis_message_router *router)
Unsubscribe the router from the upstream topic, blocking until the final message has been processed...
struct stasis_message_type * stasis_message_type(const struct stasis_message *msg)
Get the message type for a stasis_message.
int64_t ast_tvdiff_ms(struct timeval end, struct timeval start)
Computes the difference (in milliseconds) between two struct timeval instances.
Structure representing a change of snapshot of channel state.
void ast_statsd_log_string(const char *metric_name, const char *metric_type, const char *value, double sample_rate)
Send a stat to the configured statsd server.
int ast_str_set(struct ast_str **buf, ssize_t max_len, const char *fmt,...)
Set a dynamic string using variable arguments.
struct stasis_topic * ast_channel_topic_all(void)
A topic which publishes the events for all channels.
static void default_route(void *data, struct stasis_subscription *sub, struct stasis_message *message)
Router callback for any message that doesn't otherwise have a route.
static struct stasis_subscription * sub
Statsd channel stats. Exmaple of how to subscribe to Stasis events.
#define RAII_VAR(vartype, varname, initval, dtor)
Declare a variable that will call a destructor function when it goes out of scope.
const struct timeval * stasis_message_timestamp(const struct stasis_message *msg)
Get the time when a message was created.
struct timeval creationtime
static void updates(void *data, struct stasis_subscription *sub, struct stasis_message *message)
Router callback for ast_channel_snapshot_update messages.
static struct stasis_message_router * router
static int load_module(void)
void ast_statsd_log(const char *metric_name, const char *metric_type, intmax_t value)
Send a stat to the configured statsd server.
#define stasis_message_router_create(topic)
static void statsmaker(void *data, struct stasis_subscription *sub, struct stasis_message *message)
Subscription callback for all channel messages.
#define stasis_subscribe(topic, callback, data)
The descriptor of a dynamic string XXX storage will be optimized later if needed We use the ts field ...
void * stasis_message_data(const struct stasis_message *msg)
Get the data contained in a message.
int stasis_subscription_final_message(struct stasis_subscription *sub, struct stasis_message *msg)
Determine whether a message is the final message to be received on a subscription.
struct stasis_subscription * stasis_unsubscribe_and_join(struct stasis_subscription *subscription)
Cancel a subscription, blocking until the last message is processed.
struct ast_channel_snapshot * new_snapshot
Module has failed to load, may be in an inconsistent state.
int stasis_message_router_set_default(struct stasis_message_router *router, stasis_subscription_cb callback, void *data)
Sets the default route of a router.
struct stasis_message_type * ast_channel_snapshot_type(void)
Message type for ast_channel_snapshot_update.
struct ast_channel_snapshot * old_snapshot
AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS|AST_MODFLAG_LOAD_ORDER, "HTTP Phone Provisioning",.support_level=AST_MODULE_SUPPORT_EXTENDED,.load=load_module,.unload=unload_module,.reload=reload,.load_pri=AST_MODPRI_CHANNEL_DEPEND,.requires="http",)
#define AST_STATSD_GAUGE
Support for publishing to a statsd server.
#define ASTERISK_GPL_KEY
The text the key() function should return.
Asterisk module definitions.
#define ast_str_create(init_len)
Create a malloc'ed dynamic length string.