-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Disable DNSSD cache globally in preparation for address resolve #16029
Conversation
In project-chip#15934 caching is generally not used, with the rationale of: - cache is doubled/trippled: - Platform MDNS servers are expected to cache at least on linux and mac due to avahi/bonjour being system wide and enforcing TTLs - We have cache both on CASESession and Platform, with separate caching between operational and commissionable - MinMdns does not have the dnssd cache like platform, but would likely benefit the most of it (since it would have TTLs) - we do not have a good way to clear caches and we do not update them on boot advertising (platform dnssd implementations would, however since we have an internal cache that seems to break) Looking to disable caching and either build it anew if it required/helps and at least make use of only one.
PR #16029: Size comparison from cd44f9b to c430b8e Decreases (38 builds for cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, p6, telink)
Full report (38 builds for cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, p6, telink)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable, but we also need to disable the platform-mdns cache, right? Separate PR for that?
I believe that was already gated by the flag (or I assumed so). Will double-check. |
Already gated: https://github.com/project-chip/connectedhomeip/blob/master/src/lib/dnssd/Discovery_ImplPlatform.cpp#L41 so the change to make size 0 should disable it. |
PR #16029: Size comparison from 3382a5f to 1d90e31 Decreases (38 builds for cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, p6, telink)
Full report (38 builds for cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, p6, telink)
|
Problem
DNSSD caching is not consistent : extra caching layers (both case and platform), likely doubling platform caches, no cache expiry, missing where we really need it (device side where platform service does not exist).
see #11632 and #12762
Change overview
Set cache size to 0, add more ifdefs. This is in preparation to removing it everywhere or moving it to a central place, in which case we either delete or reuse the DNSSD class.
Testing
CI will validate, expect smoke tests to also pick it up to validate.