How can I test how many connections/active users does a Heroku dyno support for my app?

StackOverflow https://stackoverflow.com/questions/23204720

  •  07-07-2023
  •  | 
  •  

Domanda

Is there a tool or a way to learn how many connections can manage my Heroku app simultaneously (with one dyno) before giving slow response times or time outs? I read of Blitz and New Relic but I am unsure of how to use them!

È stato utile?

Soluzione

There's no quick and easy way to understand how your app scales. But the process usually goes along these lines:

  1. Launch your target environment (a single dyno in your case)
  2. Set up monitoring on all the possible metrics you care about. Usually this will include: CPU load, memory usage, I/O operations, database connections, etc. as well as any relevant applicative metrics. For Heroku, I recommend using Librato for a complete monitoring set.
  3. Run load tests that resemble typical usages of your application, this means not just simple reads of static pages, but also dynamic operations such as user registrations, complex API calls, and anything else you think is relevant. The tools used here really depend on what your app does and how it is built.
  4. See where you hit your limits, assume nothing, you might be bound by any of the resources you are using.
  5. Resolve bottlenecks, rinse, repeat.

This will give your more or less a clue as to where your application will require further resources in order to scale.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top