This is an automated email from the ASF dual-hosted git repository.

sorber pushed a commit to branch 6.2.x
in repository https://git-dual.apache.org/repos/asf/trafficserver.git

commit c7f9ad5bc63c6581aa3bca156f67adba40be77d3
Author: Thomas Jackson <[email protected]>
AuthorDate: Mon May 23 09:20:36 2016 -0700

    TS-3959: requests are retryable only if bytes were sent and there was no 
connection error
    
    The root issue that TS-4328 and TS-3440 were trying to fix was that ATS was 
too aggressive in retries to origin (namely after the origin had already 
recieved the request). The previous patches attempted to have ATS not retry 
assuming bytes were sent on the wire-- sadly TS-4328 actually only checks that 
we set bytes to be written to the wire. To fix this we simply check if there 
was a connection failure to origin, if so we'll assume that it is retryable 
(since connection failures to or [...]
    
    (cherry picked from commit 736009b973ad44ef4c7185f5f3bfb778903e4316)
---
 proxy/http/HttpTransact.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc
index 65dcc8a..c4d10f5 100644
--- a/proxy/http/HttpTransact.cc
+++ b/proxy/http/HttpTransact.cc
@@ -6472,8 +6472,8 @@ HttpTransact::is_request_valid(State *s, HTTPHdr 
*incoming_request)
 bool
 HttpTransact::is_request_retryable(State *s)
 {
-  // If the connection was established-- we cannot retry
-  if (s->state_machine->server_request_hdr_bytes > 0) {
+  // If there was no error establishing the connection (and we sent bytes)-- 
we cannot retry
+  if (s->current.state != CONNECTION_ERROR && 
s->state_machine->server_request_hdr_bytes > 0) {
     return false;
   }
 

-- 
To stop receiving notification emails like this one, please contact
"[email protected]" <[email protected]>.

Reply via email to