-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
feat(backend): Add TTL Strategy in Workflow Spec for Post-Completion Cleanup #11352
base: master
Are you sure you want to change the base?
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 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 |
fbdf73f
to
6355010
Compare
Signed-off-by: VaniHaripriya <[email protected]>
a0bf7c1
to
723aabd
Compare
@@ -77,9 +77,19 @@ func (t *V2Spec) ScheduledWorkflow(modelJob *model.Job) (*scheduledworkflow.Sche | |||
} | |||
} | |||
|
|||
var pipeline_options argocompiler.Options |
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.
Camel casing required to stay consistent with golang variable definition standards - PipelineOptions
var obj interface{} | ||
if util.CurrentExecutionType() == util.ArgoWorkflow { | ||
obj, err = argocompiler.Compile(job, kubernetesSpec, nil) | ||
obj, err = argocompiler.Compile(job, kubernetesSpec, &pipeline_options) |
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.
var obj interface{} | ||
if util.CurrentExecutionType() == util.ArgoWorkflow { | ||
obj, err = argocompiler.Compile(job, kubernetesSpec, nil) | ||
obj, err = argocompiler.Compile(job, kubernetesSpec, pipeline_options) |
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.
} | ||
|
||
const ( | ||
pipeline_default_ttlSeconds = int32(30) |
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.
Camel casing :)
@@ -86,6 +91,11 @@ func Compile(jobArg *pipelinespec.PipelineJob, kubernetesSpecArg *pipelinespec.S | |||
} | |||
} | |||
|
|||
pipeline_ttlseconds := pipeline_default_ttlSeconds |
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.
Camel casing here too
Description of your changes:
This PR should be merged only after #11269 gets merged.
Testing Instruxtions:
main.yaml
file from herePipeline Spec
tab if the following snippet is present:Workflow
CR:Checklist: