Skip to content

api: Directly indicate credentials revocation in cluster#4796

Open
mbarnes wants to merge 2 commits intomainfrom
1p/revoke-credentials-operation-id
Open

api: Directly indicate credentials revocation in cluster#4796
mbarnes wants to merge 2 commits intomainfrom
1p/revoke-credentials-operation-id

Conversation

@mbarnes
Copy link
Copy Markdown
Collaborator

@mbarnes mbarnes commented Apr 8, 2026

Loosely related to ARO-24384 - Move Cluster Service CRUD calls to ARO-HCP backend

What

This adds service provider property RevokeCredentialsOperationID. It works like ActiveOperationID — frontend sets it when the operation starts, backend clears it when the operation finishes — but it specifically tracks credential revocation operations.

Credential revocation operations are per-cluster, and there can only be one in progress at a time. They're submitted via POST request to an endpoint under the cluster resource. They don't change the provisioning state of the cluster — and thus don't block cluster updates — but they do block other POST requests until the revocation is complete.

Why

POST handlers already fetch the cluster document from Cosmos DB, so this will save an extra Cosmos DB query to determine whether a credential revocation is in progress.

It also inches us closer to being able to drop the subscription lock.

Testing

Updated existing unit tests.

Special notes for your reviewer

This is a two-step change. Once the backend changes in this PR reach production, the POST handlers in the frontend can start relying on the new field and stop querying Cosmos DB.

Database migration for existing clusters is not needed because of the transient nature of this new field.

@openshift-ci
Copy link
Copy Markdown

openshift-ci bot commented Apr 8, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mbarnes

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 openshift-ci bot requested review from deads2k and geoberle April 8, 2026 14:33
@openshift-ci openshift-ci bot added the approved label Apr 8, 2026
@mbarnes mbarnes force-pushed the 1p/revoke-credentials-operation-id branch from 31693fb to cd0badc Compare April 8, 2026 15:00
@mbarnes
Copy link
Copy Markdown
Collaborator Author

mbarnes commented Apr 8, 2026

/test e2e-parallel

Matthew Barnes added 2 commits April 9, 2026 17:40
This adds service provider property "RevokeCredentialsOperationID".
It works like "ActiveOperationID" but specifically tracks credential
revocation operations. Revocation operations are per-cluster, and
there can only be one in progress at a time.

POST handlers already fetch the cluster document from Cosmos DB,
so this saves an extra Cosmos DB query to determine whether a
credential revocation is in progress.

It also inches us closer to being able to drop the subscription lock.
@mbarnes mbarnes force-pushed the 1p/revoke-credentials-operation-id branch from cd0badc to cb9bfad Compare April 9, 2026 21:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants