From bf72297d35c4ab169b2e4da9973ab5b5e3410981 Mon Sep 17 00:00:00 2001 From: Vijay Dev Date: Sat, 24 Dec 2011 20:39:10 +0530 Subject: add latest changes to 3.2 release notes --- railties/guides/source/3_2_release_notes.textile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/railties/guides/source/3_2_release_notes.textile b/railties/guides/source/3_2_release_notes.textile index 370881260e..a4d5ed9116 100644 --- a/railties/guides/source/3_2_release_notes.textile +++ b/railties/guides/source/3_2_release_notes.textile @@ -71,6 +71,8 @@ h3. Railties * New applications get a flag config.active_record.auto_explain_threshold_in_seconds in the environments configuration files. With a value of 0.5 in development.rb and commented out in production.rb. No mention in test.rb. +* Added config.exceptions_app to set the exceptions application invoked by the +ShowException+ middleware when an exception happens. Defaults to ActionDispatch::PublicExceptions.new(Rails.public_path). + * Added a DebugExceptions middleware which contains features extracted from ShowExceptions middleware. * Display mounted engines' routes in rake routes. @@ -91,6 +93,14 @@ config.railties_order = [Blog::Engine, :main_app, :all] * Attributes on scaffold and model generators default to string. This allows the following: rails g scaffold Post title body:text author +* Allow scaffold/model/migration generators to accept "index" and "uniq" modifiers. For example, + + +rails g scaffold Post title:string:index author:uniq price:decimal{7,2} + + +will create indexes for +title+ and +author+ with the latter being an unique index. Some types such as decimal accept custom options. In the example, +price+ will be a decimal column with precision and scale set to 7 and 2 respectively. + * Remove old plugin generator +rails generate plugin+ in favor of +rails plugin new+ command. * Remove old config.paths.app.controller API in favor of config.paths["app/controller"]. @@ -101,6 +111,8 @@ h4. Action Controller * Make ActiveSupport::Benchmarkable a default module for ActionController::Base, so the #benchmark method is once again available in the controller context like it used to be. +* Added +:gzip+ option to +caches_page+. The default option can be configured globally using page_cache_compression. + * Rails will now use your default layout (such as "layouts/application") when you specify a layout with :only and :except condition, and those conditions fail. @@ -168,6 +180,8 @@ h4. Action Dispatch * Added ActionDispatch::RequestId middleware that'll make a unique X-Request-Id header available to the response and enables the ActionDispatch::Request#uuid method. This makes it easy to trace requests from end-to-end in the stack and to identify individual requests in mixed logs like Syslog. +* The ShowExceptions middleware now accepts a exceptions application that is responsible to render an exception when the application fails. The application is invoked with a copy of the exception in +env["action_dispatch.exception"]+ and with the PATH_INFO rewritten to the status code. + * Allow rescue responses to be configured through a railtie as in config.action_dispatch.rescue_responses. h4. Action View -- cgit v1.2.3