Skip to the page

Cloud and operations · 24 concepts

APIs and observability

GraphQL, gRPC, real-time APIs, Elasticsearch, Nginx and gateways, metrics and traces, and OAuth, past the backend basics and at interview depth.

Part 1 · 5 concepts

GraphQL in production

  1. 01

    The N+1 problem and DataLoader

    GraphQL runs a resolver once for every object in a list, so a naive server sends one SQL query per object. A DataLoader created for each request collects the keys asked…

  2. 02

    Limits, query cost and trusted documents

    One GraphQL request can ask for a huge amount of work, so a request-count rate limit is not enough. Limit depth, aliases and list sizes, add a cost limit per client…

  3. 03

    Schema design and changing a schema safely

    A schema is a contract with every client already installed. Design nullability, money and pagination on purpose, and change fields in ways old apps survive: add, never…

  4. 04

    Authorization and caching in GraphQL

    REST gives you one check per route and a cache per URL. GraphQL has one endpoint and many paths to the same object, so you check access on each field or object and you…

  5. 05

    Federation, and when GraphQL is the wrong choice

    When many teams own one graph, a router composes subgraphs into a supergraph. For partner APIs, uploads and service-to-service calls, REST or gRPC is often a better fit.

Part 2 · 6 concepts

gRPC, real-time APIs and webhooks

  1. 06

    gRPC calls and Protobuf

    gRPC sends Protobuf messages over HTTP/2 with a typed contract. It has four kinds of call, and its status codes and trailers replace HTTP status codes.

  2. 07

    Changing a proto without breaking old clients

    Protobuf puts field numbers and wire types on the wire, not names. You may add fields with new numbers, and you must never reuse, renumber or change the type of an…

  3. 08

    gRPC in production: deadlines, retries and load balancing

    gRPC waits forever unless you set a deadline, retries multiply load when they stack, and a normal Kubernetes Service balances connections, not calls, so traffic piles…

  4. 09

    Choosing and scaling real-time: polling, SSE and WebSocket

    Pick the simplest tool that fits: cached polling for one shared slow-changing value, SSE for one-way updates, WebSocket for two-way or very frequent updates. Scaling…

  5. 10

    Long-lived connections: heartbeats and resuming

    Every proxy and load balancer on the path has an idle timeout, so connections need heartbeats. After a drop, clients must be able to resume from the last event they saw.

  6. 11

    Webhooks: delivery, retries and signatures

    A webhook is at-least-once delivery over HTTP. Senders use an outbox, per-endpoint queues, backoff and a signature. Receivers answer fast, verify the signature on the…

Part 3 · 4 concepts

Search and Elasticsearch

  1. 12

    The inverted index, analyzers and mappings

    Elasticsearch finds documents by looking up terms in an inverted index. Analyzers decide the terms, and the mapping decides whether a field is searched as text or…

  2. 13

    Writing product search and tuning relevance

    A good product search combines a scored full-text query with exact filters and business signals. When ranking looks wrong, ask Elasticsearch why with explain, then…

  3. 14

    Keeping the index in sync and reindexing without downtime

    The database owns the data and the search index is a copy. Use an outbox or change data capture to feed it, order events by version, and change mappings by building a…

  4. 15

    Shards, replicas and cluster health

    An index is split into primary shards, each with replicas. The number of primaries is fixed at creation, and red means a primary shard has no home.

Part 4 · 3 concepts

Nginx and API gateways

  1. 16

    What Nginx does in front of your app, and how proxying fails

    Nginx is a reverse proxy: it ends TLS, buffers slow clients, routes by host and path and balances load. Many production bugs come from DNS caching, certificate chains…

  2. 17

    Rate limits and reviewing an Nginx config

    limit_req uses a leaky bucket per key. Choose the key carefully behind a load balancer, add a burst, return 429, and know how proxy_pass changes the path.

  3. 18

    API gateways, Ingress and service meshes

    A gateway handles keys, quotas and routing for outside callers. An ingress or Gateway API implementation routes traffic into a Kubernetes cluster. A mesh handles…

Part 5 · 3 concepts

Observability for developers

  1. 19

    Metric types, PromQL and cardinality

    A counter only goes up, a gauge moves both ways, and a histogram counts observations into buckets. Use rate() on counters, histogram_quantile on bucket rates, and keep…

  2. 20

    Incident dashboards and SLO burn-rate alerts

    A dashboard for an incident answers who is hurting and what changed. SLO alerts page on how fast the error budget is burning, over a long and a short window together.

  3. 21

    Logs, traces and the OpenTelemetry Collector

    Logs and traces travel through a pipeline that can fall behind or lose data. The OpenTelemetry Collector receives, limits, samples and exports telemetry, and traces…

Part 6 · 3 concepts

OAuth, tokens and login providers

  1. 22

    Which OAuth flow for which client, and why users get logged out

    Use the authorization code flow with PKCE for apps with a user, client credentials for machines, and the device flow for TVs. Keep users signed in with refresh token…

  2. 23

    Validating tokens, scopes and API keys

    An API must verify the signature, issuer, audience and expiry of every token, accept access tokens and not ID tokens, and still check that the caller may touch this…

  3. 24

    Identity providers, SAML SSO and service identity

    Choose build, buy or host for login by features, cost at scale and exit path. Enterprise customers bring SAML, and services call each other with their own identities…

Your first interview is free

Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.

Start your free interview