Track performances and errors for requests and background jobs.
https://www.rorvswild.com
In the happy world of #Ruby, we don’t #RTFM, we #RTNM
New documentation website for Ruby, Rails, and a bunch of selected gems:
rubyrubyrubyruby.dev
Short intro post:
www.rorvswild.com/blog/2025/re...
Contribute:
github.com/BaseSecrete/...
Wdyt?
In the happy world of #Ruby, we don’t #RTFM, we #RTNM
New documentation website for Ruby, Rails, and a bunch of selected gems:
rubyrubyrubyruby.dev
Short intro post:
www.rorvswild.com/blog/2025/re...
Contribute:
github.com/BaseSecrete/...
Wdyt?
1. Set minimum code coverage with current value 📏
2. You're not allowed to decrease it ⛔️
3. Every week check the value and increase the minimum accordingly 🔄
4. Code coverage will slowly but magically increase ⬆️
1. Set minimum code coverage with current value 📏
2. You're not allowed to decrease it ⛔️
3. Every week check the value and increase the minimum accordingly 🔄
4. Code coverage will slowly but magically increase ⬆️
Because a SQL query is triggered on each call. Memoizing the result is not necessarily better since it won't be uncached when reload is called. Instead, switch that method to a relation.
Because a SQL query is triggered on each call. Memoizing the result is not necessarily better since it won't be uncached when reload is called. Instead, switch that method to a relation.
It works fine with a few thousand. But that would probably eat too much memory if you're loading a lot of ActiveRecord instances. The trick is to load IDs only if you do not need to access any attributes or methods.
It works fine with a few thousand. But that would probably eat too much memory if you're loading a lot of ActiveRecord instances. The trick is to load IDs only if you do not need to access any attributes or methods.
Enqueuing via ActiveJob::Base#perform_later triggers callbacks and generates one round-trip for each job. Bulk enqueuing skips callbacks and enqueues all jobs in one step.
Enqueuing via ActiveJob::Base#perform_later triggers callbacks and generates one round-trip for each job. Bulk enqueuing skips callbacks and enqueues all jobs in one step.
Pipelining sends a bunch of commands without waiting for each individually. Instead of having N round-trips, there is only one, thus code is less idle. Of course, that's not possible when you need the result of the previous command for the next one.
Pipelining sends a bunch of commands without waiting for each individually. Instead of having N round-trips, there is only one, thus code is less idle. Of course, that's not possible when you need the result of the previous command for the next one.
ActiveRecord's method insert_all is fast but limited when dealing with associations. Fortunately the gem activerecord-import has come to the rescue. It triggers a single query per table to avoid round-trips with the database.
ActiveRecord's method insert_all is fast but limited when dealing with associations. Fortunately the gem activerecord-import has come to the rescue. It triggers a single query per table to avoid round-trips with the database.