22 #include <sys/socket.h>
23 #include <osmocom/core/linuxlist.h>
33 enum osmo_stats_class {
34 OSMO_STATS_CLASS_UNKNOWN,
35 OSMO_STATS_CLASS_GLOBAL,
36 OSMO_STATS_CLASS_PEER,
37 OSMO_STATS_CLASS_SUBSCRIBER,
40 enum osmo_stats_reporter_type {
41 OSMO_STATS_REPORTER_STATSD,
42 OSMO_STATS_REPORTER_LOG,
46 enum osmo_stats_reporter_type type;
49 unsigned int have_net_config : 1;
58 enum osmo_stats_class max_class;
62 struct sockaddr dest_addr;
64 struct sockaddr bind_addr;
69 int force_single_flush;
77 int64_t value, int64_t delta);
90 void osmo_stats_init(
void *ctx);
91 int osmo_stats_report();
93 int osmo_stats_set_interval(
int interval);
105 int osmo_stats_reporter_set_remote_addr(
struct osmo_stats_reporter *srep,
const char *addr);
107 int osmo_stats_reporter_set_local_addr(
struct osmo_stats_reporter *srep,
const char *addr);
110 enum osmo_stats_class class_id);
111 int osmo_stats_reporter_set_name_prefix(
struct osmo_stats_reporter *srep,
const char *prefix);