Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mosquitto config LWT #1188

Closed
agrosjea opened this issue Mar 4, 2019 · 8 comments
Closed

Mosquitto config LWT #1188

agrosjea opened this issue Mar 4, 2019 · 8 comments

Comments

@agrosjea
Copy link
Contributor

agrosjea commented Mar 4, 2019

In mosquitto.conf I found no reference to defining an LWT message when I connect to another broker.
This feature would be really nice to be aware of each sub-broker connexion state. Does it exists ?

Here is my current conf

connection MyCentralBroker
address MyCentralBroker.net:1883
topic # both 1
clientid Site1

Would be grat to have here for example:

lwt_message site1/isAlive
lwt_retain true
lwt_payload {"state" : false}
@karlp
Copy link
Contributor

karlp commented Mar 6, 2019

there's no way of changing the message itself, but notifications_topic will do what you want.

@karlp
Copy link
Contributor

karlp commented Mar 6, 2019

(if you're bridging to a broker that allows publishing to the $SYS tree, you already have this LWT topic under $SYS/broker/connections/...)

@agrosjea
Copy link
Contributor Author

Thanks karlp
Not sure to fully understand though
notifications_topic is a parameter of the config file ? how do I use it exactly ?
What should I do with $SYS ? can I publish my LWT there ?

@karlp
Copy link
Contributor

karlp commented Mar 14, 2019

notificatoin_topic is a config directive, yes. Please read the documentation on bridges.

@agrosjea
Copy link
Contributor Author

Oh great, as that mechanism is a bit similar to LWT i would recommend that you put the keyword LWT somewhere in the conf file above notification system.
"notifications" is too generic and didnt ring a bell when reading your doc.
Thanks for your great software!

@karlp
Copy link
Contributor

karlp commented Mar 24, 2019

this ticket can be closed I believe.

@agrosjea
Copy link
Contributor Author

agrosjea commented Mar 29, 2019 via email

@ralight
Copy link
Contributor

ralight commented Apr 26, 2019

I've added a line to the documentation as well, so this should be easier to find in the future.

@ralight ralight closed this as completed Apr 26, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Aug 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants