Benchmarking

I have a node.js backend that supports API endpoints. I can use wrkHTTP GET, POST, PUT to compare requests. I can also use the module pm2to track CPU and memory usage.

But how do I emulate multiple login sessions? I want to compare the memory tests of the logging sessions and find out with 1 GB of memory how many users can establish logon sessions with the server. (I assume that when I see 100% memory usage pm2and high latency from wrk, and that the maximum number of session connections can be on my server) And am I on the right track?

ps: I used passport.jsto handle logins.

+4
source share
1 answer

What you are trying to do is usually called "Load Testing".

There are many tools that simulate many simultaneous users and stress tests of your site, such as Tsung, ApacheBench, JMeter, etc.

Here is a tutorial on setting up JMeter so you can download the test login page: https://www.youtube.com/watch?v=hGkrSFKcj10

, JMeter , (.. HTTP- POST), , pm2 , , .

+4

Source: https://habr.com/ru/post/1612391/


All Articles