Why do we migrate? Due to a change in licensing, we cannot provide Elasticsearch versions >= 8.0. Version 7.17.x will...
Debugging performance issues in your Rails app can be a tough challenge. To get more detailed insights consider using the...
10.0.0 2024-03-07 Compatible changes console command: You can now globally disable the IRB multiline feature by setting irb...
Today I stumbled across a pretty harmless-looking query in our application which turned out to be pretty harmful and...
A Rails script lives in lib/scripts and is run with bin/rails runner lib/scripts/.... They are a simple tool to perform...
A general overview about why and how we migrate can be found under Migrating from Elasticsearch to Opensearch
In Capistrano 3, your Capfile requires 'capistrano/rails/migrations', which brings two Capistrano tasks: deploy:migrate and deploy:migrating. The former checks...
#pluck is commonly used as a performant way to retain single database values from an ActiveRecord::Relation Book.pluck(:title, :price...
If you ever need to restore exact records from one database to another, Marshal might come in handy. Marshal.dump is...
While upgrading CarrierWave from version 0.11.x to 3.x, we encountered some very nasty fails. Below are the basic...
TLDR Using .includes or .eager_load with 1-n associations is dangerous. Always use .preload instead. Consider the following ActiveRecord...
Given you have an array column like this: create_table "users", force: :cascade do |t| t.integer "movie_ids", default: [], array...
It's not possible to change the bwlimit of Proxmox storages via the Web-UI (at least in Proxmox 7...
We regularly have tasks that need to be performed around a deploy. Be it to notify operations about changed application...
Do you remember finding where a method is defined? I recently learned from a senior colleague that Method objects are...
You don't want sensitive user data in your logs. Background Rails per default filters sensitive data like...
Looking at the source code of the validates_numericality_of validator, it becomes clear that it converts the attribute in...
When you allow file uploads in your app, a user might upload content that hurts other users. Our primary concern...
In Ruby on Rails ActiveRecord::Relation#merge overwrites existing conditions on the same column. This may cause the relation to...
Usually you add errors to :base in ActiveRecord, in case no appropriate attribute could be used to add the error...
Let's say we have posts with an attribute title that is mandatory. Our example feature request is to tag...
By default most exceptions in Rails will render a 500 error page and will create a new issue in your...
Rails Active Support provides some helpful methods for calculating times and dates, like Duration#ago or Duration#from...
By activating strict_loading you force developers to address n+1 queries by preloading all associations used in the index...