Background upload of an IFormFile to Azure blob storage
I have a few endpoints that are dealing with files in my app. Some of them may accept
IFormFileCollection or regular IFormFile. During the request hanlding content of those files is being uploaded to azure blob storage. The problem I encountered is that process of uploading to the blob storage can take 3-5 seconds. Are there any options to upload files in the background and return after persisting data to the db? As far as I understand it would be a bad practice to reference/use IFormFile after returning response the the client, so just creating a background job and passing it as a reference would not be an option