fixes proxy forwarding claim_id to old parent (#9828)
when v3 child reloads claim state while connected to v3 proxy the proxy forwarded it to parent despite it being v2
Timotej S committed
Aug 27, 2020 at 14:52 UTC
08bd4bb284c924584d8bda6e72fcfb89002b5eb1
2 files changed
+4
-2
streaming/rrdpush.c
+3
@@ -369,6 +369,9 @@ void rrdpush_claimed_id(RRDHOST *host)
369
{
370
if(unlikely(!host->rrdpush_send_enabled || !host->rrdpush_sender_connected))
371
return;
372
+
373
+ if(host->sender->version < STREAM_VERSION_CLAIM)
374
+ return;
375
376
sender_start(host->sender);
377
netdata_mutex_lock(&host->claimed_id_lock);
streaming/sender.c
+1
-2
@@ -622,8 +622,7 @@ void *rrdpush_sender_thread(void *ptr) {
622
buffer_sprintf(s->build, "TIMESTAMP %ld", now);
623
sender_commit(s);
624
}
625
- if (s->version >= STREAM_VERSION_CLAIM)
626
- rrdpush_claimed_id(s->host);
625
+ rrdpush_claimed_id(s->host);
626
continue;
627
}
628