diff --git a/go.mod b/go.mod index 1e61696c6..f3a75af83 100644 --- a/go.mod +++ b/go.mod @@ -2,8 +2,6 @@ module open-cluster-management.io/ocm go 1.22.5 -replace open-cluster-management.io/api => github.com/haoqing0110/api v0.0.0-20240920101950-b79b23b51797 - require ( github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc github.com/evanphx/json-patch v5.9.0+incompatible @@ -98,6 +96,7 @@ require ( github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect github.com/mitchellh/copystructure v1.2.0 // indirect github.com/mitchellh/reflectwalk v1.0.2 // indirect + github.com/moby/sys/sequential v0.6.0 // indirect github.com/moby/sys/user v0.1.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect diff --git a/go.sum b/go.sum index a8411340e..ec298dacd 100644 --- a/go.sum +++ b/go.sum @@ -137,8 +137,6 @@ github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4 github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0 h1:bkypFPDjIYGfCYD5mRBvpqxfYX1YCS1PXdKYWi8FsN0= github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0/go.mod h1:P+Lt/0by1T8bfcF3z737NnSbmxQAppXMRziHUxPOC8k= -github.com/haoqing0110/api v0.0.0-20240920101950-b79b23b51797 h1:tD02gj6DoUFS9FfGMloQjBrrQ3UTZz3Ey2oD9qAkf/4= -github.com/haoqing0110/api v0.0.0-20240920101950-b79b23b51797/go.mod h1:9erZEWEn4bEqh0nIX2wA7f/s3KCuFycQdBrPrRzi0QM= github.com/huandu/xstrings v1.3.3/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= github.com/huandu/xstrings v1.4.0 h1:D17IlohoQq4UcpqD7fDk80P7l+lwAmlFaBHgOipl2FU= github.com/huandu/xstrings v1.4.0/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= @@ -180,8 +178,8 @@ github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zx github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= github.com/moby/patternmatcher v0.6.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= -github.com/moby/sys/sequential v0.5.0 h1:OPvI35Lzn9K04PBbCLW0g4LcFAJgHsvXsRyewg5lXtc= -github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= +github.com/moby/sys/sequential v0.6.0 h1:qrx7XFUd/5DxtqcoH1h438hF5TmOvzC/lspjy7zgvCU= +github.com/moby/sys/sequential v0.6.0/go.mod h1:uyv8EUTrca5PnDsdMGXhZe6CCe8U/UiTWd+lL+7b/Ko= github.com/moby/sys/user v0.1.0 h1:WmZ93f5Ux6het5iituh9x2zAG7NFY9Aqi49jjE1PaQg= github.com/moby/sys/user v0.1.0/go.mod h1:fKJhFOnsCN6xZ5gSfbM6zaHGgDJMrqt9/reuj4T7MmU= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= @@ -445,6 +443,8 @@ k8s.io/utils v0.0.0-20240310230437-4693a0247e57 h1:gbqbevonBh57eILzModw6mrkbwM0g k8s.io/utils v0.0.0-20240310230437-4693a0247e57/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= open-cluster-management.io/addon-framework v0.10.1-0.20240703130731-ba7fd000a03a h1:La1cYE3xkPFS2OJnsPQbkkahKE7yabuPcIISRfb4qsg= open-cluster-management.io/addon-framework v0.10.1-0.20240703130731-ba7fd000a03a/go.mod h1:C1VETu/CIQKYfMiVAgNzPEUHjCpL9P1Z/KsGhHa4kl4= +open-cluster-management.io/api v0.14.1-0.20240923014927-17751e4cfddb h1:waqo8IxjYIz5dQ71pDM2Qn7jcPYWrTwd6BC1xB0VWKE= +open-cluster-management.io/api v0.14.1-0.20240923014927-17751e4cfddb/go.mod h1:9erZEWEn4bEqh0nIX2wA7f/s3KCuFycQdBrPrRzi0QM= open-cluster-management.io/sdk-go v0.14.1-0.20240918072645-225dcf1b6866 h1:nxYrSsYwl9Mq8DuaJ0K98PCpuGsai+AvXbggMfZDCGI= open-cluster-management.io/sdk-go v0.14.1-0.20240918072645-225dcf1b6866/go.mod h1:jCyXPY900UK1n4xwUBWSz27s7lcXN/fhIDF6xu3jIHw= sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.29.0 h1:/U5vjBbQn3RChhv7P11uhYvCSm5G2GaIi5AIGBS6r4c= diff --git a/test/integration/operator/clustermanager_hosted_test.go b/test/integration/operator/clustermanager_hosted_test.go index f87e1be47..f8086c3c8 100644 --- a/test/integration/operator/clustermanager_hosted_test.go +++ b/test/integration/operator/clustermanager_hosted_test.go @@ -401,8 +401,8 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 41 { - return fmt.Errorf("should get 41 relatedResources, actual got %v, %v", + if len(actual.Status.RelatedResources) != 42 { + return fmt.Errorf("should get 42 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil @@ -480,8 +480,8 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v, %v", + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil @@ -694,8 +694,8 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 40 { - return fmt.Errorf("should get 40 relatedResources, actual got %v, %v", + if len(actual.Status.RelatedResources) != 41 { + return fmt.Errorf("should get 41 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil @@ -755,8 +755,8 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil }, eventuallyTimeout, eventuallyInterval).ShouldNot(gomega.HaveOccurred()) @@ -830,8 +830,8 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v", len(actual.Status.RelatedResources)) + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v", len(actual.Status.RelatedResources)) } return nil }, eventuallyTimeout, eventuallyInterval).ShouldNot(gomega.HaveOccurred()) @@ -885,6 +885,7 @@ var _ = ginkgo.Describe("ClusterManager Hosted Mode", func() { hubRegistrationDeployment, hubPlacementDeployment, hubRegistrationWebhookDeployment, hubWorkWebhookDeployment, hubWorkControllerDeployment, hubAddonManagerDeployment) }) + ginkgo.It("Deployment should be reconciled when manually updated", func() { gomega.Eventually(func() error { registrationDeployment, err := hostedKubeClient.AppsV1().Deployments(hubNamespaceHosted).Get(hostedCtx, hubRegistrationDeployment, metav1.GetOptions{}) diff --git a/test/integration/operator/clustermanager_test.go b/test/integration/operator/clustermanager_test.go index 1c173b486..b7a27a7b8 100644 --- a/test/integration/operator/clustermanager_test.go +++ b/test/integration/operator/clustermanager_test.go @@ -376,8 +376,8 @@ var _ = ginkgo.Describe("ClusterManager Default Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 41 { - return fmt.Errorf("should get 41 relatedResources, actual got %v, %v", + if len(actual.Status.RelatedResources) != 42 { + return fmt.Errorf("should get 42 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil @@ -455,8 +455,8 @@ var _ = ginkgo.Describe("ClusterManager Default Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v, %v", + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v, %v", len(actual.Status.RelatedResources), actual.Status.RelatedResources) } return nil @@ -667,8 +667,8 @@ var _ = ginkgo.Describe("ClusterManager Default Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 40 { - return fmt.Errorf("should get 40 relatedResources, actual got %v", len(actual.Status.RelatedResources)) + if len(actual.Status.RelatedResources) != 41 { + return fmt.Errorf("should get 41 relatedResources, actual got %v", len(actual.Status.RelatedResources)) } return nil }, eventuallyTimeout, eventuallyInterval).ShouldNot(gomega.HaveOccurred()) @@ -723,8 +723,8 @@ var _ = ginkgo.Describe("ClusterManager Default Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v", len(actual.Status.RelatedResources)) + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v", len(actual.Status.RelatedResources)) } return nil }, eventuallyTimeout, eventuallyInterval).ShouldNot(gomega.HaveOccurred()) @@ -794,8 +794,8 @@ var _ = ginkgo.Describe("ClusterManager Default Mode", func() { if err != nil { return err } - if len(actual.Status.RelatedResources) != 45 { - return fmt.Errorf("should get 45 relatedResources, actual got %v", len(actual.Status.RelatedResources)) + if len(actual.Status.RelatedResources) != 46 { + return fmt.Errorf("should get 46 relatedResources, actual got %v", len(actual.Status.RelatedResources)) } return nil }, eventuallyTimeout, eventuallyInterval).ShouldNot(gomega.HaveOccurred()) diff --git a/vendor/modules.txt b/vendor/modules.txt index b60804077..9e80681b5 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -243,6 +243,8 @@ github.com/mitchellh/copystructure # github.com/mitchellh/reflectwalk v1.0.2 ## explicit github.com/mitchellh/reflectwalk +# github.com/moby/sys/sequential v0.6.0 +## explicit; go 1.17 # github.com/moby/sys/user v0.1.0 ## explicit; go 1.17 # github.com/mochi-mqtt/server/v2 v2.6.5 @@ -1528,7 +1530,7 @@ open-cluster-management.io/addon-framework/pkg/agent open-cluster-management.io/addon-framework/pkg/assets open-cluster-management.io/addon-framework/pkg/index open-cluster-management.io/addon-framework/pkg/utils -# open-cluster-management.io/api v0.14.1-0.20240923014927-17751e4cfddb => github.com/haoqing0110/api v0.0.0-20240920101950-b79b23b51797 +# open-cluster-management.io/api v0.14.1-0.20240923014927-17751e4cfddb ## explicit; go 1.22.0 open-cluster-management.io/api/addon/v1alpha1 open-cluster-management.io/api/client/addon/clientset/versioned @@ -1728,4 +1730,3 @@ sigs.k8s.io/structured-merge-diff/v4/value ## explicit; go 1.12 sigs.k8s.io/yaml sigs.k8s.io/yaml/goyaml.v2 -# open-cluster-management.io/api => github.com/haoqing0110/api v0.0.0-20240920101950-b79b23b51797