A typical DNS query to a resolver
"A typical DNS query to a resolver" is right. DNS queries normally use UDP on port 53. The query is one small question and one small answer, so a TCP handshake (the setup messages before a connection opens) is not worth the extra time. DNS switches to TCP for large responses and for zone transfers (copying a whole DNS zone between servers).
"An SSH session", "A PostgreSQL client connection" and "An HTTP/1.1 request" are wrong. They all need a reliable, ordered stream of bytes, so they run on TCP.
Read more
- RFC 1035 (https://www.rfc-editor.org/rfc/rfc1035)rfc-editor.org
- UDP (MDN) (https://developer.mozilla.org/en-US/docs/Glossary/UDP)developer.mozilla.org