diff options
author | Vijay Dev <vijaydev.cse@gmail.com> | 2017-05-20 20:28:29 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-20 20:28:29 +0530 |
commit | ac3564693c6df9c9f9a46f681f4f6a4ea84997e6 (patch) | |
tree | f14278916799f9cd6c0b7ba4bbdbab863fed62be /guides/source | |
parent | dccfcbfdafb2bd77a7d130cb69e0c3725d7f7c6d (diff) | |
parent | 99209b4ec06b2f87b28de5bd7d02b6ed815994e6 (diff) | |
download | rails-ac3564693c6df9c9f9a46f681f4f6a4ea84997e6.tar.gz rails-ac3564693c6df9c9f9a46f681f4f6a4ea84997e6.tar.bz2 rails-ac3564693c6df9c9f9a46f681f4f6a4ea84997e6.zip |
Merge pull request #29162 from ffmike/update-rack-guide
Update 'Rails on Rack' guide [ci skip]
Diffstat (limited to 'guides/source')
-rw-r--r-- | guides/source/rails_on_rack.md | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/guides/source/rails_on_rack.md b/guides/source/rails_on_rack.md index f25b185fb5..cef8450ee4 100644 --- a/guides/source/rails_on_rack.md +++ b/guides/source/rails_on_rack.md @@ -110,11 +110,12 @@ use ActiveSupport::Cache::Strategy::LocalCache::Middleware use Rack::Runtime use Rack::MethodOverride use ActionDispatch::RequestId +use ActionDispatch::RemoteIp +use Sprockets::Rails::QuietAssets use Rails::Rack::Logger use ActionDispatch::ShowExceptions use WebConsole::Middleware use ActionDispatch::DebugExceptions -use ActionDispatch::RemoteIp use ActionDispatch::Reloader use ActionDispatch::Callbacks use ActiveRecord::Migration::CheckPending @@ -124,7 +125,7 @@ use ActionDispatch::Flash use Rack::Head use Rack::ConditionalGet use Rack::ETag -run Rails.application.routes +run MyApp.application.routes ``` The default middlewares shown here (and some others) are each summarized in the [Internal Middlewares](#internal-middleware-stack) section, below. @@ -238,6 +239,14 @@ Much of Action Controller's functionality is implemented as Middlewares. The fol * Makes a unique `X-Request-Id` header available to the response and enables the `ActionDispatch::Request#request_id` method. +**`ActionDispatch::RemoteIp`** + +* Checks for IP spoofing attacks. + +**`Sprockets::Rails::QuietAssets`** + +* Suppresses logger output for asset requests. + **`Rails::Rack::Logger`** * Notifies the logs that the request has began. After request is complete, flushes all the logs. @@ -250,10 +259,6 @@ Much of Action Controller's functionality is implemented as Middlewares. The fol * Responsible for logging exceptions and showing a debugging page in case the request is local. -**`ActionDispatch::RemoteIp`** - -* Checks for IP spoofing attacks. - **`ActionDispatch::Reloader`** * Provides prepare and cleanup callbacks, intended to assist with code reloading during development. |