Downloading folder having large files times out

I have FileProvider based MacOS application, where user is trying to copy the folder having mix of small and large files. Large files are having size ~ 1.5 GB from FileProvider based drive to locally on Desktop. Since the folder was on cloud and not downloaded the copy action triggered the download. Small files were downloaded successfully however during large file download the URLSession timed out. We are using default timeout for URLSession which is 1 min. I tried to capture logs Console.app where i found FileProvider daemon errors. PFA

Solutions tried so far:

  1. Increased timeout for URLSession from 5 to 10 mins - configuration.timeoutIntervalForRequest
  2. Set timeout for resource - configuration.timeoutIntervalForResource

It happens when we have low network bandwidth. Network connectivity is there but the bandwidth is low. Any clue by looking at these errors?

Your screenshot shows NSError: Cocoa 3072 "‹private›", which means the operation was cancelled. The error message is private because your device doesn't have the file provider profile installed. You would be able to gather more information by installing the profile.

Assuming you are using NSFileProviderReplicatedExtension, your implementation of fetchContents(for:version:request:completionHandler:) should return a Progress object with a cancellationHandler that calls the completionHandler, as shown in this sample. Did you do that? If you have the progress, and update the progress when the download is ongoing, I won't expect that the system cancels the operation.

Best,
——
Ziqiao Chen
 Worldwide Developer Relations.

Downloading folder having large files times out
 
 
Q