mosquitto icon indicating copy to clipboard operation
mosquitto copied to clipboard

LWT on child broker

Open agrosjea opened this issue 6 years ago • 4 comments

Hi ! I am enountering an issue on Mosquitto using a dual broker configuration main broker in the cloud is 1.5.5 (cant update right now) client broker is 1.5.7 under Windows with the following conf file :

port 1883
protocol mqtt
connection_messages true
log_timestamp true
log_type warning
log_dest file c:\mqtt_log.log

connection MyServer
address myserver:1883
topic # both 1
clientid MyClientBroker
  • Connexion works as expected and my Windows client can both publish and retrieve messages from main server.
  • Using MQTT box I connect a client (using TCP/MQTT protocol) and define Last Will Testament QoS 2 and retained.
  • Whenever I disconnect manually my MQTT box client, I can see that the LWT is handled when I reconnect.
  • But if I stop my service in Windows abruptly, the last will is not handled by the main server. Is that a bug or is it as designed ? Any workaround ?

A possible workaround for me would be to be able to define an Will message for the Windows broker itself. But I do not see any mention in the config file on how to define a Will.

agrosjea avatar Feb 26 '19 22:02 agrosjea