DHH's Rails Keynote

dhh at rails

David Heinemeier Hansson (DHH) is the 37Signals partner who created Rails in 2004 while building Basecamp. He just gave the opening RailsConf keynote on the growth of Rails (a lot) and the new features of Rails 2.

Rails was extracted in 2004. Since then there have been

>1 million downloads of Rails gems

> 600 plugins (5 lines of ruby code); one of the best ways for people to contribute to rails; experimental

~10K members on the rubyonrails-talk Google group

1 job advertisement that is looking for 3 years of Ruby on Rails (longer than Rails has been around)

DHH talked about the new features in Rails 2. If you follow Rails, it is likely that this information is not new.

  • More formats – It is now incredibly simple to turn an HTML page into XML, plain text, a V-Card, ATOM, or RSS. Good.
  • REST is now native – A REST API is now built at the same time as your application. Active Webservice has been rolled into Active Resource so there are no separate Rails calls to generate an API. No more native SOAP, I guess you’ll need a plug-in for that. These two features have been shipped in 37Signals’ HIghrise (where one page can actually be called in 6 different formats). There are Ruby gems available today that you can use to get access to them (sorry I didn’t catch the name).
  • New Debug language – Breakpoints were broken in an earlier Ruby version. This was the impetus for a new debug language, ruby-debugger, to be created.
  • HTTP Performance Improvements – For development purposes it can make sense to keep your CSS and JavaScript files separate. However, the browser can only handle two connections to a host at a time. In Rails 2, all of your JavaScript and CSS will be turned into 1 file and gzipped for deployment; it stays seperate for development. Images are the other big perf hog. Rails 2 makes it easy to send images out from multiple hosts (it remembers the host for caching) which allows for more connections and increased performance.
  • Query Cache – Hitting your database can also slow down your app. Now “selects” will be cached until an insert, delete, or update statement is run.
  • HTTP Authentication – There will now be increased support for letting machines/bots/feedreaders authenticate via HTTP which machines can handle easily, but is too ugly and awkward for human users. Users will get a login box
  • Auto-MIT License – Rails and many of the plugins are open-sourced under the MIT license. From now on the plugin generator will auto-generate an MIT license for the file. You’ll still be able to change the license, but this will help to solve the problem of code being uploaded without a license.

DHH also shared some of his thoughts on what else will become core features. Just as AJAX and REST are now native, ATOM will become native. OpenID may become native. Less certainty here as not all apps need OpenID, but going forward Rails will be developed with OpenID in mind. Given the recent Twitter kerpuffle I had originally expected scaling to be addressed more specifically. I don’t think that there is a known solution yet to be discussed within the context of Rails 2. I think that is a problem that is yet to be solved and isn’t ready to be addressed in the core.

To read more on this keynote check out Justin Ball’s and Giles Blowkett’s blogs.

Even if you don’t follow care about Rails in particular, it is important to note these trends in web application frameworks. An API is assumed. AJAX is assumed. Feeds are assumed. Performance is recognized as an issue (when isn’t it). Identity is important, but as I think most feel about OpenID, they aren’t sure what to do with it just yet.