-
Notifications
You must be signed in to change notification settings - Fork 112
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
Add conditions pkg to support Build CRDs to operate on Conditions #475
Add conditions pkg to support Build CRDs to operate on Conditions #475
Conversation
5351e3d
to
556e8c0
Compare
556e8c0
to
3b999a5
Compare
/retest |
Note that Conditions has official API support from Kubernetes in v1.19. In addition to an API defined in https://github.com/kubernetes/apimachinery/blob/master/pkg/apis/meta/v1/types.go#L1354-L1368 |
3b999a5
to
edde66c
Compare
@adambkaplan cool, more than happy to rely on that in the future. We will just need to keep our local |
25a38b9
to
07cfd48
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just found a couple of minor things in the docs that should be changed.
92a349f
to
a043915
Compare
@HeavyWombat thanks, I added your suggestions. |
a043915
to
adec8bf
Compare
- Adding a generic conditions pkg, so that any controller that needs to support Conditions can use the pkg to set/retrieve their related conditions. - Adding a Condition of the type Succeeded for resources that run to completion, like the BuildRun - Adding a generic Condition types. This can be extended in the future with new fields. - Adding unit tests for the new conditions pkg. - Adding support for the Conditions pkg in the BuildRun, although the CRD is not yet generating or updating the Status.Condition object. This is done by extending the Status struct to include a Conditions field. The conditions framework is heavily based on https://github.com/knative/pkg/blob/master/apis/condition_set.go
This adds support for the CRD to inline with the BuildRun types changes.
adec8bf
to
cfd5d7e
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: SaschaSchwarze0 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 |
This is not yet fixing #307 , but rather the base framework so that we can operate on Conditions. We would need a new PR for how do we populate the Conditions field in the BuildRun.
This includes
Adding a generic conditions pkg, so that any controller that needs to support Conditions can use the pkg to set/retrieve their related conditions.
Adding a Condition of the type Succeeded for resources that run to completion, like the BuildRun
Adding a generic Condition types. This can be extended in the future with new fields.
Adding unit tests for the new conditions pkg.
Adding support for the Conditions pkg in the BuildRun, although the CRD is not yet generating or updating the Status.Condition object. This is done by extending the Status struct to include a Conditions field.
Extend BuildRun CRD with Conditions fields . This adds support for the CRD to inline with the BuildRun types changes.
Part of this conditions framework is heavily based on https://github.com/knative/pkg/blob/master/apis/condition_set.go