-
Type: Improvement
-
Resolution: Fixed
-
Priority: Unknown
-
Affects Version/s: None
-
Component/s: None
-
None
Currently a connection's "idle deadline" is increased in the Go driver only when reading writing to the connection. However, the CMAP spec defines "idle" as:
Idle: The Connection is currently "available" (as defined below) and has been for longer than maxIdleTimeMS.
"Available" is defined as:
The Connection has been established and is waiting in the pool to be checked out.
As a result, it's currently possible to check in a connection to the pool that has not been read from or written to for more than maxIdleTimeMS and it will be considered stale due to idle timeout. According to the definition of "idle" in the CMAP spec, that should be impossible.
Update the Go driver to increase the connection's idle deadline when it is checked into the pool.