diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-11-25 17:33:56 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-11-25 17:34:10 +0000 |
commit | 83ba6762cc43d9db581b979bb5e3445669e46cc2 (patch) | |
tree | 2e69833b43f791ed253a7a20318b767ebe56cdb8 /src/health/health_event_loop.c | |
parent | Releasing debian version 1.47.5-1. (diff) | |
download | netdata-83ba6762cc43d9db581b979bb5e3445669e46cc2.tar.xz netdata-83ba6762cc43d9db581b979bb5e3445669e46cc2.zip |
Merging upstream version 2.0.3+dfsg (Closes: #923993, #1042533, #1045145).
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/health/health_event_loop.c')
-rw-r--r-- | src/health/health_event_loop.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/health/health_event_loop.c b/src/health/health_event_loop.c index 04d70e11f..0bf6892dd 100644 --- a/src/health/health_event_loop.c +++ b/src/health/health_event_loop.c @@ -133,12 +133,12 @@ static void health_initialize_rrdhost(RRDHOST *host) { rrdhost_flag_set(host, RRDHOST_FLAG_INITIALIZED_HEALTH); host->health_log.max = health_globals.config.health_log_entries_max; - host->health_log.health_log_history = health_globals.config.health_log_history; + host->health_log.health_log_retention_s = health_globals.config.health_log_retention_s; host->health.health_default_exec = string_dup(health_globals.config.default_exec); host->health.health_default_recipient = string_dup(health_globals.config.default_recipient); host->health.use_summary_for_notifications = health_globals.config.use_summary_for_notifications; - host->health_log.next_log_id = (uint32_t)now_realtime_sec(); + host->health_log.next_log_id = get_uint32_id(); host->health_log.next_alarm_id = 0; rw_spinlock_init(&host->health_log.spinlock); @@ -229,7 +229,7 @@ static void health_event_loop(void) { "Postponing alarm checks for %"PRId32" seconds, " "because it seems that the system was just resumed from suspension.", (int32_t)health_globals.config.postpone_alarms_during_hibernation_for_seconds); - schedule_node_info_update(localhost); + schedule_node_state_update(localhost, 0); } if (unlikely(silencers->all_alarms && silencers->stype == STYPE_DISABLE_ALARMS)) { @@ -298,13 +298,11 @@ static void health_event_loop(void) { } worker_is_busy(WORKER_HEALTH_JOB_HOST_LOCK); -#ifdef ENABLE_ACLK - if (netdata_cloud_enabled) { + { struct aclk_sync_cfg_t *wc = host->aclk_config; if (wc && wc->send_snapshot == 2) continue; } -#endif // the first loop is to lookup values from the db foreach_rrdcalc_in_rrdhost_read(host, rc) { @@ -651,7 +649,6 @@ static void health_event_loop(void) { break; } } -#ifdef ENABLE_ACLK struct aclk_sync_cfg_t *wc = host->aclk_config; if (wc && wc->send_snapshot == 1) { wc->send_snapshot = 2; @@ -660,7 +657,6 @@ static void health_event_loop(void) { else if (process_alert_pending_queue(host)) rrdhost_flag_set(host, RRDHOST_FLAG_ACLK_STREAM_ALERTS); -#endif dfe_done(host); |