Google Drive vs Saving Media in the DB as BLOB

I’m working on a project that needs to contain and present rich text, videos, images etc.
I’m considering what’s the most preferred method of organizing my files / my media as it’s called here.

From my simple understanding so far, I understand from this doc that basically I can just make a folder tree under my google drive, put everything in there via standard google drive and access it via simple Anvil API.

Also reading this, and if I understand correctly, media objects are used as an abstract layer for representing the files/media/assets with a single API (including the files retrieved from google drive).

That being said, in a very basic step of the docs, it says that media objects can be saved as BLOBs into the DB (correct?).

So now the first question that pops into my head is - what method of containing my media is most preferred?
Should I keep it all as media blobs in the DB with media type columns?
Should I just easily organize all of my files in my own google drive, away from anvil’s infrastructure/DB?
Should I (probably not) save my media in both places?

Assuming I’m going to work with around 5-10 GB of data (that is few hundreds MBs in docs and images and the rest in 1080p video files).
Assuming I’m going to need to present the user with multiple files at the same time, but not more than 10 files per page (plus-minus).

I didn’t find any topic in the forum right now nor in the docs which recommend or explains how to make a smart choice between the tools/options for my own purpose, so I’m asking here now.

P.S
I also couldn’t find a clear explanation regarding the limitation of each method (Google/DB), in a comparison kinda way. I guess it could also have answered this question so unless there is something like that, I think it would be nice to add.

Based on the size of your files, you will likely need Google Drive to store your media. Please see below:

Size limitations aside, I default to using Anvil Data tables since I get all of the DB functionality along with some (limited) storage of media.

If necessary, you could combine the two approaches by storing files in Google drive and maintaining their relationship to other data by storing their corresponding file IDs in Anvil DataTables.

3 Likes

Makes sense. Thank you!