Skip to content

Pluggable HomeKit advertiser + optional native DNS-SD (share host mDNS) #212

Open

Description

@kgoderis

Goal

Let embeds publish _hap._tcp through a pluggable HomekitAdvertiser, so they can:

  • share a host JmDNS / mDNS service (preferred when one exists),
  • use a dedicated JmDNS, or
  • optionally register via native DNS-SD (Bonjour / Avahi libdns_sd) and avoid a second in-process multicast stack.

Motivation (refined)

This is primarily about clean host integration and fewer duplicate mDNS stacks, not a permanent “UDP 5353 is exclusively locked on macOS” story.

mDNSResponder typically listens with SO_REUSEPORT; a healthy JmDNS can share the port. A temporary JmDNS 3.6.4 regression (seen in some openHAB snapshots) failed to bind and looked like a hard conflict; 3.6.5+ behaves normally again.

Native DNS-SD remains useful as an optional backend for standalone HAP-Java and as a building block until hosts (especially openHAB core) expose their own system-mDNS path.

Architecture split

Concern Where
HAP advertise SPI + default JmDNS / optional native backends HAP-Java
Shared mDNS for all bindings / future native Bonjour for the runtime openHAB core
Choosing shared vs dedicated vs system advertiser for HomeKit openHAB io.homekit

Details: docs/NATIVE_DNSSD.md (also on PR branch).

Implementation

Tracked in PR #213.

openHAB tracking: openhab/openhab-addons#22012 / openhab/openhab-addons#22013

Activity

  1. added 3 commits that reference this issue on Oct 22, 2026
    175f81a
    fb1842f
    9c032ca
  2. changed the title [-]macOS: JmDNS advertiser cannot bind UDP 5353 (mDNSResponder); need native DNS-SD path[/-] [+]Pluggable HomeKit advertiser + optional native DNS-SD (share host mDNS)[/+] on Nov 22, 2026
  3. kgoderis commented on Nov 22, 2026

    @kgoderis
    Author

    Updated this issue (title + body) to match the agreed direction on #213: pluggable HomekitAdvertiser, optional native DNS-SD as optimization, HAP vs openHAB split. The exclusive-5353 framing was overstated (JmDNS 3.6.4 blip).

    Docs on the PR branch: docs/NATIVE_DNSSD.md. openHAB tracking: openhab/openhab-addons#22012 / #22013.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions