From 353b7bab08704cd2f7e2b6951c9dcd7cf3023e3a Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Wed, 27 Jul 2016 13:25:18 +0200 Subject: http: skip requesting if pipeline is full The rewrite in 742f67eaede80d2f9b3631d8697ebd63b8f95427 is based on the assumption that the pipeline will always be at least one item short each time it is called, but the logs in #832113 suggest that this isn't always the case. I fail to see how at the moment, but the old implementation had this behavior, so restoring it can't really hurt, can it? --- methods/server.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/methods/server.cc b/methods/server.cc index 461143388..6d147fe12 100644 --- a/methods/server.cc +++ b/methods/server.cc @@ -427,6 +427,8 @@ bool ServerMethod::Fetch(FetchItem *) decltype(PipelineDepth) CurrentDepth = 0; for (FetchItem const *I = Queue; I != QueueBack; I = I->Next) ++CurrentDepth; + if (CurrentDepth > AllowedDepth) + return true; do { // Make sure we stick with the same server -- cgit v1.2.3