Class: Rabbitek::Server::Hooks::OpenTracing
- Inherits:
-
Rabbitek::ServerHook
- Object
- Rabbitek::ServerHook
- Rabbitek::Server::Hooks::OpenTracing
- Defined in:
- lib/rabbitek/server/hooks/opentracing.rb
Overview
OpenTracing server hook
Instance Method Summary collapse
Instance Method Details
#call(consumer, message) ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/rabbitek/server/hooks/opentracing.rb', line 11 def call(consumer, ) response = nil ::OpenTracing.start_active_span( .delivery_info.routing_key, opts(.delivery_info, .properties) ) do |scope| response = super rescue StandardError => e Utils::OpenTracing.log_error(scope.span, e) raise end response end |