နားလည်ထားရမယ့် အချက်
Redis က network မှတစ်ဆင့်အသုံးပြုသော in-memory data structure server ဖြစ်ပြီး cache၊ session store၊ rate limiter၊ leaderboard၊ event stream နှင့် message broker စတဲ့ workload များကို latency နည်းနည်းနဲ့ဖြေရှင်းနိုင်ပါတယ်။ ဒီ course က Redis Open Source 8.10 ကို reference လုပ်ထားပြီး core commands အများစုက recent Redis 7/8 installations တွင်လည်း အလုပ်လုပ်ပါတယ်။ Redis ကို PostgreSQL အစားထိုးမဟုတ်ဘဲ use case အလိုက်တွဲသုံးမယ်။
လက်တွေ့ scenario နဲ့ ချိတ်ကြည့်မယ်
PostgreSQL က tutorial၊ user၊ enrollment နဲ့ progress ရဲ့ durable source of truth ဖြစ်နေမယ်။ Redis က catalog cache၊ session၊ request counter၊ leaderboard၊ notifications နဲ့ background jobs ကိုကိုင်မယ်။ Lesson တစ်ခုပြီးတိုင်း cache correctness၊ expiry၊ memory၊ durability နဲ့ failure behavior ကိုပါ စဉ်းစားသွားမယ်။
အတူတူ စမ်းရေးကြည့်မယ်
PostgreSQL (source of truth)
↕
Node.js API ── Redis 8.10
├─ catalog cache
├─ sessions & rate limits
├─ leaderboard
└─ streams & notificationsRedis နှင့် PostgreSQL တို့၏တာဝန်ခွဲခြားမှုနှင့် course project ကိုရှင်းပြနိုင်မည်။၅ မိနစ် စမ်းကြည့်
မိမိ app တစ်ခုအတွက် durable data သုံးမျိုးနှင့် Redis ထဲထားနိုင်သော temporary/derived data သုံးမျိုးရေးပါ။
သတိလေးတစ်ချက်
Redis မြန်တယ်ဆိုပြီး critical data အားလုံးကို persistence/recovery plan မရှိဘဲ Redis တစ်ခုတည်းထဲမထားပါနှင့်။