HTTP Semantics: Method Idempotency and Safety¶
Classifying operations by whether they are safe (no side effects) and idempotent (repeatable without different effect) enables caching, retry logic, and client optimization; these properties are semantic contracts independent of implementation.
Tension Addressed¶
Reliability vs. Latency (enables safe retries)
Recognizable As¶
GET vs. POST decisions, read vs. write operations, query vs. command separation (CQRS), idempotency keys in APIs
Canonical Sources¶
Fielding et al., RFC 7231 HTTP/1.1 Semantics (2014); Fielding REST dissertation (2000)
Transfers To¶
API design, database operations, distributed systems, CQRS, event sourcing, cache invalidation strategies
Sub-concepts: - Safe methods: Can be cached and prefetched freely - Idempotent methods: Can be retried automatically on failure - Non-idempotent operations: Require application-level deduplication if reliability is needed
Related Concepts¶
- Idempotency - Distributed Patterns