From aa6d21e6100f9712a19c153ecb21dfd0bd2b4aeb Mon Sep 17 00:00:00 2001 From: Ian-Nara Date: Fri, 19 Dec 2025 14:47:50 -0700 Subject: [PATCH 1/2] make warning less aggressive --- src/main/java/com/uid2/optout/traffic/TrafficCalculator.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java b/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java index 49f657f..95b339f 100644 --- a/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java +++ b/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java @@ -554,7 +554,7 @@ private void evictOldCacheEntries(long cutoffTimestamp) { /** * Determine traffic status based on current vs baseline traffic. - * Logs warnings at 50%, 75%, and 90% of the circuit breaker threshold. + * Logs warnings after 80% of the threshold is reached. */ TrafficStatus determineStatus(int recentTrafficTotal, int baselineTraffic) { if (baselineTraffic == 0 || thresholdMultiplier == 0) { @@ -566,7 +566,7 @@ TrafficStatus determineStatus(int recentTrafficTotal, int baselineTraffic) { double thresholdPercent = (double) recentTrafficTotal / threshold * 100; // log warning if we reach 50 percent of the threshold - if (thresholdPercent >= 50.0) { + if (thresholdPercent >= 75.0) { LOGGER.warn("high_message_volume: {}% of threshold reached, recentTrafficTotal={}, threshold={} ({}x{})", String.format("%.1f", thresholdPercent), recentTrafficTotal, threshold, thresholdMultiplier, baselineTraffic); } From b0e6d93d5ac3fea360323c0660a86df9ea2e5f01 Mon Sep 17 00:00:00 2001 From: Ian-Nara Date: Fri, 19 Dec 2025 14:48:56 -0700 Subject: [PATCH 2/2] tweak value --- src/main/java/com/uid2/optout/traffic/TrafficCalculator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java b/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java index 95b339f..125689c 100644 --- a/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java +++ b/src/main/java/com/uid2/optout/traffic/TrafficCalculator.java @@ -566,7 +566,7 @@ TrafficStatus determineStatus(int recentTrafficTotal, int baselineTraffic) { double thresholdPercent = (double) recentTrafficTotal / threshold * 100; // log warning if we reach 50 percent of the threshold - if (thresholdPercent >= 75.0) { + if (thresholdPercent >= 80.0) { LOGGER.warn("high_message_volume: {}% of threshold reached, recentTrafficTotal={}, threshold={} ({}x{})", String.format("%.1f", thresholdPercent), recentTrafficTotal, threshold, thresholdMultiplier, baselineTraffic); }