-
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
Export required Conversions for Reconciling the Deprecated CustomRun #6496
Conversation
3292699
to
b519267
Compare
b519267
to
b330396
Compare
/assign |
1 similar comment
/assign |
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
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: EmmaMunley The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This commit exports the required conversions for reconciling v1beta1 CustomRun in the PipelineRun reconciler. It involves the following ConvertFrom funcs: - Param - WorkspaceBinding - TaskRef
b330396
to
656e579
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.
I'm curious why we need to export the individual conversion functions instead of just using the existing exported functions for converting Tasks, TaskRuns, etc?
Yeah I also tried to use the existing exported functions but for the createRunObject func, it is accessing the |
Just a heads up, permalinks can help with linking to sections of code-- they ensure that if the code changes, you're still linking to the lines intended. It's hard for me to see why this is necessary without the context of #6444; I'm not sure whether this PR makes sense on its own. Is the problem specifically that v1beta1 customruns might have v1beta1 params and workspace bindings, and those need to be converted somewhere? It might be easier to wait until #6498 is addressed. I'd actually prefer to not have a PR split here, since the reason for this PR depends heavily on what is needed by the storage swap PR, and doesn't necessarily make sense as a change on its own. Other reviewers may have different opinions. |
@@ -18,7 +18,8 @@ func (tr TaskRef) convertTo(ctx context.Context, sink *v1.TaskRef) { | |||
tr.convertBundleToResolver(sink) | |||
} | |||
|
|||
func (tr *TaskRef) convertFrom(ctx context.Context, source v1.TaskRef) { | |||
// ConvertFrom v1 TaskRef is exported for reconciling the deprecated v1beta1 CustomRun |
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.
v1beta1 customrun is not deprecated
Thanks @lbernick . I think that makes a lot of sense and I will take the guidance since we can always reopen this if this could help break #6444 down.
|
Changes
This commit exports the required conversions for reconciling v1beta1
CustomRun in the PipelineRun reconciler. It involves the following
ConvertFrom funcs:
ie. we would want to convert the fields back in v1beta1 at https://github.com/tektoncd/pipeline/blob/main/pkg/reconciler/pipelinerun/pipelinerun.go#L970-L975
part of #5541
/kind misc
Submitter Checklist
As the author of this PR, please check off the items in this checklist:
/kind <type>
. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tepRelease Notes