diff --git a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AbstractProxyServlet.java b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AbstractProxyServlet.java index ede1b133eb7..f003e18ba8d 100644 --- a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AbstractProxyServlet.java +++ b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AbstractProxyServlet.java @@ -763,10 +763,9 @@ public abstract class AbstractProxyServlet extends HttpServlet } } - protected void onContinue(HttpServletRequest clientRequest, Request proxyRequest) + protected Runnable onContinue(HttpServletRequest clientRequest, Request proxyRequest) { - if (_log.isDebugEnabled()) - _log.debug("{} handling 100 Continue", getRequestId(clientRequest)); + return null; } /** @@ -851,10 +850,10 @@ public abstract class AbstractProxyServlet extends HttpServlet class ProxyContinueProtocolHandler extends ContinueProtocolHandler { @Override - protected void onContinue(Request request) + protected Runnable onContinue(Request request) { HttpServletRequest clientRequest = (HttpServletRequest)request.getAttributes().get(CLIENT_REQUEST_ATTRIBUTE); - AbstractProxyServlet.this.onContinue(clientRequest, request); + return AbstractProxyServlet.this.onContinue(clientRequest, request); } } } diff --git a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AsyncMiddleManServlet.java b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AsyncMiddleManServlet.java index bb902313989..b7f9d294456 100644 --- a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AsyncMiddleManServlet.java +++ b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/AsyncMiddleManServlet.java @@ -171,11 +171,11 @@ public class AsyncMiddleManServlet extends AbstractProxyServlet } @Override - protected void onContinue(HttpServletRequest clientRequest, Request proxyRequest) + protected Runnable onContinue(HttpServletRequest clientRequest, Request proxyRequest) { - super.onContinue(clientRequest, proxyRequest); - Runnable action = (Runnable)proxyRequest.getAttributes().get(CONTINUE_ACTION_ATTRIBUTE); - action.run(); + if (_log.isDebugEnabled()) + _log.debug("{} handling 100 Continue", getRequestId(clientRequest)); + return (Runnable)proxyRequest.getAttributes().get(CONTINUE_ACTION_ATTRIBUTE); } private void transform(ContentTransformer transformer, ByteBuffer input, boolean finished, List output) throws IOException diff --git a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/ProxyServlet.java b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/ProxyServlet.java index 2ab028db7c4..2ef6d8a4a1a 100644 --- a/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/ProxyServlet.java +++ b/jetty-ee11/jetty-ee11-proxy/src/main/java/org/eclipse/jetty/ee11/proxy/ProxyServlet.java @@ -16,7 +16,6 @@ package org.eclipse.jetty.ee11.proxy; import java.io.IOException; import java.io.InputStream; import java.nio.ByteBuffer; -import java.util.concurrent.Executor; import java.util.concurrent.TimeUnit; import jakarta.servlet.AsyncContext; @@ -144,12 +143,11 @@ public class ProxyServlet extends AbstractProxyServlet } @Override - protected void onContinue(HttpServletRequest clientRequest, Request proxyRequest) + protected Runnable onContinue(HttpServletRequest clientRequest, Request proxyRequest) { - super.onContinue(clientRequest, proxyRequest); - Runnable action = (Runnable)proxyRequest.getAttributes().get(CONTINUE_ACTION_ATTRIBUTE); - Executor executor = getHttpClient().getExecutor(); - executor.execute(action); + if (_log.isDebugEnabled()) + _log.debug("{} handling 100 Continue", getRequestId(clientRequest)); + return (Runnable)proxyRequest.getAttributes().get(CONTINUE_ACTION_ATTRIBUTE); } /**