-
Type: Question
-
Resolution: Gone away
-
Priority: Major - P3
-
None
-
Affects Version/s: 4.9.0
-
Component/s: Query Operations
-
None
-
Java Drivers
Summary
In Java, the mongodb-driver-sync jar, findOneAndUpdate method doesn't return the updated document after executing the update query, when we set FindOneAndUpdateOptions with ReturnDocument.AFTER
Please find the details below:
- version of the driver - mongodb-driver-sync version 4.9.0
- MongoDB server version - 6
- topology - replica set.
How to Reproduce
- Please run the MongoDB 6 server in replica set mode.
- use jar mongodb-driver-sync version 4.9.0 as dependencies in your java project.
- Write java code to execute update query using findOneAndUpdate method with FindOneAndUpdateOptions - ReturnDocument.AFTER
Thanks.