Thuta Learning
Firebase Tutorial
AdvancedDevOps & Toolsအလယ်အလတ်

Cloud Storage ဆိုတာဘာလဲ?

Firebase Tutorialသင်ခန်းစာ 20

Cloud Storage ဆိုတာဘာလဲ?

Cloud Storage က user upload လုပ်တဲ့ files တွေကိုသိမ်းဖို့ Firebase service ဖြစ်ပါတယ်။ Profile avatar, product image, PDF, audio, video, receipt image စတာတွေကိုသိမ်းနိုင်ပါတယ်။ Firestore က text/data သိမ်းဖို့ကောင်းပြီး Storage က file သိမ်းဖို့ကောင်းပါတယ်။

Firestore နှင့် Storage ကို တွဲသုံးပုံ

Image file ကို Storage ထဲတင်ပြီး ရလာတဲ့ download URL သို့မဟုတ် file path ကို Firestore document ထဲမှာသိမ်းပါ။ ဥပမာ user profile document ထဲမှာ avatarUrl field ထည့်ထားနိုင်ပါတယ်။

သတိထားရန်

Upload file size, file type, access permission ကို မစစ်ဘဲထားရင် storage cost တက်နိုင်ပြီး မလိုလားတဲ့ file တွေဝင်လာနိုင်ပါတယ်။ Client-side validation + Security Rules နှစ်ခုလုံးလိုအပ်ပါတယ်။

နောက်ဆုံးပြင်ဆင်ရက်

Progress ကို ဤ browser (ဤစက်) တွင်သာ သိမ်းထားပါသည်။ အခြားစက်များနှင့် sync မလုပ်ပါ။

ဤသင်ခန်းစာတွင် အမှားတွေ့ပါက အကြောင်းကြားရန်သင့် email app ကို ဤသင်ခန်းစာလိပ်စာ ဖြည့်ပြီးသားဖြင့် ဖွင့်ပေးပါမည် — သင်ကိုယ်တိုင် ပို့မှသာ ပို့မည်ဖြစ်သည်။

Cloud Storage ဆိုတာဘာလဲ? | Thuta Learning