-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: 2.4.4
-
Component/s: Operations
-
None
-
Minor Change
The following code:
var collections = database.ListCollections().ToList();
throws a FormatException when run against server 3.5.12. The message is:
The GuidRepresentation for the reader is CSharpLegacy, which requires the binary sub type to be UuidLegacy, not UuidStandard.
This is happening because the collection info now includes a UUID.
The ReadBinaryData method should be able to read either subtype 3 or subtype 4 BsonBinary values regardless of the settings. The GuidRepresentation from the settings should only be used when the value read is of subtype 3.
This change will be backward breaking only to applications that were counting on the BsonBinaryReader to enforce that all UUIDs read were of the expected subtype.
- is duplicated by
-
CSHARP-2182 C# Driver - System.FormatException on ListCollections()
- Closed