When upgrading a Rails application, you might find that sometimes functionality is extracted from Rails and moved into a new gem. These gems are called shims, and they will basically allow you to keep using an old functionality, once the core API takes that out.
You can also find shims in form of monkey patches. In this case it's functionality that you develop to make your migration easier.
In this article I will list some of the functionality of past versions of Rails that was extracted into gems.
Having a clear idea of how much test coverage your Rails application has is really important. Especially if you are planning to upgrade to a newer version of Rails. A good test suite will tell you if your application is working as it did before the upgrade.
At FastRuby.io, we recommend having at least 80% of your application covered before attempting to upgrade. A number lower than that would require you to make a lot more manual testing to ensure that the application is properly working after the upgrade. If your application doesn't meet that number, we suggest to first spend some time improving the test suite before starting the upgrade.
In this article, I'll show you how you can measure your test coverage using SimpleCov.
A quick note before starting: SimpleCov doesn't work in projects with Ruby
1.8.7 or lower. If that's your case, you can try rcov.
Rails upgrades can be done in many different ways. Depending on the application that you want to upgrade, some ways make more sense than others. There are factors that determine which Rails upgrade strategy is the best for your case, like how big your application is, or how frequently changes are pushed to the master branch. In this article I'll be covering two common Rails Upgrade strategies so you can decide which one is the best for your application.
Deprecation warnings are a common thing in our industry. They are warnings that notify us that a specific feature (e.g. a method) will be removed soon (usually in the next minor or major version) and should be replaced with something else.
Features are deprecated rather than immediately removed, in order to provide backward compatibility (a solution that works in both the current and the future version), and to give programmers time to implement the code in a way that follows the new standard.
In this guide we'll show you what the workflow is that we use at FastRuby.io to address deprecation warnings when we upgrade Rails applications.
Protected Attributes to
Strong Parameters in a Rails project can be a huge step of the upgrade process. Especially when we are upgrading a large application. This guide is meant to help you tackle that step faster and with a lot less pain.
Here we continue with the series of articles where we talk about how minor adjustments in the code can lead to major performance improvements.
In this article we'll focus on the use of ActiveRecord::Batches#find_each when it comes to iterations across a large number of records.
This article is part of our Upgrade Rails series. To see more of them, click here.
This article will cover the most important aspects that you need to know to get
your Ruby on Rails application from version 5.2 to 6.0.
Next week the Rails community is having the biggest event of the year, the Rails Conf 2019. We participated in previous editions of this conference but this time we have the honor to be on the speakers side of it. We'll be teaching you what we're best at: Rails Upgrades.
Some time ago we wrote a couple of Tips for Writing Fast Rails. It was about time we wrote part two so here it is!
This is part of our Upgrade Rails series. We will be covering the most important aspects that you need to know to update your Ruby on Rails application from version 3.1 to 3.2.
This is part of our Upgrade Rails series. We will be covering the most important aspects that you need to know to update your Ruby on Rails application from version 3.0 to 3.1. If you are in an older version, you can take a look at our previous article.
This article is the first of our Upgrade Rails series. We will be covering the most important aspects that you need to know to update your Ruby on Rails application from version 2.3 to 3.0.