Skip to content

Conversation

tchap
Copy link
Contributor

@tchap tchap commented Oct 1, 2025

pkg/operator/staticpod/internal/atomicdir contains internal helpers for performing atomic operations on directories.

This patch contains only a standalone swap function, which will be subsequenty used for synchronizing directory with the given state.

This splits some logic from #2009

@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Oct 1, 2025
@openshift-ci-robot
Copy link

@tchap: This pull request references Jira Issue OCPBUGS-33013, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.21.0) matches configured target version for branch (4.21.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @wangke19

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

pkg/operator/staticpod/internal/atomicdir contains internal helpers for performing atomic operations on directories.

This patch contains only a standalone swap function, which will be subsequenty used for synchronizing directory with the given state.

This splits some logic from #2009

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 openshift-eng/jira-lifecycle-plugin repository.

// Get the expected state.
state, ok := dir[entry.Name()]
if !ok {
t.Errorf("Directory %q contains unexpected file %q", path, entry.Name())
Copy link
Contributor

Choose a reason for hiding this comment

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

ok, so this will find extra files in path but not in dir

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not sure I understand. Missing files that are in dir but not in path are checked at the end of this function.

pkg/operator/staticpod/internal/atomicdir contains internal helpers for
performing atomic operations on directories.

This patch contains only a standalone swap function, which will be
subsequenty used for synchronizing directory with the given state.
@p0lyn0mial
Copy link
Contributor

/lgtm

Copy link
Contributor

openshift-ci bot commented Oct 1, 2025

@tchap: all tests passed!

Full PR test history. Your PR dashboard.

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-sigs/prow repository. I understand the commands that are listed here.

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Oct 1, 2025
Copy link
Contributor

openshift-ci bot commented Oct 1, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: p0lyn0mial, tchap

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

The pull request process is described here

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 openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 1, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 339f6f0 into openshift:master Oct 1, 2025
4 checks passed
@openshift-ci-robot
Copy link

@tchap: Jira Issue OCPBUGS-33013: Some pull requests linked via external trackers have merged:

The following pull request, linked via external tracker, has not merged:

All associated pull requests must be merged or unlinked from the Jira bug in order for it to move to the next state. Once unlinked, request a bug refresh with /jira refresh.

Jira Issue OCPBUGS-33013 has not been moved to the MODIFIED state.

In response to this:

pkg/operator/staticpod/internal/atomicdir contains internal helpers for performing atomic operations on directories.

This patch contains only a standalone swap function, which will be subsequenty used for synchronizing directory with the given state.

This splits some logic from #2009

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 openshift-eng/jira-lifecycle-plugin repository.

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. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants