-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mongo Db Atlas data READ/WRITE becomes slower after 3 or 4 hours #15278
Comments
Without a repro script, there's no way we can reasonably repro this or make any informed recommendations. |
Here` is the index file for the node server There are 3 watch functions and a total of 16 collections The problem is that whenever I start or restart my server, the total number of connections is around 85. After some time, it rises to 160-180. However, after 4 to 5 hours of inactivity, the number of connections remains at 160-180, and any requests made afterward take longer to respond.
|
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
The text was updated successfully, but these errors were encountered: