[JAVA-4419] Error labels are not added to MongoWriteConcernException Created: 01/Dec/21  Updated: 28/Oct/23  Resolved: 02/Dec/21

Status: Closed
Project: Java Driver
Component/s: Command Operations
Affects Version/s: None
Fix Version/s: 4.4.1

Type: Bug Priority: Major - P3
Reporter: Jeffrey Yemin Assignee: Jeffrey Yemin
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Documentation Changes: Not Needed

 Description   

The error labels are at the top level of the response document, and the driver is assuming that they are embedded in the writeConcernError document. The fix is to ensure that error labels at the top level are properly added to MongoWriteConcernException.

Currently the code for this is not consolidated, but to avoid API changes in MongoWriteConcernException we won't centralize it there as part of this change.



 Comments   
Comment by Githook User [ 02/Dec/21 ]

Author:

{'name': 'Jeff Yemin', 'email': 'jeff.yemin@mongodb.com', 'username': 'jyemin'}

Message: Add error labels to MongoWriteConcernException (#834)

The error labels are at the top level of the response
document, and the code was assuming that they were
embedded in the writeConcernError document. This fix
ensures that error labels at the top level are properly
added to MongoWriteConcernException

JAVA-4419
Branch: 4.4.x
https://github.com/mongodb/mongo-java-driver/commit/27c5812284705f639bc275111e56e9315b6ee909

Comment by Githook User [ 02/Dec/21 ]

Author:

{'name': 'Jeff Yemin', 'email': 'jeff.yemin@mongodb.com', 'username': 'jyemin'}

Message: Add error labels to MongoWriteConcernException (#834)

The error labels are at the top level of the response
document, and the code was assuming that they were
embedded in the writeConcernError document. This fix
ensures that error labels at the top level are properly
added to MongoWriteConcernException

JAVA-4419
Branch: master
https://github.com/mongodb/mongo-java-driver/commit/6f5de9b29de6b42bd8c0fee7704c4ed0501dd1ea

Generated at Thu Feb 08 09:02:01 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.