Answer the question
In order to leave comments, you need to log in
What is the correct way to efficiently connect to MongoDB in parallel?
const MongoClient = require("mongodb").MongoClient;
const url = "mongodb://localhost:27017/";
const mongoClient = new MongoClient(url);
Here is an example, we have created a mono client, can we use the same client in parallel to connect to the database, or do we need to re-create it every time?
Well, or how to send many requests more efficiently without overloading node js.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question