How may i send a message to single client id or multiple client ids without connecting to any topic ? is this even possible in emqtt ? i have heard mqtt protocol does not support my senario .
another question : is there any way to publish message to some client ids not all of them in a specific topic ? i guess it just accept one single client at the time.
Hi @nerdial
According to MQTT spec, messages are always published to topics,
never published targeting any specific client-id.
One can of course use unique topic to make it work like an 'id'.
As far as I know, emqx does not support anything special in this regard.
To your second question (not sure if I completely follow though):
Messages are broadcasted to all clients who subscribes to that specific topic
(or wildcard topic which matches the producer's target topic).
One exception is shared-subscription, if two or more clients subscribe to the same group,
messages are randomly delivered to one of the clients in the group.
@nerdial, Hi As @spring2maz explained, the MQTT protocol does not support it.
this is the "MQTT P2P" scenario, your client can subscribe one private topic, means one client one topic. you can publish to any topic as your client.
My question is "How to publish same msg to multiple topic one time"
Most helpful comment
Hi @nerdial
According to MQTT spec, messages are always published to topics,
never published targeting any specific client-id.
One can of course use unique topic to make it work like an 'id'.
As far as I know, emqx does not support anything special in this regard.
To your second question (not sure if I completely follow though):
Messages are broadcasted to all clients who subscribes to that specific topic
(or wildcard topic which matches the producer's target topic).
One exception is shared-subscription, if two or more clients subscribe to the same group,
messages are randomly delivered to one of the clients in the group.