Caching Strategies

Cache-aside, read-through, write-through and where each belongs.

7Questions
15Flashcards
6Terms
Questions

7 to work through

  1. advanced

    A discussion platform has a handful of extremely popular threads receiving most reads and writes, and individual cache nodes become bottlenecks. How should hot-key detection, caching, coalescing, partitioning and asynchronous writes combine?

    3 min answer
  2. advanced

    A popular cache key expires at peak. A thousand concurrent requests miss and hit the database simultaneously, and it falls over. Name three fixes and pick one to deploy first.

    3 min answer
  3. advanced

    A quick-commerce platform holds inventory across hundreds of dark stores that changes continuously. Which inventory data must be strongly consistent, which can be cached, and what should happen at checkout when the cached view is stale?

    2 min answer
  4. advanced

    A social platform has 1% of content receiving 90% of requests. How should adaptive caching, hot-key replication, request coalescing and partitioning work together?

    2 min answer
  5. advanced

    Chat clients download the full workspace user and channel directory on connect. For large workspaces this is slow and expensive. A CDN does not help. Why, and what does?

    2 min answer
  6. advanced

    Design read receipts and unread counts for a messaging product. Why is this harder than it looks?

    2 min answer
  7. advanced

    Uber's Docstore (a sharded MySQL-backed document store) serves reads dominated by recently active trips. CacheFront put Redis in front of it. Why build the cache into the storage layer rather than leaving it to each caller, and how must invalidation, read-your-writes and post-failover warming behave?

    3 min answer
Data Architecture

Neighbouring topics

Data Architecture

General material on structuring, storing and governing data.

10 quiz 31 cards 25 terms

Relational Modelling

Normalisation, keys, constraints and the invariants a schema enforces.

3 quiz 10 cards 4 terms

NoSQL Stores

Key-value, document, wide-column and graph — what each buys and forbids.

5 quiz 13 cards 4 terms

Indexing

Designing indexes per query shape, and paying for them on every write.

5 quiz 12 cards 6 terms

Query Optimisation

Reading a plan, fixing statistics, and finding the real bottleneck.

3 quiz 11 cards 4 terms

Transactions & Isolation

ACID, isolation levels, and the anomalies each level permits.

3 quiz 10 cards 4 terms

Replication

Primaries, replicas, lag, and synchronous versus asynchronous durability.

4 quiz 14 cards 6 terms

Partitioning & Sharding

Splitting data across machines, and the one-way door of a partition key.

6 quiz 12 cards 10 terms

Cache Invalidation

Stampedes, penetration, staleness windows and versioned keys.

3 quiz 7 cards 2 terms

CQRS

Separating the write model from the read models that serve queries.

4 quiz 10 cards 5 terms

Event Sourcing

Storing the change log as the system of record, and what that costs forever.

5 quiz 13 cards 4 terms

Change Data Capture

Turning a database's replication log into a stream, and its coupling risk.

5 quiz 14 cards 5 terms

Data Warehousing

Dimensional modelling, star schemas and analytical workloads.

4 quiz 13 cards 3 terms

Data Lakes & Lakehouses

Open formats on object storage with transactional metadata on top.

4 quiz 11 cards 4 terms

ETL & ELT

Where transformation happens, and how much raw history you keep.

3 quiz 9 cards 3 terms

Streaming Data

Windowing, watermarks, late arrivals and exactly-once semantics.

3 quiz 10 cards 2 terms

Data Governance

Ownership, lineage, quality, catalogues and who may see what.

3 quiz 9 cards 4 terms

Data Lifecycle & Retention

How long data is kept, where it ages to, and how it is actually deleted.

4 quiz 11 cards 5 terms

Polyglot Persistence

Choosing a store per workload, and the operational cost of variety.

6 quiz 12 cards 4 terms