"This era' true revolution in web development"

Phu Ly is a software developer working out of London that seems to quite fancy the Rails:

Ruby on Rails has to be the one of the real breakthroughs in Web Development and indeed, development itself…

This is no hyperbole. Far more so than Ajax, this is this era’s true revolution in web development. The majesty of the framework is sufficient for me to make a long term commitment to Ruby; In fact, calling RoR a Ruby framework understates things; it’s probably the killer app for Ruby itself.

Thanks, Phu.

Kwartz 2.0 brings more templating choice to Rails

Kwartz is a templating system for Ruby built on the concept of Independence of Presentation Logic, which bans loops, conditions, and similar constructs from the template files themselves. Instead that logic is added in a second pass based on ids in the original template.

With the latest 2.0 release, Kwartz is now available as a templating option for Rails. Makoto Kuwata used the hooks created by Jamis Buck to follow the conventions of instance-to-template variables and even allowed the use of helpers.

Another familiar template language for Ruby, Amrita, is also on the way with Rails integration. Rails will still only ship with ERb and Builder for the default options, but Kwartz and soon Amrita are getting very easy to inject as an alternative. Great work, guys!

Got design chops? lighttpd needs them!

A star is rising as an alternative, lighter-weight web server that doesn’t start with an A and ends with ‘pache. It’s called lighttpd and they actually maintain their FastCGI bindings, which makes them a promising future heir to the crown of Rails Favorite Application Server. But while Jan and friends work on the code, they need your design chops to make them look good doing so.

In short, they need a logo. And who better to ask than the design-savvy Rails community? Our thoughts exactly. So here comes the plea: If you got the skills, please make an entry in the logo competition for lighttpd.

Rails job in Columbus, Ohio

Just spotted this mighty brief posting for a Rails position in Columbus, Ohio on craigslist and thought I’d pass it along. It’s never been a better time to jump on something fresh and expect to actually find work doing it. We have a wide array of independent consultants working exclusively in Rails already and more are joining all the time. Be part of it.

5th Rails book announced (2nd from O'Reilly)

Robby Russell has announced his authorship of an upcoming book that’ll provide “… an in-depth look at RoR, how it works inside and out”. The book is to be published by O’Reilly. This will then be their second Rails book (they’re already doing a Developer’s Notebook) and the fifth book in total announced for Rails. What awesome news!

Hopefully we can get a nice mesh of complimentary books out of all these announcements. We’ll want the imminent sea of uptake to acquire the entire shelve of Rails book at the book store. Not worry about choosing.

Rails 0.12.1: No major update without a bit of pain

There’s nothing like pushing a new major update in order to find bugs in the code when its exposed to a couple of hundred working applications. Thankfully the fixes were almost as swift as the reports. In any case, you’ll definitely want to upgrade to 0.12.1 right away. There’s a good handful of fixes for both Action Pack and Active Record (mostly concerning the new eager loading).

Here’s the dirt, so you don’t have to go look it up. First for Action Pack:

  • Added xml_http_request/xhr method for simulating XMLHttpRequest in functional tests #1151 [Sam Stephenson]. Example: xhr :post, :index
  • Fixed that Ajax.Base.options.asynchronous wasn’t being respected in Ajax.Request (thanks Jon Casey)
  • Fixed that :get, :post, and the others should take a flash array as the third argument just like process #1144 [rails@cogentdude.com]
  • Fixed a problem with Flash.now
  • Fixed stringification on all assigned hashes. The sacrifice is that assigns[:person] won’t work in testing. Instead assigns[“person”] or assigns(:person) must be used. In other words, the keys of assigns stay strings but we’ve added a method-based accessor to appease the need for symbols.
  • Fixed that rendering a template would require a connection to the database #1146

Then for Active Record:

  • Fixed frivilous database queries being triggered with eager loading on empty associations and other things
  • Fixed order of loading in eager associations
  • Fixed stray comma when using eager loading and ordering together from has_many associations #1143

Updating, as always, couldn’t be easier than gem install rails --include-dependencies.

Rails 0.12.0: Eager associations, new Base.find API, assertions revisited, more Ajax!

The time had come to butcher the piggy-back query and introduce real association loading through outer joins. Behold, the glorious eager loading of associations that makes it silly easy to fetch not 1, 2, but unlimited associations alongside any record in a single query. Turning 50 database queries into 1 never felt this good.

# Turning N+1 queries into 1
for post in Post.find(:all, :include => [ :author, :comments ])
  puts "Post:            " + post.title
  puts "Written by:      " + post.author.name
  puts "Last comment on: " + post.comments.first.created_on

And to match the eager loading, we’re introducing a brand new unified API for Base.find, which works the same whether you’re searching for a specific id, the first record, or all the records. By using named options we alleviate your poor brain for remembering whether the ordering option was argument number 3 or 4.

Person.find(1, :conditions =>"administrator = 1", :order =>"created_on DESC")
Person.find(1, 5, 6, :conditions =>"administrator = 1", :order =>"created_on DESC")
Person.find(:first, :order =>"created_on DESC", :offset => 5)
Person.find(:all, :conditions => [ "category IN (?)", categories], :limit => 50)
Person.find(:all, :offset => 10, :limit => 10)

Better testing
We’ve also slashed the huge number of assertions for testing controllers. In one fell swoop, we’ve gone from around thirty to a shap seven. The remaining assertions are more flexible than before, not nearly as hard to remember, and are followed on by the fantastic new assert_tag, which makes examining the HTML output of an action so much easier than the XHTML/REXML fumblings of yesterday.

More Ajaxing
Of course, we couldn’t make a new release without asserting the undisputed position as the number one framework for doing Ajaxed applications. This release contains a bunch of new smooth effects for visualizing your non-refreshing actions. It’s now much easier to make Ajaxed applications that treat the unfortunate without Javascript nicely with request.xml_http_request? and alternative targets for ajax links and forms. We’ve also added periodically_call_remote that can be used to Ajax-update a given block every so seconds.

In the next release, which will be not very far off, we’re also adding awesome support for both Google Suggest-like search boxes and for upload progress indicators. There’s a powerful team behind pushing the envelope on this. We have so not seen the end of it.

A total of 96 changes, tweaks, and fixes
All these goodies are just the tip of the iceberg, though. There’s a total of 96 new features, changes, tweaks, and fixes packed into this monster of a release. And we didn’t even have time to push in all of the pending patches. How’s that for an action-packed three weeks since the last release?

Fully backwards compatible!
Despite the true onslaught of new features, fixes, and goodies, we’ve managed to keep this release fully backwards compatible with 0.11.1. So you just do a “gem update rails” and all the new stuff is available for use in your current application (to take advantage of the new JS effects you’ll want to copy that one over, though — use rails . in your app dir to get that for free).

See the changelogs for the full story:

Rails Day: Make an application in 24 hours and win!

Since Rails is supposedly this über-productive bag of lightning bolts, you should be able to accomplish great things within a single clip of 24 hours, right? That’s the assumption Rails Day is setting out to prove. A competition to build something meaningful, cool, neat, and/or beautiful that’ll be judged by a panel of experts including yours truly and Dave Thomas.

There’s even a great give-away happening. The best applications can win an Apple Mac Mini (courtesy of the ever-fantastic TextDrive— are you signed up yet?), an iPod Mini from the crew at Odeo, 6 books from the Pragmatic Bookshelf, lifetime Basecamp basic subscription, and more. It’s a true shower of gifts.

The whole shebang is going down on June 4th. Read more at Railsday.com.

Portland Rails presentation draws full house

Lucas Carlson talks about how Portland is turning into a power zone for Rails development and how great his presentation there went last night:

Last night I gave a presentation about Rails to what was supposed to be the local Perl mongers and Ruby group. Usually, between 6-10 people show up to either meeting, so I was expecting 20-25 people. But Rails pulled people out of the cracks and the turnout was around 50 people.

Overall, the crowd seemed very happy and excited, many oooos and ahhhhs. A lot of people emailed me afterwards saying that they were planning on starting their first Rails sites.

You should get involved with your local Java, Perl, Python, or PHP user groups too. Let the rhetoric take a back seat for a little while and show your fellow programmers what it is we have here in Ruby on Rails land. No reason hoggin all the tool toys for yourself. Sharing is so much more fun.

RForum 0.1 sees the light of day

RForum is one of the earliest open source applications based on Rails, but it has only just reached a state where the authors Andreas Schwarz and Alexey Verkhovsky were willing to share with the world. Hence, the release of RForum 0.1.

Congratulations on the release. With the project out in the open, we’ll hopefully more rapid improvement towards a 1.0 release.