You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
proxy.config.http.send_100_continue_response default should be changed to 1 #7346
I'm opening a new issue rather than reopening effectively the same older issue #2543. This original issue was closed deciding that it would be more standards compliant for the origin to product the 100-continue response. And in general I agree. However, with this setting set to 0, the exchange between the user agent and ATS is not standards compliant if the Expect header is set to 100-continue.
In the current default case, the following steps occur.
Client sends POST request with Expect header set to 100-continue
ATS sends post request to origin
ATS sets up tunnel to send post body from client to origin
ATS receives and relays 100-continue response from origin
ATS receives and relays the POST response
So from the client's perspective,
Send POST request
Send POST body
Receive 100-continue response
Receive POST body response
In this default sequence the 100-continue does absolutely nothing. If the client was implementing things strictly, the client should stall sending the post body because it hasn't received the 100-continue response.
The reason I stumbled on this is that I was helping something debug "performance" issues with adding ATS to an exchange. Adding ATS adding 1 second to the latency of a relatively small post request made by curl. Even those the ATS and the origin were sitting right next to each other. The issue is that proxy.config.http.send_100_continue_response was set to 0. Curl didn't stall but it seemed to wait for around 1 second before sending along the post body anyway.
Since many people evaluate ATS using tools like curl, I think a more standards compliant and better out of the box experience would be to have proxy.config.http.send_100_continue_response set to 1 by default.
The other alternative would be to adjust the ATS behavior to properly delay transmitting the POST body until the 100-continue response has been propagated. That is a much bigger change, and I don't see anyone taking the time to do that in the near future..
Hmm, based on the issue, the default should be 1 for proxy.config.http.send_100_continue_response. I am working up another PR, so the 100-continue is processed before the post body is sent. With that change, we can leave the default for proxy.config.http.send_100_continue_response to 0.
Activity
bryancall commentedon Mar 18, 2021
In this use case is the origin sending back a 100-continue to ATS?
bryancall commentedon Mar 18, 2021
Here is the original issue: https://issues.apache.org/jira/browse/TS-1125 and commit: 9da1230
shinrich commentedon Jun 18, 2021
Hmm, based on the issue, the default should be 1 for proxy.config.http.send_100_continue_response. I am working up another PR, so the 100-continue is processed before the post body is sent. With that change, we can leave the default for proxy.config.http.send_100_continue_response to 0.