Skip to content

Commit

Permalink
Remove runid labels from pipelineloop's child pipelinerun (kubeflow#648)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomcli authored Jul 1, 2021
1 parent 3163801 commit 2cfc78d
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ const (

// pipelineLoopIterationLabelKey is the label identifier for the iteration number. This label is added to the Run's PipelineRuns.
pipelineLoopIterationLabelKey = "/pipelineLoopIteration"

// LabelKeyWorkflowRunId is the label identifier a pipelinerun is managed by the Kubeflow Pipeline persistent agent.
LabelKeyWorkflowRunId = "pipeline/runid"
)

// Reconciler implements controller.Reconciler for Configuration resources.
Expand Down Expand Up @@ -690,6 +693,11 @@ func getPipelineRunLabels(run *v1alpha1.Run, iterationStr string) map[string]str
prOriginalName = run.ObjectMeta.Labels["tekton.dev/pipelineRun"]
}
labels[pipelineloop.GroupName+originalPRKey] = prOriginalName
// Empty the RunId reference from the KFP persistent agent because LabelKeyWorkflowRunId should be unique across all pipelineruns
_, ok := labels[LabelKeyWorkflowRunId]
if ok {
delete(labels, LabelKeyWorkflowRunId)
}
return labels
}

Expand Down

0 comments on commit 2cfc78d

Please sign in to comment.