Enable statsd support
Change-Id: I00b8aa4e59028a4c1098a3bae034e8d8ddfbe681
diff --git a/src/hlr.c b/src/hlr.c
index 7046180..c544310 100644
--- a/src/hlr.c
+++ b/src/hlr.c
@@ -23,6 +23,7 @@
#include <getopt.h>
#include <osmocom/core/msgb.h>
+#include <osmocom/core/stats.h>
#include <osmocom/core/logging.h>
#include <osmocom/core/application.h>
#include <osmocom/gsm/gsup.h>
@@ -663,6 +664,7 @@
exit(1);
}
+ osmo_stats_init(hlr_ctx);
vty_init(&vty_info);
ctrl_vty_init(hlr_ctx);
handle_options(argc, argv);
diff --git a/src/hlr_vty.c b/src/hlr_vty.c
index 04e0191..d0a623a 100644
--- a/src/hlr_vty.c
+++ b/src/hlr_vty.c
@@ -27,6 +27,7 @@
#include <osmocom/core/talloc.h>
#include <osmocom/vty/vty.h>
+#include <osmocom/vty/stats.h>
#include <osmocom/vty/command.h>
#include <osmocom/vty/logging.h>
#include <osmocom/vty/misc.h>
@@ -367,6 +368,7 @@
{
logging_vty_add_cmds(cat);
osmo_talloc_vty_add_cmds();
+ osmo_stats_vty_add_cmds();
install_element_ve(&show_gsup_conn_cmd);
diff --git a/tests/test_nodes.vty b/tests/test_nodes.vty
index ee7885b..d90fa70 100644
--- a/tests/test_nodes.vty
+++ b/tests/test_nodes.vty
@@ -16,6 +16,10 @@
show talloc-context (application|all) (full|brief|DEPTH)
show talloc-context (application|all) (full|brief|DEPTH) tree ADDRESS
show talloc-context (application|all) (full|brief|DEPTH) filter REGEXP
+ show stats
+ show stats level (global|peer|subscriber)
+ show asciidoc counters
+ show rate-counters
show gsup-connections
subscriber (imsi|msisdn|id|imei) IDENT show
show subscriber (imsi|msisdn|id|imei) IDENT