Archives par mot-clef : rails

RoomRoom (ex. Troc de Chambre) ; le dernier né

Je vais faire comme chez moi et je ne vais pas me gêner pour vous parler un peu du dernier projet sorti de chez Autrement, la boîte où je bosse depuis plusieurs années : RoomRoom, où comment revendre sa chambre … Lire la suite

Publié dans Autrement, Informatique, Uncategorized | Tagué , | 4 commentaires

How to use a different ActiveRecord connection pool between Unicorn and Sidekiq?

I work on a Rails (4.1) application, sitting behind Unicorn and backed by a couple of Sidekiq processes. A quick reminder : Unicorn is an application server (for Rack-compatible Ruby applications) based on the multi-process master-workers model, and Sidekiq is … Lire la suite

Publié dans Informatique | Tagué , , , | 1 commentaire

API Versioning in Rails with Accept HTTP headers

To implement API versioning in Rails, not using URL namespaces but custom MIME types, there are a few different approches. The Tribesports way Recently, I’ve seen a blog post about the Tribesports API. They chose to add a new MIME … Lire la suite

Publié dans Informatique | Tagué , , , , | 4 commentaires

You have modified your Gemfile in development

Twice this week I’ve had a problem with Bundler (1.0.10). During a deploy with Capistrano, I had some errors like this : I’ve searched in Google for this kind of errors, and everything I’ve found was dealing with .bundle directories, … Lire la suite

Publié dans Informatique | Tagué , , , | Laisser un commentaire

RVM, Passenger and symlinks

Here is some kind of follow up after my previous lengthy description on how we use RVM, Passenger and Rails at work. One of my co-workers has updated RVM this morning (to get the brand new 1.0.0) and all his … Lire la suite

Publié dans Informatique | Tagué , , , | Laisser un commentaire

You are using the old router DSL !

In some Rails 3 application, I get a somewhat cryptic message in my development log file : DEPRECATION WARNING: You are using the old router DSL which will be removed in Rails 3.1. Please check how to update your routes … Lire la suite

Publié dans Informatique | Tagué | 1 commentaire

Rails 3 lazy-loading and the console

While debugging an Rails 3 application in development, I started to wonder if the lazy-loading feature of ActiveRecord 3 was really working. In a model, I was building a query depending on some parameters. Something like this (obviously simplified) : … Lire la suite

Publié dans Informatique | Tagué , , | Laisser un commentaire