Przeglądaj źródła

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?
David Kalnischkies 10 lat temu
rodzic
commit
353b7bab08
1 zmienionych plików z 2 dodań i 0 usunięć
  1. 2 0
      methods/server.cc

+ 2 - 0
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