The server DISCONNECT and I receive LWT message?

146 views Asked by At

Isn't if the server did not receive any messages from the client within the (1.5) * KeepAlivetime and the client did not send any PINGREQ within the aforementioned period, the server should DISCONNECT?

If yes, why I am receiving LWT message which is should not be received as DISCONNECT occures?

1

There are 1 answers

1
hardillb On BEST ANSWER

Last will and Testement will be sent if the client does not explicitly disconnect it's self.

If the broker disconnects the client due to a ping time out then the LWT will be sent, this is the specific reason why the LWT feature exists.

Or do you mean your now disconnected client is receiving it's own LWT?