I have just been thinking about broker auto-discovery - particularly for small devices that you don't want to have to individually configure each of the nodes.
Ideas:
- Zeroconf / Multicast-DNS / DNS-SD
- Anycast / a well-known IPv6 address
- DHCP option
The last option is probably the easiest for small devices - any other ideas?
Started a wiki page here:
http://mqtt.org/wiki/broker_auto-discovery
nick.
Would not need to be a protocol modification at all - just a broker feature for advertising the port, and the client app to use for passing to the connect() call.
from mobile
> --
> To learn more about MQTT please visit http://mqtt.org
>
> To post to this group, send email to mq...@googlegroups.com
> To unsubscribe from this group, send email to
> mqtt+uns...@googlegroups.com
>
> For more options, visit this group at
> http://groups.google.com/group/mqtt
It's also worth adding that MQTT's little brother, MQTT-s, includes a broker/gateway discovery mechanism.
It is pretty light weight, as you'd expect, but I haven't done a sidebyside comparison with those you list.
As Andy says, brokers are free to implement any discovery system they want... Doesn't need to be part of the protocol.
Nick
> I have just been thinking about broker auto-discovery - particularly for
> small devices that you don't want to have to individually configure each of
> the nodes.
Like Andy said, he's reported it as a bug against mosquitto (
https://bugs.launchpad.net/mosquitto/+bug/902916 ) so I've been
thinking about this a bit myself.
I'm looking at adding zeroconf support to mosquitto, but it does vex
me somewhat that the client libraries are about 2/3 bigger than the
mosquitto executable...
On Sun, Jan 1, 2012 at 6:06 PM, Nicholas O'Leary <nick....@gmail.com> wrote:
> It's also worth adding that MQTT's little brother, MQTT-s, includes a
> broker/gateway discovery mechanism.
Sounds good. I've got the MQTT-S protocol pdf printed out - I will get
round to reading it one of these days.
Cheers,
Roger
That sounds like an interesting approach which I'd not considered
myself. Glad to hear you got it working for yourself.
I think the correct approach here is to use a library provided by e.g.
avahi. It's not even all that difficult - I've got some code written
to do it that's not quite complete. The reason I haven't done more is
because it's important that it is a cross platform solution and also
because I'm not sure how the user interface should appear for the
clients. Is a -a option on the clients sufficient? I don't know.
Cheers,
Roger