[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [mosquitto-dev] Basic configuration issue with multiple listeners
|
On 13/08/2019 17:13, Greg Troxel wrote:
...snip
The corollary: Is mosquitto's hidden invocation of the default
listener by innocuous-looking directives really the best approach?
No, and this appears to be a widely-held view, but it's hard to change
because fixes will break existing configs.
To quote an old Turkish proverb (in turn, quoted in "Practices of an
Agile Developer" by Subramanian & Hunt), "No matter how far down the
wrong road you have gone, turn back" :-
This looks to me like a side-effect waiting to bite you. Could
starting the default listener be made explicit? Or indeed removed
altogether? An explicit "listener 1883 0.0.0.0" directive would seem
to do the same job but has the advantage of making it obvious what is
happening?
That is a half-fix (doesn't fix the association of modifiers and
listeners), but the combination of:
remove default listener from code
add "listener 1883 0.0.0.0" to example config, at end
make modifier config lines be an error if there is no listener
would seem to have minimal pain for people with existing configs, and
avoid a lot of other confusion.
That would seem a good proposal.
Peter