* conditional overflow doesn't overflow on capacity * typo
@@ -35,7 +35,7 @@ func TimeMachinePour(l *Leaky, msg types.Event) {
}
l.Last_ts = d
l.mutex.Unlock()
- if l.Limiter.AllowN(d, 1) {
+ if l.Limiter.AllowN(d, 1) || l.conditionalOverflow {
l.logger.Tracef("Time-Pouring event %s (tokens:%f)", d, l.Limiter.GetTokensCount())
l.Queue.Add(msg)
} else {