You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Gary Tully (JIRA)" <ji...@apache.org> on 2014/03/19 15:40:42 UTC

[jira] [Comment Edited] (AMQ-5108) MQTT subscriptions for cleansession=true MUST be non-durable

    [ https://issues.apache.org/jira/browse/AMQ-5108?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13940508#comment-13940508 ] 

Gary Tully edited comment on AMQ-5108 at 3/19/14 2:39 PM:
----------------------------------------------------------

with that patch applied i often see:{code}Tests run: 29, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 41.505 sec <<< FAILURE! - in org.apache.activemq.transport.mqtt.MQTTTest
testReceiveMessageSentWhileOffline(org.apache.activemq.transport.mqtt.MQTTTest)  Time elapsed: 0.328 sec  <<< ERROR!
java.net.ProtocolException: Command from server contained an invalid message id: 1
	at org.fusesource.mqtt.client.CallbackConnection.completeRequest(CallbackConnection.java:723)
	at org.fusesource.mqtt.client.CallbackConnection.processFrame(CallbackConnection.java:762)
	at org.fusesource.mqtt.client.CallbackConnection.access$1500(CallbackConnection.java:51)
	at org.fusesource.mqtt.client.CallbackConnection$6.onTransportCommand(CallbackConnection.java:392)
	at org.fusesource.hawtdispatch.transport.TcpTransport.drainInbound(TcpTransport.java:709)
	at org.fusesource.hawtdispatch.transport.TcpTransport$6.run(TcpTransport.java:588)
	at org.fusesource.hawtdispatch.internal.NioDispatchSource$3.run(NioDispatchSource.java:209)
	at org.fusesource.hawtdispatch.internal.SerialDispatchQueue.run(SerialDispatchQueue.java:100)
	at org.fusesource.hawtdispatch.internal.pool.SimpleThread.run(SimpleThread.java:77){code} this needs some investigation. But it works standalone so may just be some inter test interactions.


was (Author: gtully):
with that patch applied i often see:{code}Tests run: 29, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 41.505 sec <<< FAILURE! - in org.apache.activemq.transport.mqtt.MQTTTest
testReceiveMessageSentWhileOffline(org.apache.activemq.transport.mqtt.MQTTTest)  Time elapsed: 0.328 sec  <<< ERROR!
java.net.ProtocolException: Command from server contained an invalid message id: 1
	at org.fusesource.mqtt.client.CallbackConnection.completeRequest(CallbackConnection.java:723)
	at org.fusesource.mqtt.client.CallbackConnection.processFrame(CallbackConnection.java:762)
	at org.fusesource.mqtt.client.CallbackConnection.access$1500(CallbackConnection.java:51)
	at org.fusesource.mqtt.client.CallbackConnection$6.onTransportCommand(CallbackConnection.java:392)
	at org.fusesource.hawtdispatch.transport.TcpTransport.drainInbound(TcpTransport.java:709)
	at org.fusesource.hawtdispatch.transport.TcpTransport$6.run(TcpTransport.java:588)
	at org.fusesource.hawtdispatch.internal.NioDispatchSource$3.run(NioDispatchSource.java:209)
	at org.fusesource.hawtdispatch.internal.SerialDispatchQueue.run(SerialDispatchQueue.java:100)
	at org.fusesource.hawtdispatch.internal.pool.SimpleThread.run(SimpleThread.java:77){code} this needs some investigation.

> MQTT subscriptions for cleansession=true MUST be non-durable
> ------------------------------------------------------------
>
>                 Key: AMQ-5108
>                 URL: https://issues.apache.org/jira/browse/AMQ-5108
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: MQTT
>    Affects Versions: 5.9.0
>            Reporter: Dhiraj Bokde
>            Assignee: Gary Tully
>             Fix For: 5.10.0
>
>         Attachments: AMQ-5108.patch
>
>
> When MQTT cleansession flag is set to 1, the Broker MUST remove existing subscriptions for the provided client id as well as not leave any subscriptions created in that clean session around after the network connection is closed. ActiveMQ MUST therefore create non-durable subscriptions for cleansession=1 sessions. 
> A patch is attached that adds this behavior, as well as fixes some small issues in MQTT tests. It also includes a fix to remove connection info when the connection is shutdown due to a transport error or exception. 



--
This message was sent by Atlassian JIRA
(v6.2#6252)