engineering
Dispatch
The reflex when an application gets slow is to add a cache, and the reflex when adding a cache is to reach for Redis. Both reflexes are often wrong. The database is faster than most developers think, and the cache is slower than they assume.
engineering
Dispatch
An audit log is one of those features that looks easy from the outside and reveals its difficulty only when you need it. The first time someone asks 'who changed this and when?' you discover whether your audit log was designed for query or for ceremony. Here is what separates the two.
engineering
Dispatch
Every new microservice, worker, and serverless function quietly consumes a database connection. The math eventually catches up with you. Here is how connection budgets actually work, why connection storms cause cascading outages, and what to do before you hit the wall.
engineering
Dispatch
Edge caching can make a slow API feel instant or quietly serve stale data to half your customers. The difference between the two outcomes is mostly about three Cache-Control directives, the Vary header, and a clear-eyed view of what you actually want cached. Most surprises in production come from...
engineering
Dispatch
Most backup strategies have a bug, and the bug is that nobody has tested the restore. This is the field guide we wish someone had given us before we discovered the bug ourselves: what to back up, where to store it, how to test the restore, and the small set of rules that turn a backup from a comf...
engineering
Dispatch
A circuit breaker is a small piece of code that tracks whether a downstream dependency is healthy and refuses to call it when it isn't. The implementation is fifty lines. The judgment about thresholds, half-open recovery, and which calls deserve a breaker is what separates a useful tool from a fa...
engineering
Dispatch
Distributed tracing has a reputation for complexity that scares small teams away from adopting it. The reputation is wrong about the minimum case. A request ID propagated through your services and a 50-line Jaeger setup gets you 80% of the value, and you can grow from there.
engineering
Dispatch
Most database indexes are B-trees. Most queries that need an index are well served by one. The interesting indexes are the others, the ones for full-text search, geographic queries, append-only time-series, and JSON containment. Knowing when each helps separates the developer who writes WH
engineering
Dispatch
Every webhook is a promise that something happened, traveling over a network that is permitted to forget. The vocabulary of guarantees (at-most-once, at-least-once, exactly-once) is the wrong starting point. The right starting point is the question of which lies you are willing to tell to whom.
engineering
Dispatch
Every API hits the moment when a change is necessary, the change is breaking, and clients in the wild cannot be updated atomically. The wrong response is to deploy and pray. The right response is a versioning strategy chosen before the first breaking change, not after it.
engineering
Dispatch
Two requests arrive at the same row. Both want to update it. Without a strategy, one of them silently overwrites the other and you have a lost update. The two strategies that solve this are pessimistic and optimistic locking, and the choice between them is a load and contention question.
engineering
Dispatch
A queue is the right starting point for async work. It is also where most teams stop. The patterns that actually carry production weight are chained jobs, fan-out / fan-in, sagas, and idempotent retries. Here is when each one applies and how to wire it up without a heavy framework.