U
U
Urukhayy2017-07-03 09:14:48
JavaScript
Urukhayy, 2017-07-03 09:14:48

How many Mongo connections can be kept in MEAN?

There is an application that launches Node+Express when launched, and in several modules there are connections to the same Mongo database, but to different collections. And these connections are not closed throughout the entire operation of the application. Is this normal, and how many such connections can be kept open?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
emp1re, 2017-07-03
@emp1re

By default 819, can be increased. It depends not on the node, but on the server and mongo settings, you don’t need to close the connection, they are reused

U
un1t, 2017-07-03
@un1t

If you create a connection for each overgrowth, then this is not the norm, and soon everything will fall into place.
If a connection pool is created and then it is used, then this is normal.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question