Class: Aws::S3::Plugins::Md5s::Handler Private
- Inherits:
-
Seahorse::Client::Handler
- Object
- Seahorse::Client::Handler
- Aws::S3::Plugins::Md5s::Handler
- Defined in:
- lib/aws-sdk-s3/plugins/md5s.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Constant Summary collapse
- CHUNK_SIZE =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
one MB
1 * 1024 * 1024
Instance Method Summary collapse
- #call(context) ⇒ Object private
Instance Method Details
#call(context) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
24 25 26 27 28 29 30 31 32 |
# File 'lib/aws-sdk-s3/plugins/md5s.rb', line 24 def call(context) if !context[:checksum_algorithms] # skip in favor of flexible checksum body = context.http_request.body if body.respond_to?(:size) && body.size > 0 context.http_request.headers['Content-Md5'] ||= md5(body) end end @handler.call(context) end |