diff --git a/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/config/JakartaWebSocketServletContainerInitializer.java b/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/config/JakartaWebSocketServletContainerInitializer.java index 0152893e926..a2df82c96f9 100644 --- a/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/config/JakartaWebSocketServletContainerInitializer.java +++ b/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/config/JakartaWebSocketServletContainerInitializer.java @@ -20,16 +20,16 @@ package org.eclipse.jetty.websocket.jakarta.server.config; import java.util.HashSet; import java.util.Set; +import jakarta.servlet.ServletContainerInitializer; +import jakarta.servlet.ServletContext; +import jakarta.servlet.ServletException; +import jakarta.servlet.annotation.HandlesTypes; import jakarta.websocket.DeploymentException; import jakarta.websocket.Endpoint; import jakarta.websocket.server.ServerApplicationConfig; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpoint; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContainerInitializer; -import jakarta.servlet.ServletContext; -import jakarta.servlet.ServletException; -import jakarta.servlet.annotation.HandlesTypes; import org.eclipse.jetty.servlet.FilterHolder; import org.eclipse.jetty.servlet.ServletContextHandler; diff --git a/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/internal/JakartaWebSocketServerContainer.java b/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/internal/JakartaWebSocketServerContainer.java index 1bf4c37aaa9..2cfcec11230 100644 --- a/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/internal/JakartaWebSocketServerContainer.java +++ b/jetty-websocket/websocket-jakarta-server/src/main/java/org/eclipse/jetty/websocket/jakarta/server/internal/JakartaWebSocketServerContainer.java @@ -22,10 +22,10 @@ import java.util.ArrayList; import java.util.List; import java.util.concurrent.Executor; import java.util.function.Function; +import jakarta.servlet.ServletContext; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerEndpoint; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContext; import org.eclipse.jetty.client.HttpClient; import org.eclipse.jetty.http.pathmap.PathSpec; diff --git a/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionConfigurator.java b/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionConfigurator.java index 88a48be9ae2..9c84ea60797 100644 --- a/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionConfigurator.java +++ b/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionConfigurator.java @@ -18,10 +18,10 @@ package org.eclipse.jetty.websocket.jakarta.server.examples; +import jakarta.servlet.http.HttpSession; import jakarta.websocket.HandshakeResponse; import jakarta.websocket.server.HandshakeRequest; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.http.HttpSession; public class GetHttpSessionConfigurator extends ServerEndpointConfig.Configurator { diff --git a/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionSocket.java b/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionSocket.java index 1a756138f5f..c8f978c41e2 100644 --- a/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionSocket.java +++ b/jetty-websocket/websocket-jakarta-server/src/test/java/org/eclipse/jetty/websocket/jakarta/server/examples/GetHttpSessionSocket.java @@ -19,12 +19,12 @@ package org.eclipse.jetty.websocket.jakarta.server.examples; import java.io.IOException; +import jakarta.servlet.http.HttpSession; import jakarta.websocket.EndpointConfig; import jakarta.websocket.OnMessage; import jakarta.websocket.OnOpen; import jakarta.websocket.Session; import jakarta.websocket.server.ServerEndpoint; -import jakarta.servlet.http.HttpSession; @ServerEndpoint(value = "/example", configurator = GetHttpSessionConfigurator.class) public class GetHttpSessionSocket diff --git a/jetty-websocket/websocket-jakarta-tests/src/main/java/org/eclipse/jetty/websocket/jakarta/tests/LocalServer.java b/jetty-websocket/websocket-jakarta-tests/src/main/java/org/eclipse/jetty/websocket/jakarta/tests/LocalServer.java index abb3db0ecfe..e0529abf2c0 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/main/java/org/eclipse/jetty/websocket/jakarta/tests/LocalServer.java +++ b/jetty-websocket/websocket-jakarta-tests/src/main/java/org/eclipse/jetty/websocket/jakarta/tests/LocalServer.java @@ -21,10 +21,10 @@ package org.eclipse.jetty.websocket.jakarta.tests; import java.net.URI; import java.util.Map; import java.util.function.BiConsumer; -import jakarta.websocket.OnMessage; -import jakarta.websocket.server.ServerEndpoint; import jakarta.servlet.http.HttpServletRequest; import jakarta.servlet.http.HttpServletResponse; +import jakarta.websocket.OnMessage; +import jakarta.websocket.server.ServerEndpoint; import org.eclipse.jetty.http.HttpVersion; import org.eclipse.jetty.http.pathmap.PathSpec; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/BasicEchoEndpointConfigContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/BasicEchoEndpointConfigContextListener.java index d5713c0bef9..742f6da18ee 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/BasicEchoEndpointConfigContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/BasicEchoEndpointConfigContextListener.java @@ -18,10 +18,10 @@ package com.acme.websocket; -import jakarta.websocket.DeploymentException; -import jakarta.websocket.server.ServerEndpointConfig; import jakarta.servlet.ServletContextEvent; import jakarta.servlet.ServletContextListener; +import jakarta.websocket.DeploymentException; +import jakarta.websocket.server.ServerEndpointConfig; public class BasicEchoEndpointConfigContextListener implements ServletContextListener { diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/IdleTimeoutContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/IdleTimeoutContextListener.java index d9ba4de180b..3aaee062566 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/IdleTimeoutContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/IdleTimeoutContextListener.java @@ -18,11 +18,11 @@ package com.acme.websocket; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; /** * Example of adding a server WebSocket (extending {@link jakarta.websocket.Endpoint}) programmatically via config diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/LargeEchoContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/LargeEchoContextListener.java index 7948a55c445..bc197069041 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/LargeEchoContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/LargeEchoContextListener.java @@ -18,9 +18,9 @@ package com.acme.websocket; -import jakarta.websocket.server.ServerContainer; import jakarta.servlet.ServletContextEvent; import jakarta.servlet.ServletContextListener; +import jakarta.websocket.server.ServerContainer; public class LargeEchoContextListener implements ServletContextListener { diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/PongContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/PongContextListener.java index d46bca85497..337ff5341f9 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/PongContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/com/acme/websocket/PongContextListener.java @@ -18,13 +18,13 @@ package com.acme.websocket; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.HandshakeResponse; import jakarta.websocket.server.HandshakeRequest; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; public class PongContextListener implements ServletContextListener { diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/RestartContextTest.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/RestartContextTest.java index e664e989f72..c4a09a7654e 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/RestartContextTest.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/RestartContextTest.java @@ -21,6 +21,8 @@ package org.eclipse.jetty.websocket.jakarta.tests; import java.net.URI; import java.util.concurrent.LinkedBlockingQueue; import java.util.concurrent.TimeUnit; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.ClientEndpoint; import jakarta.websocket.ContainerProvider; import jakarta.websocket.DeploymentException; @@ -29,8 +31,6 @@ import jakarta.websocket.Session; import jakarta.websocket.WebSocketContainer; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpoint; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.server.Server; import org.eclipse.jetty.server.ServerConnector; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/client/CookiesTest.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/client/CookiesTest.java index ed756dce919..3c5dc92eb34 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/client/CookiesTest.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/client/CookiesTest.java @@ -24,14 +24,14 @@ import java.util.List; import java.util.Map; import java.util.concurrent.TimeUnit; import java.util.function.Function; +import jakarta.servlet.http.Cookie; +import jakarta.servlet.http.HttpServletRequest; import jakarta.websocket.ClientEndpointConfig; import jakarta.websocket.ContainerProvider; import jakarta.websocket.Endpoint; import jakarta.websocket.HandshakeResponse; import jakarta.websocket.Session; import jakarta.websocket.WebSocketContainer; -import jakarta.servlet.http.Cookie; -import jakarta.servlet.http.HttpServletRequest; import org.eclipse.jetty.util.FuturePromise; import org.eclipse.jetty.websocket.core.FrameHandler; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointConfigContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointConfigContextListener.java index e1993cc5530..e328becbfe3 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointConfigContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointConfigContextListener.java @@ -18,11 +18,11 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.echo.BasicEchoEndpoint; /** diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointContextListener.java index 737c59c2173..da7fecf7f68 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoEndpointContextListener.java @@ -18,11 +18,11 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.pong.PongMessageEndpoint; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketConfigContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketConfigContextListener.java index e4988c72d16..5fece1a7950 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketConfigContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketConfigContextListener.java @@ -18,11 +18,11 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.echo.BasicEchoSocket; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketContextListener.java index 3cb62d294eb..18c5a5156d3 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/BasicEchoSocketContextListener.java @@ -18,10 +18,10 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; -import jakarta.websocket.DeploymentException; -import jakarta.websocket.server.ServerContainer; import jakarta.servlet.ServletContextEvent; import jakarta.servlet.ServletContextListener; +import jakarta.websocket.DeploymentException; +import jakarta.websocket.server.ServerContainer; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.echo.BasicEchoSocket; /** diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/IdleTimeoutContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/IdleTimeoutContextListener.java index db4433b2847..2a57c6871a8 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/IdleTimeoutContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/IdleTimeoutContextListener.java @@ -18,11 +18,11 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.idletimeout.OnOpenIdleTimeoutEndpoint; /** diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/LargeEchoContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/LargeEchoContextListener.java index 9fb00d1ebe7..07cf875d266 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/LargeEchoContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/LargeEchoContextListener.java @@ -18,9 +18,9 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; -import jakarta.websocket.server.ServerContainer; import jakarta.servlet.ServletContextEvent; import jakarta.servlet.ServletContextListener; +import jakarta.websocket.server.ServerContainer; /** * Configure the Large Text Message Size via the Container diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/PongContextListener.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/PongContextListener.java index a26b1fee207..e9f7e9a6acc 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/PongContextListener.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/PongContextListener.java @@ -18,14 +18,14 @@ package org.eclipse.jetty.websocket.jakarta.tests.server; +import jakarta.servlet.ServletContextEvent; +import jakarta.servlet.ServletContextListener; import jakarta.websocket.DeploymentException; import jakarta.websocket.HandshakeResponse; import jakarta.websocket.server.HandshakeRequest; import jakarta.websocket.server.ServerContainer; import jakarta.websocket.server.ServerEndpointConfig; import jakarta.websocket.server.ServerEndpointConfig.Configurator; -import jakarta.servlet.ServletContextEvent; -import jakarta.servlet.ServletContextListener; import org.eclipse.jetty.websocket.jakarta.tests.server.sockets.pong.PongMessageEndpoint; diff --git a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/WebSocketServerContainerExecutorTest.java b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/WebSocketServerContainerExecutorTest.java index df17955b91b..5ebe029cdd4 100644 --- a/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/WebSocketServerContainerExecutorTest.java +++ b/jetty-websocket/websocket-jakarta-tests/src/test/java/org/eclipse/jetty/websocket/jakarta/tests/server/WebSocketServerContainerExecutorTest.java @@ -26,6 +26,10 @@ import java.net.HttpURLConnection; import java.net.URI; import java.nio.charset.StandardCharsets; import java.util.concurrent.Executor; +import jakarta.servlet.ServletException; +import jakarta.servlet.http.HttpServlet; +import jakarta.servlet.http.HttpServletRequest; +import jakarta.servlet.http.HttpServletResponse; import jakarta.websocket.ClientEndpoint; import jakarta.websocket.ContainerProvider; import jakarta.websocket.EndpointConfig; @@ -35,10 +39,6 @@ import jakarta.websocket.OnOpen; import jakarta.websocket.Session; import jakarta.websocket.WebSocketContainer; import jakarta.websocket.server.ServerEndpoint; -import jakarta.servlet.ServletException; -import jakarta.servlet.http.HttpServlet; -import jakarta.servlet.http.HttpServletRequest; -import jakarta.servlet.http.HttpServletResponse; import org.eclipse.jetty.client.HttpClient; import org.eclipse.jetty.server.Server;