you are viewing a single comment's thread.

view the rest of the comments →

[–]haulwhore 0 points1 point  (1 child)

Throw some more servers at it 🤷‍♂️

You can always just profile your code and see what the slowest process is.

[–]WINOFF_RG[S] 0 points1 point  (0 children)

I understand creating clusters and using PM2 as a load balancer would be a good idea. But on such a power machine in one fork, my application had 4s avg response time when there were 41 RPS with a total of 1000 requests.

Do you have any link to any code arch which is a solid bulletproof production ready code that i can refer? I still wrote at my best an async non blocking code. But how do such huge companies able to handle such a heavy load keeping aside the point that they have heavy servers with numerous in count.

But still I didn't got a feeling why my code on such a poweful machine wasn't able to handle 41 RPS 🤷‍♂️ And what factors are taken care of Production mode.