From 5de4420884849efee86baaf7fe49a1207b633046 Mon Sep 17 00:00:00 2001 From: Yang Hanlin Date: Sat, 6 Sep 2025 18:59:37 +0000 Subject: [PATCH] Fix `Framework.{Patch,Delete,Get}Object` methods not passing `APICallOptions` to the underlying client methods --- clusterloader2/pkg/framework/framework.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/clusterloader2/pkg/framework/framework.go b/clusterloader2/pkg/framework/framework.go index a87b348939..0441e9ae6c 100644 --- a/clusterloader2/pkg/framework/framework.go +++ b/clusterloader2/pkg/framework/framework.go @@ -255,18 +255,18 @@ func (f *Framework) CreateObject(namespace string, name string, obj *unstructure } // PatchObject updates object (using patch) with given name using given object description. -func (f *Framework) PatchObject(namespace string, name string, obj *unstructured.Unstructured, _ ...*client.APICallOptions) error { - return client.PatchObject(f.dynamicClients.GetClient(), namespace, name, obj) +func (f *Framework) PatchObject(namespace string, name string, obj *unstructured.Unstructured, options ...*client.APICallOptions) error { + return client.PatchObject(f.dynamicClients.GetClient(), namespace, name, obj, options...) } // DeleteObject deletes object with given name and group-version-kind. -func (f *Framework) DeleteObject(gvk schema.GroupVersionKind, namespace string, name string, _ ...*client.APICallOptions) error { - return client.DeleteObject(f.dynamicClients.GetClient(), gvk, namespace, name) +func (f *Framework) DeleteObject(gvk schema.GroupVersionKind, namespace string, name string, options ...*client.APICallOptions) error { + return client.DeleteObject(f.dynamicClients.GetClient(), gvk, namespace, name, options...) } // GetObject retrieves object with given name and group-version-kind. -func (f *Framework) GetObject(gvk schema.GroupVersionKind, namespace string, name string, _ ...*client.APICallOptions) (*unstructured.Unstructured, error) { - return client.GetObject(f.dynamicClients.GetClient(), gvk, namespace, name) +func (f *Framework) GetObject(gvk schema.GroupVersionKind, namespace string, name string, options ...*client.APICallOptions) (*unstructured.Unstructured, error) { + return client.GetObject(f.dynamicClients.GetClient(), gvk, namespace, name, options...) } // ApplyTemplatedManifests finds and applies all manifest template files matching the provided