[CSHARP-2454] KeepAliveValues should use 4 byte unsigned numbers instead of 8 byte Created: 12/Dec/18  Updated: 28/Oct/23  Resolved: 14/Jan/19

Status: Closed
Project: C# Driver
Component/s: Connectivity
Affects Version/s: 2.7.2
Fix Version/s: 2.7.3

Type: Bug Priority: Critical - P2
Reporter: Robert Stam Assignee: Robert Stam
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible

 Description   

The fields of KeepAliveValues should be uint (4 bytes) instead of ulong (8 bytes). See:

https://github.com/mongodb/mongo-csharp-driver/blob/v2.7.2/src/MongoDB.Driver.Core/Core/Connections/KeepAliveValues.cs#L22

The u_long types referenced here:

https://msdn.microsoft.com/en-us/library/windows/desktop/dd877220(v=vs.85).aspx

are in the C language, where u_long is 4 bytes.

The reported side effect of this bug is that hundreds of keep alive packets are sent per second.



 Comments   
Comment by Githook User [ 24/Jan/19 ]

Author:

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

Message: CSHARP-2454: KeepAliveValues should use 4 byte unsigned integers instead of 8 byte.
Branch: v2.7.x
https://github.com/mongodb/mongo-csharp-driver/commit/42319bd0781ba673f5410ce338ce80b3ca5fc6b1

Comment by Githook User [ 14/Jan/19 ]

Author:

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

Message: CSHARP-2454: KeepAliveValues should use 4 byte unsigned integers instead of 8 byte.
Branch: master
https://github.com/mongodb/mongo-csharp-driver/commit/08f0112c6c4933185c2070ea09c9a6ebbd59fe97

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