File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -49,13 +49,17 @@ func (d *overuseDetector) onDelayStats(ds DelayStats) {
49
49
} else {
50
50
d .increasingDuration += delta
51
51
}
52
+
52
53
d .increasingCounter ++
53
- if d .increasingDuration > d .overuseTime && d .increasingCounter > 1 {
54
+
55
+ if (d .overuseTime == 0 && d .increasingCounter > 1 ) ||
56
+ (d .increasingDuration > d .overuseTime && d .increasingCounter > 1 ) {
54
57
if estimate > d .lastEstimate {
55
58
use = usageOver
56
59
}
57
60
}
58
61
}
62
+
59
63
if thresholdUse == usageUnder {
60
64
d .increasingCounter = 0
61
65
d .increasingDuration = 0
@@ -67,6 +71,7 @@ func (d *overuseDetector) onDelayStats(ds DelayStats) {
67
71
d .increasingCounter = 0
68
72
use = usageNormal
69
73
}
74
+
70
75
d .lastEstimate = estimate
71
76
72
77
d .dsWriter (DelayStats {
You can’t perform that action at this time.
0 commit comments