From 1da4e73bd6a05fc0f0c2df66824dd37d743292f0 Mon Sep 17 00:00:00 2001 From: andymck Date: Thu, 17 Aug 2023 14:16:00 +0100 Subject: [PATCH] widen both sides of the witness loader window to 2x ingestor roll up time (#599) --- iot_verifier/src/loader.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/iot_verifier/src/loader.rs b/iot_verifier/src/loader.rs index 9652309a7..5cc539666 100644 --- a/iot_verifier/src/loader.rs +++ b/iot_verifier/src/loader.rs @@ -183,15 +183,17 @@ impl Loader { // this is to allow for a witness being in a rolled up file // from just before or after the beacon files // the width extention needs to be at least equal to that - // of the ingestor roll up time + // of the ingestor roll up time plus a buffer + // to account for the potential of the ingestor write time for + // witness reports being out of sync with that of beacon files // for witnesses we do need the filter but not the arc match self .process_events( FileType::IotWitnessIngestReport, &self.ingest_store, gateway_cache, - after - self.ingestor_rollup_time, - before + self.ingestor_rollup_time, + after - (self.ingestor_rollup_time + ChronoDuration::seconds(120)), + before + (self.ingestor_rollup_time + ChronoDuration::seconds(120)), None, Some(&filter), )