class RailsBand::ActiveSupport::LogSubscriber
The custom LogSubscriber
for ActiveSupport
.
Public Instance Methods
cache_delete(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 43 def cache_delete(event) consumer_of(__method__)&.call(Event::CacheDelete.new(event)) end
cache_delete_multi(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 47 def cache_delete_multi(event) consumer_of(__method__)&.call(Event::CacheDeleteMulti.new(event)) end
cache_exist?(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 51 def cache_exist?(event) consumer_of(__method__)&.call(Event::CacheExist.new(event)) end
cache_fetch_hit(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 31 def cache_fetch_hit(event) consumer_of(__method__)&.call(Event::CacheFetchHit.new(event)) end
cache_generate(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 27 def cache_generate(event) consumer_of(__method__)&.call(Event::CacheGenerate.new(event)) end
cache_read(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 19 def cache_read(event) consumer_of(__method__)&.call(Event::CacheRead.new(event)) end
cache_read_multi(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 23 def cache_read_multi(event) consumer_of(__method__)&.call(Event::CacheReadMulti.new(event)) end
cache_write(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 35 def cache_write(event) consumer_of(__method__)&.call(Event::CacheWrite.new(event)) end
cache_write_multi(event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 39 def cache_write_multi(event) consumer_of(__method__)&.call(Event::CacheWriteMulti.new(event)) end
Private Instance Methods
consumer_of(sub_event)
click to toggle source
# File lib/rails_band/active_support/log_subscriber.rb, line 57 def consumer_of(sub_event) consumers[:"#{sub_event}.active_support"] || consumers[:active_support] || consumers[:default] end