Sha256: df9e37a70013e7f7c617cdfeea38673539ec1c1c0e76a0598dbfb6f8c7d0f9c0

Contents?: true

Size: 483 Bytes

Versions: 38

Compression:

Stored size: 483 Bytes

Contents

module Appsignal
  class Hooks
    # @api private
    class MongoRubyDriverHook < Appsignal::Hooks::Hook
      register :mongo_ruby_driver

      def dependencies_present?
        defined?(::Mongo::Monitoring::Global)
      end

      def install
        require "appsignal/integrations/mongo_ruby_driver"

        Mongo::Monitoring::Global.subscribe(
          Mongo::Monitoring::COMMAND,
          Appsignal::Hooks::MongoMonitorSubscriber.new
        )
      end
    end
  end
end

Version data entries

38 entries across 38 versions & 1 rubygems

Version Path
appsignal-2.5.3-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.3 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.3.alpha.2 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.3.alpha.2-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.3.alpha.1 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.3.alpha.1-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.2-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.2 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.1-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.1 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.1.beta.1-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.1.beta.1 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0.beta.1-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0.beta.1 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0.alpha.1-java lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.5.0.alpha.1 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.4.3 lib/appsignal/hooks/mongo_ruby_driver.rb
appsignal-2.4.2 lib/appsignal/hooks/mongo_ruby_driver.rb