diff options
author | Stelios Fragkakis <52996999+stelfrag@users.noreply.github.com> | 2023-11-23 23:56:34 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-23 23:56:34 +0200 |
commit | 85f359fc2677752ef7501fbee92d9caecc924538 (patch) | |
tree | e874de2346c715e9b5762517f9c7faf08af61da8 /health | |
parent | a721fcb61f9c50762a92d2939091fdfc02bf0014 (diff) |
Handle ephemeral hosts (#16381)
* Handle ephemeral hosts
* Node empheral removal timeout 86400 seconds (1 day)
* Move config from health to global section
* Set a node to queryable false when it is ephemeral and is removed
* Log queryable. Send queryable=0 only when forcing host deletion (the node is ephemeral)
* Switch to "is ephemeral node"
Document stream.conf
* Unregister node id
Diffstat (limited to 'health')
-rw-r--r-- | health/health.c | 14 | ||||
-rw-r--r-- | health/health.h | 1 |
2 files changed, 0 insertions, 15 deletions
diff --git a/health/health.c b/health/health.c index 2ed15b3214..99499c93ed 100644 --- a/health/health.c +++ b/health/health.c @@ -1651,17 +1651,3 @@ void *health_main(void *ptr) { netdata_thread_cleanup_pop(1); return NULL; } - -void health_add_host_labels(void) { - RRDLABELS *labels = localhost->rrdlabels; - - // The source should be CONF, but when it is set, these labels are exported by default ('send configured labels' in exporting.conf). - // Their export seems to break exporting to Graphite, see https://github.com/netdata/netdata/issues/14084. - - int is_ephemeral = appconfig_get_boolean(&netdata_config, CONFIG_SECTION_HEALTH, "is ephemeral", CONFIG_BOOLEAN_NO); - rrdlabels_add(labels, "_is_ephemeral", is_ephemeral ? "true" : "false", RRDLABEL_SRC_AUTO); - - int has_unstable_connection = appconfig_get_boolean(&netdata_config, CONFIG_SECTION_HEALTH, "has unstable connection", CONFIG_BOOLEAN_NO); - rrdlabels_add(labels, "_has_unstable_connection", has_unstable_connection ? "true" : "false", RRDLABEL_SRC_AUTO); -} - diff --git a/health/health.h b/health/health.h index ff8fb4261e..ef24624465 100644 --- a/health/health.h +++ b/health/health.h @@ -102,7 +102,6 @@ void *health_cmdapi_thread(void *ptr); char *health_edit_command_from_source(const char *source); void sql_refresh_hashes(void); -void health_add_host_labels(void); void health_string2json(BUFFER *wb, const char *prefix, const char *label, const char *value, const char *suffix); void health_log_alert_transition_with_trace(RRDHOST *host, ALARM_ENTRY *ae, int line, const char *file, const char *function); |