method
with_instrumenter
v7.1.3.2 -
Show latest stable
- Class:
ActiveRecord::ConnectionAdapters::AbstractAdapter
with_instrumenter(instrumenter, &block)public
No documentation available.
# File activerecord/lib/active_record/connection_adapters/abstract_adapter.rb, line 198
def with_instrumenter(instrumenter, &block) # :nodoc:
Thread.handle_interrupt(EXCEPTION_NEVER) do
previous_instrumenter = @instrumenter
@instrumenter = instrumenter
Thread.handle_interrupt(EXCEPTION_IMMEDIATE, &block)
ensure
@instrumenter = previous_instrumenter
end
end