Hello,
I am implementing something like chat functions on Android using MQTT and took the available example from MQTT and changed it a little in order to have a Listener. The connection is established from Android-Client to ActiveMQ-Brocker. As well I have a JbossServer with @ResourceAdapter("activemq.rar") and MDB in order to implement administration(create a new Topic at runtime etc. ) on the Server side.
I have a question concerning the Listener and Publisher in Android-Clien . The Listener and subscription is set up. It works well, but only for the first message (both ways: sending from the Client to Topic and sending from the WebConsole to Topic).
On receiving of the second message occurs an error on Android-client in Listener onFailure: java.net.ProtocolException: Command from server contained an invalid message id: 2. The same error occurs, when I try to send the second message from Client.
I attached my code.
I would be grateful if you would help me with this error.
Cheers
Alex