intermediate
HTTP protocol
Use HTTP versions, methods, status codes, headers, cookies, caching, compression, and connection reuse deliberately.
HTTP protocol interviews cover versions, methods, status codes, headers, cookies, caching, compression, and connection reuse—how clients and servers actually negotiate behavior.
Subtopics: HTTP versions, methods and status codes, headers and cookies, caching and compression, and keep-alive with connection reuse.
On interviews: compare HTTP/1.1 head-of-line blocking with HTTP/2 multiplexing, pick status codes for validation vs auth failures, and explain Cache-Control trade-offs.
Common pitfalls: wrong idempotency assumptions on methods, cookies without Secure/SameSite, and caching personalized responses without Vary.
Checklist:
- Map methods to safety and idempotency.
- Use headers deliberately for auth, caching, and security.
- Design cache keys and invalidation with validators.
- Reuse connections; align timeouts with upstream pools.