diff --git a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/AbstractDecodedMessageSink.java b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/AbstractDecodedMessageSink.java index 28628b5a5c4..9ae040bb9c6 100644 --- a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/AbstractDecodedMessageSink.java +++ b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/AbstractDecodedMessageSink.java @@ -57,13 +57,13 @@ public abstract class AbstractDecodedMessageSink implements MessageSink /** * Invoke the MessageSink with the decoded message. - * @param args the decoded message. + * @param message the decoded message. */ - public void invoke(Object... args) + void invoke(Object message) { try { - _methodHandle.invoke(args); + _methodHandle.invoke(message); } catch (Throwable t) { diff --git a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryMessageSink.java b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryMessageSink.java index c7aa552f809..bd2b2aa9d1f 100644 --- a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryMessageSink.java +++ b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryMessageSink.java @@ -53,7 +53,6 @@ public class DecodedBinaryMessageSink extends AbstractDecodedMessageSink.Basi return new ByteBufferMessageSink(coreSession, methodHandle); } - @SuppressWarnings("Duplicates") public void onWholeMessage(ByteBuffer wholeMessage) { for (Decoder.Binary decoder : _decoders) diff --git a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryStreamMessageSink.java b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryStreamMessageSink.java index a9555f4e3b0..38c40b45ac7 100644 --- a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryStreamMessageSink.java +++ b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedBinaryStreamMessageSink.java @@ -50,7 +50,6 @@ public class DecodedBinaryStreamMessageSink extends AbstractDecodedMessageSin return new InputStreamMessageSink(coreSession, methodHandle); } - @SuppressWarnings("Duplicates") public void onStreamStart(InputStream stream) { try diff --git a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextMessageSink.java b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextMessageSink.java index dff4f14625f..ff1749550c5 100644 --- a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextMessageSink.java +++ b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextMessageSink.java @@ -52,7 +52,6 @@ public class DecodedTextMessageSink extends AbstractDecodedMessageSink.Basic< return new StringMessageSink(coreSession, methodHandle); } - @SuppressWarnings("Duplicates") public void onMessage(String wholeMessage) { for (Decoder.Text decoder : _decoders) diff --git a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextStreamMessageSink.java b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextStreamMessageSink.java index 583d2f0fb04..ff2caa4730a 100644 --- a/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextStreamMessageSink.java +++ b/jetty-websocket/websocket-javax-common/src/main/java/org/eclipse/jetty/websocket/javax/common/messages/DecodedTextStreamMessageSink.java @@ -50,7 +50,6 @@ public class DecodedTextStreamMessageSink extends AbstractDecodedMessageSink. return new ReaderMessageSink(coreSession, methodHandle); } - @SuppressWarnings("Duplicates") public void onStreamStart(Reader reader) { try diff --git a/jetty-websocket/websocket-javax-tests/src/test/java/org/eclipse/jetty/websocket/javax/tests/coders/DecoderListTest.java b/jetty-websocket/websocket-javax-tests/src/test/java/org/eclipse/jetty/websocket/javax/tests/coders/DecoderListTest.java index b899af68633..28d96a65280 100644 --- a/jetty-websocket/websocket-javax-tests/src/test/java/org/eclipse/jetty/websocket/javax/tests/coders/DecoderListTest.java +++ b/jetty-websocket/websocket-javax-tests/src/test/java/org/eclipse/jetty/websocket/javax/tests/coders/DecoderListTest.java @@ -216,6 +216,12 @@ public class DecoderListTest { session.addMessageHandler(new PartialBinaryHandler(session)); } + + @Override + public void onError(Session session, Throwable t) + { + t.printStackTrace(); + } } private static class PartialTextHandler implements MessageHandler.Whole