Phase 8 / 90 days

Cache only the parts that are actually hot.

Use measurement to decide where Redis or Valkey helps, then teach TTLs, invalidation, rate limits, and load testing.

Make performance work evidence-driven.

This phase introduces caching after the app has endpoints worth measuring. The learner should see why caching is useful and why it creates new failure modes.

  • Cache hot community metadata.
  • Cache selected feed responses with TTLs.
  • Add rate limits for sensitive actions.
  • Run simple load tests and compare before/after results.
  • Redis or Valkey.
  • Cache keys, TTLs, and invalidation.
  • Connection pooling.
  • Load testing and slow endpoint measurement.

Expansion prompt

Identify one endpoint that is safe to cache.
Add Redis or Valkey caching with a clear TTL.
Explain what can go stale and how invalidation works.
Add a simple before/after measurement.
  • The app caches a small number of hot reads.
  • Stale data behavior is understood and documented.
  • Rate limits protect expensive or abusive actions.
  • The learner knows why caching is not free simplicity.