Skip to content

[release-4.21] OCPBUGS-74418: Add KMS test scenarios#844

Merged
openshift-merge-bot[bot] merged 2 commits intoopenshift:release-4.21from
gangwgr:backport-kms-cases-4.21
Mar 4, 2026
Merged

[release-4.21] OCPBUGS-74418: Add KMS test scenarios#844
openshift-merge-bot[bot] merged 2 commits intoopenshift:release-4.21from
gangwgr:backport-kms-cases-4.21

Conversation

@gangwgr
Copy link
Contributor

@gangwgr gangwgr commented Feb 24, 2026

Backport kms test cases to 4.21

@coderabbitai
Copy link

coderabbitai bot commented Feb 24, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 310c4d4f-b115-4e69-8af8-1472c9dd19bc

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

@gangwgr gangwgr changed the title Backport kms cases 4.21 [release-4.21] OCPBUGS-74418: Add KMS test scenarios Feb 24, 2026
@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 Feb 24, 2026
@openshift-ci-robot
Copy link
Contributor

@gangwgr: This pull request references Jira Issue OCPBUGS-74418, which is valid.

7 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.21.z) matches configured target version for branch (4.21.z)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)
  • release note type set to "Release Note Not Required"
  • dependent bug Jira Issue OCPBUGS-68343 is in the state Verified, which is one of the valid states (VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA))
  • dependent Jira Issue OCPBUGS-68343 targets the "4.22.0" version, which is one of the valid target versions: 4.22.0
  • bug has dependents

Requesting review from QA contact:
/cc @gangwgr

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

Details

In response to this:

Backport kms test cases to 4.21

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.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Feb 24, 2026

@openshift-ci-robot: GitHub didn't allow me to request PR reviews from the following users: gangwgr.

Note that only openshift members and repo collaborators can review this PR, and authors cannot review their own PRs.

Details

In response to this:

@gangwgr: This pull request references Jira Issue OCPBUGS-74418, which is valid.

7 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.21.z) matches configured target version for branch (4.21.z)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)
  • release note type set to "Release Note Not Required"
  • dependent bug Jira Issue OCPBUGS-68343 is in the state Verified, which is one of the valid states (VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA))
  • dependent Jira Issue OCPBUGS-68343 targets the "4.22.0" version, which is one of the valid target versions: 4.22.0
  • bug has dependents

Requesting review from QA contact:
/cc @gangwgr

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

In response to this:

Backport kms test cases to 4.21

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.

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.

@openshift-ci openshift-ci bot requested review from ibihim and liouk February 24, 2026 11:12
@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch 5 times, most recently from 573e9c0 to 35e6e8e Compare February 24, 2026 12:20
@ardaguclu
Copy link
Member

@gangwgr these need to be fixed;

vet: test/e2e-encryption-kms/encryption_kms_test.go:80:132: undefined: library.SupportedStaticEncryptionProviders
make: *** [vendor/github.com/openshift/build-machinery-go/make/targets/golang/verify-update.mk:27: verify-govet] Error 1
diff -Naup vendor/github.com/openshift/api/authorization/v1/zz_generated.crd-manifests/0000_03_config-operator_01_rolebindingrestrictions.crd.yaml bindata/oauth-openshift/authorization.openshift.io_rolebindingrestrictions.yaml

I think you may need to run make update and run goimport on encryption_kms_test.go

@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch from 35e6e8e to e03203f Compare February 25, 2026 06:05
@gangwgr
Copy link
Contributor Author

gangwgr commented Feb 25, 2026

/retest

@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch from e03203f to e0cd1a5 Compare February 25, 2026 06:20
go.mod Outdated
)

// PR 2131: OCPBUGS-74418 add KMS test helpers (release-4.21)
replace github.com/openshift/library-go => github.com/gangwgr/library-go v0.0.0-20260225055023-b41850fe248b
Copy link
Contributor

Choose a reason for hiding this comment

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

this needs to be updated.

/hold

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Mar 3, 2026
@p0lyn0mial
Copy link
Contributor

/approve
/label backport-risk-assessed

We don't need an SBAR for the TP backport.

This PR matches openshift/cluster-kube-apiserver-operator#2054 and openshift/cluster-openshift-apiserver-operator#656

/assign @liouk

@openshift-ci openshift-ci bot added the backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. label Mar 3, 2026

tests := *realPtrToTests

rand.Seed(time.Now().UnixNano())
Copy link
Member

Choose a reason for hiding this comment

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

nit: rand.Seed() is a no-op on 1.24, which is the current go version unless I'm mistaken -- we could drop this.

Copy link
Contributor

Choose a reason for hiding this comment

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

see my previous comment.

)

func TestMain(m *testing.M) {
randomizeTestOrder(m)
Copy link
Member

Choose a reason for hiding this comment

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

Instead of randomizing manually, I wonder whether we could leverage go's -test.shuffle -- then we wouldn't have to resort to such hacks, as they're quite fragile. Has this been considered?

Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like this could be replaced.

This change would not only apply specifically to the KMS tests but to all encryption tests.

Here is my proposal since this is a backport PR, let's merge it as it is, and then apply your suggestions to the master branch for all encryption tests across all repositories that use encryption.


// TestKMSEncryptionOnOff tests KMS encryption on/off cycle.
// This test:
// 2. Creates a test OAuth access token (TokenOfLife)
Copy link
Member

Choose a reason for hiding this comment

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

nit: list numbering starts at 2

@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch 3 times, most recently from e0cd1a5 to d44ddaf Compare March 3, 2026 15:15
@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch from d44ddaf to e1f994b Compare March 3, 2026 15:29
@gangwgr
Copy link
Contributor Author

gangwgr commented Mar 4, 2026

/retest

github.com/openshift/build-machinery-go v0.0.0-20250530140348-dc5b2804eeee
github.com/openshift/client-go v0.0.0-20251015124057-db0dee36e235
github.com/openshift/library-go v0.0.0-20251107090138-0de9712313a5
github.com/openshift/library-go v0.0.0-20260303081410-9c30edf843c6
Copy link
Contributor

Choose a reason for hiding this comment

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

@gangwgr gangwgr force-pushed the backport-kms-cases-4.21 branch from e1f994b to 56600da Compare March 4, 2026 09:01
@liouk
Copy link
Member

liouk commented Mar 4, 2026

/approve

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 4, 2026
@p0lyn0mial
Copy link
Contributor

/hold cancel
/lgtm

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Mar 4, 2026
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Mar 4, 2026
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 4, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gangwgr, liouk, p0lyn0mial

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
Copy link
Contributor

openshift-ci bot commented Mar 4, 2026

@gangwgr: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-gcp-operator-encryption-rotation 8e2fc3e link true /test e2e-gcp-operator-encryption-rotation
ci/prow/e2e-gcp-operator-encryption-kms 56600da link false /test e2e-gcp-operator-encryption-kms

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

@gangwgr
Copy link
Contributor Author

gangwgr commented Mar 4, 2026

/verified by @gangwgr

@openshift-ci-robot openshift-ci-robot added the verified Signifies that the PR passed pre-merge verification criteria label Mar 4, 2026
@openshift-ci-robot
Copy link
Contributor

@gangwgr: This PR has been marked as verified by @gangwgr.

Details

In response to this:

/verified by @gangwgr

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.

@openshift-merge-bot openshift-merge-bot bot merged commit c9d8d3e into openshift:release-4.21 Mar 4, 2026
16 of 17 checks passed
@openshift-ci-robot
Copy link
Contributor

@gangwgr: Jira Issue OCPBUGS-74418: 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-74418 has not been moved to the MODIFIED state.

This PR is marked as verified. If the remaining PRs listed above are marked as verified before merging, the issue will automatically be moved to VERIFIED after all of the changes from the PRs are available in an accepted nightly payload.

Details

In response to this:

Backport kms test cases to 4.21

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.

@openshift-merge-robot
Copy link
Contributor

Fix included in accepted release 4.21.0-0.nightly-2026-03-11-185944

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. backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. 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. verified Signifies that the PR passed pre-merge verification criteria

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants