Module: Datadog::Tracing::Contrib::HTTP

Extended by:
CircuitBreaker
Defined in:
lib/datadog/tracing/contrib/http.rb,
lib/datadog/tracing/contrib/http/ext.rb,
lib/datadog/tracing/contrib/http/patcher.rb,
lib/datadog/tracing/contrib/http/integration.rb,
lib/datadog/tracing/contrib/http/circuit_breaker.rb,
lib/datadog/tracing/contrib/http/instrumentation.rb,
lib/datadog/tracing/contrib/http/distributed/fetcher.rb,
lib/datadog/tracing/contrib/http/configuration/settings.rb,
lib/datadog/tracing/contrib/http/distributed/propagation.rb

Overview

HTTP integration

Defined Under Namespace

Modules: CircuitBreaker, Configuration, Distributed, Ext, Instrumentation, Patcher Classes: Integration

Class Method Summary collapse

Methods included from CircuitBreaker

internal_request?, should_skip_distributed_tracing?, should_skip_tracing?

Class Method Details

.extract(data) ⇒ Datadog::Tracing::TraceDigest?

Extract distributed headers from the given request

Parameters:

  • data (Hash)

    the request to extract from

Returns:



25
26
27
28
29
# File 'lib/datadog/tracing/contrib/http.rb', line 25

def self.extract(data)
  raise 'Please invoke Datadog.configure at least once before calling this method' unless @propagation

  @propagation.extract(data)
end

.inject(digest, data) ⇒ Object

Inject distributed headers into the given request

Parameters:



16
17
18
19
20
# File 'lib/datadog/tracing/contrib/http.rb', line 16

def self.inject(digest, data)
  raise 'Please invoke Datadog.configure at least once before calling this method' unless @propagation

  @propagation.inject!(digest, data)
end