Add OTel HttpClient Instrumentation

This will be useful for the GCE provider.
This commit is contained in:
Gene Liverman 2022-01-20 11:42:43 -05:00
parent 6d6da30696
commit 72c82cf084
No known key found for this signature in database
GPG key ID: 3AF83985B6C857C6
4 changed files with 13 additions and 0 deletions

View file

@ -17,6 +17,7 @@ module Vmpooler
# Dependencies for tracing
require 'opentelemetry-instrumentation-concurrent_ruby'
require 'opentelemetry-instrumentation-http_client'
require 'opentelemetry-instrumentation-redis'
require 'opentelemetry-instrumentation-sinatra'
require 'opentelemetry-sdk'
@ -265,6 +266,7 @@ module Vmpooler
OpenTelemetry::SDK.configure do |c|
c.use 'OpenTelemetry::Instrumentation::Sinatra'
c.use 'OpenTelemetry::Instrumentation::ConcurrentRuby'
c.use 'OpenTelemetry::Instrumentation::HttpClient'
c.use 'OpenTelemetry::Instrumentation::Redis'
c.add_span_processor(span_processor)