Flowdock
method

default_middleware_stack

Importance_0
v3.0.5 - Show latest stable - 0 notes - Class: Rails::Application
default_middleware_stack() protected

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File railties/lib/rails/application.rb, line 188
    def default_middleware_stack
      ActionDispatch::MiddlewareStack.new.tap do |middleware|
        middleware.use ::ActionDispatch::Static, paths.public.to_a.first if config.serve_static_assets
        middleware.use ::Rack::Lock if !config.allow_concurrency
        middleware.use ::Rack::Runtime
        middleware.use ::Rails::Rack::Logger
        middleware.use ::ActionDispatch::ShowExceptions, config.consider_all_requests_local if config.action_dispatch.show_exceptions
        middleware.use ::ActionDispatch::RemoteIp, config.action_dispatch.ip_spoofing_check, config.action_dispatch.trusted_proxies
        middleware.use ::Rack::Sendfile, config.action_dispatch.x_sendfile_header
        middleware.use ::ActionDispatch::Callbacks, !config.cache_classes
        middleware.use ::ActionDispatch::Cookies

        if config.session_store
          middleware.use config.session_store, config.session_options
          middleware.use ::ActionDispatch::Flash
        end

        middleware.use ::ActionDispatch::ParamsParser
        middleware.use ::Rack::MethodOverride
        middleware.use ::ActionDispatch::Head
        middleware.use ::ActionDispatch::BestStandardsSupport, config.action_dispatch.best_standards_support if config.action_dispatch.best_standards_support
      end
    end
Register or log in to add new notes.