-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lifecycle hooks for CAPI objects #5141
Comments
Using this issue, as a net to catch the use cases which could be benefited from these hooks. |
/milestone Next |
/kind proposal |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages issues and PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
This will be addressed by the work for #5175 (Runtime Extensions) |
@fabriziopandini: Closing this issue. In response to this:
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. |
User Story
As a developer/operator, I would like to run some custom logic/code for certain lifecycle events in the CAPI objects and pause the object reconciliation until the external entity finishes its execution.
Detailed Description
Currently, in CAPI, we have the ability to alter the Machine object's lifecycle after it has been marked for deletion using a special set of annotations. The presence of these annotations pauses the reconciliation,(in this case deletion) of the Machine object until the action taken by the external component is completed which is indicated by the removal of the annotations.
Extending on this pattern, as a cluster operator, I would like to have the ability to subscribe to the lifecycle events (creation/deletion/scaling up) for CAPI objects, run some custom logic and pause the object reconciliation until the execution is finished.
Anything else you would like to add:
The idea is to come up with a generic way of attaching external subscribers to events in the CAPI object lifecycle, which can be backed by Conditions (initial thought, might not be the only way to achieve this). The reconciliation of the CAPI object is paused until all the subscribers subscribing to that event finish executing their custom logic. To ensure that failures during the execution of these custom actions do not block the normal operation of the CAPI objects, add a prescribable timeout with defaults while registering the subscribers.
/kind feature
The text was updated successfully, but these errors were encountered: