SignalK / SensESP

Universal Signal K sensor framework for the ESP32 platform
https://signalk.org/SensESP/
Apache License 2.0
153 stars 81 forks source link

Announce only activated services on mDNS #582

Closed mairas closed 2 years ago

mairas commented 2 years ago

SensESP announces some networked services over mDNS. In particular, it announces the websocket client service over signalk-sensesp and the HTTP configuration interface over http.

Previously, mDNS services were announced unconditionally whenever MDNSDiscovery was instantiated. Now, the main class only starts the facilities and sets the hostname discovery. The individual services are announced only in the particular service's startup code.

mairas commented 2 years ago

This is required if SensESPMinimalApp is used and e.g. the WSClient is not instantiated. In such a case, signalk-sensesp shouldn't be advertised.