I have a NodeJS program using the mqtt
NPM plugin to send messages to Amazon MQ. I configured the queue and subscribed, and then publish the message. Here is the code.
The listener uses the OpenWire JMS client, and I'm sending messages using either MQTT or WSS. In both cases the JMS client is not receiving any message.
If I write NodeJS code for the receiver it is working.
Does the JMS client have to use either MQTT / WSS to receive the message? Does the protocol matter here?
MQTT is a Topic based messaging protocol and as such the subscribers to messages sent from the MQTT publishers need to be listening on a Topic and not a Queue. Topics are publish / subscribe to when no subscribes exist the messages will be discarded unless there exists a durable Topic subscription prior to the message having been produced so be aware of that.
In ActiveMQ there are ways of routing messages from one destination to another so you could take advantage of that to route messages or you could you something like a Camel route to forward the Topic messages sent from MQTT clients to a Queue.