Upgrading a big application to Rails 5
summary
Shopify upgrades a 13‑year monolith with >100,000 model lines and ~2,000 classes to Rails 5 using a dual booting strategy: a shared Gemfile hack then an eval_gemfile approach, a parallel CI running Rails 4.2 and 5, and a gradual rollout with small percentages before a 100% deploy. The work yields ~150 pull requests in three months to remove protected_attributes, thousands of fixed tests, monkey patches for CSRF and YAML params, and a plan to keep CI tracking Rails master.
AI-written summary · about
chapters (26)
- 0:00Intro
- 0:13Upgrade a big application to Rails 5
- 1:01RAILS Maintainer
- 1:25Started around the same time as Rails
- 3:40It is a big application
- 4:37It is in the latest Rails version
- 4:50Upgrading to Rails 5
- 5:55Dual boot strategy
- 9:34Upgrade our dependencies
- 10:09Contribute to the dependencies that don't support the latest Rails version
- 11:24Fix all the tests
- 15:43Strong Parameters
- 16:48Missing abstractions?
- 17:14Controller Tests
- 21:38Not an ideal solution
- 23:02Road to production
- 23:45Compatibilities Layers
- 26:10Benchmarks
- 27:23Cleanup
- 27:40Remove deprecations
- 28:31Upgrade configurations to match new values
- 28:46Preparation to the next upgrade
- 29:07Avoid monkey patches
- 29:40Keep tracking master
- 30:08Think about backwards compatibility
- 30:18Give back to the community
related talks
22mRiding Rails for decades
36mRuby & Rails Versioning at Scale
21mRails Upgrade Mastery: Best Practices for Large-Scale Enterprise Applications
36mRuby & Rails Versioning at Scale
38mThe Past, Present, and Future of Rails at GitHub
40mThe Past, Present, and Future of Rails at GitHub
38mThe Past, Present and Future of Rails at GitHub
29mUpgrading Rails at Scale
