File should get download with actual filename and extension after hitting downloadUrl
Problem Statement
Currently, the file service stores file in the persistent location with some random name and without extension. When we download the file using download SignedURL, it's download without extension and to see the content of the file we need to explicitly give an extension.
Solution
We can overcome this problem by adding Content-Disposition and Content-Type header at the time of download signed URL creation. We can get file name from file metadata payload and based on file extension we can get content type of the file, both name and content type we can use to create download URL.
Note: the name field in the metadata payload is optional and if it is not present in the payload, then the above solution won't work for that and follow the current implementation of download URL creation.