Skip to content

Commit 8ce16b9

Browse files
garyrussellartembilan
authored andcommitted
Test for GH-2938
Close connection in `TcpNioConnection.testInsufficientThreads()`. Before the fix, this would block for 15 seconds, causing the assert on the future completion to fail.
1 parent 796a0c4 commit 8ce16b9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

spring-integration-ip/src/test/java/org/springframework/integration/ip/tcp/connection/TcpNioConnectionTests.java

+4
Original file line numberDiff line numberDiff line change
@@ -334,6 +334,10 @@ public void testInsufficientThreads() throws Exception {
334334
logger.debug("Expected timeout", e);
335335
throw (Exception) e.getCause();
336336
}
337+
finally {
338+
connection.setPipeTimeout(15);
339+
connection.close();
340+
}
337341
return null;
338342
});
339343
try {

0 commit comments

Comments
 (0)