Hacker News new | past | comments | ask | show | jobs | submit login
Rails 3.0: Release candidate 2 (rubyonrails.org)
110 points by sant0sk1 on Aug 24, 2010 | hide | past | favorite | 28 comments



"Very few changes" = 356 commits! :-) http://github.com/rails/rails/compare/v3.0.0_RC...v3.0.0_RC2

Still, RC1 has been rock solid for me. 3.0 is gearing up to be an amazing release, been using it for all my web projects since the first beta (feb).

If you're still stuck on Rails2, seriously consider upgrading. Your life will be much happier (once you go through the pain of course ;-)


Give me the pitch for going from working 2.x code to code which may fail in unforeseen ways and will certainly take a week of dev time to release. I am not being sarcastic, I just do not see the win of being on the bleeding edge here. The huge win I see in 3.0 is the security feature for untrusted string escaping, which will save me time and pain but is also available as a back port. I am unaware of any other huge wins.


My pitch: Improved speed and security all over the place, a saner mailing solution, lazy queries and first class support for rails engines. (A/B testing whole engines out kind of things are what I find exciting.)

Having said that, this version upgrade is half a paradigm shift. Living through it has cleared up a lot of mvc and good code concepts and ideas for me. I can think of numerous ways my 2.3 rails code could be better thanks to going through the transition. That alone is worth a couple of weeks of dev time, imho.


My pitch: If you plan to support your app for a long time, you will realistically have to upgrade to 3.x eventually. Better to do so at the same time as everyone else to benefit from the hivemind's concentrated power. Plus, given advances in SCM technology, branching should be easy, and you can abandon/return to your upgrade branch later if you have insurmountable problems.


To play the devil's advocate, maybe it's best to the let the pawn... er, early adapters, go first, find all the gotchas, blog about them, patch them, and then upgrade. ;)

Disclaimer - I'll happily be one of the pawns. :D


As a paw.. I mean, early adopter, I've been using Rails 3 for things-people-pay-me-for since beta3 and seen it really mature over the last few months.


Better yet, be a not /quite/ so early adopter. Move over once the hive mind has sorted all the problems, but when they're still fresh in their minds.

I certainly buy that you'll have to update sooner or later, but I'd rather do it on my terms.


Well you dont need to upgrade to support something, i have a rails 1 app around working without issues for years, though i plan to upgrade it ;)


> If you plan to support your app for a long time, you will realistically have to upgrade to 3.x eventually.

The keyword here is "eventually".

Wait for the next point release before upgrading.

Just like Windows.


In this case, the next point release will remove all of the deprecation warnings that you're given with this release. So, if you use 3.0 now, you'll have a nice checklist of things you need to fix before 3.1. If you jump right into 3.1, stuff will break.


Cleaner routing, AREL query generation, ActiveModel for better alternative orm support aren't big things?

Edit: big list of changes http://edgeguides.rubyonrails.org/3_0_release_notes.html


No disrespect intended to the programmers of these things: they solve problems I do not have by obsoleting functioning code that I do have.


If you don't like it then why are you on Rails? Rails has been defined by doing the right thing at the cost of stability since the beginning. If you want stability you should pick almost any other platform.

Claiming that Rails solves problems you "do not have" is blub thinking at its finest. Okay, I'll grant you that the routing changes are perhaps a little gratuitous. But consider the replacement of the ad-hoc manual SQL generation by arel. You will probably never even notice when this makes a query work that would have blown up before, or when your load times decrease because of lazy querying.

ActiveModel is another place where they've added huge power and flexibility. The fact that you no longer have to use ActiveRecord to get some of its best functionality is a huge win. Just because you haven't noticed how it might help you doesn't mean it won't if you give it a chance.

Even if you really don't need anything in Rails 3, it's still a straw man argument, because Rails 3 is all about modularization and embracing much wider development paradigms. If you want to use RSpec and FactoryGirl now you can do so with fully integrated generators. If ActiveRecord is useless to you, there is a well-defined API for any other ORM to integrate just as tightly. More importantly, the APIs that the components use are now public and documented, and will remain stable over time. This makes Rails useful for an order of magnitude more projects than it used to be.

Also, I should add that I'm in the same boat as you. I have a 50,000 line/200 model app dating back 3.5 years, and the Rails 3 upgrade is going to be painful. I put up with it though, because I much prefer a cutting edge platform to one where new thinking can never get a foothold.


His point may have been that he already has the code, so for the existing code it isn't really an advantage.


If he plans to continue development on that code, then upgrading will pay dividends. If not, keep running the old code. Who's holding a gun to his head? Should progress stop to support all the old untouched projects in the world?


I agree it depends on how much you think you're going to modify. In any case it might make sense to wait until all the bugs that aren't caught until widespread adoption have been fixed.


Is this not the same argument people used to keep using PHP?


What's wrong with that?

If you have a large working corpus of code in Blub, you absolutely shouldn't replace it just because a new version of Language on Locomotives comes out.

What you should do is exactly what patio11's doing here: evaluate if an upgrade brings you something that offsets the disruption the rewrite will cause.

For me, this also includes factoring in whether or not I'm going to be actively developing the application in the next year. If so, I do things like keep the framework versions current just so, nine months down the line, I'm using a framework version that I can still get docs and plugins for.


You're right. If the new features and speed updates of Rails3 don't matter to you, then it makes perfect sense to wait until you upgrade. Not knowing your situation, I can't really tell you what exactly the benefits will be of upgrading.


those are big things but patio11's question was whether it's worth a week of dev time for an existing project - is there value in spending all the time and energy for a project working well in rails 2.3.x?


If you put it that way, and you're certain that's how it is, then it sounds like you've got no good reason to upgrade your current apps. Future ones perhaps, but not current.


Why a week not a month or a year? Or half a day for that matter? Of course, everyone is free to stay on whatever version they are using till the time it is too big to fail, er… I mean to big to be refactored. I cannot escape "IE6" popping up in my head as I read this discussion.


Until you see an obvious reason to convince you to upgrade your code, don't. I'm starting a couple of longer-term Rails projects for clients right now, happily using 3.0. But I'll be waiting a while longer before upgrading my existing sites. Amid all the hype about 3.0 let's not forget 2.3 isn't half bad either.


If you'd like to see how much work it will be, there's always the rails-upgrade gem: http://rubygems.org/gems/rails-upgrade

Not that it's 100%, but it should pinpoint what you need to update. Lots of stuff is just deprecated, 3.1 will break it.


I know you're being facetious here, but I do think most of those commits are internal changes and not API changes. Things like removing unnecessary instantiations of variables, adding/removing deprecations, docs, and cleaning up tests.


Moments after the release, deployed http://rubygems.org/ on rc2. Didn't have any problems moving over from rc1 :)


Holt sh1t, "unless any blockers are discovered with this release, we’re targeting the final release of Rails 3.0 for this week(!!!)."

Here's hoping that'll be before the weekend and wish for a Heroku update of the Bamboo stack :-)


Personally, I don't think it will be that big of a deal to upgrade to Rails 3 from a 2.x app. They have done a good job of deprecating stuff, so Rails 3 should naturally lead to a leaner Rails 3.1. While it might not be a standard app-maintenance upgrade, I think it's worth it if you have decent code with some tests.

Also, not sure how it will compare to the 1.x => 2.x upgrade, but I was able to get a very complex application with horrible code and no tests upgraded from 1.x Rails to 2.x Rails. It only took me 3 or 4 days to get 90% of the app working. The rest was just stuff that I didn't find was broken. Since the app didn't have any integration tests, none of those features even got tested. I had to rely on traditional QA to find the errors, and this process took just under a month.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: