Migrate a large existing app from Rails 3 to Rails 5. Would you do it?

It'll take a lot of time, especially if you don't have a good test suite. (And even if you do...).

But the other option is basically to decide that the existing platform is legacy. And start planning to rebuild it.

Which is the better idea is largely a business decision - staffing would be a key consideration for instance - if you have a lot of on-hand rails experience and people familiar with the old code base then that's some points towards an upgrade.

I'm doing an upgrade from 4.2 -> 5 for a large complex codebase that's passed hands through multiple teams. Nowhere near as bad as going from 3, but the original 3 -> 4 upgrade was done pretty lazily. It's a big job, and it's hard to do quickly.

We tackled it by making a long-running staging instance running the upgrade, and trying to QA all the new work on the main site via that upgraded instance. (As well as checking it works on the production 4.2 of course). This means that while we were testing all the new functionality we were also testing the upgrade.

That, plus the - in our case super painful - fixing of all the tests, has got us pretty confident about the release - QA folks have been regularly using the upgrade branch for a month or two now, and we've been chipping away at issues over that time while still working on the main platform. (We've been lucky that almost all the new work has merged into both master and upgrade pretty painlessly).

/r/rails Thread