Do not cache decisions if DefaultDecisionSeconds=0 (#280)

* xx

* Remove outdated comment on decision caching

Remove comment about decision caching based on timeout.

---------

Co-authored-by: maxlerebourg <maxlerebourg@gmail.com>
This commit is contained in:
David
2025-10-18 11:58:00 +02:00
committed by GitHub
parent 65a2f79fb3
commit a2d3708bc3

View File

@@ -529,7 +529,7 @@ func handleNoStreamCache(bouncer *Bouncer, remoteIP string) (string, error) {
default:
bouncer.log.Debug("handleStreamCache:unknownType " + decision.Type)
}
if isLiveMode {
if isLiveMode && bouncer.defaultDecisionTimeout > 0 {
durationSecond := int64(duration.Seconds())
if bouncer.defaultDecisionTimeout < durationSecond {
durationSecond = bouncer.defaultDecisionTimeout