[CSHARP-2392] ChangeStreamDocument.ClusterTime should be serialized as Timestamp Created: 21/Sep/18  Updated: 28/Oct/23  Resolved: 04/Oct/18

Status: Closed
Project: C# Driver
Component/s: Serialization
Affects Version/s: 2.7.0
Fix Version/s: 2.7.1

Type: Bug Priority: Major - P3
Reporter: John Murphy Assignee: Robert Stam
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Case:

 Description   

Attempting to access ChangeStreamDocument.ClusterTime results in a System.FormatException as we are trying to deserialize a BsonTimestamp as a BsonDocument.

According to the spec this value is a Timestamp, so we should treat it accordingly.



 Comments   
Comment by Githook User [ 06/Nov/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Improve ChangeStreamDocument integration test.
Branch: v2.7.x
https://github.com/mongodb/mongo-csharp-driver/commit/70c012c70376c995f8a3a5baa1bab5ef51453081

Comment by Githook User [ 06/Nov/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Refactor change stream integration test to at least access all properties of ChangeStreamDocument.
Branch: v2.7.x
https://github.com/mongodb/mongo-csharp-driver/commit/b21f77288b944586e610060080d67b2930a97cdf

Comment by Githook User [ 06/Nov/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Minor change to tests.
Branch: v2.7.x
https://github.com/mongodb/mongo-csharp-driver/commit/119fe3284807b469c01e8c4e42800b30d15e3a71

Comment by Githook User [ 04/Oct/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Improve ChangeStreamDocument integration test.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/fd823262826dc788c4c744cb2f64ce19d4f31aff

Comment by Githook User [ 04/Oct/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Refactor change stream integration test to at least access all properties of ChangeStreamDocument.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/cdd66b37e8efb5264bb3116287c14580ce6ea72b

Comment by Githook User [ 04/Oct/18 ]

Author:

{'name': 'rstam', 'email': 'robert@robertstam.org', 'username': 'rstam'}

Message: CSHARP-2392: Minor change to tests.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/997e6d00404d89b483193ad81e97e21daba9e1d5

Comment by John Murphy [ 21/Sep/18 ]

Previously ClusterTime was broken so I don't think backwards compatibility of changing the return type is of concern.

PR: https://github.com/mongodb/mongo-csharp-driver/pull/344

Generated at Wed Feb 07 21:42:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.