Sha256: 59224f93c45629caf33a6a7b01d58e333aba681bc282e335516cd4efc3ad5c4f

Contents?: true

Size: 513 Bytes

Versions: 40

Compression:

Stored size: 513 Bytes

Contents

# frozen_string_literal: true

require 'elastic_apm/span_helpers'

module ElasticAPM
  # @api private
  module Spies
    # @api private
    class JSONSpy
      def install
        ::JSON.class_eval do
          include SpanHelpers
          span_class_method :parse, 'JSON#parse', 'json.parse'
          span_class_method :parse!, 'JSON#parse!', 'json.parse'
          span_class_method :generate, 'JSON#generate', 'json.generate'
        end
      end
    end

    register 'JSON', 'json', JSONSpy.new
  end
end

Version data entries

40 entries across 40 versions & 1 rubygems

Version Path
elastic-apm-3.6.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.5.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.4.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.3.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.2.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.1.0 lib/elastic_apm/spies/json.rb
elastic-apm-3.0.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.12.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.11.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.10.1 lib/elastic_apm/spies/json.rb
elastic-apm-2.10.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.9.1 lib/elastic_apm/spies/json.rb
elastic-apm-2.9.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.8.1 lib/elastic_apm/spies/json.rb
elastic-apm-2.8.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.7.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.6.1 lib/elastic_apm/spies/json.rb
elastic-apm-2.6.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.5.0 lib/elastic_apm/spies/json.rb
elastic-apm-2.4.0 lib/elastic_apm/spies/json.rb