Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Further improve resilience of image pulls
Previously, we'd time-out a pull operation after unsuccessfully retrying for about 17 minutes (for details see commit 582487f). This worked fine in most situations, but we have seen at least one case of a particularly unreliable network connection that would not be able to finish a large pull when operating under this policy. This commit: * Completely removes timeouts from image pulls. We'll keep retrying forever, or until users cancel the pull. (From the perspective of the REST API, "canceling" mean closing the HTTP connection. This is what happens when a user Ctrl+C during a pull in the CLI, or, say, we kill a curl process that was using the REST API to pull image.) * Still uses exponential back-off, but we now limit the interval between retries to 5 minutes. The rationale is that some very unreliable networks may be up only for relatively small time windows. Therefore, using intervals that are too long would increase the risk of missing these windows. * Tries to avoid flooding the log stream with messages about retries. We'll log every retry attempt up to the 10th. After that, we'll log retries only once about every 2h. This retry count is reset every time we successfully download any amount of data. Signed-off-by: Leandro Motta Barros <[email protected]> Change-type: patch
- Loading branch information