File uploads are super slow BECAUSE THEY'RE SENT IN MANY SMALL POST REQUESTS, WTF?!

Did anyone else hit their reverse proxy (nginx / apache / others…) configured request size limit?

These limits may not be easy to raise, for security reasons, especially if the reverse proxy is shared by other servers that don’t need huge file upload capabilities.

1 Like

Normally you would apply the upload size limit to one parrticular vhost.

But I see how splitting the files can help when there is an unchangeable upload limit or the files are larger than the largest upload limit (i.e. 1GB file with 100MB limit on cloudflare free plan)

In this case, it would help a lot if the UploadFS module could upload multiple chunks in parallel.

But if the server upload limit allows, one request will always be fastest I think.

The problem is, the UploadFS thing calculates the progress based on completion of chunks, so if you just set the chunk size really high so it uploads in one chunk, the progress meter will show 0% the entire time, then jump to 100% the moment it’s done.

So I think the UploadFS module needs major changes, but it appears it is now discontinued :man_shrugging:

Well in this case, what is the best way to fix this issue?

Especially on local networks, file upload and download speeds needs to be drastically improved. It’s currently extremely slow. Fixing that first, we can worry about reverse proxies next.

on open.rocket.chat or if you are running develop there is this PR being ran: https://github.com/RocketChat/Rocket.Chat/pull/16617

But… while sending in big chunk… you for sure will hit limits of your proxy for bigger files