Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mosquitto-dev] Mosquitto connection disconnection message time

Thanks Carl/Roger.

 

Let me brief about my case.

 

Used apps :

Mosquitto 1.4.8 (broker)

Python 2.7.11 with paho.mqtt client module.

MQTT 3.1

Mqttwarn 0.6 (listener)

 

I have remote devices wanted to monitor their availability by using mosquitto/MQTT protocol.

We have prepared a python code (shared in previous email) to initiate connection from remote device to connect e device with management server.

And wanted to append record connect time at every connection initiated by remote devices.

and record disconnect time, IP, hostname (of remote device) with LWT messages after any timeout or abrupt disconnection from the remote device.

 

We tried at our end but it’s appending disconnection time as older time (when it was last connection made with broker).

Is it possible to generate any message from the broker at every connect and disconnect with remote device?

 

Example –

 

Publish message at connect:–

“IT works !!! connection made with broker” from IP – 10.x.x.x at <<date and time>>.

 

LWT message at disconnect: -

“IT works !!! remote device disconnected from broker” whose IP – 10.x.x.x at <<date and time>>.

 

Please share any ftp/repository to upload configuration and code for your reference.

 

Thanks

Rajeev

 

 

 



::DISCLAIMER::
----------------------------------------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only.
E-mail transmission is not guaranteed to be secure or error-free as information could be intercepted, corrupted,
lost, destroyed, arrive late or incomplete, or may contain viruses in transmission. The e mail and its contents
(with or without referred errors) shall therefore not attach any liability on the originator or HCL or its affiliates.
Views or opinions, if any, presented in this email are solely those of the author and may not necessarily reflect the
views or opinions of HCL or its affiliates. Any form of reproduction, dissemination, copying, disclosure, modification,
distribution and / or publication of this message without the prior written consent of authorized representative of
HCL is strictly prohibited. If you have received this email in error please delete it and notify the sender immediately.
Before opening any email and/or attachments, please check them for viruses and other defects.

----------------------------------------------------------------------------------------------------------------------------------------------------


Back to the top