-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Internal Code
-
None
-
Fully Compatible
-
ALL
-
v7.0, v6.3, v6.2, v6.0, v5.0
-
Service Arch 2023-04-17
-
0
EgressConnectionResetByPeerDuringSessionCtor is designed to perform the following:
- Start a listener thread (the server).
- Create a connection to the server and block the connection before it attempts to set socket options (using a fail-point).
- Have the server close the connection.
- Verify the status that the newly created connection returns.
Currently, the server thread doesn't wait for the client to reach the fail-point. As a result, the server may close the connection before the client thread attempts to create a session. This may result in the client returning ErrorCodes::HostUnreachable through the following code-path:
- _doSyncConnect observes a closed socket (asio::error::connection_reset) before attempting to construct the Session object.
- This is translated to DBException, potentially through here.
- We later on add additional details to the Status object through here.
So long as the server uses the fail-point to synchronizes with the client, this issue should be avoidable.