Open
Description
await mongoose.connect(process.env.MONGO_URL, {
useNewUrlParser: true,
useUnifiedTopology: true,
serverSelectionTimeoutMS: 15000,
socketTimeoutMS: 45000,
});
This is how the code looks,
I am currently using a paid cluster in Atlas. I have monitored the RAM and CPU usage while this happens. The RAM and CPU are perfectly normal, but the data READ/WRITE process becomes slower, and the following event is triggered multiple times before this
mongoose.connection.on('disconnected', async () => {
console.log('MongoDB disconnected, attempting to reconnect...');
});
I am using node js with express
{
"mongoose": "^7.8.6",
"express": "^4.19.2",
}
the node version on the local system is v22.3.0
Metadata
Metadata
Assignees
Labels
No labels