]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Author: Alex Rousskov <rousskov@measurement-factory.com>
authorAmos Jeffries <amosjeffries@squid-cache.org>
Sun, 7 Nov 2010 10:04:54 +0000 (03:04 -0700)
committerAmos Jeffries <amosjeffries@squid-cache.org>
Sun, 7 Nov 2010 10:04:54 +0000 (03:04 -0700)
Bug 3091: Bypassed ICAP errors are not counted as service failures.

Notify ICAP service about the failure even if we can bypass it. Otherwise,
a failing service may continue to stay "up", preventing Squid from using a
healthy backup alternative in a service_set (or bypassing ICAP completeley).

src/adaptation/icap/ModXact.cc

index eaef7a51bb486acf2e73ac1a8dbee37ee3cd9be3..2d5093e6c8571112e95a4afcf8dc2b7dd944202a 100644 (file)
@@ -639,6 +639,8 @@ void Adaptation::Icap::ModXact::bypassFailure()
         if (!doneWithIo())
             debugs(93, 7, HERE << "Warning: bypass failed to stop I/O" << status());
     }
+
+    service().noteFailure(); // we are bypassing, but this is still a failure
 }
 
 void Adaptation::Icap::ModXact::disableBypass(const char *reason, bool includingGroupBypass)