aws/aws-sdk-ruby — pull request #228 by trevorrowe (2013-04-12 22:36:41+00:00)
Title: Support the "Expect" header and "100-continue" responses

Added two new configuration options to AWS.config:

* :http_continue_timeout (time in seconds)
* :http_continue_threshold (size in bytes)

If a request body exceeds the :http_continue_threshold, then the
"Expect" header will be set to "100-continue". The http client will
then wait for a "100 Continue" response or :http_continue_timeout
seconds before sending the body.

By default the `:http_continue_threshold` defaults to `false` (which disables this feature). The `:http_continue_timeout` defaults to 1 second, but only takes effect when the request body exceedes the `:http_continue_threshold`.

Due to a bug in Net::HTTP, this feature will only work with a patch. You can monkey patch Net::HTTP with the following:

```
AWS.patch_net_http_100_continue!
```

Please note, this feature does not work in Ruby 1.8