DataDog / extendeddaemonset

Kubernetes Extended Daemonset controller
Apache License 2.0
98 stars 13 forks source link

fix: avoid to flag an ERS as stuck if rollout is done #140

Closed clamoriniere closed 2 years ago

clamoriniere commented 2 years ago

What does this PR do?

Set only to true SetRollingUpdateStuckMetric when we are unable to delete pods but we still have some pods to delete

Motivation

ers_rolling_update_stuck can run 1 even if the rolling update is done. because it only check if we can delete pods. But in some case, for example a cluster scale up. we can reach the point that we have more unavailable pods than expected.

Additional Notes

Anything else we should know when reviewing?

Describe your test plan

Write there any instructions and details you may have to test your PR.

codecov-commenter commented 2 years ago

Codecov Report

Merging #140 (9a790db) into main (9f0d05b) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #140   +/-   ##
=======================================
  Coverage   62.38%   62.38%           
=======================================
  Files          41       41           
  Lines        2193     2193           
=======================================
  Hits         1368     1368           
  Misses        717      717           
  Partials      108      108           
Flag Coverage Δ
unittests 62.38% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...endeddaemonsetreplicaset/strategy/rollingupdate.go 82.94% <100.00%> (ø)

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 9f0d05b...9a790db. Read the comment docs.