Class: Atatus::GRPC::ClientInterceptor Private
- Inherits:
-
GRPC::ClientInterceptor
- Object
- GRPC::ClientInterceptor
- Atatus::GRPC::ClientInterceptor
- Defined in:
- lib/atatus/grpc.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Constant Summary collapse
- TYPE =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
'external'
- SUBTYPE =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
'grpc'
Instance Method Summary collapse
-
#request_response(request:, call:, method:, metadata:) ⇒ Object
private
rubocop:disable Lint/UnusedMethodArgument, Style/ExplicitBlockArgument.
Instance Method Details
#request_response(request:, call:, method:, metadata:) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
rubocop:disable Lint/UnusedMethodArgument, Style/ExplicitBlockArgument
29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/atatus/grpc.rb', line 29 def request_response(request:, call:, method:, metadata:) return yield unless (transaction = Atatus.current_transaction) if (trace_context = transaction.trace_context) trace_context.apply_headers { |k, v| [k.downcase] = v } end Atatus.with_span( method, TYPE, subtype: SUBTYPE, context: span_context(call) ) do yield end end |