Skip to content
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

DRAFT: New deployment controller #247

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

RomanBednar
Copy link
Contributor

@RomanBednar RomanBednar commented Jul 24, 2024

  • PR has commits for library-go for the sake of testing and review
  • some commits are meant to be dropped and are here just for demonstration purposes
  • needs better naming

Related bug: https://issues.redhat.com/browse/OCPBUGS-24588

ClusterCSIDriver condition when precondition fails:

  - lastTransitionTime: "2024-07-24T11:13:45Z"
    message: |
      dummy precondition 3 failed
    reason: PreconditionNotFulfilled
    status: "True"
    type: DeploymentDegraded

Controllers can be configured with csi-operator to have multiple preconditions, errors are then aggregated in ClusterCSIDriver:

- lastTransitionTime: "2024-07-24T11:13:45Z"
    message: |
      dummy error 2
      dummy error 3
    reason: PreconditionNotFulfilled
    status: "True"
    type: DeploymentDegraded

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 24, 2024
Copy link
Contributor

openshift-ci bot commented Jul 24, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

Copy link
Contributor

openshift-ci bot commented Jul 24, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: RomanBednar

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 Jul 24, 2024
preconditions []func(context.Context) (bool, error)
}

func NewMyController(
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not really sure if this meets the goal of writing new controller with DeploymentController API - ideally the API of the new controller should match the current deployment controller (so for callers the change is transparent) but I was not sure how that could be done since the signature of workload controller constructor is different.

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. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant