Skip to content

Commit aa6d21e

Browse files
committed
make warning less aggressive
1 parent ef656ba commit aa6d21e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/com/uid2/optout/traffic/TrafficCalculator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,7 @@ private void evictOldCacheEntries(long cutoffTimestamp) {
554554

555555
/**
556556
* Determine traffic status based on current vs baseline traffic.
557-
* Logs warnings at 50%, 75%, and 90% of the circuit breaker threshold.
557+
* Logs warnings after 80% of the threshold is reached.
558558
*/
559559
TrafficStatus determineStatus(int recentTrafficTotal, int baselineTraffic) {
560560
if (baselineTraffic == 0 || thresholdMultiplier == 0) {
@@ -566,7 +566,7 @@ TrafficStatus determineStatus(int recentTrafficTotal, int baselineTraffic) {
566566
double thresholdPercent = (double) recentTrafficTotal / threshold * 100;
567567

568568
// log warning if we reach 50 percent of the threshold
569-
if (thresholdPercent >= 50.0) {
569+
if (thresholdPercent >= 75.0) {
570570
LOGGER.warn("high_message_volume: {}% of threshold reached, recentTrafficTotal={}, threshold={} ({}x{})",
571571
String.format("%.1f", thresholdPercent), recentTrafficTotal, threshold, thresholdMultiplier, baselineTraffic);
572572
}

0 commit comments

Comments
 (0)