Ruby on Rails 2.2 Released
Key features in the update include:
- Ruby 1.9 compatibility. Among the key features that Ruby 1.9 brings (at least for users of the "main" C-based implementation) is a single native thread for every Ruby thread. Finally. Now Rails applications can run with much less memory consumption and better processor utilization. Will you miss all those extra Mongrel instances? Probably not.
- Thread safety. Important updates to the framework have been made to ensure thread safety. This will be a big boon to JRuby users (who have been dreaming of this for a long time), but C Ruby users will have to wait for certain dependencies to be updated before they can really enjoy its benefits (most notably those--ahem--with large amounts of C code). To enable mutli-threading, add
config/environments/production.rb. (Note, however that this will disable automatic loading by
ActiveSupport::Dependencies.) Plan on becoming more familiar with
- Internationalization. i18n has been baked into the framework, making localization of your application much easier.
- ActiveRecord now has a proper connection pool.
The release notes are here.
Rails 2.2 now requires RubyGems 1.3.1, so you'll want to make sure to update it (
gem update --system) first. To install the new version, do something like the following:
gem install rails rake rails:update
Arun Gupta from Sun also gives a nice overview of how to run Rails 2.2 on GlassFish v3 Prelude and JRuby 1.1.5.