From bbcdc4406bee29b385ef5ef0054212e049845c50 Mon Sep 17 00:00:00 2001 From: Santiago Mola Date: Mon, 16 Sep 2024 08:24:32 +0200 Subject: [PATCH] Retry JettyServlet3ServeFromAsyncTimeout on socket timeout --- .../request-3/src/test/groovy/JettyServlet3Test.groovy | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dd-java-agent/instrumentation/servlet/request-3/src/test/groovy/JettyServlet3Test.groovy b/dd-java-agent/instrumentation/servlet/request-3/src/test/groovy/JettyServlet3Test.groovy index 9465bc596ec..3b6dfbfc3c2 100644 --- a/dd-java-agent/instrumentation/servlet/request-3/src/test/groovy/JettyServlet3Test.groovy +++ b/dd-java-agent/instrumentation/servlet/request-3/src/test/groovy/JettyServlet3Test.groovy @@ -13,6 +13,8 @@ import org.eclipse.jetty.server.Server import org.eclipse.jetty.server.handler.ErrorHandler import org.eclipse.jetty.server.session.SessionHandler import org.eclipse.jetty.servlet.ServletContextHandler +import spock.lang.Retry + import javax.servlet.AsyncEvent import javax.servlet.AsyncListener import javax.servlet.Servlet @@ -510,6 +512,8 @@ class ServeFromOnAsyncTimeout extends AbstractHttpServlet { } } +//@Flaky("Fails with timeout very often under high load") +@Retry(exceptions = SocketTimeoutException, count = 3, delay = 500, mode = Retry.Mode.SETUP_FEATURE_CLEANUP) class JettyServlet3ServeFromAsyncTimeout extends JettyServlet3Test { @Override Class servlet() {