3 ms·
This came up again during http2. The browser vendors just aren't willing to take on the extra latency at the start of the request.
by merbpoll 11y ago
This came up again during http2. The browser vendors just aren't willing to take on the extra latency at the start of the request.
- deleted 11y ago[deleted]
- zrm 11y agoWhere is the extra latency? You can do DNS queries for example.com and _http._tcp.example.com concurrently so that you get both answers in the time of one round trip to the DNS server. If there actually is a SRV record and the target isn't locally cached then you would need to do another query, but that is faster than establishing an HTTP session with example.com, getting the 301 redirect and then having to do the query anyway.
- merbpoll 11y agoThey didn't want to wait for multiple queries to finish. If you're interested in a detailed rationale you can take a look through the mailing list archives (though it'll be frustrating reading).
- spc476 11y agoAnd that's because the major DNS servers don't bother with answering more than one question per query. Nothing in the DNS specification limits the number of questions to one. The only down side might be that the response to multiple questions might not fit in the standard UDP DNS packet.
- merbpoll 11y agoDNS servers can't answer more than one question per query because NXDOMAIN is signalled in the message header and so when QDCOUNT is greater than one the response becomes ambiguous.