This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
fixeria gerrit-no-reply at lists.osmocom.orgfixeria has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/26175 )
Change subject: stats: clarify error messages in cfg_no_stats_reporter_{statsd,log}
......................................................................
stats: clarify error messages in cfg_no_stats_reporter_{statsd,log}
Change-Id: I287130213c7de31a510f293bed0f3daddd53ce04
Related: SYS#5713
---
M src/vty/stats_vty.c
M tests/stats/stats_vty_test.vty
2 files changed, 9 insertions(+), 4 deletions(-)
Approvals:
Jenkins Builder: Verified
osmith: Looks good to me, but someone else must approve
pespin: Looks good to me, approved
diff --git a/src/vty/stats_vty.c b/src/vty/stats_vty.c
index 308bab6..c6c50ef 100644
--- a/src/vty/stats_vty.c
+++ b/src/vty/stats_vty.c
@@ -312,8 +312,8 @@
srep = osmo_stats_reporter_find(OSMO_STATS_REPORTER_STATSD, name);
if (!srep) {
- vty_out(vty, "%% No statsd logging active%s",
- VTY_NEWLINE);
+ vty_out(vty, "%% There is no such statsd reporter with name '%s'%s",
+ name ? name : "", VTY_NEWLINE);
return CMD_WARNING;
}
@@ -366,8 +366,8 @@
srep = osmo_stats_reporter_find(OSMO_STATS_REPORTER_LOG, name);
if (!srep) {
- vty_out(vty, "%% No log reporting active%s",
- VTY_NEWLINE);
+ vty_out(vty, "%% There is no such log reporter with name '%s'%s",
+ name ? name : "", VTY_NEWLINE);
return CMD_WARNING;
}
diff --git a/tests/stats/stats_vty_test.vty b/tests/stats/stats_vty_test.vty
index ddfb3a6..94cc7e8 100644
--- a/tests/stats/stats_vty_test.vty
+++ b/tests/stats/stats_vty_test.vty
@@ -203,6 +203,11 @@
stats_vty_test(config)# show running-config
... !(foo|bar|zoo)
+stats_vty_test(config)# no stats reporter statsd statsd-foo
+% There is no such statsd reporter with name 'statsd-foo'
+stats_vty_test(config)# no stats reporter log log-zoo
+% There is no such log reporter with name 'log-zoo'
+
stats_vty_test(config)# stats interval 1337
stats_vty_test(config)# show running-config
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/26175
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I287130213c7de31a510f293bed0f3daddd53ce04
Gerrit-Change-Number: 26175
Gerrit-PatchSet: 3
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: osmith <osmith at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20211109/a4b17422/attachment.htm>