Sha256: e9525df370345712f11b57836b04e91fb2c39ccab727b26b0e4c7221fdb0075a

Contents?: true

Size: 727 Bytes

Versions: 13

Compression:

Stored size: 727 Bytes

Contents

# This file is distributed under New Relic's license terms.
# See https://github.com/newrelic/newrelic-ruby-agent/blob/main/LICENSE for complete details.
# frozen_string_literal: true

module NewRelic::Agent::Instrumentation
  module ActiveSupportBroadcastLogger
    def record_one_broadcast_with_new_relic(*args)
      if broadcasts && broadcasts[1..-1]
        broadcasts[1..-1].each { |broadcasted_logger| broadcasted_logger.instance_variable_set(:@skip_instrumenting, true) }
        yield
        broadcasts.each { |broadcasted_logger| broadcasted_logger.instance_variable_set(:@skip_instrumenting, false) }
      else
        NewRelic::Agent.logger.error('Error recording broadcasted logger')
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
newrelic_rpm-9.17.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.16.1 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.16.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.15.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.14.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.13.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.12.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.11.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.10.2 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.10.1 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.10.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.9.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb
newrelic_rpm-9.8.0 lib/new_relic/agent/instrumentation/active_support_broadcast_logger/instrumentation.rb