Web开发框架 - Rails 3.2.3 RC1 发布

openkk 12年前
     <p>Rails 3.2.3 RC1 发布了,该版本修改了 config.active_record.whitelist_attributes 的默认值为 true,该版本会影响到新生成的应用程序,那些使用升级的用户不存在向后兼容性问题,更详细的信息请看 <a href="/misc/goto?guid=4958334877122808126">ruby on rails security guide</a></p>    <h3>与 3.2.2 版本比较,该版本改进记录:</h3>    <p><em>Action Mailer</em></p>    <ul>     <li>Upgrade mail version to 2.4.3 <em>ML</em></li>    </ul>    <p><em>Action Pack</em></p>    <ul>     <li>Do not include the authenticity token in forms where remote: true as ajax forms use the meta-tag value <em>DHH</em> </li>     <li>Turn off verbose mode of rack-cache, we still have X-Rack-Cache to check that info. Closes #5245. <em>Santiago Pastorino</em> </li>     <li>Fix #5238, rendered_format is not set when template is not rendered. <em>Piotr Sarnacki</em> </li>     <li>Upgrade rack-cache to 1.2. <em>José Valim</em> </li>     <li>ActionController::SessionManagement is deprecated. <em>Santiago Pastorino</em> </li>     <li>Since the router holds references to many parts of the system like engines, controllers and the application itself, inspecting the route set can actually be really slow, therefore we default alias inspect to to_s. <em>José Valim</em> </li>     <li>Add a new line after the textarea opening tag. Closes #393 <em>rafaelfranca</em> </li>     <li>Always pass a respond block from to responder. We should let the responder to decide what to do with the given overridden response block, and not short circuit it. <em>sikachu</em> </li>     <li>Fixes layout rendering regression from 3.2.2. <em>José Valim</em> </li>    </ul>    <p><em>Active Model</em></p>    <ul>     <li>No changes</li>    </ul>    <p><em>Active Record</em></p>    <ul>     <li>Added find_or_create_by_{attribute}! dynamic method. <em>Andrew Whited</em> </li>     <li>Whitelist all attribute assignment by default. Change the default for newly generated applications to whitelist all attribute assignment. Also update the generated model classes so users are reminded of the importance of attr_accessible. <em>NZKoz</em> </li>     <li>Update ActiveRecord::AttributeMethods#attribute_present? to return false for empty strings. <em>Jacobkg</em> </li>     <li>Fix associations when using per class databases. <em>larskanis</em> </li>     <li>Revert setting NOT NULL constraints in add_timestamps <em>fxn</em> </li>     <li>Fix mysql to use proper text types. Fixes #3931. <em>kennyj</em> </li>     <li>Fix #5069 - Protect foreign key from mass assignment through association builder. <em>byroot</em><br /> </li>    </ul>    <img title="Rails logo" alt="Web开发框架 - Rails 3.2.3 RC1 发布" src="https://simg.open-open.com/show/bc193d0b6fc2860e8b7a5423a5fe2d30.png" width="90" height="90" />    <p><strong>Ruby on Rails</strong> 是一个用于开发数据库驱动的网络应用程序的完整框架。Rails基于MVC(模型- 视图- 控制器)设计模式。从视图中的Ajax应用,到控制器中的访问请求和反馈,到封装数据库的模型,Rails 为你提供一个纯Ruby的开发环境。发布网站时,你只需要一个数据库和一个网络服务器即可。</p>    <p>Ruby On Rails是一个用于编写网络应用程序的软件包.它基于一种计算机软件语言Ruby,给程序开发人员提供了强大的框架支持.你可以用比以前少的多的代码和 短的多的时间编写出一流的网络软件.比较著名的社区网站43things.com, odeo.com和basecamphq.com就是用Ruby On Rails编写的.</p>    <p>Ruby On Rails的指导原则是”不要重复你自己”(Don’t Repeat Yourself, 或DRY).意思是说你写的代码不会有重复的地方.比如以往数据库的接口往往是类似的程序代码但是在很多地方都要重复用到.这无论是给编写还是维护都造成 了很大的代价.相反,Ruby On Rails给你提供了绝大多数的支持,让你只需要短短的几行代码就可以实现强大的功能.而且,Rails提供了代码生成工具,让你甚至不需要编写一行代码 就实现强大的管理程序.</p>    <p>Ruby On Rails通过reflection和runtime extension减少了对configuration文件的依靠,这和Java,C#语言的方向有很大不同,让你减少了很多配置和部署的麻烦,但是性能上却完全可以应付一般网站的需求.</p>    <p>Rails 支持各类网络服务器和数据库。在服务器方面,我们推荐Apache、 lighttpd 或 nginx 代理至 Mongrel (或者使用FastCGI)。 数据库方面,你可以采用MySQL、PostgreSQL、 SQLite、 Oracle、 SQL Server、 DB2、 或其他任何我们支持的系统。 Rails可以在各类操作系统上运行,不过我们建议采用基于'nix的系统进行开发。</p>