Closed OguzBey closed 1 year ago
Are you trying to connect locally, to a server? What happens when you log the connectionURI
?
Are you trying to connect locally, to a server? What happens when you log the
connectionURI
?Are you trying to connect locally, to a server? What happens when you log the
connectionURI
?
I do not trying to reconnect locally, just such errors appear on the screen, I do not understand how it came out yet. App running on production. If I could catch the error I would print some variables to the screen.
@vkarpov15 I saw that there was an issue similar to this that you handled so I'll defer this to you if I'm unable to resolve.
No logs in the connection error event are firing? Is this your first time attempting to connect to production or have you connected before?
No logs in the connection error event are firing? Is this your first time attempting to connect to production or have you connected before?
Yes, no connection error firing. If it happen, first error display then calling disconnect event and 'Mongoose Connection: Disconnected. Reconnection starts in 5 secs...' text prints. I don't think the connection is broken either.
After deploying in the production environment, mongoose must be updated. Maybe I can solve this problem by downgrading the version. I don't think I've seen such an error before.
package.json version -> "mongoose": "^5.11.8" package-lock 5.13.15
This issue is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 5 days
This issue was closed because it has been inactive for 19 days since being marked as stale.
Prerequisites
Mongoose version
5.13.15
Node.js version
16.5.0
MongoDB server version
4.4.0
Typescript version (if applicable)
No response
Description
I don't understand where this error occurs. Express app, nodejs cluster, Mongodb cluster
reconnection hook was not triggered either.
Steps to Reproduce
Expected Behavior
Does this error occur while query is running or does it happen by itself? Can someone explain?