Class: Aws::Plugins::DynamoDBCRC32Validation::Handler

Inherits:
Seahorse::Client::Handler show all
Defined in:
lib/aws-sdk-core/plugins/dynamodb_crc32_validation.rb

Instance Attribute Summary

Attributes inherited from Seahorse::Client::Handler

#handler

Instance Method Summary collapse

Methods inherited from Seahorse::Client::Handler

#initialize, #inspect

Constructor Details

This class inherits a constructor from Seahorse::Client::Handler

Instance Method Details

#call(context) ⇒ Object



21
22
23
24
25
26
27
28
29
30
# File 'lib/aws-sdk-core/plugins/dynamodb_crc32_validation.rb', line 21

def call(context)
  # disable response gzipping - Net::HTTP unzips these responses
  # before we can see the body, making it impossible to verify
  # the CRC32 checksum against the compressed body stream
  context.http_request.headers['accept-encoding'] = ''

  @handler.call(context).on_success do |response|
    response.error = validate(context)
  end
end