Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Load Balancing with Node and Heroku

I have a web app that accepts api requests from an ios app. My web app is hosted on Heroku using their free dyno which is able to process 512 mb of data per request. Because node is a single threaded application this will be a problem once we start getting higher levels of traffic from the ios end to the web server. I'm also not the richest person in the world so i'm wondering if it would be smart to create another free heroku app and use a round robin approach to balance the load received from the ios app?

I just need to be pointed into the right direction. Vertical scaling is not really an option financially.

like image 700
brian Scroggins Avatar asked Sep 03 '25 02:09

brian Scroggins


1 Answers

I'm the Node.js platform owner at Heroku.

You may be doing some premature optimization. Node.js, on our smallest 1X size (512MB RAM), can handle hundreds of simultaneous connections and thousands of requests per minute.

If your iOS app is consistently maxing that out, it may be time to consider monetization!

like image 63
hunterloftis Avatar answered Sep 04 '25 17:09

hunterloftis