Andrei Alecu
Andrei Alecu
Output of script: ``` .... 1223/10000 1224/10000 Timeout after 1224/10000 ``` If mongoose is bypassed and the other code that is commented out is swapped in, the issue doesn't seem...
It seems that if you make the schema bigger/more bloated with additional fields, even if they are **not** populated, the issue occurs earlier after about 400 iterations. But this could...
> I have been fighting this issue have have not been able to go above version 8.2.2 Thank you for this! I've tried running my repro on several mongoose versions,...
Update: I used yarn resolutions to pin `mongodb` to `6.3.0` and it appears that the problem no longer reproduces with my test script. Indeed this may be an upstream issue...
It appears that the problem started with `mongodb` `6.4.0` - I've been trying various resolutions. `6.3.0` works, `6.4.0` exhibits the problem.
This may be the same issue as: https://jira.mongodb.org/projects/NODE/issues/NODE-6370 https://jira.mongodb.org/browse/NODE-6166
I can confirm that we resolved our issue with the workaround of pinning `mongodb` to `6.3.0` using yarn resolutions. This is not a mongoose issue. mongoose `8.5.1` with mongodb `6.3.0`...
Seems it might be a good idea to have mongoose define a peer dependency to mongodb instead of a direct dependency. In this case the version of the driver would...
That would probably work, but I think making mongodb a peer dependency might still be a good idea. Or a peer dependency with a default. See: https://github.com/yarnpkg/berry/issues/3710#issuecomment-963732582
You can probably get it to repro if you use upsert and update the same document repeatedly. I haven't tried optimizing the repro. I noticed it happens easier with bigger...