@cryptotaxi247 / netdata-1 / commits / 7bba071ae

Fix the log entry for incoming cloud start streaming commands (#12908)

Add the correct requested chart sequence id from the cloud and also record the local one we have

Stelios Fragkakis committed May 16, 2022 at 12:38 UTC 7bba071aece796e62987ca43f78f034bccd419ec
1 file changed +4 -3
database/sqlite/sqlite_aclk_chart.c
+4 -3
@@ -634,7 +634,7 @@ void aclk_receive_chart_reset(struct aclk_database_worker_config *wc, struct acl
634 freez(hostname);
635 } else {
636 log_access(
637 - "ACLK STA [%s (%s)]: Restarting chart sync from sequence %" PRIu64,
637 + "ACLK STA [%s (%s)]: RESTARTING CHART SYNC FROM SEQUENCE %" PRIu64,
638 wc->node_id,
639 wc->host ? wc->host->hostname : "N/A",
640 cmd.param1);
@@ -750,9 +750,10 @@ void aclk_start_streaming(char *node_id, uint64_t sequence_id, time_t created_at
750 __sync_synchronize();
751 wc->batch_created = now_realtime_sec();
752 log_access(
753 - "ACLK REQ [%s (%s)]: CHARTS STREAM from %" PRIu64 " t=%ld resets=%d",
753 + "ACLK REQ [%s (%s)]: CHARTS STREAM from %"PRIu64" (LOCAL %"PRIu64") t=%ld resets=%d" ,
754 wc->node_id,
755 hostname ? hostname : "N/A",
756 + sequence_id + 1,
757 wc->chart_sequence_id,
758 wc->chart_timestamp,
759 wc->chart_reset_count);
@@ -785,7 +786,7 @@ void aclk_start_streaming(char *node_id, uint64_t sequence_id, time_t created_at
786 "ACLK REQ [%s (%s)]: CHART RESET from %" PRIu64 " t=%ld batch=%" PRIu64,
787 wc->node_id,
788 hostname ? hostname : "N/A",
788 - wc->chart_sequence_id,
789 + sequence_id + 1,
790 wc->chart_timestamp,
791 wc->batch_id);
792 cmd.opcode = ACLK_DATABASE_RESET_CHART;