Skip to content

Commit

Permalink
add parallel policy as owner references
Browse files Browse the repository at this point in the history
Signed-off-by: rahulii <[email protected]>
  • Loading branch information
rahulii committed Aug 8, 2024
1 parent 43fb57b commit 35e475b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/reconciler/parallel/parallel_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1519,6 +1519,10 @@ func makeIngressChannelEventPolicy(parallelName, channelName, parallelEventPolic
APIVersion: "flows.knative.dev/v1",
Kind: "Parallel",
Name: parallelName,
}, {
APIVersion: "eventing.knative.dev/v1alpha1",
Kind: "EventPolicy",
Name: parallelEventPolicyName,
},
}...),
WithEventPolicyLabels(resources.LabelsForParallelChannelsEventPolicy(parallelName)),
Expand Down
6 changes: 6 additions & 0 deletions pkg/reconciler/parallel/resources/eventpolicy.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,12 @@ func MakeEventPolicyForParallelIngressChannel(p *flowsv1.Parallel, ingressChanne
APIVersion: flowsv1.SchemeGroupVersion.String(),
Kind: parallelKind,
Name: p.Name,
UID: p.UID,
}, {
APIVersion: eventingv1alpha1.SchemeGroupVersion.String(),
Kind: "EventPolicy",
Name: parallelPolicy.Name,
UID: parallelPolicy.UID,
},
},
Labels: LabelsForParallelChannelsEventPolicy(p.Name),
Expand Down

0 comments on commit 35e475b

Please sign in to comment.