From f21fa6e6e9ba5e338df79e58ebcdbd67af1dfc9c Mon Sep 17 00:00:00 2001 From: Simone Bordet Date: Wed, 9 Nov 2022 12:13:27 +0100 Subject: [PATCH] Fixed flakyness of GracefulShutdownTest by explicitly setting the Connector shutdownIdleTimeout to a large value that does not interfere with the tests. Signed-off-by: Simone Bordet --- .../eclipse/jetty/http2/client/GracefulShutdownTest.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/jetty-http2/http2-client/src/test/java/org/eclipse/jetty/http2/client/GracefulShutdownTest.java b/jetty-http2/http2-client/src/test/java/org/eclipse/jetty/http2/client/GracefulShutdownTest.java index 5fd1c1c4b48..38bd99709ce 100644 --- a/jetty-http2/http2-client/src/test/java/org/eclipse/jetty/http2/client/GracefulShutdownTest.java +++ b/jetty-http2/http2-client/src/test/java/org/eclipse/jetty/http2/client/GracefulShutdownTest.java @@ -44,6 +44,15 @@ import static org.junit.jupiter.api.Assertions.assertTrue; public class GracefulShutdownTest extends AbstractTest { + @Override + protected void start(ServerSessionListener listener) throws Exception + { + super.start(listener); + // Don't let the default shutdown idleTimeout + // of just 1000 ms interfere with the test. + connector.setShutdownIdleTimeout(15000); + } + @Test public void testGracefulShutdownWhileIdle() throws Exception {