-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Minor - P4
-
Affects Version/s: None
-
Component/s: None
-
None
-
Networking & Observability
-
ALL
-
N&O 2025-09-15
-
0
-
None
-
None
-
None
-
None
-
None
-
None
-
None
The start() function in jstests/sharding/libs/proxy_protocol.js does not wait for the spawned reverse proxy process to listen on its configured interface. Instead, it checks that the process did not immediately terminate, and then waits for the process to log that it has started. However, the process does not listen on any interfaces until after it has logged the message.
This causes jstests that use the process to be flaky. Sometimes the test will attempt to connect to the reverse proxy before the reverse proxy is listening.
To fix this, we should modify start() to wait until either the process has terminated or the result of netstat (or similar) indicates that the process is LISTENing.
This race affects jstest on all server versions back to v7.0, so it should be backported.