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
Model.deleteMany does not respect writeConcern settings in options #13592
Comments
@vkarpov15 |
MongooseServerSelectionError: Could not connect to any servers in your MongoDB Atlas cluster. One common reason is that you're trying to access the database from an IP that isn't whitelisted. Make sure your current IP address is on your Atlas cluster's IP whitelist |
@IslandRhythms this is not related to the reported issue. Edit: I have open public access to my test database, please check again. |
fix: prevent overwriting user defined writeConcern
Prerequisites
Mongoose version
7.0.3
Node.js version
18.16.0
MongoDB version
5.2.0
Operating system
macOS
Operating system version (i.e. 20.04, 11.3, 10)
No response
Issue
I have a LogModel defined using
the write concern here is to speedup the log write requests.
Now I would like to remove the logs inside a transaction with other models, and the error is:
Cannot have explicit session with unacknowledged writes
I tried supply explicit write concern into the deleteMany query to override the setting in model, but same error occurs.
so I think the deleteMany is not respecting the overriding options.
The text was updated successfully, but these errors were encountered: