-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Keep Pipeline.status field for backward compatibility 👾 #1762
Conversation
@vdemeester: GitHub didn't allow me to request PR reviews from the following users: poy. Note that only tektoncd members and repo collaborators can review this PR, and authors cannot review their own PRs. 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. |
// It usually is used to communicate the observed state of the Pipeline from | ||
// the controller, but was unused as there is no controller for Pipeline. | ||
// +optional | ||
Status PipelineStatus `json:"status,omitempty"` |
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.
omitempty
has no effect on struct fields that aren't pointers. This will result in clients always sending "status":{}
, so we'll never be able to upgrade servers to stop accepting it.
If we change this to *PipelineStatus
then new clients won't send it, but servers will at least still know about it and will be able to decode it.
Then in the future we can remove the field once we believe clients have upgraded to not rely on it.
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.
@imjasonh good point… forgot to modify this to a pointer… 🙃
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.
My goal is to not have this in v1alpha2
(aka v1beta1
), that way, it fades away once we remove v1alpha1
👼
9adb98b
to
5792335
Compare
/approve |
They are not used, and shouldn't be there, but client that have previous version of this struct would fail targeting the API. This is a *partial* revert of tektoncd#1640, as it doesn't reintroduce the `UpdateStatus` generation. Signed-off-by: Vincent Demeester <[email protected]>
5792335
to
1e01a4b
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.
One question: Do we need to do this for pipeline resources as well?
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dibyom, ImJasonH 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 |
We do, I'll follow-up 👼 |
Changes
They are not used, and shouldn't be there, but client that have
previous version of this struct would fail targeting the API.
This is a partial revert of #1640, as it doesn't reintroduce the
UpdateStatus
generation./cc @bobcatfish @poy
Submitter Checklist
These are the criteria that every PR should meet, please check them off as you
review them:
See the contribution guide for more details.
Double check this list of stuff that's easy to miss:
cmd
dir, please updatethe release Task to build and release this image.
Reviewer Notes
If API changes are included, additive changes must be approved by at least two OWNERS and backwards incompatible changes must be approved by more than 50% of the OWNERS, and they must first be added in a backwards compatible way.