supabase / storage

S3 compatible object storage service that stores metadata in Postgres
https://supabase.com/docs/guides/storage
Apache License 2.0
711 stars 103 forks source link

Add `file_metadata` field to objects schema #439

Open bombillazo opened 4 months ago

bombillazo commented 4 months ago

Feature Request

Currently, the objects schema in the Storage API schema is a light abstraction over the S3 storage. There is a metadata column in the objects table, but it corresponds to the metadata of the S3 file and cannot be used by the user. The API does not expose any way to add related metadata to a file to the objects directly. This metadata would ideally be in JSON format to contain user-determined data. Currently, the user needs to get around this limitation by either:

The storage API should natively support metadata, and the API / JS clients should be updated to enable this powerful and common feature for file storage management. My proposal is to add a new column called file_metadata to differentiate it to the current metadata field.

fenos commented 4 months ago

@bombillazo I generally agree that allowing Storing arbritary metadata could be a nice feature to have in Storage. Will add this on the roadmap! 🎉

logemann commented 3 months ago

strong agree on adding custom metadata per storge object. Having to maintain a mirror table just for additional data is a pain, especially the lack of usable triggers to keep both sides in sync.

dmbr0 commented 3 months ago

+2 for this. I would definitely like this. would like to tag files that are being uploaded.

Razikus commented 3 months ago

+1

zhanziyang commented 3 months ago

+1 for this

joe-ashwell commented 3 months ago

Also +1

oleva commented 3 months ago

Would make multi tenant systems a lot easier to manage. Ie. tenants quota. | +1

lecramr commented 3 months ago

+1

danvoyce commented 2 months ago

+1000000000

I'm currently having to add metadata into my file names, so would love to clean up this mess!

momongah commented 2 months ago

+1 for this. I'm currently working with AI generated images and need to store the prediction parameters that generated each image. Otherwise I gotta use AWS S3 cuz I know they have metadata feature.

KindArt commented 2 months ago

+1

ykoitzsch commented 2 months ago

+1 looking forward to this

vatanak10 commented 1 month ago

+1

loringabriel commented 1 month ago

+1

PremchandGat commented 1 month ago

+1 looking for same

normanyu commented 1 month ago

This would improve my workflow with supabase as well. Right now, I need to keep a separate table and keep it in sync every time i upload, move or delete objects.

Gbillington1 commented 1 month ago

+1

I switched from self hosting to supabase, closed down my own s3 bucket to use supabase storage, and now I can't store metadata on the objects... Please please please add this functionality!

Protonosgit commented 1 month ago

+1 seems very helpful!!

patra0o commented 3 weeks ago

+1

fahad-frontend commented 3 weeks ago

+999 would really help out majorly in making supabase storage my go to for all apps. Currently having to use alternatives despite using supabase db and auth

tusamni commented 2 weeks ago

Great request.

bombillazo commented 2 weeks ago

@fenos on this topic, since we're not sure when we might get this, is it wise to add a custom trigger to the storage schema so that when a DELETE event happens on the objects table, we can automatically delete it in our metadata table?

These are the types of things having a dedicated file_metadata field would prevent so we wouldn't have to sync data and resources across tables.

Aadilhassan commented 1 week ago

+1

Toshiro00 commented 4 days ago

+1 it could prevent extra table for metadata