Pub/Sub (Publish-Subscribe) is a messaging pattern in which producers publish messages to a named channel (topic) without knowing who consumes them, and consumers subscribe to topics they care about without knowing who produced the messages. The pattern decouples producers from consumers, enabling fan-out, replay, and asynchronous processing.

How it differs from queues

  • Queue…
Saga

A Saga is a pattern for executing a business transaction that spans multiple services or databases by chaining local transactions together, with compensating actions to roll back partial progress on failure. Sagas replace distributed transactions (two-phase commit) in microservice systems where global ACID across services is impractical.

How it works

A saga breaks a business transaction into a…

Webhook

A webhook is an HTTP callback that one system sends to another to notify it of an event. Instead of the receiver polling for changes, the source POSTs an event payload to a URL the receiver registered ahead of time. Webhooks are the default integration mechanism between SaaS products.

How it works

The receiver registers a URL with the source (in a dashboard or via API). When an event occurs,…

Pagination is the API pattern for splitting a large collection into smaller pages so clients fetch results incrementally. It is one of the universal API design decisions, with consequences for performance, consistency, and the client developer experience.

Common strategies

  • Offset / page-number. ?page=3&limit=20. Simple, supports jumping to arbitrary pages, but slow on large tables and…

HTTP (Hypertext Transfer Protocol) is the application-layer protocol the web runs on. It defines how clients (typically browsers or API consumers) request resources from servers using methods like GET, POST, PUT, and DELETE, and how servers respond with status codes, headers, and an optional body.

How it works

HTTP is a request-response protocol over a reliable transport, traditionally TCP. A…

Page 1