Skip to content

Commit 614fef3

Browse files
Add the resource UID to the binding.spec.resource in the dependencies-distributor
Signed-off-by: changzhen <[email protected]>
1 parent 2953630 commit 614fef3

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

pkg/dependenciesdistributor/dependencies_distributor.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -767,6 +767,7 @@ func buildAttachedBinding(independentBinding *workv1alpha2.ResourceBinding, obje
767767
Kind: object.GetKind(),
768768
Namespace: object.GetNamespace(),
769769
Name: object.GetName(),
770+
UID: object.GetUID(),
770771
ResourceVersion: object.GetResourceVersion(),
771772
},
772773
RequiredBy: result,

pkg/dependenciesdistributor/dependencies_distributor_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3144,6 +3144,7 @@ func Test_buildAttachedBinding(t *testing.T) {
31443144
Kind: "Deployment",
31453145
Namespace: "fake-ns",
31463146
Name: "demo-app",
3147+
UID: "db56a4a6-0dff-465a-b046-2c1dea42a42b",
31473148
ResourceVersion: "22222",
31483149
},
31493150
RequiredBy: []workv1alpha2.BindingSnapshot{

0 commit comments

Comments
 (0)