Repository navigation
resolved: make maximum transaction attempts 1 for non-probe MDNS requests - #22753
Conversation
| /* Maximum attempts to send MDNS requests is one except for probe requests, see RFC 6762 Section 8.1 */ | ||
| #define MDNS_TRANSACTION_ATTEMPTS_MAX 1 | ||
|
|
||
| #define MDNS_PROBE_TRANSACTION_ATTEMPTS_MAX 3 |
There was a problem hiding this comment.
RFC 6762 Section 8.1 says about probe requests. Where can I find that other requests should be tried only once?
Could you update comment more, e.g. quoting a relevant sentence in the RFC?
There was a problem hiding this comment.
The RFC doesn't explicitly state that a non-probe mDNS query should only be attempted once.
However, since RFC 6762 differentiates between normal (single-shot/continuous) and probe requests, it probably makes sense to fire each normal query only once with no retries.
Otherwise we'd be sending out three attempts for a normal query as well.
The exception of course being probing, which should be attempted a max of 3 times as described in section 8.1.
This also messes with the timing of continuous querying in #22532.
Avahi's implementation is also in line with this.
There was a problem hiding this comment.
This blurb in section 8.1 of RFC6762 also points out the difference in timing restrictions for probe and regular queries.
Note that probing is the one exception from the normal rule that there should be at least one
second between repetitions of the same question, and the interval between subsequent repetitions
should at least double.
There was a problem hiding this comment.
I see. That part indeed implies the regular queries should be tried once. Could you update the comment in the code with quoting the above sentences?
There was a problem hiding this comment.
Updated the comment in the code.
Maximum attempts to send mDNS requests is one except for probe requests, which should be attempted thrice. Implemented fix to account for the difference between regular queries and probe requests, and prevent even regular queries from being attempted thrice. See RFC 6762 Section 8.1
7641fb8 to
b01f76c
Compare
|
Just a heads-up, looks this PR will be reverted in #23875. |
Maximum attempts to send MDNS requests is one except for probe requests. See RFC 6762 Section 8.1
However, TRANSACTION_ATTEMPTS_MAX macro does not account for probe requests.