'How does MongoClient.connect work under the hood?

Does it work like pg pool.connect (returns spare connection, or creates a new one)? What happens if I call it many times? Like thousands (for every job in queue); How to handle this task properly?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source