refactor: move updateContainerStoppedLabel to containerutil#1890
Conversation
Signed-off-by: Hsing-Yu (David) Chen <davidhsingyuchen@gmail.com>
1560e93 to
eec294d
Compare
|
We're doing some works that are the same. I refactored the container start in PR #1864, but I discovered that the CL is enormous, which made it difficult for reviewers to review. So,I am breaking it down into multiple PRs such as #1882, #1891 and so on. Once one PR is merged, I will proceed with the next one. |
Oh I see, I checked the open PRs yesterday, and it seems that #1864 was just reopened today. I will stop creating PRs for those items.
Maybe they can be done in parallel as the refactoring blocks not only |
|
SGTM. |
PR is a blocker of refactoring
container stopandcontainer startas part of #1680.Thought process:
Containerfrom the function name to avoid stuttering with the package name (i.e.,containerutil). Also, one of the parameters iscontainer containerd.Container, so the semantics should be already clear.stopped boolis a bit misleading as it seems to say whether the container is stopped, but the point is to convey whether the container is explicitly stopped so that containerd can decide if the container should be restarted. As a result, I renamed the parameter and the function accordingly.Please let me know if I should do this in a follow-up PR instead, or it just doesn't make sense and shouldn't be done at all, thanks!
Signed-off-by: Hsing-Yu (David) Chen davidhsingyuchen@gmail.com