Max chunked upload size desktop client and server connection closed

Hi Nextcloud community

I found IMHO an inconsistency between how the Nextcloud desktop client and server are handling chunked file uploads:

What happens now is that for fast upload connections, the chunk size is increased over 512 MB, which then causes the (in my case) nginx server to close the connection for the uploaded chunk. This in turn leads the client to fail the file upload (, until the client is restarted? for another try).

From my point of view, there are different approaches to solve this issue:

  • The client should retry the failed chunk upload with the most recent successfully uploaded chunk size, hence the client’s error handing should be improved
  • Nextcloud client and server should implicitly (both using the same maximal chunk file size in their respective configuration files and documentation) or explicitly (agreement of the same maximal chunk file size e.g. via capabilities API?) communicate and agree upon the maximal chunk file size

The advantage of the first approach would be, that the client would also become more robust with any other transparent intermediate boxes that would limit the maximal upload chunk file size.

What do you think? How do we proceed from here?

Thanks for your inputs