webiny-js icon indicating copy to clipboard operation
webiny-js copied to clipboard

504 error from CloudFront on large video/mp4 files

Open gil-3bd opened this issue 3 years ago • 0 comments

Version

5.30.0

Operating System

macOS Monterey 12.4

Browser

Google Chrome

What are the steps to reproduce this bug?

When uploading a large (1GB) video/mp4 file through File Manager, the files upload successfully but when I try to access or load the file via the "File Details" URL the files don't load and eventually I get a 504 error from CloudFront. However, if the file is under 50MB they load correctly.

What is the expected behavior?

When loading any video/mp4 file from example url https://uniqueurl.cloudfront.net/files/videofile.mp4 should redirect to the expected url example: https://fm-bucket-00000.s3.amazonaws.com/videofile.mp4 without any timeout 504 errors from CloudFront.

What do you see instead?

Timeout 504 error from CloudFront

Additional information

No response

Possible solution

Figure out how to handle large video/mp4 files download in the download lambda function.

gil-3bd avatar Aug 08 '22 19:08 gil-3bd

Upgrading to Webiny v5.31.0 has fixed the 504 Error when accessing large files in the File Manager.

gil-3bd avatar Aug 25 '22 21:08 gil-3bd

I'm trying to upload a single 5GB file (not multiple) via the File Manager but now I’m getting an error that reads “Multiple max size exceeded.” even after increasing the "Maximum file upload size" value. However, if the file is under 1GB it uploads correctly.

image

It looks like there is a limit of 1000mb fallback to the files here on the code

gil-3bd avatar Aug 26 '22 18:08 gil-3bd

@gil-3bd Good catch. What do you think, should we remove that client side limitation entirely, and let users upload whatever they like? I don't remember when and why, but I think that limitation was defined there completely randomly.

Pavel910 avatar Aug 27 '22 08:08 Pavel910

@Pavel910 I think we should let the users upload whatever they like by defining it in the backend General Settings

gil-3bd avatar Aug 30 '22 15:08 gil-3bd