The Envato marketplace sites recently upgraded from Rails 2.3 to Rails 3.2. We
did this incrementally at full production scale, while handling 8000 requests
per minute, with no outages or problems. The techniques we’ve developed
even let us seamlessly and safely experiment with mixing Rails 4 servers into
our production stack in the near future.
We wanted to be able to confidently make the huge version jump without having
to do an all-or-nothing cutover. In order to achieve this we made a number of
modifications that allowed us to run Rails 3.2 servers side-by-side on our load
balancer with all of our 2.3 servers. This let us build confidence in our
upgrade to the new version gradually with far lower risk of our users receiving
a bad experience.
We’ve released the patches we used as a gem
magically lets Rails 2, 3, and 4 servers live happily side by side.
If you are still stuck back on a Rails 2.3 app, this should help kick start your
upgrade progress to Rails 3 (and beyond to 4 if you’re ready).
This post will go into the technical details around making this upgrade as
smooth as it was.