The existing file upload functionality is too basic and doesn't handle edge cases very well.
Here are a few examples:
If the upload to MinIO fails for whatever reason, the metadata may still be stored in PostgreSQL as if nothing happened and subsequent uploads of the same file may not be possible.
If there already is a file with the same name, the HTTP API responds with a 500 error where a descriptive 4XX error would be more suitable.
The existing file upload functionality is too basic and doesn't handle edge cases very well. Here are a few examples: