docker-archive / deploykit

A toolkit for creating and managing declarative, self-healing infrastructure.
Apache License 2.0
2.25k stars 262 forks source link

Handle stale swarm version in swarm store #854

Closed kaufers closed 6 years ago

kaufers commented 6 years ago

On startup the manager plugin attempts to write to the backend store. In swarm mode this can fail with:

Error response from daemon: rpc error: code = 2 desc = update out of sequence

This commit detects this error, retrieves an updated version, and attempts it again (up to 10 times with an increasing wait time).

codecov[bot] commented 6 years ago

Codecov Report

Merging #854 into master will decrease coverage by 0.12%. The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #854      +/-   ##
==========================================
- Coverage   48.52%   48.39%   -0.13%     
==========================================
  Files          89       88       -1     
  Lines        8020     7965      -55     
==========================================
- Hits         3892     3855      -37     
+ Misses       3771     3758      -13     
+ Partials      357      352       -5

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 014a8ac...09d9b9f. Read the comment docs.