Class: Datadog::Contrib::Aws::Handler
- Inherits:
-
Seahorse::Client::Handler
- Object
- Seahorse::Client::Handler
- Datadog::Contrib::Aws::Handler
- Defined in:
- lib/ddtrace/contrib/aws/instrumentation.rb
Overview
Generates Spans for all interactions with AWS
Instance Method Summary collapse
Instance Method Details
#call(context) ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/ddtrace/contrib/aws/instrumentation.rb', line 13 def call(context) pin = Datadog::Pin.get_from(::Aws) return @handler.call(context) unless pin && pin.enabled? pin.tracer.trace(RESOURCE) do |span| result = @handler.call(context) annotate!(span, pin, ParsedContext.new(context)) result end end |