I am developping a web app on heroku. Most of requests on my server are database operations. How many concurrent requests can be treated by 1 web dyno + 1 Mongo HQ replicaSet ? How to increase this value ?
the number of open connections to the database (connection pools) are determined by your MongoDB driver and can usually be set manually when the client is initialized.
you should check with your database hosting service if they limit the number of open connections.
make sure to initialize the client once for each web dyno and not on every database request by mistake, so the connections pool will actually be used.
also, keep in mind that a dyno has 4 cores, so if you're running 4 processes with 'cluster', each one of those processes will have its own connections pool.