From 925afca37cb124eff0819ee51400aa5df16daa68 Mon Sep 17 00:00:00 2001 From: gmhomb Date: Wed, 27 Mar 2024 16:16:59 +0100 Subject: [PATCH] out_prometheus_remote_write: update cutoff treshold This treshold was added to stop metrics older than one hour being sent to prometheus. It seems that during compilation, atleast on windows, this number gets changed to 817405952, which is significantly lower and results in all metrics being thrown. The treshold have been changed to a static value that persists through compilation. Signed-off-by: gmhomb --- include/cmetrics/cmt_encode_prometheus_remote_write.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/cmetrics/cmt_encode_prometheus_remote_write.h b/include/cmetrics/cmt_encode_prometheus_remote_write.h index 9351ed6..0d9f680 100644 --- a/include/cmetrics/cmt_encode_prometheus_remote_write.h +++ b/include/cmetrics/cmt_encode_prometheus_remote_write.h @@ -25,7 +25,7 @@ #include #define CMT_ENCODE_PROMETHEUS_REMOTE_WRITE_ADD_METADATA CMT_FALSE -#define CMT_ENCODE_PROMETHEUS_REMOTE_WRITE_CUTOFF_THRESHOLD 60L*60L*1000000000L +#define CMT_ENCODE_PROMETHEUS_REMOTE_WRITE_CUTOFF_THRESHOLD 3600000000000L /* One hour in nanoseconds */ #define CMT_ENCODE_PROMETHEUS_REMOTE_WRITE_SUCCESS 0 #define CMT_ENCODE_PROMETHEUS_REMOTE_WRITE_ALLOCATION_ERROR 1