Sha256: b8ccf2387ac489fa8e43aa717e8866a5d201a89826d51118a898f65c9f383737
Contents?: true
Size: 807 Bytes
Versions: 35
Compression:
Stored size: 807 Bytes
Contents
# frozen_string_literal: true require_relative '../patcher' require_relative 'ext' require_relative 'instrumentation' module Datadog module Tracing module Contrib module MongoDB # Patcher enables patching of 'mongo' module. module Patcher include Contrib::Patcher module_function def target_version Integration.version end def patch ::Mongo::Client.include(Instrumentation::Client) add_mongo_monitoring end def add_mongo_monitoring # Subscribe to all COMMAND queries with our subscriber class ::Mongo::Monitoring::Global.subscribe(::Mongo::Monitoring::COMMAND, MongoCommandSubscriber.new) end end end end end end
Version data entries
35 entries across 35 versions & 2 rubygems