diff --git a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee10/websocket/api/RemoteEndpoint.java b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee10/websocket/api/RemoteEndpoint.java index 682b083ae7b3..d46fa6f3f2e4 100644 --- a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee10/websocket/api/RemoteEndpoint.java +++ b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee10/websocket/api/RemoteEndpoint.java @@ -103,9 +103,8 @@ public interface RemoteEndpoint * @param fragment the text being sent * @param isLast true if this is the last piece of the partial bytes * @param callback callback to notify of success or failure of the write operation - * @throws IOException this never throws IOException, it was a mistake to have this in the signature. */ - void sendPartialString(String fragment, boolean isLast, WriteCallback callback) throws IOException; + void sendPartialString(String fragment, boolean isLast, WriteCallback callback); /** * Send a Ping message containing the given application data to the remote endpoint, blocking until all of the diff --git a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee10/websocket/common/JettyWebSocketRemoteEndpoint.java b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee10/websocket/common/JettyWebSocketRemoteEndpoint.java index 13172bb5d871..3bda018a8944 100644 --- a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee10/websocket/common/JettyWebSocketRemoteEndpoint.java +++ b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee10/websocket/common/JettyWebSocketRemoteEndpoint.java @@ -124,7 +124,6 @@ public void sendPartialString(String fragment, boolean isLast) throws IOExceptio b.block(getBlockingTimeout(), TimeUnit.MILLISECONDS); } - // FIXME: Remove the throws IOException from API for this method in the next major release. @Override public void sendPartialString(String fragment, boolean isLast, WriteCallback callback) { diff --git a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee10/websocket/tests/AnnotatedPartialListenerTest.java b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee10/websocket/tests/AnnotatedPartialListenerTest.java index 768af6760d2b..8d5148d20552 100644 --- a/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee10/websocket/tests/AnnotatedPartialListenerTest.java +++ b/jetty-ee10/jetty-ee10-websocket/jetty-ee10-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee10/websocket/tests/AnnotatedPartialListenerTest.java @@ -13,7 +13,6 @@ package org.eclipse.jetty.ee10.websocket.tests; -import java.io.IOException; import java.net.URI; import java.nio.ByteBuffer; import java.util.Objects; @@ -62,14 +61,7 @@ public void onWebSocketPartialBinary(ByteBuffer payload, boolean fin) @Override public void onWebSocketPartialText(String payload, boolean fin) { - try - { - session.getRemote().sendPartialString(payload, fin, WriteCallback.NOOP); - } - catch (IOException e) - { - throw new IllegalStateException(e); - } + session.getRemote().sendPartialString(payload, fin, WriteCallback.NOOP); } } diff --git a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee9/websocket/api/RemoteEndpoint.java b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee9/websocket/api/RemoteEndpoint.java index c6c4f6b0c8c2..6a45b6d588ce 100644 --- a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee9/websocket/api/RemoteEndpoint.java +++ b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-api/src/main/java/org/eclipse/jetty/ee9/websocket/api/RemoteEndpoint.java @@ -103,9 +103,8 @@ public interface RemoteEndpoint * @param fragment the text being sent * @param isLast true if this is the last piece of the partial bytes * @param callback callback to notify of success or failure of the write operation - * @throws IOException this never throws IOException, it was a mistake to have this in the signature. */ - void sendPartialString(String fragment, boolean isLast, WriteCallback callback) throws IOException; + void sendPartialString(String fragment, boolean isLast, WriteCallback callback); /** * Send a Ping message containing the given application data to the remote endpoint, blocking until all of the diff --git a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee9/websocket/common/JettyWebSocketRemoteEndpoint.java b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee9/websocket/common/JettyWebSocketRemoteEndpoint.java index 9a94ddb14ba1..5f15844024c1 100644 --- a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee9/websocket/common/JettyWebSocketRemoteEndpoint.java +++ b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-common/src/main/java/org/eclipse/jetty/ee9/websocket/common/JettyWebSocketRemoteEndpoint.java @@ -124,7 +124,6 @@ public void sendPartialString(String fragment, boolean isLast) throws IOExceptio b.block(getBlockingTimeout(), TimeUnit.MILLISECONDS); } - // FIXME: Remove the throws IOException from API for this method in the next major release. @Override public void sendPartialString(String fragment, boolean isLast, WriteCallback callback) { diff --git a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee9/websocket/tests/AnnotatedPartialListenerTest.java b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee9/websocket/tests/AnnotatedPartialListenerTest.java index e9d50c85bb23..d007469e0419 100644 --- a/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee9/websocket/tests/AnnotatedPartialListenerTest.java +++ b/jetty-ee9/jetty-ee9-websocket/jetty-ee9-websocket-jetty-tests/src/test/java/org/eclipse/jetty/ee9/websocket/tests/AnnotatedPartialListenerTest.java @@ -13,7 +13,6 @@ package org.eclipse.jetty.ee9.websocket.tests; -import java.io.IOException; import java.net.URI; import java.nio.ByteBuffer; import java.util.Objects; @@ -62,14 +61,7 @@ public void onWebSocketPartialBinary(ByteBuffer payload, boolean fin) @Override public void onWebSocketPartialText(String payload, boolean fin) { - try - { - session.getRemote().sendPartialString(payload, fin, WriteCallback.NOOP); - } - catch (IOException e) - { - throw new IllegalStateException(e); - } + session.getRemote().sendPartialString(payload, fin, WriteCallback.NOOP); } }