Sha256: eff2d374ecde913c88424862e261205c407ccaca981c393b53668a3caf80a0bf

Contents?: true

Size: 940 Bytes

Versions: 25

Compression:

Stored size: 940 Bytes

Contents

require 'rollbar'

module Rollbar
  module RailtieMixin
    extend ActiveSupport::Concern

    included do
      rake_tasks do
        require 'rollbar/rake_tasks'
      end

      initializer 'rollbar.configuration' do
        config.after_initialize do
          Rollbar.preconfigure do |config|
            config.default_logger = proc { ::Rails.logger }
            config.environment ||= ::Rails.env
            config.root ||= ::Rails.root
            config.framework = "Rails: #{::Rails::VERSION::STRING}"
            config.filepath ||= ::Rails.application.class.parent_name + '.rollbar'
          end
        end
      end

      initializer 'rollbar.controller_methods' do
        ActiveSupport.on_load(:action_controller) do
          # lazily load action_controller methods
          require 'rollbar/plugins/rails/controller_methods'
          include Rollbar::Rails::ControllerMethods
        end
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
rollbar-2.17.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.16.4 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.16.3 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.16.2 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.16.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.6 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.5 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.4 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.3 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.2 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.1 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.15.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.14.1 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.14.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.13.3 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.13.2 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.13.1 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.13.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.12.0 lib/rollbar/plugins/rails/railtie_mixin.rb
rollbar-2.11.5 lib/rollbar/plugins/rails/railtie_mixin.rb