summaryrefslogtreecommitdiffstats
path: root/streaming/receiver.c
diff options
context:
space:
mode:
authorCosta Tsaousis <costa@netdata.cloud>2022-11-09 20:43:52 +0200
committerGitHub <noreply@github.com>2022-11-09 20:43:52 +0200
commit96ba2dadb48439e667c62b721a6d8c41a92a5187 (patch)
treec45ae146c1c1a55d3d63981ab04dcbefaf1c09b9 /streaming/receiver.c
parent4b39609c35fceae5374fd051c0b987eb708312f6 (diff)
break active-active loop from replicating non-existing child to each other (#13968)
break active-active loop from replicating non-existing child to each-other
Diffstat (limited to 'streaming/receiver.c')
-rw-r--r--streaming/receiver.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/streaming/receiver.c b/streaming/receiver.c
index ed5d51fe3d..40673f05b4 100644
--- a/streaming/receiver.c
+++ b/streaming/receiver.c
@@ -726,6 +726,9 @@ static int rrdpush_receive(struct receiver_state *rpt)
rrdcontext_host_child_connected(rpt->host);
+
+ rrdhost_flag_clear(rpt->host, RRDHOST_FLAG_RRDPUSH_RECEIVER_DISCONNECTED);
+
size_t count = streaming_parser(rpt, &cd, fp_in, fp_out,
#ifdef ENABLE_HTTPS
(rpt->ssl.conn) ? &rpt->ssl : NULL
@@ -734,6 +737,8 @@ static int rrdpush_receive(struct receiver_state *rpt)
#endif
);
+ rrdhost_flag_set(rpt->host, RRDHOST_FLAG_RRDPUSH_RECEIVER_DISCONNECTED);
+
log_stream_connection(rpt->client_ip, rpt->client_port,
rpt->key, rpt->host->machine_guid, rpt->hostname,
"DISCONNECTED");