You are viewing documentation for version 3 of the AWS SDK for Ruby. Version 2 documentation can be found here.

Class: Aws::S3::Plugins::Md5s

Inherits:
Seahorse::Client::Plugin show all
Defined in:
gems/aws-sdk-s3/lib/aws-sdk-s3/plugins/md5s.rb

Constant Summary

REQUIRED_OPERATIONS =

Amazon S3 requires these operations to have an MD5 checksum

[
  :delete_objects,
  :put_bucket_cors,
  :put_bucket_lifecycle,
  :put_bucket_policy,
  :put_bucket_tagging,
]

Instance Method Summary collapse

Methods inherited from Seahorse::Client::Plugin

#add_options, #after_initialize, after_initialize, #before_initialize, before_initialize, option

Methods included from Seahorse::Client::HandlerBuilder

#handle, #handle_request, #handle_response

Instance Method Details

#add_handlers(handlers, config) ⇒ Object



66
67
68
69
70
71
72
73
74
# File 'gems/aws-sdk-s3/lib/aws-sdk-s3/plugins/md5s.rb', line 66

def add_handlers(handlers, config)
  # priority set low to ensure md5 is computed AFTER the request is
  # built but before it is signed
  handlers.add(Handler, {
    priority: 10,
    step: :build,
    operations: config.compute_checksums ? nil : REQUIRED_OPERATIONS,
  })
end