How to identify whether the publish
to a topic
was success or not. Is there any way to get acknowledgement on publishing to a topic.
If there is any connection loss during publish
between the clients(Publisher/Subscriber) how to handle it.
I don't want the subscriber to send an ack to specific topic in the publishing end after receiving the pay_load.
Here is my ruby code:
Assume, I have created clients(@client)
and configured on both sides.
Publish
def publish_it
@client.publish('test/hai', 'message')
# Ack the publish
end
Subscribe
@client.subscribe('test/#')
@client.get do |topic,message|
puts "#{topic}: #{message}"
end