Method: NewRelic::Agent#disable_all_tracing
- Defined in:
- lib/new_relic/agent.rb
#disable_all_tracing ⇒ Object
Yield to the block without collecting any metrics or traces in any of the subsequent calls. If executed recursively, will keep track of the first entry point and turn on tracing again after leaving that block. This uses the thread local Tracer::State.
556 557 558 559 560 561 562 563 564 565 566 567 |
# File 'lib/new_relic/agent.rb', line 556 def disable_all_tracing record_api_supportability_metric(:disable_all_tracing) return yield unless agent begin agent.push_trace_execution_flag(false) yield ensure agent.pop_trace_execution_flag end end |