M
M
m5xim2016-08-06 13:42:22
Node.js
m5xim, 2016-08-06 13:42:22

Processes or threads?

A highly loaded server is being designed, Node js is single-threaded, how the processor, resources will be used optimally when creating x threads, by the number of cores listening to different websocket ports in one application or instead of threads by creating x applications and running them using some kind of process dispatcher (pm2,forever)? Passing data between threads/processes is not needed.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
komarevtsev, 2016-08-06
@m5xim

Через cluster меньше оперативной памяти займет, так как родительский процесс всего один. И так лучше масштабируемость

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question