Module: Datadog::Tracing::Contrib::Grape::Instrumentation::GenerateApiMethodPatch
- Defined in:
- lib/datadog/tracing/contrib/grape/instrumentation.rb
Overview
GenerateApiMethodPatch - class method instrumentation for endpoint render (Grape < 3.0.0)
Instance Method Summary collapse
Instance Method Details
#generate_api_method(*params, &block) ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/datadog/tracing/contrib/grape/instrumentation.rb', line 11 def generate_api_method(*params, &block) method_api = super proc do |*args| ::ActiveSupport::Notifications.instrument('endpoint_render.grape.start_render') method_api.call(*args) end end |