Scaling Rails web sockets in Kubernetes with AnyCable

24-Jun-2022 1418
One of the things I love the most about Rails is how easy it makes implementing many features with very little setup from my part. One example is ActionCable for web sockets. Before ActionCable, whenever I needed to build realtime features I had to resort to separate tools or perhaps a dedicated hosted service if scale was an issue (for example we have been using Sendbird for years at Brella).ActionCable made everything so much easier in terms of feature implementation, but with a catch: it really doesn't perform all that well with many concurrent clients. As soon as you start having a few thousands of clients active at the same time, latency goes beyond what is considered "realtime".
Use coupon code:

RUBYONRAILS

to get 30% discount on our bundle!
Prepare for your next tech interview with our comprehensive collection of programming interview guides. Covering JavaScript, Ruby on Rails, React, and Python, these highly-rated books offer thousands of essential questions and answers to boost your interview success. Buy our 'Ultimate Job Interview Preparation eBook Bundle' featuring 2200+ questions across multiple languages. Ultimate Job Interview Preparation eBook Bundle