Sha256: 420a30b9540ed1eca667484688fc9792c6caed03fa49aeb42f295b5de2b65736

Contents?: true

Size: 564 Bytes

Versions: 110

Compression:

Stored size: 564 Bytes

Contents

# frozen_string_literal: true

module Appsignal
  class Hooks
    # @api private
    class UnicornHook < Appsignal::Hooks::Hook
      register :unicorn

      def dependencies_present?
        defined?(::Unicorn::HttpServer) &&
          defined?(::Unicorn::Worker)
      end

      def install
        require "appsignal/integrations/unicorn"
        ::Unicorn::HttpServer.send(:prepend, Appsignal::Integrations::UnicornIntegration::Server)
        ::Unicorn::Worker.send(:prepend, Appsignal::Integrations::UnicornIntegration::Worker)
      end
    end
  end
end

Version data entries

110 entries across 110 versions & 1 rubygems

Version Path
appsignal-3.3.11-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.11 lib/appsignal/hooks/unicorn.rb
appsignal-3.4.0-java lib/appsignal/hooks/unicorn.rb
appsignal-3.4.0 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.10-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.10 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.9-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.9 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.8-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.8 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.7-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.7 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.6-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.6 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.5-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.5 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.4-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.4 lib/appsignal/hooks/unicorn.rb
appsignal-3.3.3-java lib/appsignal/hooks/unicorn.rb
appsignal-3.3.3 lib/appsignal/hooks/unicorn.rb