Cache-Aside
Lazy-load data into a cache the application controls, keep the database as source of truth, and treat invalidation as the hard part — the stampede and the stale-write race — with a correct TypeScript loader.
Lazy-load data into a cache the application controls, keep the database as source of truth, and treat invalidation as the hard part — the stampede and the stale-write race — with a correct TypeScript loader.
Command Query Responsibility Segregation splits the write and read sides of a system so each can be modeled, scaled, and optimized independently — without inheriting Event Sourcing.
The default data-access pattern as a deliberate choice, not an absence of one: what one shared model buys you, the four failure modes that eventually break it, and the signals you have outgrown it.
Store state as an append-only log of immutable events, not a mutable row. Rebuild any past state, get audit for free, and pay for it in query and versioning complexity.
The textbook protocol for atomic commit across multiple resources: how prepare-then-commit works, why a coordinator crash can block participants indefinitely, and where 2PC is still the right answer.