module TestProf::EventProf::Instrumentations::ActiveSupport
Wrapper over ActiveSupport::Notifications
Public Class Methods
instrument(event) { || ... }
click to toggle source
# File lib/test_prof/event_prof/instrumentations/active_support.rb, line 34 def instrument(event) ::ActiveSupport::Notifications.instrument(event) { yield } end
subscribe(event, &block)
click to toggle source
# File lib/test_prof/event_prof/instrumentations/active_support.rb, line 28 def subscribe(event, &block) raise ArgumentError, "Block is required!" unless block ::ActiveSupport::Notifications.subscribe(event, Subscriber.new(block)) end