You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@activemq.apache.org by "Jan Kerkenhoff (Jira)" <ji...@apache.org> on 2020/08/21 06:42:00 UTC
[jira] [Updated] (ARTEMIS-2883) Websocket Implementation Breaks
with Large Messages
[ https://issues.apache.org/jira/browse/ARTEMIS-2883?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jan Kerkenhoff updated ARTEMIS-2883:
------------------------------------
Description:
When publishing a large Message into an Topic (ca 80kb) and subscribing to this topic via a websocket connection, the websocket connection gets broken by artemis sending the wrong packages.
Steps to reproduce:
Subscribe to an topic with a large retained message via an mqtt websocket
When this happens the following is seen in the artemis log:
{code:java}
2020-08-19 19:13:08,697 WARN [org.apache.activemq.artemis.core.server] AMQ222061: Client connection failed, clearing up resources for session f1cd4c98-e23c-11ea-bb3c-00155d89640c
2020-08-19 19:14:55,535 WARN [io.netty.channel.AbstractChannelHandlerContext] Failed to mark a promise as failure because it has succeeded already: DefaultChannelPromise@33ebd0(success): java.lang.IllegalArgumentException: promise already done: DefaultChannelPromise@33ebd0(success)
at io.netty.channel.AbstractChannelHandlerContext.isNotValidPromise(AbstractChannelHandlerContext.java:885) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:774) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:758) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.writeContinuationFrame(WebSocketFrameEncoder.java:64) [artemis-server-2.12.0.jar:2.12.0]
at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.write(WebSocketFrameEncoder.java:45) [artemis-server-2.12.0.jar:2.12.0]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:792) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:702) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:112) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext$WriteTask.run(AbstractChannelHandlerContext.java:1102) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.utils.ActiveMQThreadFactory$1.run(ActiveMQThreadFactory.java:118) [artemis-commons-2.12.0.jar:2.12.0]
{code}
Error Message from the Browser (see attached screenshot)
was:
When publishing a large Message into an Topic (ca 80kb) and subscribing to this topic via a websocket connection, the websocket connection gets broken by artemis sending the wrong packages.
Steps to reproduce:
Subscribe to an topic with a large retained message via an mqtt websocket
When this happens the following is seen in the artemis log:
{code:java}
//2020-08-19 19:13:08,697 WARN [org.apache.activemq.artemis.core.server] AMQ222061: Client connection failed, clearing up resources for session f1cd4c98-e23c-11ea-bb3c-00155d89640c
2020-08-19 19:14:55,535 WARN [io.netty.channel.AbstractChannelHandlerContext] Failed to mark a promise as failure because it has succeeded already: DefaultChannelPromise@33ebd0(success): java.lang.IllegalArgumentException: promise already done: DefaultChannelPromise@33ebd0(success)
at io.netty.channel.AbstractChannelHandlerContext.isNotValidPromise(AbstractChannelHandlerContext.java:885) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:774) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:758) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.writeContinuationFrame(WebSocketFrameEncoder.java:64) [artemis-server-2.12.0.jar:2.12.0]
at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.write(WebSocketFrameEncoder.java:45) [artemis-server-2.12.0.jar:2.12.0]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:792) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:702) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:112) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext$WriteTask.run(AbstractChannelHandlerContext.java:1102) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.utils.ActiveMQThreadFactory$1.run(ActiveMQThreadFactory.java:118) [artemis-commons-2.12.0.jar:2.12.0]
{code}
Error Message from the Browser (see attached screenshot)
> Websocket Implementation Breaks with Large Messages
> ---------------------------------------------------
>
> Key: ARTEMIS-2883
> URL: https://issues.apache.org/jira/browse/ARTEMIS-2883
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Components: MQTT
> Affects Versions: 2.12.0
> Environment: Artemis Version: 2.12.0
> Websocket Implementations: ngx-mqtt: 6.13.0
> Chrome: 84.0.4147.135
> Reporter: Jan Kerkenhoff
> Priority: Major
> Attachments: 2020-08-19 13_25_26-172.16.94.101 - Remote Desktop Connection.png
>
>
> When publishing a large Message into an Topic (ca 80kb) and subscribing to this topic via a websocket connection, the websocket connection gets broken by artemis sending the wrong packages.
>
> Steps to reproduce:
> Subscribe to an topic with a large retained message via an mqtt websocket
>
> When this happens the following is seen in the artemis log:
> {code:java}
> 2020-08-19 19:13:08,697 WARN [org.apache.activemq.artemis.core.server] AMQ222061: Client connection failed, clearing up resources for session f1cd4c98-e23c-11ea-bb3c-00155d89640c
> 2020-08-19 19:14:55,535 WARN [io.netty.channel.AbstractChannelHandlerContext] Failed to mark a promise as failure because it has succeeded already: DefaultChannelPromise@33ebd0(success): java.lang.IllegalArgumentException: promise already done: DefaultChannelPromise@33ebd0(success)
> at io.netty.channel.AbstractChannelHandlerContext.isNotValidPromise(AbstractChannelHandlerContext.java:885) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:774) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:758) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.writeContinuationFrame(WebSocketFrameEncoder.java:64) [artemis-server-2.12.0.jar:2.12.0]
> at org.apache.activemq.artemis.core.server.protocol.websocket.WebSocketFrameEncoder.write(WebSocketFrameEncoder.java:45) [artemis-server-2.12.0.jar:2.12.0]
> at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:792) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:702) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:112) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:717) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:709) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.AbstractChannelHandlerContext$WriteTask.run(AbstractChannelHandlerContext.java:1102) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-all-4.1.48.Final.jar:4.1.48.Final]
> at org.apache.activemq.artemis.utils.ActiveMQThreadFactory$1.run(ActiveMQThreadFactory.java:118) [artemis-commons-2.12.0.jar:2.12.0]
> {code}
> Error Message from the Browser (see attached screenshot)
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)