Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@haircommander
Copy link
Member

What type of PR is this?

/kind bug

What this PR does / why we need it:

there are still two cases where the container state isn't checked atomically: container start and sandbox remove

fix these cases, so we don't risk updating state based on stale data

Which issue(s) this PR fixes:

Special notes for your reviewer:

Does this PR introduce a user-facing change?


@openshift-ci-robot openshift-ci-robot added kind/bug Categorizes issue or PR as related to a bug. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. labels Jun 10, 2020
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: haircommander

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jun 10, 2020
@codecov
Copy link

codecov bot commented Jun 10, 2020

Codecov Report

Merging #3864 (339ae08) into master (61d79c8) will increase coverage by 0.00%.
The diff coverage is 0.00%.

@@           Coverage Diff           @@
##           master    #3864   +/-   ##
=======================================
  Coverage   40.54%   40.54%           
=======================================
  Files         109      109           
  Lines        8798     8804    +6     
=======================================
+ Hits         3567     3570    +3     
- Misses       4913     4914    +1     
- Partials      318      320    +2     

there are still two cases where the container state isn't checked atomically: container start and sandbox remove

fix these cases, so we don't risk updating state based on stale data.

Signed-off-by: Peter Hunt <[email protected]>
@haircommander
Copy link
Member Author

I will get to this after #3868, I think we need an internal UpdateContainerStatus()

}

func (c *Container) ShouldBeStarted() error {
if c.state.Status == ContainerStateCreated {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we check if the container is in running state as well? If not, can we rename the function to ShouldBeCreated? ShouldBeStarted makes me think that running state is valid as well.

@openshift-ci-robot
Copy link

@haircommander: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/openshift-jenkins/critest_fedora 339ae08 link /test critest_fedora
ci/openshift-jenkins/critest_rhel 339ae08 link /test critest_rhel
ci/openshift-jenkins/integration_fedora 339ae08 link /test integration_fedora
ci/openshift-jenkins/integration_crun 339ae08 link /test integration_crun
ci/openshift-jenkins/integration_crun_cgroupv2 339ae08 link /test integration_cgroupv2
ci/openshift-jenkins/integration_rhel 339ae08 link /test integration_rhel
ci/openshift-jenkins/e2e_features_fedora 339ae08 link /test e2e_features_fedora
ci/openshift-jenkins/e2e_crun 339ae08 link /test e2e_crun
ci/openshift-jenkins/e2e_fedora 339ae08 link /test e2e_fedora
ci/kata-jenkins 339ae08 link /test kata-containers
ci/openshift-jenkins/e2e_rhel 339ae08 link /test e2e_rhel
ci/openshift-jenkins/e2e_crun_cgroupv2 339ae08 link /test e2e_cgroupv2
ci/openshift-jenkins/e2e_features_rhel 339ae08 link /test e2e_features_rhel
ci/prow/launch-aws 339ae08 link /test launch-aws
ci/prow/e2e-aws 339ae08 link /test e2e-aws

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@openshift-merge-robot
Copy link
Contributor

@haircommander: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/e2e-agnostic 339ae08 link /test e2e-agnostic

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@haircommander
Copy link
Member Author

replacing this with #4406

@haircommander haircommander deleted the atomic-start-remove branch September 27, 2021 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. kind/bug Categorizes issue or PR as related to a bug.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants