Skip to content

Commit

Permalink
Speed up LocalOutgoingServerSessionTest
Browse files Browse the repository at this point in the history
This test uses an older SocketAcceptor, that cannot be interrupted. This means that we wait until SO_TIMEOUT before the test ends.

This commit reduces the SO_TIMEOUT value. This runs the risk of introducing instability.
  • Loading branch information
guusdk committed Jan 3, 2025
1 parent 75f7d3b commit 65bc760
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ public void run()
try {
log("Waiting for new socket.");

server.setSoTimeout((int)SO_TIMEOUT.multipliedBy(10).toMillis());
server.setSoTimeout((int)SO_TIMEOUT.toMillis());
final Socket socket = server.accept(); // This cannot be interrupted, which makes the entire test run very slow.
log("Accepted new socket connection.");

Expand Down

0 comments on commit 65bc760

Please sign in to comment.