Class: Honeycomb::Aws::SdkHandler

Inherits:
Seahorse::Client::Handler
  • Object
show all
Defined in:
lib/honeycomb/integrations/aws.rb

Overview

An AWS plugin handler that creates spans around SDK calls.

Each aws-sdk client provides a one-to-one mapping of methods to logical API operations. SdkHandler is responsible for starting the root level AWS span for the SDK method being called.

Plugin accomplishes this by adding the handler early in the process, around the initialization step. This doesn’t necessarily represent the network latency of the API requests being made to Amazon, since SDK calls might involve several underlying operations: request signing, response parsing, retries, redirects, etc. Thus, ApiHandler is responsible for creating child spans around individual HTTP API calls. The span created by SdkHandler represents the overall result of the method call you made to the aws-sdk client.

Instance Method Summary collapse

Instance Method Details

#call(context) ⇒ Object



86
87
88
89
90
91
92
93
94
95
96
# File 'lib/honeycomb/integrations/aws.rb', line 86

def call(context)
  setup(context)
  response = @handler.call(context)
  teardown(context, response.error)
  response
rescue StandardError => e
  teardown(context, e)
  raise e
ensure
  finish(context)
end