lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-users] MQTT Default Keepalive is 0, Mosquitto 2.0.12 requires a no


From: Luciano Moretti
Subject: [lwip-users] MQTT Default Keepalive is 0, Mosquitto 2.0.12 requires a non-zero keep alive.
Date: Wed, 15 Sep 2021 16:36:53 -0500

Found this issue today when we couldn't get our device to talk to a newly installed MQTT server: 

By default the LwIP MQTT Client sends a keepalive of 0 unless you set it yourself. Documentation in the header file says "0 to disable keep alive functionality"

Mosquitto 2.0.12 now requires a non-zero keep alive value.

Reading the MQTT specification it's not clear what should happen with a Keep Alive set to 0, stating "A Keep Alive value of zero (0) has the effect of turning off the keep alive mechanism. This means that, in this case, the Server is not required to disconnect the Client on the grounds of inactivity."  It's not required to disconnect, but it doesn't say that it can't immediately disconnect either.

Thought this might save some others some time.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]