Bibek Joshi

5 posts found

Designing a Multi-Layer Caching Strategy in Django with Redis
13 min read

Designing a Multi-Layer Caching Strategy in Django with Redis

Database queries are the primary performance bottleneck in many Django applications. In this guide, we build a practical multi-layer caching strategy using Redis. Starting with a baseline Django API, we measure response times, introduce caching step-by-step, and analyze how each caching layer improves performance while addressing cache invalidation, data consistency, and production pitfalls.

Designing a Production-Ready FastAPI Project Structure
8 min read

Designing a Production-Ready FastAPI Project Structure

Building a FastAPI application that survives the jump to production is about far more than writing fast endpoints. Folder layout, async database setup, environment configuration, middleware, testing, and Docker all need to work together from day one. This guide walks you through every layer of a production-grade FastAPI project with working code you can copy directly into your own setup.