What is Ruby doing on Rails?
Hello, you're reading Infinum Ruby Drops, bringing you the latest Ruby and Rails related news straight to your inbox every week.
Infinum Academy
Infinum Academy is a free 5-week summer programming course for students. Choose one of the 5 courses, learn from Infinum and Porsche Digital Croatia's best developers and get a chance to build your very own app.

Apply by May 31!

Infinum Academy is intended for Croatian students and will be held in Croatian.
Read More
Rails
Dockerizing helps ease the pain of dependencies Getting a new developer set up with a Rails app (or any app) can be tedious. Part of the tedium is the chore of manually installing all the dependencies: Ruby, RVM, Rails, PostgreSQL, Redis, etc.
Some people, when faced with an API problem, think “I’ll use GraphQL!” And now they have N+1 problems.
It's 2021 and you need to build an XML API. Yes, JSON would be preferred by most developers, but sometimes you need to offer both. What are your options?
Ruby
RSpec examples should have enough detail in the descriptions to rewrite them from scratch.

Things usually work until they don't. In this blog post, I'll describe a simple way to monitor the uptime and responsiveness of Sidekiq processes in Rails apps.
To save memory and improve performance, Ruby 3.1 added Array#intersect? method which returns true if two arrays have at least one element in common, otherwise returns false.
Blast from the past
One conversation I continue to enjoy is about responsibility. The conversation really boils down to one question.

Should it really be the responsibility of X to do Y?
This is the story of how we changed our data storage architecture from the active-active clusters over to Vitess — a horizontal scaling system for MySQL. Vitess is the present and future of Datastores for Slack and continues to be a major success story for us.
Beyond Ruby
We take a look at whats new in Postgres 14, with idle and active connection scaling, memory monitoring, query IDs and more.
API gateways are an integral part of microservices architecture in recent years. In this article, we will take a deeper dive into the technical components of a self-serve API gateway system.
Repository of the week
Before: 7362.54 req/sec
After: 24432.62 req/sec (3.3x faster)