diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-04-14 18:12:10 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2022-04-14 18:12:10 +0000 |
commit | b5321aff06d6ea8d730d62aec2ffd8e9271c1ffc (patch) | |
tree | 36c41e35994786456154f9d3bf88c324763aeea4 /daemon/analytics.c | |
parent | Adding upstream version 1.33.1. (diff) | |
download | netdata-upstream/1.34.0.tar.xz netdata-upstream/1.34.0.zip |
Adding upstream version 1.34.0.upstream/1.34.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | daemon/analytics.c | 28 |
1 files changed, 13 insertions, 15 deletions
diff --git a/daemon/analytics.c b/daemon/analytics.c index 4501a46a5..0af41fdda 100644 --- a/daemon/analytics.c +++ b/daemon/analytics.c @@ -362,21 +362,15 @@ void analytics_alarms_notifications(void) void analytics_get_install_type(void) { - struct install_type_info t = get_install_type(); - - if (t.install_type == NULL) { + if (localhost->system_info->install_type == NULL) { analytics_set_data_str(&analytics_data.netdata_install_type, "unknown"); } else { - analytics_set_data_str(&analytics_data.netdata_install_type, t.install_type); + analytics_set_data_str(&analytics_data.netdata_install_type, localhost->system_info->install_type); } - if (t.prebuilt_distro != NULL) { - analytics_set_data_str(&analytics_data.netdata_prebuilt_distro, t.prebuilt_distro); + if (localhost->system_info->prebuilt_dist != NULL) { + analytics_set_data_str(&analytics_data.netdata_prebuilt_distro, localhost->system_info->prebuilt_dist); } - - freez(t.prebuilt_arch); - freez(t.prebuilt_distro); - freez(t.install_type); } /* @@ -422,12 +416,16 @@ void analytics_metrics(void) rrdset_foreach_read(st, localhost) { rrdset_rdlock(st); - rrddim_foreach_read(rd, st) - { - if (rrddim_flag_check(rd, RRDDIM_FLAG_HIDDEN) || rrddim_flag_check(rd, RRDDIM_FLAG_OBSOLETE)) - continue; - dimensions++; + + if (rrdset_is_available_for_viewers(st)) { + rrddim_foreach_read(rd, st) + { + if (rrddim_flag_check(rd, RRDDIM_FLAG_HIDDEN) || rrddim_flag_check(rd, RRDDIM_FLAG_OBSOLETE)) + continue; + dimensions++; + } } + rrdset_unlock(st); } { |