What's default value heartbeat in mqtt plugin?

97 views
Skip to first unread message

Hoa Le Quang

unread,
Aug 9, 2016, 3:44:11 AM8/9/16
to rabbitmq-users
Hi guys,

I'm using rabbitmq with mqtt plugin as mqtt server. As the topic, I wanna know what's default value heartbeat set in mqtt plugin?
Thanks!

Jean-Sébastien Pédron

unread,
Aug 9, 2016, 4:16:54 AM8/9/16
to rabbitm...@googlegroups.com
On 09/08/2016 09:44, Hoa Le Quang wrote:
> Hi guys,

Hi!

> I'm using rabbitmq with mqtt plugin as mqtt server. As the topic, I
> wanna know what's default value heartbeat set in mqtt plugin?

With MQTT, the interval is set by the client when it connects, not the
server.

--
Jean-Sébastien Pédron
Pivotal / RabbitMQ

Hoa Le Quang

unread,
Sep 20, 2016, 7:58:54 AM9/20/16
to rabbitmq-users, jean-se...@rabbitmq.com
Thanks Jean for your reply.
 My clients are  android app and I am using Paho library. Would you please to let me know how to sent heartbeat time with Paho? 

Jean-Sébastien Pédron

unread,
Sep 21, 2016, 3:14:45 AM9/21/16
to rabbitm...@googlegroups.com
On 20.09.2016 13:58, Hoa Le Quang wrote:
> Thanks Jean for your reply.
> My clients are android app and I am using Paho library. Would you
> please to let me know how to sent heartbeat time with Paho?

Hi!

It's in the Paho documentation. I don't know Paho, but at least the
MqttConnect constructor takes a "keep alive interval" argument:

http://www.eclipse.org/paho/files/javadoc/org/eclipse/paho/client/mqttv3/internal/wire/MqttConnect.html#MqttConnect-java.lang.String-int-boolean-int-java.lang.String-char:A-org.eclipse.paho.client.mqttv3.MqttMessage-java.lang.String-

Hoa Le Quang

unread,
Sep 22, 2016, 10:36:00 PM9/22/16
to rabbitmq-users, jean-se...@rabbitmq.com
I got it.Thank you very much for your quickly reply :)
Reply all
Reply to author
Forward
0 new messages