From d35961c2095f96b1f8d5035961f535920fb5bd5e Mon Sep 17 00:00:00 2001 From: shriramsharma Date: Thu, 25 Jul 2024 12:26:04 -0700 Subject: [PATCH 1/8] added generation check Signed-off-by: Shriram Sharma --- admiral/cmd/admiral/cmd/root.go | 2 + .../clientconnectionconfigcontroller.go | 4 + admiral/pkg/controller/admiral/controller.go | 12 + .../controller/admiral/delegator_mock_test.go | 6 + admiral/pkg/controller/admiral/dependency.go | 5 + .../pkg/controller/admiral/dependencyproxy.go | 206 +++++++++++++++++ admiral/pkg/controller/admiral/deployment.go | 22 ++ .../pkg/controller/admiral/deployment_test.go | 126 +++++++++++ admiral/pkg/controller/admiral/envoyfilter.go | 4 + .../pkg/controller/admiral/globaltraffic.go | 4 + admiral/pkg/controller/admiral/node.go | 5 + .../controller/admiral/outlierdetection.go | 4 + admiral/pkg/controller/admiral/rollouts.go | 22 ++ .../pkg/controller/admiral/rollouts_test.go | 108 +++++++++ .../pkg/controller/admiral/routingpolicy.go | 4 + admiral/pkg/controller/admiral/service.go | 5 + admiral/pkg/controller/common/config.go | 6 + admiral/pkg/controller/common/types.go | 1 + .../pkg/controller/istio/destinationrule.go | 4 + admiral/pkg/controller/istio/serviceentry.go | 4 + admiral/pkg/controller/istio/sidecar.go | 5 + .../pkg/controller/istio/virtualservice.go | 4 + admiral/pkg/test/mock.go | 2 + go.sum | 210 ++++++++++++++++++ tests/perf/perf_service_test.go | 136 ++++++++++++ 25 files changed, 911 insertions(+) create mode 100644 admiral/pkg/controller/admiral/dependencyproxy.go create mode 100644 tests/perf/perf_service_test.go diff --git a/admiral/cmd/admiral/cmd/root.go b/admiral/cmd/admiral/cmd/root.go index df08c658d..4e893b1ce 100644 --- a/admiral/cmd/admiral/cmd/root.go +++ b/admiral/cmd/admiral/cmd/root.go @@ -242,6 +242,8 @@ func GetRootCmd(args []string) *cobra.Command { rootCmd.PersistentFlags().BoolVar(¶ms.EnableSyncIstioResourcesToSourceClusters, "enable_sync_istio_resources_to_source_clusters", true, "Enable/Disable Sync of Istio Resources to Source Clusters") rootCmd.PersistentFlags().BoolVar(¶ms.AdmiralStateSyncerMode, "admiral_state_syncer_mode", false, "Enable/Disable admiral to run as state syncer only") rootCmd.PersistentFlags().Int64Var(¶ms.DefaultWarmupDurationSecs, "default_warmup_duration_in_seconds", 45, "The default value for the warmupDurationSecs to be used on Destination Rules created by admiral") + + rootCmd.PersistentFlags().BoolVar(¶ms.EnableGenerationCheck, "enable_generation_check", true, "Enable/Disable Generation Check") return rootCmd } diff --git a/admiral/pkg/controller/admiral/clientconnectionconfigcontroller.go b/admiral/pkg/controller/admiral/clientconnectionconfigcontroller.go index a2a406327..2a79d08e1 100644 --- a/admiral/pkg/controller/admiral/clientconnectionconfigcontroller.go +++ b/admiral/pkg/controller/admiral/clientconnectionconfigcontroller.go @@ -31,6 +31,10 @@ type ClientConnectionConfigController struct { Cache *clientConnectionSettingsCache } +func (c *ClientConnectionConfigController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type clientConnectionSettingsItem struct { clientConnectionSettings *v1.ClientConnectionConfig status string diff --git a/admiral/pkg/controller/admiral/controller.go b/admiral/pkg/controller/admiral/controller.go index 85ce1e1b8..76f74f1d5 100644 --- a/admiral/pkg/controller/admiral/controller.go +++ b/admiral/pkg/controller/admiral/controller.go @@ -52,6 +52,7 @@ type Delegator interface { GetProcessItemStatus(interface{}) (string, error) LogValueOfAdmiralIoIgnore(interface{}) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error) + DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) } type EventType string @@ -152,6 +153,17 @@ func NewController(name, clusterEndpoint string, stopCh <-chan struct{}, delegat if err != nil { ctxLogger.Errorf(err.Error()) } + + // Check if the generation of the object has changed + // if the generation of old and new object is same then we do not process the object + doesGenerationMatch, err := controller.delegator.DoesGenerationMatch(ctxLogger, oldObj, newObj) + if err != nil { + ctxLogger.Errorf(ControllerLogFormat, taskAddEventToQueue, controller.queue.Len(), err.Error()) + } + if doesGenerationMatch { + return + } + controller.delegator.LogValueOfAdmiralIoIgnore(newObj) latestObj, isVersionChanged := checkIfResourceVersionHasIncreased(ctxLogger, ctx, oldObj, newObj, delegator) txId, ctxLogger = updateTxId(ctx, newObj, latestObj, txId, ctxLogger, controller) diff --git a/admiral/pkg/controller/admiral/delegator_mock_test.go b/admiral/pkg/controller/admiral/delegator_mock_test.go index 37ca703c3..b0e9aaba1 100644 --- a/admiral/pkg/controller/admiral/delegator_mock_test.go +++ b/admiral/pkg/controller/admiral/delegator_mock_test.go @@ -2,6 +2,8 @@ package admiral import ( "context" + + log "github.com/sirupsen/logrus" ) type MockDelegator struct { @@ -9,6 +11,10 @@ type MockDelegator struct { getErr error } +func (m *MockDelegator) DoesGenerationMatch(ctx *log.Entry, i interface{}, i2 interface{}) (bool, error) { + return false, nil +} + func NewMockDelegator() *MockDelegator { return &MockDelegator{} } diff --git a/admiral/pkg/controller/admiral/dependency.go b/admiral/pkg/controller/admiral/dependency.go index 8048ab295..c5ec0d6b7 100644 --- a/admiral/pkg/controller/admiral/dependency.go +++ b/admiral/pkg/controller/admiral/dependency.go @@ -6,6 +6,7 @@ import ( "sync" "time" + log "github.com/sirupsen/logrus" meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" @@ -38,6 +39,10 @@ type DependencyController struct { informer cache.SharedIndexInformer } +func (d *DependencyController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type DependencyItem struct { Dependency *v1.Dependency Status string diff --git a/admiral/pkg/controller/admiral/dependencyproxy.go b/admiral/pkg/controller/admiral/dependencyproxy.go new file mode 100644 index 000000000..6459fe1f5 --- /dev/null +++ b/admiral/pkg/controller/admiral/dependencyproxy.go @@ -0,0 +1,206 @@ +package admiral + +import ( + "context" + "fmt" + "sync" + "time" + + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + log "github.com/sirupsen/logrus" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + + v1 "github.com/istio-ecosystem/admiral/admiral/pkg/apis/admiral/v1alpha1" + "k8s.io/client-go/kubernetes" + "k8s.io/client-go/tools/cache" + + clientset "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned" + informerV1 "github.com/istio-ecosystem/admiral/admiral/pkg/client/informers/externalversions/admiral/v1alpha1" + "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" +) + +// DependencyProxyHandler interface contains the methods that are required +type DependencyProxyHandler interface { + Added(ctx context.Context, obj *v1.DependencyProxy) error + Updated(ctx context.Context, obj *v1.DependencyProxy) error + Deleted(ctx context.Context, obj *v1.DependencyProxy) error +} + +type DependencyProxyController struct { + K8sClient kubernetes.Interface + admiralCRDClient clientset.Interface + DependencyProxyHandler DependencyProxyHandler + Cache *dependencyProxyCache + informer cache.SharedIndexInformer +} + +func (d *DependencyProxyController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + +type DependencyProxyItem struct { + DependencyProxy *v1.DependencyProxy + Status string +} + +type dependencyProxyCache struct { + //map of dependencies key=identity value array of onboarded identitys + cache map[string]*DependencyProxyItem + mutex *sync.Mutex +} + +func (d *dependencyProxyCache) Put(dep *v1.DependencyProxy) { + defer d.mutex.Unlock() + d.mutex.Lock() + + key := d.getKey(dep) + d.cache[key] = &DependencyProxyItem{ + DependencyProxy: dep, + Status: common.ProcessingInProgress, + } +} + +func (d *dependencyProxyCache) getKey(dep *v1.DependencyProxy) string { + return dep.Name +} + +func (d *dependencyProxyCache) Get(identity string) *v1.DependencyProxy { + defer d.mutex.Unlock() + d.mutex.Lock() + + depItem, ok := d.cache[identity] + if ok { + return depItem.DependencyProxy + } + + return nil +} + +func (d *dependencyProxyCache) Delete(dep *v1.DependencyProxy) { + defer d.mutex.Unlock() + d.mutex.Lock() + delete(d.cache, d.getKey(dep)) +} + +func (d *dependencyProxyCache) GetDependencyProxyProcessStatus(dep *v1.DependencyProxy) string { + defer d.mutex.Unlock() + d.mutex.Lock() + + key := d.getKey(dep) + + depItem, ok := d.cache[key] + if ok { + return depItem.Status + } + + return common.NotProcessed +} + +func (d *dependencyProxyCache) UpdateDependencyProxyProcessStatus(dep *v1.DependencyProxy, status string) error { + defer d.mutex.Unlock() + d.mutex.Lock() + + key := d.getKey(dep) + + depItem, ok := d.cache[key] + if ok { + depItem.Status = status + d.cache[key] = depItem + return nil + } + + return fmt.Errorf(LogCacheFormat, "Update", "DependencyProxy", + dep.Name, dep.Namespace, "", "nothing to update, dependency proxy not found in cache") +} + +func NewDependencyProxyController(stopCh <-chan struct{}, handler DependencyProxyHandler, configPath string, namespace string, resyncPeriod time.Duration, clientLoader loader.ClientLoader) (*DependencyProxyController, error) { + + controller := DependencyProxyController{} + controller.DependencyProxyHandler = handler + + depProxyCache := dependencyProxyCache{} + depProxyCache.cache = make(map[string]*DependencyProxyItem) + depProxyCache.mutex = &sync.Mutex{} + + controller.Cache = &depProxyCache + var err error + + controller.K8sClient, err = clientLoader.LoadKubeClientFromPath(configPath) + if err != nil { + return nil, fmt.Errorf("failed to create dependency controller k8s client: %v", err) + } + + controller.admiralCRDClient, err = clientLoader.LoadAdmiralClientFromPath(configPath) + if err != nil { + return nil, fmt.Errorf("failed to create dependency controller crd client: %v", err) + + } + + controller.informer = informerV1.NewDependencyProxyInformer( + controller.admiralCRDClient, + namespace, + resyncPeriod, + cache.Indexers{}, + ) + + NewController("dependencyproxy-ctrl", "", stopCh, &controller, controller.informer) + + return &controller, nil +} + +func (d *DependencyProxyController) Added(ctx context.Context, obj interface{}) error { + dep, ok := obj.(*v1.DependencyProxy) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) + } + d.Cache.Put(dep) + return d.DependencyProxyHandler.Added(ctx, dep) +} + +func (d *DependencyProxyController) Updated(ctx context.Context, obj interface{}, oldObj interface{}) error { + dep, ok := obj.(*v1.DependencyProxy) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) + } + d.Cache.Put(dep) + return d.DependencyProxyHandler.Updated(ctx, dep) +} + +func (d *DependencyProxyController) Deleted(ctx context.Context, obj interface{}) error { + dep, ok := obj.(*v1.DependencyProxy) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) + } + d.Cache.Delete(dep) + return d.DependencyProxyHandler.Deleted(ctx, dep) +} + +func (d *DependencyProxyController) GetProcessItemStatus(obj interface{}) (string, error) { + dependencyProxy, ok := obj.(*v1.DependencyProxy) + if !ok { + return common.NotProcessed, fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) + } + return d.Cache.GetDependencyProxyProcessStatus(dependencyProxy), nil +} + +func (d *DependencyProxyController) UpdateProcessItemStatus(obj interface{}, status string) error { + dependencyProxy, ok := obj.(*v1.DependencyProxy) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) + } + return d.Cache.UpdateDependencyProxyProcessStatus(dependencyProxy, status) +} + +func (d *DependencyProxyController) LogValueOfAdmiralIoIgnore(obj interface{}) { +} + +func (d *DependencyProxyController) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error) { + dependencyProxy, ok := obj.(*v1.DependencyProxy) + if ok && isRetry { + return d.Cache.Get(dependencyProxy.Name), nil + } + if ok && d.admiralCRDClient != nil { + return d.admiralCRDClient.AdmiralV1alpha1().DependencyProxies(dependencyProxy.Namespace).Get(ctx, dependencyProxy.Name, meta_v1.GetOptions{}) + } + return nil, fmt.Errorf("admiralcrd client is not initialized, txId=%s", ctx.Value("txId")) +} diff --git a/admiral/pkg/controller/admiral/deployment.go b/admiral/pkg/controller/admiral/deployment.go index 6e8b6eed5..b7dc05c6d 100644 --- a/admiral/pkg/controller/admiral/deployment.go +++ b/admiral/pkg/controller/admiral/deployment.go @@ -50,6 +50,28 @@ type DeploymentController struct { labelSet *common.LabelSet } +func (d *DeploymentController) DoesGenerationMatch(ctxLogger *log.Entry, obj interface{}, oldObj interface{}) (bool, error) { + if !common.DoGenerationCheck() { + ctxLogger.Debugf(ControllerLogFormat, "DoesGenerationMatch", "", + fmt.Sprintf("generation check is disabled")) + return false, nil + } + deploymentNew, ok := obj.(*k8sAppsV1.Deployment) + if !ok { + return false, fmt.Errorf("type assertion failed, %v is not of type *v1.Deployment", obj) + } + deploymentOld, ok := oldObj.(*k8sAppsV1.Deployment) + if !ok { + return false, fmt.Errorf("type assertion failed, %v is not of type *v1.Deployment", oldObj) + } + if deploymentNew.Generation == deploymentOld.Generation { + ctxLogger.Infof(ControllerLogFormat, "DoesGenerationMatch", "", + fmt.Sprintf("old and new generation matched for deployment %s", deploymentNew.Name)) + return true, nil + } + return false, nil +} + type deploymentCache struct { //map of dependencies key=identity value array of onboarded identities cache map[string]*DeploymentClusterEntry diff --git a/admiral/pkg/controller/admiral/deployment_test.go b/admiral/pkg/controller/admiral/deployment_test.go index b77d21eb6..115518725 100644 --- a/admiral/pkg/controller/admiral/deployment_test.go +++ b/admiral/pkg/controller/admiral/deployment_test.go @@ -14,6 +14,7 @@ import ( "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" "github.com/istio-ecosystem/admiral/admiral/pkg/test" + log "github.com/sirupsen/logrus" "github.com/stretchr/testify/assert" k8sAppsV1 "k8s.io/api/apps/v1" coreV1 "k8s.io/api/core/v1" @@ -215,6 +216,113 @@ func TestDeploymentController_Deleted(t *testing.T) { } } +func TestDeploymentControlle_DoesGenerationMatch(t *testing.T) { + dc := DeploymentController{} + + admiralParams := common.AdmiralParams{} + + testCases := []struct { + name string + deploymentNew interface{} + deploymentOld interface{} + enableGenerationCheck bool + expectedValue bool + expectedError error + }{ + { + name: "Given context, new deployment and old deployment object " + + "When new deployment is not of type *v1.Deployment " + + "Then func should return an error", + deploymentNew: struct{}{}, + deploymentOld: struct{}{}, + enableGenerationCheck: true, + expectedError: fmt.Errorf("type assertion failed, {} is not of type *v1.Deployment"), + }, + { + name: "Given context, new deployment and old deployment object " + + "When old deployment is not of type *v1.Deployment " + + "Then func should return an error", + deploymentNew: &k8sAppsV1.Deployment{}, + deploymentOld: struct{}{}, + enableGenerationCheck: true, + expectedError: fmt.Errorf("type assertion failed, {} is not of type *v1.Deployment"), + }, + { + name: "Given context, new deployment and old deployment object " + + "When deployment generation check is enabled but the generation does not match " + + "Then func should return false ", + deploymentNew: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + deploymentOld: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 1, + }, + }, + enableGenerationCheck: true, + expectedError: nil, + }, + { + name: "Given context, new deployment and old deployment object " + + "When deployment generation check is disabled " + + "Then func should return false ", + deploymentNew: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + deploymentOld: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 1, + }, + }, + expectedError: nil, + }, + { + name: "Given context, new deployment and old deployment object " + + "When deployment generation check is enabled and the old and new deployment generation is equal " + + "Then func should just return true", + deploymentNew: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + deploymentOld: &k8sAppsV1.Deployment{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + enableGenerationCheck: true, + expectedError: nil, + expectedValue: true, + }, + } + + ctxLogger := log.WithFields(log.Fields{ + "txId": "abc", + }) + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + admiralParams.EnableGenerationCheck = tc.enableGenerationCheck + common.ResetSync() + common.InitializeConfig(admiralParams) + actual, err := dc.DoesGenerationMatch(ctxLogger, tc.deploymentNew, tc.deploymentOld) + if !ErrorEqualOrSimilar(err, tc.expectedError) { + t.Errorf("expected: %v, got: %v", tc.expectedError, err) + } + if err == nil { + if tc.expectedValue != actual { + t.Errorf("expected: %v, got: %v", tc.expectedValue, actual) + } + } + }) + } + +} + func TestNewDeploymentController(t *testing.T) { config, err := clientcmd.BuildConfigFromFlags("", "../../test/resources/admins@fake-cluster.k8s.local") if err != nil { @@ -664,6 +772,15 @@ func TestDeploymentDeleted(t *testing.T) { } func TestUpdateProcessItemStatus(t *testing.T) { + common.ResetSync() + admiralParams := common.AdmiralParams{ + LabelSet: &common.LabelSet{ + WorkloadIdentityKey: "identity", + EnvKey: "admiral.io/env", + AdmiralCRDIdentityLabel: "identity", + }, + } + common.InitializeConfig(admiralParams) var ( serviceAccount = &coreV1.ServiceAccount{} env = "prd" @@ -805,6 +922,15 @@ func TestUpdateProcessItemStatus(t *testing.T) { } func TestGetProcessItemStatus(t *testing.T) { + common.ResetSync() + admiralParams := common.AdmiralParams{ + LabelSet: &common.LabelSet{ + WorkloadIdentityKey: "identity", + EnvKey: "admiral.io/env", + AdmiralCRDIdentityLabel: "identity", + }, + } + common.InitializeConfig(admiralParams) var ( serviceAccount = &coreV1.ServiceAccount{} env = "prd" diff --git a/admiral/pkg/controller/admiral/envoyfilter.go b/admiral/pkg/controller/admiral/envoyfilter.go index 9281ef6a3..f1b273faa 100644 --- a/admiral/pkg/controller/admiral/envoyfilter.go +++ b/admiral/pkg/controller/admiral/envoyfilter.go @@ -32,6 +32,10 @@ type EnvoyFilterController struct { informer cache.SharedIndexInformer } +func (e *EnvoyFilterController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + func (e *EnvoyFilterController) Added(ctx context.Context, obj interface{}) error { ef, ok := obj.(*networking.EnvoyFilter) if !ok { diff --git a/admiral/pkg/controller/admiral/globaltraffic.go b/admiral/pkg/controller/admiral/globaltraffic.go index cc6e45967..399758ea6 100644 --- a/admiral/pkg/controller/admiral/globaltraffic.go +++ b/admiral/pkg/controller/admiral/globaltraffic.go @@ -34,6 +34,10 @@ type GlobalTrafficController struct { informer cache.SharedIndexInformer } +func (d *GlobalTrafficController) DoesGenerationMatch(*logrus.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type gtpItem struct { GlobalTrafficPolicy *v1.GlobalTrafficPolicy Status string diff --git a/admiral/pkg/controller/admiral/node.go b/admiral/pkg/controller/admiral/node.go index 5ab0cfa84..a19a43a7b 100644 --- a/admiral/pkg/controller/admiral/node.go +++ b/admiral/pkg/controller/admiral/node.go @@ -6,6 +6,7 @@ import ( "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + log "github.com/sirupsen/logrus" k8sV1Informers "k8s.io/client-go/informers/core/v1" "k8s.io/client-go/rest" @@ -25,6 +26,10 @@ type NodeController struct { informer cache.SharedIndexInformer } +func (p *NodeController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type Locality struct { Region string } diff --git a/admiral/pkg/controller/admiral/outlierdetection.go b/admiral/pkg/controller/admiral/outlierdetection.go index d5d3eb4c6..97a5de143 100644 --- a/admiral/pkg/controller/admiral/outlierdetection.go +++ b/admiral/pkg/controller/admiral/outlierdetection.go @@ -35,6 +35,10 @@ type OutlierDetectionController struct { crdclient clientset.Interface } +func (o *OutlierDetectionController) DoesGenerationMatch(*logrus.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + func (c *odCache) Put(od *v1.OutlierDetection) { defer c.mutex.Unlock() diff --git a/admiral/pkg/controller/admiral/rollouts.go b/admiral/pkg/controller/admiral/rollouts.go index 48ce50027..026011714 100644 --- a/admiral/pkg/controller/admiral/rollouts.go +++ b/admiral/pkg/controller/admiral/rollouts.go @@ -55,6 +55,28 @@ type RolloutController struct { labelSet *common.LabelSet } +func (rc *RolloutController) DoesGenerationMatch(ctxLogger *log.Entry, obj interface{}, oldObj interface{}) (bool, error) { + if !common.DoGenerationCheck() { + ctxLogger.Debugf(ControllerLogFormat, "DoesGenerationMatch", "", + fmt.Sprintf("generation check is disabled")) + return false, nil + } + rolloutNew, ok := obj.(*argo.Rollout) + if !ok { + return false, fmt.Errorf("type assertion failed, %v is not of type *argo.Rollout", obj) + } + rolloutOld, ok := oldObj.(*argo.Rollout) + if !ok { + return false, fmt.Errorf("type assertion failed, %v is not of type *argo.Rollout", oldObj) + } + if rolloutNew.Generation == rolloutOld.Generation { + ctxLogger.Infof(ControllerLogFormat, "DoesGenerationMatch", "", + fmt.Sprintf("old and new generation matched for rollout %s", rolloutNew.Name)) + return true, nil + } + return false, nil +} + type rolloutCache struct { //map of dependencies key=identity value array of onboarded identities cache map[string]*RolloutClusterEntry diff --git a/admiral/pkg/controller/admiral/rollouts_test.go b/admiral/pkg/controller/admiral/rollouts_test.go index afdface12..5ab8fa1e8 100644 --- a/admiral/pkg/controller/admiral/rollouts_test.go +++ b/admiral/pkg/controller/admiral/rollouts_test.go @@ -17,6 +17,7 @@ import ( "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" "github.com/istio-ecosystem/admiral/admiral/pkg/test" + log "github.com/sirupsen/logrus" "github.com/stretchr/testify/assert" coreV1 "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -40,6 +41,113 @@ func TestNewRolloutController(t *testing.T) { } } +func TestRolloutController_DoesGenerationMatch(t *testing.T) { + rc := RolloutController{} + + admiralParams := common.AdmiralParams{} + + testCases := []struct { + name string + rolloutNew interface{} + rolloutOld interface{} + enableGenerationCheck bool + expectedValue bool + expectedError error + }{ + { + name: "Given context, new rollout and old rollout object " + + "When new rollout is not of type *argo.Rollout " + + "Then func should return an error", + rolloutNew: struct{}{}, + rolloutOld: struct{}{}, + enableGenerationCheck: true, + expectedError: fmt.Errorf("type assertion failed, {} is not of type *argo.Rollout"), + }, + { + name: "Given context, new rollout and old rollout object " + + "When old rollout is not of type *argo.Rollout " + + "Then func should return an error", + rolloutNew: &argo.Rollout{}, + rolloutOld: struct{}{}, + enableGenerationCheck: true, + expectedError: fmt.Errorf("type assertion failed, {} is not of type *argo.Rollout"), + }, + { + name: "Given context, new rollout and old rollout object " + + "When rollout generation check is enabled but the generation does not match " + + "Then func should return false ", + rolloutNew: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + rolloutOld: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 1, + }, + }, + expectedError: nil, + enableGenerationCheck: true, + }, + { + name: "Given context, new rollout and old rollout object " + + "When rollout generation check is disabled " + + "Then func should return false", + rolloutNew: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + rolloutOld: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 1, + }, + }, + expectedError: nil, + }, + { + name: "Given context, new rollout and old rollout object " + + "When rollout generation check is enabled and the old and new rollout generation is equal " + + "Then func should just return true", + rolloutNew: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + rolloutOld: &argo.Rollout{ + ObjectMeta: v1.ObjectMeta{ + Generation: 2, + }, + }, + expectedValue: true, + enableGenerationCheck: true, + expectedError: nil, + }, + } + + ctxLogger := log.WithFields(log.Fields{ + "txId": "abc", + }) + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + admiralParams.EnableGenerationCheck = tc.enableGenerationCheck + common.ResetSync() + common.InitializeConfig(admiralParams) + actual, err := rc.DoesGenerationMatch(ctxLogger, tc.rolloutNew, tc.rolloutOld) + if !ErrorEqualOrSimilar(err, tc.expectedError) { + t.Errorf("expected: %v, got: %v", tc.expectedError, err) + } + if err == nil { + if tc.expectedValue != actual { + t.Errorf("expected: %v, got: %v", tc.expectedValue, actual) + } + } + }) + } + +} + func TestRolloutController_Added(t *testing.T) { common.ResetSync() admiralParams := common.AdmiralParams{ diff --git a/admiral/pkg/controller/admiral/routingpolicy.go b/admiral/pkg/controller/admiral/routingpolicy.go index c22d8a88a..a9c020167 100644 --- a/admiral/pkg/controller/admiral/routingpolicy.go +++ b/admiral/pkg/controller/admiral/routingpolicy.go @@ -44,6 +44,10 @@ type RoutingPolicyController struct { informer cache.SharedIndexInformer } +func (r *RoutingPolicyController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + func (r *RoutingPolicyController) Added(ctx context.Context, obj interface{}) error { routingPolicy, ok := obj.(*v1.RoutingPolicy) if !ok { diff --git a/admiral/pkg/controller/admiral/service.go b/admiral/pkg/controller/admiral/service.go index c00233042..4669dce9d 100644 --- a/admiral/pkg/controller/admiral/service.go +++ b/admiral/pkg/controller/admiral/service.go @@ -7,6 +7,7 @@ import ( "time" "github.com/prometheus/common/log" + "github.com/sirupsen/logrus" "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" @@ -46,6 +47,10 @@ type ServiceController struct { informer cache.SharedIndexInformer } +func (s *ServiceController) DoesGenerationMatch(*logrus.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type serviceCache struct { //map of dependencies key=identity value array of onboarded identities cache map[string]*ServiceClusterEntry diff --git a/admiral/pkg/controller/common/config.go b/admiral/pkg/controller/common/config.go index 7e460dd4a..cc6f8d4b8 100644 --- a/admiral/pkg/controller/common/config.go +++ b/admiral/pkg/controller/common/config.go @@ -426,6 +426,12 @@ func EnableSWAwareNSCaches() bool { return wrapper.params.EnableSWAwareNSCaches } +func DoGenerationCheck() bool { + wrapper.RLock() + defer wrapper.RUnlock() + return wrapper.params.EnableGenerationCheck +} + func DoSyncIstioResourcesToSourceClusters() bool { wrapper.RLock() defer wrapper.RUnlock() diff --git a/admiral/pkg/controller/common/types.go b/admiral/pkg/controller/common/types.go index fb624bab3..9df6cbc36 100644 --- a/admiral/pkg/controller/common/types.go +++ b/admiral/pkg/controller/common/types.go @@ -99,6 +99,7 @@ type AdmiralParams struct { EnableSyncIstioResourcesToSourceClusters bool AdmiralStateSyncerMode bool DefaultWarmupDurationSecs int64 + EnableGenerationCheck bool // Cartographer specific params TrafficConfigPersona bool diff --git a/admiral/pkg/controller/istio/destinationrule.go b/admiral/pkg/controller/istio/destinationrule.go index 35a301cde..a3dbd2e04 100644 --- a/admiral/pkg/controller/istio/destinationrule.go +++ b/admiral/pkg/controller/istio/destinationrule.go @@ -39,6 +39,10 @@ type DestinationRuleController struct { Cluster string } +func (drc *DestinationRuleController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type DestinationRuleItem struct { DestinationRule *networking.DestinationRule Status string diff --git a/admiral/pkg/controller/istio/serviceentry.go b/admiral/pkg/controller/istio/serviceentry.go index 7c2ab9ef2..5d8b009ea 100644 --- a/admiral/pkg/controller/istio/serviceentry.go +++ b/admiral/pkg/controller/istio/serviceentry.go @@ -35,6 +35,10 @@ type ServiceEntryController struct { Cluster string } +func (s *ServiceEntryController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + type ServiceEntryItem struct { ServiceEntry *networking.ServiceEntry Status string diff --git a/admiral/pkg/controller/istio/sidecar.go b/admiral/pkg/controller/istio/sidecar.go index 12b8a1eb1..d8356f392 100644 --- a/admiral/pkg/controller/istio/sidecar.go +++ b/admiral/pkg/controller/istio/sidecar.go @@ -7,6 +7,7 @@ import ( "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + log "github.com/sirupsen/logrus" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/admiral" networking "istio.io/client-go/pkg/apis/networking/v1alpha3" @@ -35,6 +36,10 @@ type SidecarController struct { informer cache.SharedIndexInformer } +func (s *SidecarController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + func NewSidecarController(stopCh <-chan struct{}, handler SidecarHandler, config *rest.Config, resyncPeriod time.Duration, clientLoader loader.ClientLoader) (*SidecarController, error) { sidecarController := SidecarController{} diff --git a/admiral/pkg/controller/istio/virtualservice.go b/admiral/pkg/controller/istio/virtualservice.go index 0f98880c6..04c62f6ea 100644 --- a/admiral/pkg/controller/istio/virtualservice.go +++ b/admiral/pkg/controller/istio/virtualservice.go @@ -31,6 +31,10 @@ type VirtualServiceController struct { informer cache.SharedIndexInformer } +func (v *VirtualServiceController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { + return false, nil +} + func NewVirtualServiceController(stopCh <-chan struct{}, handler VirtualServiceHandler, config *rest.Config, resyncPeriod time.Duration, clientLoader loader.ClientLoader) (*VirtualServiceController, error) { vsController := VirtualServiceController{} diff --git a/admiral/pkg/test/mock.go b/admiral/pkg/test/mock.go index fee79701a..bffd775f7 100644 --- a/admiral/pkg/test/mock.go +++ b/admiral/pkg/test/mock.go @@ -40,9 +40,11 @@ func (m *MockIstioConfigStore) Delete(typ, name, namespace string) error { } type MockDeploymentHandler struct { + Obj *k8sAppsV1.Deployment } func (m *MockDeploymentHandler) Added(ctx context.Context, obj *k8sAppsV1.Deployment) error { + m.Obj = obj return nil } diff --git a/go.sum b/go.sum index d80e8dbda..7c93c5514 100644 --- a/go.sum +++ b/go.sum @@ -18,24 +18,142 @@ cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmW cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= +cloud.google.com/go v0.110.8/go.mod h1:Iz8AkXJf1qmxC3Oxoep8R1T36w8B92yU29PcBhHO5fk= +cloud.google.com/go/accessapproval v1.7.1/go.mod h1:JYczztsHRMK7NTXb6Xw+dwbs/WnOJxbo/2mTI+Kgg68= +cloud.google.com/go/accesscontextmanager v1.8.1/go.mod h1:JFJHfvuaTC+++1iL1coPiG1eu5D24db2wXCDWDjIrxo= +cloud.google.com/go/aiplatform v1.50.0/go.mod h1:IRc2b8XAMTa9ZmfJV1BCCQbieWWvDnP1A8znyz5N7y4= +cloud.google.com/go/analytics v0.21.3/go.mod h1:U8dcUtmDmjrmUTnnnRnI4m6zKn/yaA5N9RlEkYFHpQo= +cloud.google.com/go/apigateway v1.6.1/go.mod h1:ufAS3wpbRjqfZrzpvLC2oh0MFlpRJm2E/ts25yyqmXA= +cloud.google.com/go/apigeeconnect v1.6.1/go.mod h1:C4awq7x0JpLtrlQCr8AzVIzAaYgngRqWf9S5Uhg+wWs= +cloud.google.com/go/apigeeregistry v0.7.1/go.mod h1:1XgyjZye4Mqtw7T9TsY4NW10U7BojBvG4RMD+vRDrIw= +cloud.google.com/go/appengine v1.8.1/go.mod h1:6NJXGLVhZCN9aQ/AEDvmfzKEfoYBlfB80/BHiKVputY= +cloud.google.com/go/area120 v0.8.1/go.mod h1:BVfZpGpB7KFVNxPiQBuHkX6Ed0rS51xIgmGyjrAfzsg= +cloud.google.com/go/artifactregistry v1.14.1/go.mod h1:nxVdG19jTaSTu7yA7+VbWL346r3rIdkZ142BSQqhn5E= +cloud.google.com/go/asset v1.14.1/go.mod h1:4bEJ3dnHCqWCDbWJ/6Vn7GVI9LerSi7Rfdi03hd+WTQ= +cloud.google.com/go/assuredworkloads v1.11.1/go.mod h1:+F04I52Pgn5nmPG36CWFtxmav6+7Q+c5QyJoL18Lry0= +cloud.google.com/go/automl v1.13.1/go.mod h1:1aowgAHWYZU27MybSCFiukPO7xnyawv7pt3zK4bheQE= +cloud.google.com/go/baremetalsolution v1.2.0/go.mod h1:68wi9AwPYkEWIUT4SvSGS9UJwKzNpshjHsH4lzk8iOw= +cloud.google.com/go/batch v1.4.1/go.mod h1:KdBmDD61K0ovcxoRHGrN6GmOBWeAOyCgKD0Mugx4Fkk= +cloud.google.com/go/beyondcorp v1.0.0/go.mod h1:YhxDWw946SCbmcWo3fAhw3V4XZMSpQ/VYfcKGAEU8/4= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= +cloud.google.com/go/bigquery v1.55.0/go.mod h1:9Y5I3PN9kQWuid6183JFhOGOW3GcirA5LpsKCUn+2ec= +cloud.google.com/go/billing v1.17.0/go.mod h1:Z9+vZXEq+HwH7bhJkyI4OQcR6TSbeMrjlpEjO2vzY64= +cloud.google.com/go/binaryauthorization v1.7.0/go.mod h1:Zn+S6QqTMn6odcMU1zDZCJxPjU2tZPV1oDl45lWY154= +cloud.google.com/go/certificatemanager v1.7.1/go.mod h1:iW8J3nG6SaRYImIa+wXQ0g8IgoofDFRp5UMzaNk1UqI= +cloud.google.com/go/channel v1.17.0/go.mod h1:RpbhJsGi/lXWAUM1eF4IbQGbsfVlg2o8Iiy2/YLfVT0= +cloud.google.com/go/cloudbuild v1.14.0/go.mod h1:lyJg7v97SUIPq4RC2sGsz/9tNczhyv2AjML/ci4ulzU= +cloud.google.com/go/clouddms v1.7.0/go.mod h1:MW1dC6SOtI/tPNCciTsXtsGNEM0i0OccykPvv3hiYeM= +cloud.google.com/go/cloudtasks v1.12.1/go.mod h1:a9udmnou9KO2iulGscKR0qBYjreuX8oHwpmFsKspEvM= +cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= +cloud.google.com/go/contactcenterinsights v1.10.0/go.mod h1:bsg/R7zGLYMVxFFzfh9ooLTruLRCG9fnzhH9KznHhbM= +cloud.google.com/go/container v1.26.0/go.mod h1:YJCmRet6+6jnYYRS000T6k0D0xUXQgBSaJ7VwI8FBj4= +cloud.google.com/go/containeranalysis v0.11.0/go.mod h1:4n2e99ZwpGxpNcz+YsFT1dfOHPQFGcAC8FN2M2/ne/U= +cloud.google.com/go/datacatalog v1.17.1/go.mod h1:nCSYFHgtxh2MiEktWIz71s/X+7ds/UT9kp0PC7waCzE= +cloud.google.com/go/dataflow v0.9.1/go.mod h1:Wp7s32QjYuQDWqJPFFlnBKhkAtiFpMTdg00qGbnIHVw= +cloud.google.com/go/dataform v0.8.1/go.mod h1:3BhPSiw8xmppbgzeBbmDvmSWlwouuJkXsXsb8UBih9M= +cloud.google.com/go/datafusion v1.7.1/go.mod h1:KpoTBbFmoToDExJUso/fcCiguGDk7MEzOWXUsJo0wsI= +cloud.google.com/go/datalabeling v0.8.1/go.mod h1:XS62LBSVPbYR54GfYQsPXZjTW8UxCK2fkDciSrpRFdY= +cloud.google.com/go/dataplex v1.9.1/go.mod h1:7TyrDT6BCdI8/38Uvp0/ZxBslOslP2X2MPDucliyvSE= +cloud.google.com/go/dataproc/v2 v2.2.0/go.mod h1:lZR7AQtwZPvmINx5J87DSOOpTfof9LVZju6/Qo4lmcY= +cloud.google.com/go/dataqna v0.8.1/go.mod h1:zxZM0Bl6liMePWsHA8RMGAfmTG34vJMapbHAxQ5+WA8= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= +cloud.google.com/go/datastore v1.14.0/go.mod h1:GAeStMBIt9bPS7jMJA85kgkpsMkvseWWXiaHya9Jes8= +cloud.google.com/go/datastream v1.10.0/go.mod h1:hqnmr8kdUBmrnk65k5wNRoHSCYksvpdZIcZIEl8h43Q= +cloud.google.com/go/deploy v1.13.0/go.mod h1:tKuSUV5pXbn67KiubiUNUejqLs4f5cxxiCNCeyl0F2g= +cloud.google.com/go/dialogflow v1.43.0/go.mod h1:pDUJdi4elL0MFmt1REMvFkdsUTYSHq+rTCS8wg0S3+M= +cloud.google.com/go/dlp v1.10.1/go.mod h1:IM8BWz1iJd8njcNcG0+Kyd9OPnqnRNkDV8j42VT5KOI= +cloud.google.com/go/documentai v1.22.1/go.mod h1:LKs22aDHbJv7ufXuPypzRO7rG3ALLJxzdCXDPutw4Qc= +cloud.google.com/go/domains v0.9.1/go.mod h1:aOp1c0MbejQQ2Pjf1iJvnVyT+z6R6s8pX66KaCSDYfE= +cloud.google.com/go/edgecontainer v1.1.1/go.mod h1:O5bYcS//7MELQZs3+7mabRqoWQhXCzenBu0R8bz2rwk= +cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= +cloud.google.com/go/essentialcontacts v1.6.2/go.mod h1:T2tB6tX+TRak7i88Fb2N9Ok3PvY3UNbUsMag9/BARh4= +cloud.google.com/go/eventarc v1.13.0/go.mod h1:mAFCW6lukH5+IZjkvrEss+jmt2kOdYlN8aMx3sRJiAI= +cloud.google.com/go/filestore v1.7.1/go.mod h1:y10jsorq40JJnjR/lQ8AfFbbcGlw3g+Dp8oN7i7FjV4= +cloud.google.com/go/firestore v1.13.0/go.mod h1:QojqqOh8IntInDUSTAh0c8ZsPYAr68Ma8c5DWOy8xb8= +cloud.google.com/go/functions v1.15.1/go.mod h1:P5yNWUTkyU+LvW/S9O6V+V423VZooALQlqoXdoPz5AE= +cloud.google.com/go/gkebackup v1.3.1/go.mod h1:vUDOu++N0U5qs4IhG1pcOnD1Mac79xWy6GoBFlWCWBU= +cloud.google.com/go/gkeconnect v0.8.1/go.mod h1:KWiK1g9sDLZqhxB2xEuPV8V9NYzrqTUmQR9shJHpOZw= +cloud.google.com/go/gkehub v0.14.1/go.mod h1:VEXKIJZ2avzrbd7u+zeMtW00Y8ddk/4V9511C9CQGTY= +cloud.google.com/go/gkemulticloud v1.0.0/go.mod h1:kbZ3HKyTsiwqKX7Yw56+wUGwwNZViRnxWK2DVknXWfw= +cloud.google.com/go/gsuiteaddons v1.6.1/go.mod h1:CodrdOqRZcLp5WOwejHWYBjZvfY0kOphkAKpF/3qdZY= +cloud.google.com/go/iam v1.1.2/go.mod h1:A5avdyVL2tCppe4unb0951eI9jreack+RJ0/d+KUZOU= +cloud.google.com/go/iap v1.9.0/go.mod h1:01OFxd1R+NFrg78S+hoPV5PxEzv22HXaNqUUlmNHFuY= +cloud.google.com/go/ids v1.4.1/go.mod h1:np41ed8YMU8zOgv53MMMoCntLTn2lF+SUzlM+O3u/jw= +cloud.google.com/go/iot v1.7.1/go.mod h1:46Mgw7ev1k9KqK1ao0ayW9h0lI+3hxeanz+L1zmbbbk= +cloud.google.com/go/kms v1.15.2/go.mod h1:3hopT4+7ooWRCjc2DxgnpESFxhIraaI2IpAVUEhbT/w= +cloud.google.com/go/language v1.11.0/go.mod h1:uDx+pFDdAKTY8ehpWbiXyQdz8tDSYLJbQcXsCkjYyvQ= +cloud.google.com/go/lifesciences v0.9.1/go.mod h1:hACAOd1fFbCGLr/+weUKRAJas82Y4vrL3O5326N//Wc= +cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= +cloud.google.com/go/longrunning v0.5.1/go.mod h1:spvimkwdz6SPWKEt/XBij79E9fiTkHSQl/fRUUQJYJc= +cloud.google.com/go/managedidentities v1.6.1/go.mod h1:h/irGhTN2SkZ64F43tfGPMbHnypMbu4RB3yl8YcuEak= +cloud.google.com/go/maps v1.4.0/go.mod h1:6mWTUv+WhnOwAgjVsSW2QPPECmW+s3PcRyOa9vgG/5s= +cloud.google.com/go/mediatranslation v0.8.1/go.mod h1:L/7hBdEYbYHQJhX2sldtTO5SZZ1C1vkapubj0T2aGig= +cloud.google.com/go/memcache v1.10.1/go.mod h1:47YRQIarv4I3QS5+hoETgKO40InqzLP6kpNLvyXuyaA= +cloud.google.com/go/metastore v1.12.0/go.mod h1:uZuSo80U3Wd4zi6C22ZZliOUJ3XeM/MlYi/z5OAOWRA= +cloud.google.com/go/monitoring v1.16.0/go.mod h1:Ptp15HgAyM1fNICAojDMoNc/wUmn67mLHQfyqbw+poY= +cloud.google.com/go/networkconnectivity v1.13.0/go.mod h1:SAnGPes88pl7QRLUen2HmcBSE9AowVAcdug8c0RSBFk= +cloud.google.com/go/networkmanagement v1.9.0/go.mod h1:UTUaEU9YwbCAhhz3jEOHr+2/K/MrBk2XxOLS89LQzFw= +cloud.google.com/go/networksecurity v0.9.1/go.mod h1:MCMdxOKQ30wsBI1eI659f9kEp4wuuAueoC9AJKSPWZQ= +cloud.google.com/go/notebooks v1.10.0/go.mod h1:SOPYMZnttHxqot0SGSFSkRrwE29eqnKPBJFqgWmiK2k= +cloud.google.com/go/optimization v1.5.0/go.mod h1:evo1OvTxeBRBu6ydPlrIRizKY/LJKo/drDMMRKqGEUU= +cloud.google.com/go/orchestration v1.8.1/go.mod h1:4sluRF3wgbYVRqz7zJ1/EUNc90TTprliq9477fGobD8= +cloud.google.com/go/orgpolicy v1.11.1/go.mod h1:8+E3jQcpZJQliP+zaFfayC2Pg5bmhuLK755wKhIIUCE= +cloud.google.com/go/osconfig v1.12.1/go.mod h1:4CjBxND0gswz2gfYRCUoUzCm9zCABp91EeTtWXyz0tE= +cloud.google.com/go/oslogin v1.10.1/go.mod h1:x692z7yAue5nE7CsSnoG0aaMbNoRJRXO4sn73R+ZqAs= +cloud.google.com/go/phishingprotection v0.8.1/go.mod h1:AxonW7GovcA8qdEk13NfHq9hNx5KPtfxXNeUxTDxB6I= +cloud.google.com/go/policytroubleshooter v1.9.0/go.mod h1:+E2Lga7TycpeSTj2FsH4oXxTnrbHJGRlKhVZBLGgU64= +cloud.google.com/go/privatecatalog v0.9.1/go.mod h1:0XlDXW2unJXdf9zFz968Hp35gl/bhF4twwpXZAW50JA= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= +cloud.google.com/go/pubsub v1.33.0/go.mod h1:f+w71I33OMyxf9VpMVcZbnG5KSUkCOUHYpFd5U1GdRc= +cloud.google.com/go/pubsublite v1.8.1/go.mod h1:fOLdU4f5xldK4RGJrBMm+J7zMWNj/k4PxwEZXy39QS0= +cloud.google.com/go/recaptchaenterprise/v2 v2.7.2/go.mod h1:kR0KjsJS7Jt1YSyWFkseQ756D45kaYNTlDPPaRAvDBU= +cloud.google.com/go/recommendationengine v0.8.1/go.mod h1:MrZihWwtFYWDzE6Hz5nKcNz3gLizXVIDI/o3G1DLcrE= +cloud.google.com/go/recommender v1.11.0/go.mod h1:kPiRQhPyTJ9kyXPCG6u/dlPLbYfFlkwHNRwdzPVAoII= +cloud.google.com/go/redis v1.13.1/go.mod h1:VP7DGLpE91M6bcsDdMuyCm2hIpB6Vp2hI090Mfd1tcg= +cloud.google.com/go/resourcemanager v1.9.1/go.mod h1:dVCuosgrh1tINZ/RwBufr8lULmWGOkPS8gL5gqyjdT8= +cloud.google.com/go/resourcesettings v1.6.1/go.mod h1:M7mk9PIZrC5Fgsu1kZJci6mpgN8o0IUzVx3eJU3y4Jw= +cloud.google.com/go/retail v1.14.1/go.mod h1:y3Wv3Vr2k54dLNIrCzenyKG8g8dhvhncT2NcNjb/6gE= +cloud.google.com/go/run v1.2.0/go.mod h1:36V1IlDzQ0XxbQjUx6IYbw8H3TJnWvhii963WW3B/bo= +cloud.google.com/go/scheduler v1.10.1/go.mod h1:R63Ldltd47Bs4gnhQkmNDse5w8gBRrhObZ54PxgR2Oo= +cloud.google.com/go/secretmanager v1.11.1/go.mod h1:znq9JlXgTNdBeQk9TBW/FnR/W4uChEKGeqQWAJ8SXFw= +cloud.google.com/go/security v1.15.1/go.mod h1:MvTnnbsWnehoizHi09zoiZob0iCHVcL4AUBj76h9fXA= +cloud.google.com/go/securitycenter v1.23.0/go.mod h1:8pwQ4n+Y9WCWM278R8W3nF65QtY172h4S8aXyI9/hsQ= +cloud.google.com/go/servicedirectory v1.11.0/go.mod h1:Xv0YVH8s4pVOwfM/1eMTl0XJ6bzIOSLDt8f8eLaGOxQ= +cloud.google.com/go/shell v1.7.1/go.mod h1:u1RaM+huXFaTojTbW4g9P5emOrrmLE69KrxqQahKn4g= +cloud.google.com/go/spanner v1.49.0/go.mod h1:eGj9mQGK8+hkgSVbHNQ06pQ4oS+cyc4tXXd6Dif1KoM= +cloud.google.com/go/speech v1.19.0/go.mod h1:8rVNzU43tQvxDaGvqOhpDqgkJTFowBpDvCJ14kGlJYo= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= +cloud.google.com/go/storagetransfer v1.10.0/go.mod h1:DM4sTlSmGiNczmV6iZyceIh2dbs+7z2Ayg6YAiQlYfA= +cloud.google.com/go/talent v1.6.2/go.mod h1:CbGvmKCG61mkdjcqTcLOkb2ZN1SrQI8MDyma2l7VD24= +cloud.google.com/go/texttospeech v1.7.1/go.mod h1:m7QfG5IXxeneGqTapXNxv2ItxP/FS0hCZBwXYqucgSk= +cloud.google.com/go/tpu v1.6.1/go.mod h1:sOdcHVIgDEEOKuqUoi6Fq53MKHJAtOwtz0GuKsWSH3E= +cloud.google.com/go/trace v1.10.1/go.mod h1:gbtL94KE5AJLH3y+WVpfWILmqgc6dXcqgNXdOPAQTYk= +cloud.google.com/go/translate v1.9.0/go.mod h1:d1ZH5aaOA0CNhWeXeC8ujd4tdCFw8XoNWRljklu5RHs= +cloud.google.com/go/video v1.20.0/go.mod h1:U3G3FTnsvAGqglq9LxgqzOiBc/Nt8zis8S+850N2DUM= +cloud.google.com/go/videointelligence v1.11.1/go.mod h1:76xn/8InyQHarjTWsBR058SmlPCwQjgcvoW0aZykOvo= +cloud.google.com/go/vision/v2 v2.7.2/go.mod h1:jKa8oSYBWhYiXarHPvP4USxYANYUEdEsQrloLjrSwJU= +cloud.google.com/go/vmmigration v1.7.1/go.mod h1:WD+5z7a/IpZ5bKK//YmT9E047AD+rjycCAvyMxGJbro= +cloud.google.com/go/vmwareengine v1.0.0/go.mod h1:Px64x+BvjPZwWuc4HdmVhoygcXqEkGHXoa7uyfTgSI0= +cloud.google.com/go/vpcaccess v1.7.1/go.mod h1:FogoD46/ZU+JUBX9D606X21EnxiszYi2tArQwLY4SXs= +cloud.google.com/go/webrisk v1.9.1/go.mod h1:4GCmXKcOa2BZcZPn6DCEvE7HypmEJcJkr4mtM+sqYPc= +cloud.google.com/go/websecurityscanner v1.6.1/go.mod h1:Njgaw3rttgRHXzwCB8kgCYqv5/rGpFCsBOvPbYgszpg= +cloud.google.com/go/workflows v1.12.0/go.mod h1:PYhSk2b6DhZ508tj8HXKaBh+OFe+xdl0dHF/tJdzPQM= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= +github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA= github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M= @@ -45,23 +163,46 @@ github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZ github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= +github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd/go.mod h1:64YHyfSL2R96J44Nlwm39UHepQbyR5q10x7iYa1ks2E= +github.com/Masterminds/goutils v1.1.0/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= +github.com/Masterminds/semver v1.5.0/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y= +github.com/Masterminds/sprig v2.22.0+incompatible/go.mod h1:y6hNFY5UBTIWBxnzTeuNhlNS5hqE0NB0E6fgfo2Br3o= github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= +github.com/RocketChat/Rocket.Chat.Go.SDK v0.0.0-20210112200207-10ab4d695d60/go.mod h1:rjP7sIipbZcagro/6TCk6X0ZeFT2eyudH5+fve/cbBA= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d h1:UQZhZ2O0vMHr2cI+DC1Mbh0TJxzA3RcLoMsFw+aXw7E= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= +github.com/antonmedv/expr v1.9.0/go.mod h1:5qsM3oLGDND7sDmQGDXHkYfkjYMUX14qsgqmHhwGEk8= github.com/argoproj/argo-rollouts v1.2.1 h1:4hSgKEqpQsZreZBv+XcLsB+oBaRGMVW19nMScx5ikIQ= github.com/argoproj/argo-rollouts v1.2.1/go.mod h1:ETmWr9Lysxr9SgbqalMMBdytBcDHUt9qulFoKJ9b9ZU= +github.com/argoproj/notifications-engine v0.3.1-0.20220129012210-32519f8f68ec/go.mod h1:QF4tr3wfWOnhkKSaRpx7k/KEErQAh8iwKQ2pYFu/SfA= +github.com/argoproj/pkg v0.9.0/go.mod h1:ra+bQPmbVAoEL+gYSKesuigt4m49i3Qa3mE/xQcjCiA= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/aws/aws-sdk-go v1.55.2 h1:/2OFM8uFfK9e+cqHTw9YPrvTzIXT2XkFGXRM7WbJb7E= github.com/aws/aws-sdk-go v1.55.2/go.mod h1:eRwEWoyTWFMVYVQzKMNHWP5/RV4xIUGMQfXQHfHkpNU= +github.com/aws/aws-sdk-go-v2 v1.13.0/go.mod h1:L6+ZpqHaLbAaxsqV0L4cvxZY7QupWJB4fhkf8LXvC7w= +github.com/aws/aws-sdk-go-v2/config v1.13.1/go.mod h1:Ba5Z4yL/UGbjQUzsiaN378YobhFo0MLfueXGiOsYtEs= +github.com/aws/aws-sdk-go-v2/credentials v1.8.0/go.mod h1:gnMo58Vwx3Mu7hj1wpcG8DI0s57c9o42UQ6wgTQT5to= +github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.10.0/go.mod h1:I6/fHT/fH460v09eg2gVrd8B/IqskhNdpcLH0WNO3QI= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.4/go.mod h1:XHgQ7Hz2WY2GAn//UXHofLfPXWh+s62MbMOijrg12Lw= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.2.0/go.mod h1:BsCSJHx5DnDXIrOcqB8KN1/B+hXLG/bi4Y6Vjcx/x9E= +github.com/aws/aws-sdk-go-v2/internal/ini v1.3.5/go.mod h1:R3sWUqPcfXSiF/LSFJhjyJmpg9uV6yP2yv3YZZjldVI= +github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.15.0/go.mod h1:bPS4S6vXEGUVMabXYHOJRFvoWrztb38v4i84i8Hd6ZY= +github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2 v1.16.0/go.mod h1:5rsn/Fxs9Rnq28KLB8n1pJcRR3UtrHY787uapxrvDRA= +github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.7.0/go.mod h1:K/qPe6AP2TGYv4l6n7c88zh9jWBDf6nHhvg1fx/EWfU= +github.com/aws/aws-sdk-go-v2/service/sso v1.9.0/go.mod h1:vCV4glupK3tR7pw7ks7Y4jYRL86VvxS+g5qk04YeWrU= +github.com/aws/aws-sdk-go-v2/service/sts v1.14.0/go.mod h1:u0xMJKDvvfocRjiozsoZglVNXRG19043xzp3r2ivLIk= +github.com/aws/smithy-go v1.10.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk= +github.com/bradleyfalzon/ghinstallation/v2 v2.0.4/go.mod h1:B40qPqJxWE0jDZgOR1JmaMy+4AY1eBP+IByOvqyAKp0= github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -70,6 +211,7 @@ github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghf github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/chai2010/gettext-go v0.0.0-20160711120539-c6fed771bfd5/go.mod h1:/iP1qXHoty45bqomnu2LM+VVyAEdWN+vtSHGlQgyxbw= github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927 h1:SKI1/fuSdodxmNNyVBR8d7X/HuLnRpvvFO0AgyQk764= github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927/go.mod h1:h/aW8ynjgkuj+NQRlZcDbAbM1ORAbXjXX77sX7T289U= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= @@ -82,9 +224,11 @@ github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnht github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= github.com/emicklei/go-restful/v3 v3.10.1 h1:rc42Y5YTp7Am7CS630D7JmhRjq4UlEUuEKfrDac4bSQ= @@ -98,12 +242,17 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.m github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84= github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= +github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4= +github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d/go.mod h1:ZZMPRZwes7CROmyNKgQzC3XPs6L/G2EJLHddWejkmf4= +github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/flowstack/go-jsonschema v0.1.1/go.mod h1:yL7fNggx1o8rm9RlgXv7hTBWxdBM0rVwpMwimd3F3N0= github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU= github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32/go.mod h1:GIjDIg/heH5DOkXY3YJ/wNhfHsQHoXGjl8G8amsYQ1I= +github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -132,9 +281,12 @@ github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+ github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= +github.com/go-telegram-bot-api/telegram-bot-api/v5 v5.4.0/go.mod h1:A2S0CWkNylc2phvKXWBBdD3K0iGnDBGbzRpISP2zBl8= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -147,6 +299,7 @@ github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= +github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -185,6 +338,8 @@ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-github/v41 v41.0.0/go.mod h1:XgmCA5H323A9rtgExdTcnDkcqp6S30AVACCBDOonIxg= +github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -206,19 +361,26 @@ github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20211214055906-6f57359322fd h1:1FjCyPC+syAzJ5/2S8fqdZK1R22vvA0J7JZKcuOIQ7Y= github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= +github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= +github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/gregdel/pushover v1.1.0/go.mod h1:EcaO66Nn1StkpEm1iKtBTV3d2A16SoMsVER1PthX7to= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= +github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= +github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= +github.com/hashicorp/go-retryablehttp v0.7.0/go.mod h1:vAew36LZh98gCBJNLH42IQ1ER/9wtLZZ8meHqQvEYWY= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= +github.com/huandu/xstrings v1.3.2/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20210905161508-09a460cdf81d/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= @@ -240,6 +402,7 @@ github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnr github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= +github.com/juju/ansiterm v0.0.0-20180109212912-720a0952cc2a/go.mod h1:UJSiEoRfvx3hP73CvoARgeLjaIOjybY9vj8PUPPFGeU= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= @@ -253,6 +416,8 @@ github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de/go.mod h1:zAbeS9B/r2mtpb6U+EI2rYA5OAXxsYw6wTamcNW+zcE= +github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= @@ -260,11 +425,18 @@ github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0 github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/matryer/resync v0.0.0-20161211202428-d39c09a11215 h1:hDa3vAq/Zo5gjfJ46XMsGFbH+hTizpR4fUzQCk2nxgk= github.com/matryer/resync v0.0.0-20161211202428-d39c09a11215/go.mod h1:LH+NgPY9AJpDfqAFtzyer01N9MYNsAKUf3DC9DV1xIY= +github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= +github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= +github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= +github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/reflectwalk v1.0.1/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= +github.com/moby/term v0.0.0-20210610120745-9d4ed1856297/go.mod h1:vgPCkQMyxTZ7IDy8SXRufE172gr8+K/JE/7hHFxHW3A= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -272,11 +444,13 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= +github.com/newrelic/newrelic-client-go v0.72.0/go.mod h1:VXjhsfui0rvhM9cVwnKwlidF8NbXlHZvh63ZKi6fImA= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= @@ -290,6 +464,9 @@ github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7J github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= +github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= +github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0= +github.com/opsgenie/opsgenie-go-sdk-v2 v1.0.5/go.mod h1:f0ezb0R/mrB9Hpm5RrIS6EX3ydjsR2nAB88nYYXZcNY= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -311,10 +488,15 @@ github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6L github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= +github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/servicemeshinterface/smi-sdk-go v0.4.1/go.mod h1:9rsLPBNcqfDNmEgyYwpopn93aE9yz46d2EHFBNOYj/w= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= +github.com/slack-go/slack v0.10.1/go.mod h1:wWL//kk0ho+FcQXcBTmEafUI5dz4qz5f4mMk8oIkioQ= +github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= +github.com/spaceapegames/go-wavefront v1.8.1/go.mod h1:GtdIjtJ0URkfPmaKx0+7vMSDvT/MON9v+4pbdagA8As= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU= @@ -338,9 +520,15 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/tj/assert v0.0.3/go.mod h1:Ne6X72Q+TB1AteidzQncjw9PabbMp4PBMZ1k+vd1Pvk= +github.com/tomnomnom/linkheader v0.0.0-20180905144013-02ca5825eb80/go.mod h1:iFyPdL66DjUD96XmzVL3ZntbzcflLnznH0fr99w5VqE= +github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= +github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= +github.com/whilp/git-urls v0.0.0-20191001220047-6db9661140c0/go.mod h1:2rx5KE5FLD0HRfkkpyn8JwbVLBdhgeiOb2D2D9LLKM4= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= +github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -366,6 +554,7 @@ go.opentelemetry.io/otel/sdk/metric v1.27.0/go.mod h1:we7jJVrYN2kh3mVBlswtPU22K0 go.opentelemetry.io/otel/trace v1.27.0 h1:IqYb813p7cmbHk0a5y6pD5JPakbVfftRXABGt5/Rscw= go.opentelemetry.io/otel/trace v1.27.0/go.mod h1:6RiD1hkAprV4/q+yd2ln1HG9GoPx39SuvvstaLBl+l4= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= +go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5/go.mod h1:nmDLcffg48OtT/PSW0Hg7FvpRQsQh5OSqIylirxKC7o= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -373,6 +562,7 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -407,6 +597,7 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -472,6 +663,7 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -601,6 +793,9 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +gomodules.xyz/envconfig v1.3.1-0.20190308184047-426f31af0d45/go.mod h1:41y72mzHT7+jFNgyBpJRrZWuZJcLmLrTpq6iGgOFJMQ= +gomodules.xyz/notify v0.1.0/go.mod h1:wGy0vLXGpabCg0j9WbjzXf7pM7Khz11FqCLtBbTujP0= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -676,6 +871,7 @@ google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13 h1:U7+wNaVuSTaUqNvK2+osJ9ejEZxbjHHk8F2b6Hpx0AE= google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13/go.mod h1:RdyHbowztCGQySiCvQPgWQWgWhGnouTdCflKoDBt32U= +google.golang.org/genproto/googleapis/rpc v0.0.0-20230920204549-e6e6cdab5c13/go.mod h1:KSqppvjFjtoCI+KGd4PELB0qLNxdJHRGqRI09mB6pQA= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -696,6 +892,7 @@ google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAG google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= +google.golang.org/grpc v1.57.0/go.mod h1:Sd+9RMTACXwmub0zcNY2c4arhtrbBYD1AUHI/dt16Mo= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -713,6 +910,7 @@ google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFW google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= +gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -721,6 +919,7 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= +gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= @@ -751,10 +950,17 @@ istio.io/client-go v1.14.0 h1:KKXMnxXx3U2866OP8FBYlJhjKdI3yIUQnt8L6hSzDHE= istio.io/client-go v1.14.0/go.mod h1:C7K0CKQlvY84yQKkZhxQbD1riqvnsgXJm3jF5GOmzNg= k8s.io/api v0.24.2 h1:g518dPU/L7VRLxWfcadQn2OnsiGWVOadTLpdnqgY2OI= k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= +k8s.io/apiextensions-apiserver v0.24.2/go.mod h1:e5t2GMFVngUEHUd0wuCJzw8YDwZoqZfJiGOW6mm2hLQ= k8s.io/apimachinery v0.24.2 h1:5QlH9SL2C8KMcrNJPor+LbXVTaZRReml7svPEh4OKDM= k8s.io/apimachinery v0.24.2/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= +k8s.io/apiserver v0.24.2/go.mod h1:pSuKzr3zV+L+MWqsEo0kHHYwCo77AT5qXbFXP2jbvFI= +k8s.io/cli-runtime v0.24.2/go.mod h1:1LIhKL2RblkhfG4v5lZEt7FtgFG5mVb8wqv5lE9m5qY= k8s.io/client-go v0.24.2 h1:CoXFSf8if+bLEbinDqN9ePIDGzcLtqhfd6jpfnwGOFA= k8s.io/client-go v0.24.2/go.mod h1:zg4Xaoo+umDsfCWr4fCnmLEtQXyCNXCvJuSsglNcV30= +k8s.io/cluster-bootstrap v0.24.2/go.mod h1:eIHV338K03vBm3u/ROZiNXxWJ4AJRoTR9PEUhcTvYkg= +k8s.io/code-generator v0.24.2/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= +k8s.io/component-base v0.24.2/go.mod h1:ucHwW76dajvQ9B7+zecZAP3BVqvrHoOxm8olHEg0nmM= +k8s.io/component-helpers v0.24.2/go.mod h1:TRQPBQKfmqkmV6c0HAmUs8cXVNYYYLsXy4zu8eODi9g= k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= @@ -764,6 +970,8 @@ k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5 h1:/zkKSeCtGRHYqRmrpa9uPYDWMpmQ5bZijBSoOpW384c= k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5/go.mod h1:/BYxry62FuDzmI+i9B+X2pqfySRmSOW2ARmj5Zbqhj0= +k8s.io/kubectl v0.24.2/go.mod h1:+HIFJc0bA6Tzu5O/YcuUt45APAxnNL8LeMuXwoiGsPg= +k8s.io/kubernetes v1.23.1/go.mod h1:baMGbPpwwP0kT/+eAPtdqoWNRoXyyTJ2Zf+fw/Y8t04= k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 h1:qY1Ad8PODbnymg2pRbkyMT/ylpTrCM8P2RJ0yroCyIk= @@ -774,6 +982,8 @@ rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2/go.mod h1:B+TnT182UBxE84DiCz4CVE26eOSDAeYCpfDnC2kdKMY= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +sigs.k8s.io/kustomize/api v0.10.1/go.mod h1:2FigT1QN6xKdcnGS2Ppp1uIWrtWN28Ms8A3OZUZhwr8= +sigs.k8s.io/kustomize/kyaml v0.13.0/go.mod h1:FTJxEZ86ScK184NpGSAQcfEqee0nul8oLCK30D47m4E= sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= sigs.k8s.io/structured-merge-diff/v4 v4.2.1/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= sigs.k8s.io/structured-merge-diff/v4 v4.2.3 h1:PRbqxJClWWYMNV1dhaG4NsibJbArud9kFxnAMREiWFE= diff --git a/tests/perf/perf_service_test.go b/tests/perf/perf_service_test.go new file mode 100644 index 000000000..d053a1b7c --- /dev/null +++ b/tests/perf/perf_service_test.go @@ -0,0 +1,136 @@ +package perf + +import ( + "fmt" + "time" + + "github.com/jamiealquiza/tachymeter" + . "github.com/onsi/gomega" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +var _ PerfHandler = (*ServicePerfHandler)(nil) + +type ServicePerfHandler struct { + source ClusterAssetMap + destination ClusterAssetMap +} + +func NewServicePerfHandler(sourceClusterAssetMap, destinationClusterAssetMap ClusterAssetMap) *tachymeter.Metrics { + a := &ServicePerfHandler{ + source: sourceClusterAssetMap, + destination: destinationClusterAssetMap, + } + + return a.Run() +} + +func (a *ServicePerfHandler) Run() *tachymeter.Metrics { + defer a.Revert() + return computeMetrics(a.Action(), a.Reaction()) +} + +func (a *ServicePerfHandler) Action() TimeMap { + timeMap := make(TimeMap) + + for destinationAsset, destinationClusters := range a.destination { + client := getKubeClient(destinationClusters.west) + namespace := getNamespaceName(destinationAsset) + dep, err := client.AppsV1().Deployments(namespace).Get(ctx, getDeploymentName(destinationAsset), metav1.GetOptions{}) + if dep != nil && err == nil { + timeMap[destinationAsset] = handleDeployment(destinationClusters.west, destinationAsset, RegionWest, TempServiceIdentifier) + } else { + timeMap[destinationAsset] = handleRollout(destinationClusters.west, destinationAsset, TempServiceIdentifier) + } + } + + return timeMap +} + +func (a *ServicePerfHandler) Reaction() TimeMultiMap { + timeMap := make(TimeMultiMap) + + for sourceAsset, sourceClusters := range a.source { + timeMap[sourceAsset] = make([]time.Time, 0) + + fmt.Printf("\twaiting for service entries to get updated in cluster %q\n", sourceClusters.west) + + for destinationAsset, destinationClusters := range a.destination { + if sourceClusters.west == destinationClusters.west { + timeMap[destinationAsset] = append(timeMap[destinationAsset], a.wait(sourceClusters.west, sourceAsset, destinationAsset)) + } + } + } + + return timeMap +} + +func (a *ServicePerfHandler) Revert() { + for destinationAsset, destinationClusters := range a.destination { + client := getKubeClient(destinationClusters.west) + namespace := getNamespaceName(destinationAsset) + deploymentName := getDeploymentName(destinationAsset) + dep, err := client.AppsV1().Deployments(namespace).Get(ctx, deploymentName, metav1.GetOptions{}) + if dep != nil && err == nil { + handleDeployment(destinationClusters.west, destinationAsset, TempServiceIdentifier, RegionWest) + } else { + handleRollout(destinationClusters.west, destinationAsset, StableServiceIdentifier) + } + } +} + +func (a *ServicePerfHandler) wait(sourceCluster, sourceAsset, destinationAsset string) time.Time { + var ts time.Time + serviceEntryName := getServiceEntryName(destinationAsset) + + Eventually(func(g Gomega) { + se, err := getIstioClient(sourceCluster).NetworkingV1alpha3().ServiceEntries(SyncNamespace).Get(ctx, serviceEntryName, metav1.GetOptions{}) + g.Expect(err).ToNot(HaveOccurred()) + g.Expect(se).ToNot(BeNil()) + g.Expect(se.Spec.ExportTo).To(ContainElement(getNamespaceName(sourceAsset))) + g.Expect(len(se.Spec.Hosts)).To(Equal(1)) + g.Expect(len(se.Spec.Addresses)).To(Equal(1)) + g.Expect(len(se.Spec.Endpoints)).To(Equal(2)) + localAddress := getLocalServiceEntryAddress(getServiceName(destinationAsset, TempServiceIdentifier), getNamespaceName(destinationAsset)) + g.Expect(se.Spec.Endpoints).To(ContainElement(HaveField("Address", Equal(localAddress)))) + ts = getLastUpdatedTime(se.GetAnnotations()) + }).WithTimeout(ServiceEntryWaitTime).WithPolling(time.Second).Should(Succeed()) + + return ts +} + +func handleDeployment(cluster, asset, oldServiceIdentifier, newServiceIdentifier string) time.Time { + namespace := getNamespaceName(asset) + client := getKubeClient(cluster) + Expect(client.CoreV1().Services(namespace).Delete(ctx, getServiceName(asset, oldServiceIdentifier), metav1.DeleteOptions{})).ToNot(HaveOccurred()) + + svc, err := client.CoreV1().Services(namespace).Create(ctx, getServiceSpec(asset, newServiceIdentifier), metav1.CreateOptions{}) + Expect(err).ToNot(HaveOccurred()) + Expect(svc).ToNot(BeNil()) + + return getLastUpdatedTime(svc.GetAnnotations()) +} + +func handleRollout(cluster, asset, serviceIdentifier string) time.Time { + kubeClient := getKubeClient(cluster) + argoClient := getArgoClient(cluster) + namespace := getNamespaceName(asset) + + if serviceIdentifier == TempServiceIdentifier { + kubeClient.CoreV1().Services(namespace).Create(ctx, getServiceSpec(asset, TempServiceIdentifier), metav1.CreateOptions{}) + } + + ro, err := argoClient.ArgoprojV1alpha1().Rollouts(namespace).Get(ctx, getRolloutName(asset), metav1.GetOptions{}) + Expect(err).ToNot(HaveOccurred()) + Expect(ro).ToNot(BeNil()) + + ro.Spec.Strategy.Canary.StableService = getServiceName(asset, serviceIdentifier) + + ro.Generation++ + + ro, err = argoClient.ArgoprojV1alpha1().Rollouts(namespace).Update(ctx, ro, metav1.UpdateOptions{}) + Expect(err).ToNot(HaveOccurred()) + Expect(ro).ToNot(BeNil()) + + return getLastUpdatedTime(ro.GetAnnotations()) +} From f071c4d92e8f419be7df604cde40c6f6b9637477 Mon Sep 17 00:00:00 2001 From: rtay1188 Date: Sun, 28 Jul 2024 17:57:47 -0400 Subject: [PATCH 2/8] Operator Shards * add sample identity configuration json response * struct for identityConfig * basic cache structure * implemented interface for config discovery * add ctxLoggers * include type in CRD * first pass at building SE from identityConfig * comments * function to make IdentityConfigEnvironment * edit ctx and function names * change struct names * drafted of SEbuilder * test * shard controller setup * change names * placeholder * factor out parts of build se * factor out ingressendpoint * merge in master * linter error * add comments and make methods private * added some tests * add tests * finish tests for sebuilder * testing * test * shard controller first pass * add registry client to controller * add concurrent processing of IdentityConfig * pin kube-openapi version and fix tests * fix concurrent test issue * add some tests for shard controller * add more tests * add logvalueofadmiraltoignore test * add processitem tests * add test * addUpdateSE * fix import cycle * shard handler basic test * add config options and label selector * additional test files * minor changes to tests * change shard controller to not be per cluster * change sebuilder to use destination cluster * remove unused operator cluster of registry client * abstract readFile * fix config path * change var and func names * make registryClient private * remove labeloptions * additional test coverage * update tests * fix test names * fix comments * fixed some review comments * removed HA * consolidate ctx and ctxlogger * remove controllers for operator * remove unnecessary equals * rework endpoint processing * move client asset out of cluster scope * change bool * fix test name typo * fix review comments * add function comments * cater to review comments * edit port comments * change soureCluster to serverCluster * add generation check for shard controller Signed-off-by: Shriram Sharma --- admiral/cmd/admiral/cmd/root.go | 11 +- admiral/pkg/client/loader/client_loader.go | 4 + admiral/pkg/client/loader/fake_loader.go | 17 + admiral/pkg/client/loader/kube_loader.go | 14 +- admiral/pkg/clusters/configwriter.go | 186 ++++++++++ admiral/pkg/clusters/configwriter_test.go | 324 ++++++++++++++++++ admiral/pkg/clusters/registry.go | 115 +++---- admiral/pkg/clusters/registry_test.go | 39 +-- admiral/pkg/clusters/serviceentry_test.go | 3 + admiral/pkg/clusters/shard_handler.go | 151 ++++++++ admiral/pkg/clusters/shard_handler_test.go | 177 ++++++++++ ...eshtestblackholeIdentityConfiguration.json | 123 +++++++ ...meshtestinboundsIdentityConfiguration.json | 64 ++++ .../testdata/sampleIdentityConfiguration.json | 159 +++++++++ admiral/pkg/clusters/types.go | 21 +- admiral/pkg/controller/admiral/shard.go | 243 +++++++++++++ admiral/pkg/controller/admiral/shard_test.go | 300 ++++++++++++++++ admiral/pkg/controller/common/common.go | 2 +- admiral/pkg/controller/common/config.go | 12 + admiral/pkg/controller/common/config_test.go | 10 + admiral/pkg/controller/common/types.go | 4 + admiral/pkg/registry/registry.go | 55 +-- admiral/pkg/registry/registry_test.go | 109 +++++- admiral/pkg/registry/serviceentry.go | 204 ----------- admiral/pkg/registry/serviceentry_test.go | 197 ----------- .../testdata/sampleIdentityConfiguration.json | 174 ++++++++++ admiral/pkg/registry/testutils.go | 65 ++++ admiral/pkg/test/mock.go | 12 + go.mod | 77 ++++- go.sum | 210 ++++++++++-- 30 files changed, 2503 insertions(+), 579 deletions(-) create mode 100644 admiral/pkg/clusters/configwriter.go create mode 100644 admiral/pkg/clusters/configwriter_test.go create mode 100644 admiral/pkg/clusters/shard_handler.go create mode 100644 admiral/pkg/clusters/shard_handler_test.go create mode 100644 admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json create mode 100644 admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json create mode 100644 admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json create mode 100644 admiral/pkg/controller/admiral/shard.go create mode 100644 admiral/pkg/controller/admiral/shard_test.go delete mode 100644 admiral/pkg/registry/serviceentry.go delete mode 100644 admiral/pkg/registry/serviceentry_test.go create mode 100644 admiral/pkg/registry/testdata/sampleIdentityConfiguration.json create mode 100644 admiral/pkg/registry/testutils.go diff --git a/admiral/cmd/admiral/cmd/root.go b/admiral/cmd/admiral/cmd/root.go index 4e893b1ce..8509e0d53 100644 --- a/admiral/cmd/admiral/cmd/root.go +++ b/admiral/cmd/admiral/cmd/root.go @@ -69,8 +69,8 @@ func GetRootCmd(args []string) *cobra.Command { err error remoteRegistry *clusters.RemoteRegistry ) - if params.HAMode == common.HAController { - remoteRegistry, err = clusters.InitAdmiralHA(ctx, params) + if params.AdmiralOperatorMode { + remoteRegistry, err = clusters.InitAdmiralOperator(ctx, params) } else { remoteRegistry, err = clusters.InitAdmiral(ctx, params) } @@ -209,8 +209,6 @@ func GetRootCmd(args []string) *cobra.Command { rootCmd.PersistentFlags().IntVar(¶ms.ExportToMaxNamespaces, "exportto_max_namespaces", 35, "Max number of namespaces to write in ExportTo field before just replacing with *") // Admiral HA flags - rootCmd.PersistentFlags().StringVar(¶ms.HAMode, "ha_mode", "", - "HA Mode changes the functionality of admiral. Valid options are: "+common.HAController) rootCmd.PersistentFlags().IntVar(¶ms.DNSRetries, "dns_retries", 3, "number of retries for dns resolution") rootCmd.PersistentFlags().IntVar(¶ms.DNSTimeoutMs, "dns_timeout_ms", 1000, "ttl for dns resolution timeout") rootCmd.PersistentFlags().StringVar(¶ms.DnsConfigFile, "dns_config_file", "/etc/resolv.conf", "the dns config file to use") @@ -244,6 +242,11 @@ func GetRootCmd(args []string) *cobra.Command { rootCmd.PersistentFlags().Int64Var(¶ms.DefaultWarmupDurationSecs, "default_warmup_duration_in_seconds", 45, "The default value for the warmupDurationSecs to be used on Destination Rules created by admiral") rootCmd.PersistentFlags().BoolVar(¶ms.EnableGenerationCheck, "enable_generation_check", true, "Enable/Disable Generation Check") + + //Admiral 2.0 flags + rootCmd.PersistentFlags().BoolVar(¶ms.AdmiralOperatorMode, "admiral_operator_mode", false, "Enable/Disable admiral operator functionality") + rootCmd.PersistentFlags().StringVar(¶ms.OperatorSyncNamespace, "operator_sync_namespace", "admiral-operator-sync", + "Namespace in which Admiral Operator will put its generated configurations") return rootCmd } diff --git a/admiral/pkg/client/loader/client_loader.go b/admiral/pkg/client/loader/client_loader.go index 114b933c2..8890ffb5c 100644 --- a/admiral/pkg/client/loader/client_loader.go +++ b/admiral/pkg/client/loader/client_loader.go @@ -2,6 +2,7 @@ package loader import ( argo "github.com/argoproj/argo-rollouts/pkg/client/clientset/versioned" + admiralapi "github.com/istio-ecosystem/admiral-api/pkg/client/clientset/versioned" admiral "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned" istio "istio.io/client-go/pkg/clientset/versioned" "k8s.io/client-go/kubernetes" @@ -14,6 +15,9 @@ type ClientLoader interface { LoadAdmiralClientFromPath(path string) (admiral.Interface, error) LoadAdmiralClientFromConfig(config *rest.Config) (admiral.Interface, error) + LoadAdmiralApiClientFromPath(path string) (admiralapi.Interface, error) + LoadAdmiralApiClientFromConfig(config *rest.Config) (admiralapi.Interface, error) + LoadIstioClientFromPath(path string) (istio.Interface, error) LoadIstioClientFromConfig(config *rest.Config) (istio.Interface, error) diff --git a/admiral/pkg/client/loader/fake_loader.go b/admiral/pkg/client/loader/fake_loader.go index cd390d4ba..a6901ae4d 100644 --- a/admiral/pkg/client/loader/fake_loader.go +++ b/admiral/pkg/client/loader/fake_loader.go @@ -3,6 +3,8 @@ package loader import ( argo "github.com/argoproj/argo-rollouts/pkg/client/clientset/versioned" argofake "github.com/argoproj/argo-rollouts/pkg/client/clientset/versioned/fake" + admiralapi "github.com/istio-ecosystem/admiral-api/pkg/client/clientset/versioned" + admiralapifake "github.com/istio-ecosystem/admiral-api/pkg/client/clientset/versioned/fake" admiral "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned" admiralfake "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned/fake" istio "istio.io/client-go/pkg/clientset/versioned" @@ -16,12 +18,14 @@ const FakePrefix = "fake" // fake clients for the Admiral cluster var FakeAdmiralClient admiral.Interface = admiralfake.NewSimpleClientset() +var FakeAdmiralApiClient admiralapi.Interface = admiralapifake.NewSimpleClientset() var FakeIstioClient istio.Interface = istiofake.NewSimpleClientset() var FakeKubeClient kubernetes.Interface = kubefake.NewSimpleClientset() var FakeArgoClient argo.Interface = argofake.NewSimpleClientset() // fake clients for dependent clusters var FakeAdmiralClientMap map[string]admiral.Interface = make(map[string]admiral.Interface) +var FakeAdmiralApiClientMap map[string]admiralapi.Interface = make(map[string]admiralapi.Interface) var FakeIstioClientMap map[string]istio.Interface = make(map[string]istio.Interface) var FakeKubeClientMap map[string]kubernetes.Interface = make(map[string]kubernetes.Interface) var FakeArgoClientMap map[string]argo.Interface = make(map[string]argo.Interface) @@ -48,6 +52,19 @@ func (*FakeClientLoader) LoadAdmiralClientFromConfig(config *rest.Config) (admir return admiralClient, nil } +func (loader *FakeClientLoader) LoadAdmiralApiClientFromPath(path string) (admiralapi.Interface, error) { + return FakeAdmiralApiClient, nil +} + +func (loader *FakeClientLoader) LoadAdmiralApiClientFromConfig(config *rest.Config) (admiralapi.Interface, error) { + admiralApiClient, ok := FakeAdmiralApiClientMap[config.Host] + if !ok { + admiralApiClient = admiralapifake.NewSimpleClientset() + FakeAdmiralApiClientMap[config.Host] = admiralApiClient + } + return admiralApiClient, nil +} + func (loader *FakeClientLoader) LoadIstioClientFromPath(path string) (istio.Interface, error) { return FakeIstioClient, nil } diff --git a/admiral/pkg/client/loader/kube_loader.go b/admiral/pkg/client/loader/kube_loader.go index 6fe03bf15..2be4e8808 100644 --- a/admiral/pkg/client/loader/kube_loader.go +++ b/admiral/pkg/client/loader/kube_loader.go @@ -2,8 +2,8 @@ package loader import ( "fmt" - argo "github.com/argoproj/argo-rollouts/pkg/client/clientset/versioned" + admiralapi "github.com/istio-ecosystem/admiral-api/pkg/client/clientset/versioned" admiral "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned" log "github.com/sirupsen/logrus" istio "istio.io/client-go/pkg/clientset/versioned" @@ -34,6 +34,18 @@ func (*KubeClientLoader) LoadAdmiralClientFromConfig(config *rest.Config) (admir return admiral.NewForConfig(config) } +func (loader *KubeClientLoader) LoadAdmiralApiClientFromPath(kubeConfigPath string) (admiralapi.Interface, error) { + config, err := getConfig(kubeConfigPath) + if err != nil || config == nil { + return nil, err + } + return loader.LoadAdmiralApiClientFromConfig(config) +} + +func (loader *KubeClientLoader) LoadAdmiralApiClientFromConfig(config *rest.Config) (admiralapi.Interface, error) { + return admiralapi.NewForConfig(config) +} + func (loader *KubeClientLoader) LoadIstioClientFromPath(kubeConfigPath string) (istio.Interface, error) { config, err := getConfig(kubeConfigPath) if err != nil || config == nil { diff --git a/admiral/pkg/clusters/configwriter.go b/admiral/pkg/clusters/configwriter.go new file mode 100644 index 000000000..49e5709b7 --- /dev/null +++ b/admiral/pkg/clusters/configwriter.go @@ -0,0 +1,186 @@ +package clusters + +import ( + "errors" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/admiral" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + "github.com/istio-ecosystem/admiral/admiral/pkg/registry" + "github.com/istio-ecosystem/admiral/admiral/pkg/util" + "github.com/sirupsen/logrus" + networkingV1Alpha3 "istio.io/api/networking/v1alpha3" + "sort" + "strconv" + "strings" +) + +// IstioSEBuilder is an interface to construct Service Entry objects +// from IdentityConfig objects. It can construct multiple Service Entries +// from an IdentityConfig or construct just one given a IdentityConfigEnvironment. +type IstioSEBuilder interface { + BuildServiceEntriesFromIdentityConfig(ctxLogger *logrus.Entry, event admiral.EventType, identityConfig registry.IdentityConfig) ([]*networkingV1Alpha3.ServiceEntry, error) +} + +type ServiceEntryBuilder struct { + RemoteRegistry *RemoteRegistry + ClientCluster string +} + +// BuildServiceEntriesFromIdentityConfig builds service entries to write to the client cluster +// by looping through the IdentityConfig clusters and environments to get spec information. It +// builds one SE per environment per cluster the identity is deployed in. +func (b *ServiceEntryBuilder) BuildServiceEntriesFromIdentityConfig(ctxLogger *logrus.Entry, identityConfig registry.IdentityConfig) ([]*networkingV1Alpha3.ServiceEntry, error) { + var ( + identity = identityConfig.IdentityName + seMap = map[string]*networkingV1Alpha3.ServiceEntry{} + serviceEntries = []*networkingV1Alpha3.ServiceEntry{} + err error + ) + ctxLogger.Infof(common.CtxLogFormat, "buildServiceEntry", identity, common.GetSyncNamespace(), b.ClientCluster, "Beginning to build the SE spec") + ingressEndpoints, err := getIngressEndpoints(identityConfig.Clusters) + if err != nil { + return serviceEntries, err + } + _, isServerOnClientCluster := ingressEndpoints[b.ClientCluster] + dependentNamespaces, err := getExportTo(ctxLogger, b.RemoteRegistry.RegistryClient, b.ClientCluster, isServerOnClientCluster, identityConfig.ClientAssets) + if err != nil { + return serviceEntries, err + } + for _, identityConfigCluster := range identityConfig.Clusters { + serverCluster := identityConfigCluster.Name + for _, identityConfigEnvironment := range identityConfigCluster.Environment { + env := identityConfigEnvironment.Name + var tmpSe *networkingV1Alpha3.ServiceEntry + ep, err := getServiceEntryEndpoint(ctxLogger, b.ClientCluster, serverCluster, ingressEndpoints, identityConfigEnvironment) + if err != nil { + return serviceEntries, err + } + ports, err := getServiceEntryPorts(identityConfigEnvironment) + if err != nil { + return serviceEntries, err + } + if se, ok := seMap[env]; !ok { + tmpSe = &networkingV1Alpha3.ServiceEntry{ + Hosts: []string{common.GetCnameVal([]string{env, strings.ToLower(identity), common.GetHostnameSuffix()})}, + Ports: ports, + Location: networkingV1Alpha3.ServiceEntry_MESH_INTERNAL, + Resolution: networkingV1Alpha3.ServiceEntry_DNS, + SubjectAltNames: []string{common.SpiffePrefix + common.GetSANPrefix() + common.Slash + identity}, + Endpoints: []*networkingV1Alpha3.WorkloadEntry{ep}, + ExportTo: dependentNamespaces, + } + } else { + tmpSe = se + tmpSe.Endpoints = append(tmpSe.Endpoints, ep) + } + serviceEntries = append(serviceEntries, tmpSe) + } + } + return serviceEntries, err +} + +// getIngressEndpoints constructs the endpoint of the ingress gateway/remote endpoint for an identity +// by reading the information directly from the IdentityConfigCluster. +func getIngressEndpoints(clusters []registry.IdentityConfigCluster) (map[string]*networkingV1Alpha3.WorkloadEntry, error) { + ingressEndpoints := map[string]*networkingV1Alpha3.WorkloadEntry{} + var err error + for _, cluster := range clusters { + portNumber, err := strconv.ParseInt(cluster.IngressPort, 10, 64) + if err != nil { + return ingressEndpoints, err + } + ingressEndpoint := &networkingV1Alpha3.WorkloadEntry{ + Address: cluster.IngressEndpoint, + Locality: cluster.Locality, + Ports: map[string]uint32{cluster.IngressPortName: uint32(portNumber)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, + } + ingressEndpoints[cluster.Name] = ingressEndpoint + } + return ingressEndpoints, err +} + +// getServiceEntryPorts constructs the ServicePorts of the service entry that should be built +// for the given identityConfigEnvironment. +func getServiceEntryPorts(identityConfigEnvironment registry.IdentityConfigEnvironment) ([]*networkingV1Alpha3.ServicePort, error) { + port := &networkingV1Alpha3.ServicePort{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http} + var err error + if len(identityConfigEnvironment.Ports) == 0 { + err = errors.New("identityConfigEnvironment had no ports for: " + identityConfigEnvironment.Name) + } + for _, servicePort := range identityConfigEnvironment.Ports { + //TODO: 8090 is supposed to be set as the common.SidecarEnabledPorts (includeInboundPorts) which we check that in the rollout, but we don't have that information here so assume it is 8090 + if servicePort.TargetPort.IntValue() == 8090 { + protocol := util.GetPortProtocol(servicePort.Name) + port.Name = protocol + port.Protocol = protocol + } + } + ports := []*networkingV1Alpha3.ServicePort{port} + return ports, err +} + +// getServiceEntryEndpoint constructs the remote or local endpoints of the service entry that +// should be built for the given identityConfigEnvironment. +func getServiceEntryEndpoint(ctxLogger *logrus.Entry, clientCluster string, serverCluster string, ingressEndpoints map[string]*networkingV1Alpha3.WorkloadEntry, identityConfigEnvironment registry.IdentityConfigEnvironment) (*networkingV1Alpha3.WorkloadEntry, error) { + //TODO: Verify Local and Remote Endpoints are constructed correctly + var err error + endpoint := ingressEndpoints[serverCluster] + tmpEp := endpoint.DeepCopy() + tmpEp.Labels["type"] = identityConfigEnvironment.Type + if clientCluster == serverCluster { + //Local Endpoint Address if the identity is deployed on the same cluster as it's client and the endpoint is the remote endpoint for the cluster + tmpEp.Address = identityConfigEnvironment.ServiceName + common.Sep + identityConfigEnvironment.Namespace + common.GetLocalDomainSuffix() + for _, servicePort := range identityConfigEnvironment.Ports { + //There should only be one mesh port here (http-service-mesh), but we are preserving ability to have multiple ports + protocol := util.GetPortProtocol(servicePort.Name) + if _, ok := tmpEp.Ports[protocol]; ok { + tmpEp.Ports[protocol] = uint32(servicePort.Port) + ctxLogger.Infof(common.CtxLogFormat, "LocalMeshPort", servicePort.Port, "", serverCluster, "Protocol: "+protocol) + } else { + err = errors.New("failed to get Port for protocol: " + protocol) + } + } + } + return tmpEp, err +} + +// getExportTo constructs a sorted list of unique namespaces for a given cluster, client assets, +// and cname, where each namespace is where a client asset of the cname is deployed on the cluster. If the cname +// is also deployed on the cluster then the istio-system namespace is also in the list. +func getExportTo(ctxLogger *logrus.Entry, registryClient registry.IdentityConfiguration, clientCluster string, isServerOnClientCluster bool, clientAssets []map[string]string) ([]string, error) { + clientNamespaces := []string{} + var err error + var clientIdentityConfig registry.IdentityConfig + for _, clientAsset := range clientAssets { + // For each client asset of cname, we fetch its identityConfig + clientIdentityConfig, err = registryClient.GetIdentityConfigByIdentityName(clientAsset["name"], ctxLogger) + if err != nil { + ctxLogger.Infof(common.CtxLogFormat, "buildServiceEntry", clientAsset["name"], common.GetSyncNamespace(), "", "could not fetch IdentityConfig: "+err.Error()) + continue + } + for _, clientIdentityConfigCluster := range clientIdentityConfig.Clusters { + // For each cluster the client asset is deployed on, we check if that cluster is the client cluster we are writing to + if clientCluster == clientIdentityConfigCluster.Name { + for _, clientIdentityConfigEnvironment := range clientIdentityConfigCluster.Environment { + // For each environment of the client asset on the client cluster, we add the namespace to our list + //Do we need to check if ENV matches here for exportTo? Currently we don't, but we could + clientNamespaces = append(clientNamespaces, clientIdentityConfigEnvironment.Namespace) + } + } + } + } + if isServerOnClientCluster { + clientNamespaces = append(clientNamespaces, common.NamespaceIstioSystem) + } + if len(clientNamespaces) > common.GetExportToMaxNamespaces() { + clientNamespaces = []string{"*"} + } + sort.Strings(clientNamespaces) + var dedupClientNamespaces []string + for i := 0; i < len(clientNamespaces); i++ { + if i == 0 || clientNamespaces[i] != clientNamespaces[i-1] { + dedupClientNamespaces = append(dedupClientNamespaces, clientNamespaces[i]) + } + } + return clientNamespaces, err +} diff --git a/admiral/pkg/clusters/configwriter_test.go b/admiral/pkg/clusters/configwriter_test.go new file mode 100644 index 000000000..98e1027d2 --- /dev/null +++ b/admiral/pkg/clusters/configwriter_test.go @@ -0,0 +1,324 @@ +package clusters + +import ( + "context" + "github.com/google/go-cmp/cmp" + "github.com/google/go-cmp/cmp/cmpopts" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + "github.com/istio-ecosystem/admiral/admiral/pkg/registry" + "github.com/istio-ecosystem/admiral/admiral/pkg/util" + networkingV1Alpha3 "istio.io/api/networking/v1alpha3" + "reflect" + "strings" + "testing" +) + +func admiralParamsForConfigWriterTests() common.AdmiralParams { + return common.AdmiralParams{ + KubeconfigPath: "testdata/fake.config", + LabelSet: &common.LabelSet{ + GatewayApp: "gatewayapp", + WorkloadIdentityKey: "identity", + PriorityKey: "priority", + EnvKey: "env", + AdmiralCRDIdentityLabel: "identity", + }, + EnableSAN: true, + SANPrefix: "prefix", + HostnameSuffix: "mesh", + SyncNamespace: "ns", + MetricsEnabled: true, + SecretFilterTags: "admiral/sync", + CacheReconcileDuration: 0, + ClusterRegistriesNamespace: "default", + DependenciesNamespace: "default", + WorkloadSidecarName: "default", + Profile: common.AdmiralProfileDefault, + DependentClusterWorkerConcurrency: 5, + EnableSWAwareNSCaches: true, + ExportToIdentityList: []string{"*"}, + ExportToMaxNamespaces: 35, + EnableAbsoluteFQDN: true, + EnableAbsoluteFQDNForLocalEndpoints: true, + AdmiralOperatorMode: true, + } +} + +func createMockServiceEntry(env string, identity string, endpointAddress string, endpointPort int, exportTo []string) networkingV1Alpha3.ServiceEntry { + serviceEntry := networkingV1Alpha3.ServiceEntry{ + Hosts: []string{env + "." + strings.ToLower(identity) + ".mesh"}, + Addresses: nil, + Ports: []*networkingV1Alpha3.ServicePort{{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http}}, + Location: 1, + Resolution: 2, + Endpoints: []*networkingV1Alpha3.WorkloadEntry{{Address: endpointAddress, + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(endpointPort)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}}}, + WorkloadSelector: nil, + ExportTo: exportTo, + SubjectAltNames: []string{"spiffe://prefix/" + identity}, + } + return serviceEntry +} + +func TestGetIngressEndpoints(t *testing.T) { +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go + identityConfig := getSampleIdentityConfig() + expectedIngressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ + Address: "a-elb.us-west-2.elb.amazonaws.com.", +======= + identityConfig := registry.GetSampleIdentityConfig() + expectedIngressEndpoints := map[string]*networkingV1Alpha3.WorkloadEntry{"cg-tax-ppd-usw2-k8s": { + Address: "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(15443)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, + }} + testCases := []struct { + name string + identityConfigClusters []registry.IdentityConfigCluster + expectedIngressEndpoints map[string]*networkingV1Alpha3.WorkloadEntry + }{ + { + name: "Given an IdentityConfigCluster, " + + "Then the constructed endpoint should be the ingress endpoint", + identityConfigClusters: identityConfig.Clusters, + expectedIngressEndpoints: expectedIngressEndpoints, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + ingressEndpoints, err := getIngressEndpoints(c.identityConfigClusters) + if err != nil { + t.Errorf("While constructing ingressEndpoint, got error: %v", err) + } + if !reflect.DeepEqual(ingressEndpoints, c.expectedIngressEndpoints) { + t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") + } + }) + } +} + +func TestGetServiceEntryPorts(t *testing.T) { + e2eEnv := registry.GetSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") + expectedSEPorts := []*networkingV1Alpha3.ServicePort{{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http}} + testCases := []struct { + name string + identityConfigEnvironment registry.IdentityConfigEnvironment + expectedSEPorts []*networkingV1Alpha3.ServicePort + }{ + { + name: "Given an IdentityConfigEnvironment, " + + "Then the constructed ServiceEntryPorts should be as expected", + identityConfigEnvironment: e2eEnv, + expectedSEPorts: expectedSEPorts, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + sePorts, err := getServiceEntryPorts(e2eEnv) + if err != nil { + t.Errorf("While constructing serviceEntryPorts, got error: %v", err) + } + if !reflect.DeepEqual(sePorts, c.expectedSEPorts) { + t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") + } + }) + } +} + +func TestGetServiceEntryEndpoint(t *testing.T) { + admiralParams := admiralParamsForConfigWriterTests() + common.ResetSync() + common.InitializeConfig(admiralParams) +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go + e2eEnv := getSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") + ingressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ + Address: "a-elb.us-west-2.elb.amazonaws.com.", +======= + e2eEnv := registry.GetSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") + ingressEndpoints := map[string]*networkingV1Alpha3.WorkloadEntry{"cg-tax-ppd-usw2-k8s": { + Address: "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(15443)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, + }, "apigw-cx-ppd-usw2-k8s": { + Address: "internal-a1cbfde75adbe1fed9763495dfd07960-2123389388.us-west-2.elb.amazonaws.com.", + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(15443)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, + }} +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go + remoteEndpoint := []*networkingV1Alpha3.WorkloadEntry{{ + Address: "a-elb.us-west-2.elb.amazonaws.com.", +======= + remoteEndpoint := &networkingV1Alpha3.WorkloadEntry{ + Address: "internal-a1cbfde75adbe1fed9763495dfd07960-2123389388.us-west-2.elb.amazonaws.com.", +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(15443)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, + } + localEndpoint := &networkingV1Alpha3.WorkloadEntry{ + Address: "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-e2e.svc.cluster.local.", + Locality: "us-west-2", + Ports: map[string]uint32{"http": uint32(8090)}, + Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, + } + ctx := context.Background() + ctxLogger := common.GetCtxLogger(ctx, "ctg-taxprep-partnerdatatotax", "") + testCases := []struct { + name string + identityConfigEnvironment registry.IdentityConfigEnvironment + ingressEndpoints map[string]*networkingV1Alpha3.WorkloadEntry + clientCluster string + serverCluster string + expectedSEEndpoint *networkingV1Alpha3.WorkloadEntry + }{ + { + name: "Given an IdentityConfigEnvironment and ingressEndpoint, " + + "When the client cluster is not the same as the server cluster" + + "Then the constructed endpoint should be a remote endpoint", + identityConfigEnvironment: e2eEnv, + ingressEndpoints: ingressEndpoints, +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go + operatorCluster: "cg-tax-ppd-usw2-k8s", + sourceCluster: "apigw-cx-ppd-usw2-k8s", + remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", + expectedSEEndpoints: remoteEndpoint, +======= + clientCluster: "cg-tax-ppd-usw2-k8s", + serverCluster: "apigw-cx-ppd-usw2-k8s", + expectedSEEndpoint: remoteEndpoint, +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go + }, + { + name: "Given an IdentityConfigEnvironment and ingressEndpoint, " + + "When the client cluster is the same as the server cluster" + + "Then the constructed endpoint should be a local endpoint", + identityConfigEnvironment: e2eEnv, + ingressEndpoints: ingressEndpoints, +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go + operatorCluster: "cg-tax-ppd-usw2-k8s", + sourceCluster: "cg-tax-ppd-usw2-k8s", + remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", + expectedSEEndpoints: localEndpoint, +======= + clientCluster: "cg-tax-ppd-usw2-k8s", + serverCluster: "cg-tax-ppd-usw2-k8s", + expectedSEEndpoint: localEndpoint, +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + seEndpoint, err := getServiceEntryEndpoint(ctxLogger, c.clientCluster, c.serverCluster, c.ingressEndpoints, c.identityConfigEnvironment) + if err != nil { + t.Errorf("While constructing serviceEntryPortEndpoint, got error: %v", err) + } + opts := cmpopts.IgnoreUnexported(networkingV1Alpha3.WorkloadEntry{}) + if !cmp.Equal(seEndpoint, c.expectedSEEndpoint, opts) { + t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") + t.Errorf(cmp.Diff(seEndpoint, c.expectedSEEndpoint, opts)) + } + }) + } +} + +<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go +func TestBuildServiceEntriesFromIdentityConfig(t *testing.T) { + +======= +func TestGetExportTo(t *testing.T) { + admiralParams := admiralParamsForConfigWriterTests() + common.ResetSync() + common.InitializeConfig(admiralParams) + ctxLogger := common.GetCtxLogger(context.Background(), "ctg-taxprep-partnerdatatotax", "") + testCases := []struct { + name string + registryClient registry.IdentityConfiguration + clientCluster string + isServerOnClientCluster bool + clientAssets []map[string]string + expectedNamespaces []string + }{ + { + name: "Given asset info, cluster info, and client info, " + + "When the client cluster is the same as the server cluster" + + "Then the constructed dependent namespaces should include istio-system", + registryClient: registry.NewRegistryClient(registry.WithRegistryEndpoint("PLACEHOLDER")), + clientCluster: "cg-tax-ppd-usw2-k8s", + isServerOnClientCluster: true, + clientAssets: []map[string]string{{"name": "sample"}}, + expectedNamespaces: []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal", "istio-system"}, + }, + { + name: "Given asset info, cluster info, and client info, " + + "When the client cluster is not the same as the server cluster" + + "Then the constructed dependent namespaces should not include istio-system", + registryClient: registry.NewRegistryClient(registry.WithRegistryEndpoint("PLACEHOLDER")), + clientCluster: "cg-tax-ppd-usw2-k8s", + isServerOnClientCluster: false, + clientAssets: []map[string]string{{"name": "sample"}}, + expectedNamespaces: []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal"}, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + namespaces, err := getExportTo(ctxLogger, c.registryClient, c.clientCluster, c.isServerOnClientCluster, c.clientAssets) + if err != nil { + t.Errorf("While constructing sorted dependent namespaces, got error: %v", err) + } + if !cmp.Equal(namespaces, c.expectedNamespaces) { + t.Errorf("Mismatch between constructed sortedDependentNamespaces and expected sortedDependentNamespaces") + t.Errorf(cmp.Diff(namespaces, c.expectedNamespaces)) + } + }) + } +} + +func TestBuildServiceEntriesFromIdentityConfig(t *testing.T) { + admiralParams := admiralParamsForConfigWriterTests() + common.ResetSync() + common.InitializeConfig(admiralParams) + rr, _ := InitAdmiralOperator(context.Background(), admiralParams) + ctxLogger := common.GetCtxLogger(context.Background(), "ctg-taxprep-partnerdatatotax", "") + identityConfig := registry.GetSampleIdentityConfig() + expectedLocalServiceEntryprf := createMockServiceEntry("prf", "Intuit.ctg.taxprep.partnerdatatotax", "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-prf.svc.cluster.local.", 8090, []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal", "istio-system"}) + expectedLocalServiceEntrye2e := createMockServiceEntry("e2e", "Intuit.ctg.taxprep.partnerdatatotax", "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-e2e.svc.cluster.local.", 8090, []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal", "istio-system"}) + expectedLocalServiceEntryqal := createMockServiceEntry("qal", "Intuit.ctg.taxprep.partnerdatatotax", "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-qal.svc.cluster.local.", 8090, []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal", "istio-system"}) + expectedLocalServiceEntries := []*networkingV1Alpha3.ServiceEntry{&expectedLocalServiceEntryprf, &expectedLocalServiceEntrye2e, &expectedLocalServiceEntryqal} + testCases := []struct { + name string + clientCluster string + identityConfig registry.IdentityConfig + expectedServiceEntries []*networkingV1Alpha3.ServiceEntry + }{ + { + name: "Given information to build an se, " + + "When the client cluster is the same as the server cluster" + + "Then the constructed se should have local endpoint and istio-system in exportTo", + clientCluster: "cg-tax-ppd-usw2-k8s", + identityConfig: identityConfig, + expectedServiceEntries: expectedLocalServiceEntries, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + serviceEntryBuilder := ServiceEntryBuilder{ClientCluster: c.clientCluster, RemoteRegistry: rr} + serviceEntries, err := serviceEntryBuilder.BuildServiceEntriesFromIdentityConfig(ctxLogger, c.identityConfig) + if err != nil { + t.Errorf("While constructing service entries, got error: %v", err) + } + opts := cmpopts.IgnoreUnexported(networkingV1Alpha3.ServiceEntry{}, networkingV1Alpha3.ServicePort{}, networkingV1Alpha3.WorkloadEntry{}) + if !cmp.Equal(serviceEntries, c.expectedServiceEntries, opts) { + t.Errorf("Mismatch between constructed sorted entries and expected service entries") + t.Errorf(cmp.Diff(serviceEntries, c.expectedServiceEntries, opts)) + } + }) + } +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go +} diff --git a/admiral/pkg/clusters/registry.go b/admiral/pkg/clusters/registry.go index c57a7befb..e02b540e6 100644 --- a/admiral/pkg/clusters/registry.go +++ b/admiral/pkg/clusters/registry.go @@ -3,12 +3,12 @@ package clusters import ( "context" "fmt" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/istio" "os" "time" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/admiral" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" - "github.com/istio-ecosystem/admiral/admiral/pkg/controller/istio" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/secret" "github.com/istio-ecosystem/admiral/admiral/pkg/util" commonUtil "github.com/istio-ecosystem/admiral/admiral/pkg/util" @@ -76,33 +76,26 @@ func InitAdmiral(ctx context.Context, params common.AdmiralParams) (*RemoteRegis return rr, err } -func InitAdmiralHA(ctx context.Context, params common.AdmiralParams) (*RemoteRegistry, error) { +func InitAdmiralOperator(ctx context.Context, params common.AdmiralParams) (*RemoteRegistry, error) { var ( err error rr *RemoteRegistry ) - logrus.Infof("Initializing Admiral HA with params: %v", params) + logrus.Infof("Initializing Admiral Operator with params: %v", params) common.InitializeConfig(params) - if common.GetHAMode() == common.HAController { - rr = NewRemoteRegistryForHAController(ctx) - } else { - return nil, fmt.Errorf("admiral HA only supports %s mode", common.HAController) - } - destinationServiceProcessor := &ProcessDestinationService{} - rr.DependencyController, err = admiral.NewDependencyController( - ctx.Done(), - &DependencyHandler{ - RemoteRegistry: rr, - DestinationServiceProcessor: destinationServiceProcessor, - }, - params.KubeconfigPath, - params.DependenciesNamespace, - params.CacheReconcileDuration, - rr.ClientLoader) + //init admiral state + commonUtil.CurrentAdmiralState = commonUtil.AdmiralState{ReadOnly: ReadOnlyEnabled, IsStateInitialized: StateNotInitialized} + // start admiral state checker for DR + drStateChecker := initAdmiralStateChecker(ctx, params.AdmiralStateCheckerName, params.DRStateStoreConfigPath) + rr = NewRemoteRegistry(ctx, params) + ctx = context.WithValue(ctx, "remoteRegistry", rr) + RunAdmiralStateCheck(ctx, params.AdmiralStateCheckerName, drStateChecker) + pauseForAdmiralToInitializeState() + logrus.Infof("starting ShardController") + rr.ShardController, err = admiral.NewShardController(ctx.Done(), &ShardHandler{RemoteRegistry: rr}, params.KubeconfigPath, params.DependenciesNamespace, params.CacheReconcileDuration, rr.ClientLoader) if err != nil { - return nil, fmt.Errorf("error with DependencyController initialization: %v", err) + return nil, fmt.Errorf("error with ShardController initialization, err: %v", err) } - err = InitAdmiralWithDefaultPersona(ctx, params, rr) go rr.shutdown() return rr, err @@ -172,13 +165,12 @@ func (r *RemoteRegistry) createCacheController(clientConfig *rest.Config, cluste StartTime: time.Now(), } ) - if common.GetHAMode() != common.HAController { + if !common.IsAdmiralOperatorMode() { logrus.Infof("starting ServiceController clusterID: %v", clusterID) rc.ServiceController, err = admiral.NewServiceController(stop, &ServiceHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) if err != nil { return fmt.Errorf("error with ServiceController initialization, err: %v", err) } - if common.IsClientConnectionConfigProcessingEnabled() { logrus.Infof("starting ClientConnectionsConfigController clusterID: %v", clusterID) rc.ClientConnectionConfigController, err = admiral.NewClientConnectionConfigController( @@ -189,71 +181,64 @@ func (r *RemoteRegistry) createCacheController(clientConfig *rest.Config, cluste } else { logrus.Infof("ClientConnectionsConfigController processing is disabled") } - logrus.Infof("starting GlobalTrafficController clusterID: %v", clusterID) rc.GlobalTraffic, err = admiral.NewGlobalTrafficController(stop, &GlobalTrafficHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) if err != nil { return fmt.Errorf("error with GlobalTrafficController initialization, err: %v", err) } - logrus.Infof("starting OutlierDetectionController clusterID : %v", clusterID) rc.OutlierDetectionController, err = admiral.NewOutlierDetectionController(stop, &OutlierDetectionHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) if err != nil { return fmt.Errorf("error with OutlierDetectionController initialization, err: %v", err) } - logrus.Infof("starting NodeController clusterID: %v", clusterID) rc.NodeController, err = admiral.NewNodeController(stop, &NodeHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, r.ClientLoader) if err != nil { return fmt.Errorf("error with NodeController controller initialization, err: %v", err) } - logrus.Infof("starting ServiceEntryController for clusterID: %v", clusterID) - rc.ServiceEntryController, err = istio.NewServiceEntryController(stop, &ServiceEntryHandler{RemoteRegistry: r, ClusterID: clusterID}, clusterID, clientConfig, resyncPeriod.SeAndDrReconcileInterval, r.ClientLoader) - if err != nil { - return fmt.Errorf("error with ServiceEntryController initialization, err: %v", err) - } - - logrus.Infof("starting DestinationRuleController for clusterID: %v", clusterID) - rc.DestinationRuleController, err = istio.NewDestinationRuleController(stop, &DestinationRuleHandler{RemoteRegistry: r, ClusterID: clusterID}, clusterID, clientConfig, resyncPeriod.SeAndDrReconcileInterval, r.ClientLoader) - if err != nil { - return fmt.Errorf("error with DestinationRuleController initialization, err: %v", err) - } - - logrus.Infof("starting VirtualServiceController for clusterID: %v", clusterID) - virtualServiceHandler, err := NewVirtualServiceHandler(r, clusterID) - if err != nil { - return fmt.Errorf("error initializing VirtualServiceHandler: %v", err) - } - rc.VirtualServiceController, err = istio.NewVirtualServiceController(stop, virtualServiceHandler, clientConfig, 0, r.ClientLoader) - if err != nil { - return fmt.Errorf("error with VirtualServiceController initialization, err: %v", err) - } - - logrus.Infof("starting SidecarController for clusterID: %v", clusterID) - rc.SidecarController, err = istio.NewSidecarController(stop, &SidecarHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) - if err != nil { - return fmt.Errorf("error with SidecarController initialization, err: %v", err) - } - logrus.Infof("starting RoutingPoliciesController for clusterID: %v", clusterID) rc.RoutingPolicyController, err = admiral.NewRoutingPoliciesController(stop, &RoutingPolicyHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) if err != nil { return fmt.Errorf("error with RoutingPoliciesController initialization, err: %v", err) } + logrus.Infof("starting DeploymentController for clusterID: %v", clusterID) + rc.DeploymentController, err = admiral.NewDeploymentController(stop, &DeploymentHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, resyncPeriod.UniversalReconcileInterval, r.ClientLoader) + if err != nil { + return fmt.Errorf("error with DeploymentController initialization, err: %v", err) + } + logrus.Infof("starting RolloutController clusterID: %v", clusterID) + if r.AdmiralCache == nil { + logrus.Warn("admiral cache was nil!") + } else if r.AdmiralCache.argoRolloutsEnabled { + rc.RolloutController, err = admiral.NewRolloutsController(stop, &RolloutHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, resyncPeriod.UniversalReconcileInterval, r.ClientLoader) + if err != nil { + return fmt.Errorf("error with RolloutController initialization, err: %v", err) + } + } } - logrus.Infof("starting DeploymentController for clusterID: %v", clusterID) - rc.DeploymentController, err = admiral.NewDeploymentController(stop, &DeploymentHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, resyncPeriod.UniversalReconcileInterval, r.ClientLoader) + logrus.Infof("starting ServiceEntryController for clusterID: %v", clusterID) + rc.ServiceEntryController, err = istio.NewServiceEntryController(stop, &ServiceEntryHandler{RemoteRegistry: r, ClusterID: clusterID}, clusterID, clientConfig, resyncPeriod.SeAndDrReconcileInterval, r.ClientLoader) if err != nil { - return fmt.Errorf("error with DeploymentController initialization, err: %v", err) + return fmt.Errorf("error with ServiceEntryController initialization, err: %v", err) } - logrus.Infof("starting RolloutController clusterID: %v", clusterID) - if r.AdmiralCache == nil { - logrus.Warn("admiral cache was nil!") - } else if r.AdmiralCache.argoRolloutsEnabled { - rc.RolloutController, err = admiral.NewRolloutsController(stop, &RolloutHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, resyncPeriod.UniversalReconcileInterval, r.ClientLoader) - if err != nil { - return fmt.Errorf("error with RolloutController initialization, err: %v", err) - } + logrus.Infof("starting DestinationRuleController for clusterID: %v", clusterID) + rc.DestinationRuleController, err = istio.NewDestinationRuleController(stop, &DestinationRuleHandler{RemoteRegistry: r, ClusterID: clusterID}, clusterID, clientConfig, resyncPeriod.SeAndDrReconcileInterval, r.ClientLoader) + if err != nil { + return fmt.Errorf("error with DestinationRuleController initialization, err: %v", err) + } + logrus.Infof("starting VirtualServiceController for clusterID: %v", clusterID) + virtualServiceHandler, err := NewVirtualServiceHandler(r, clusterID) + if err != nil { + return fmt.Errorf("error initializing VirtualServiceHandler: %v", err) + } + rc.VirtualServiceController, err = istio.NewVirtualServiceController(stop, virtualServiceHandler, clientConfig, 0, r.ClientLoader) + if err != nil { + return fmt.Errorf("error with VirtualServiceController initialization, err: %v", err) + } + logrus.Infof("starting SidecarController for clusterID: %v", clusterID) + rc.SidecarController, err = istio.NewSidecarController(stop, &SidecarHandler{RemoteRegistry: r, ClusterID: clusterID}, clientConfig, 0, r.ClientLoader) + if err != nil { + return fmt.Errorf("error with SidecarController initialization, err: %v", err) } r.PutRemoteController(clusterID, &rc) return nil diff --git a/admiral/pkg/clusters/registry_test.go b/admiral/pkg/clusters/registry_test.go index 823946d52..348f7fa97 100644 --- a/admiral/pkg/clusters/registry_test.go +++ b/admiral/pkg/clusters/registry_test.go @@ -2,7 +2,6 @@ package clusters import ( "context" - "fmt" "strings" "sync" "testing" @@ -446,7 +445,7 @@ func checkIfLogged(entries []*logrus.Entry, phrase string) bool { return false } -func TestInitAdmiralHA(t *testing.T) { +func TestInitAdmiralOperator(t *testing.T) { var ( ctx = context.TODO() dummyKubeConfig = "./testdata/fake.config" @@ -459,12 +458,11 @@ func TestInitAdmiralHA(t *testing.T) { expectedErr error }{ { - name: "Given Admiral is running in HA mode for database builder, " + - "When InitAdmiralHA is invoked with correct parameters, " + - "Then, it should return RemoteRegistry with 3 controllers - DependencyController, " + - "DeploymentController, and RolloutController", + name: "Given Admiral is running in Operator mode, " + + "When InitAdmiralOperator is invoked with correct parameters, " + + "Then, it should return RemoteRegistry which has a ShardController and RegistryClient", params: common.AdmiralParams{ - HAMode: common.HAController, + AdmiralOperatorMode: true, KubeconfigPath: dummyKubeConfig, DependenciesNamespace: dependencyNamespace, }, @@ -472,34 +470,23 @@ func TestInitAdmiralHA(t *testing.T) { if rr == nil { t.Error("expected RemoteRegistry to be initialized, but got nil") } - // check if it has DependencyController initialized - if rr != nil && rr.DependencyController == nil { - t.Error("expected DependencyController to be initialized, but it was not") + // check if it has ShardController initialized + if rr != nil && rr.ShardController == nil { + t.Error("expected ShardController to be initialized, but it was not") } - }, - expectedErr: nil, - }, - { - name: "Given Admiral is running in HA mode for database builder, " + - "When InitAdmiralHA is invoked with invalid HAMode parameter, " + - "Then InitAdmiralHA should return an expected error", - params: common.AdmiralParams{ - KubeconfigPath: dummyKubeConfig, - DependenciesNamespace: dependencyNamespace, - }, - assertFunc: func(rr *RemoteRegistry, t *testing.T) { - if rr != nil { - t.Error("expected RemoteRegistry to be uninitialized") + // check if it has a RegistryClient initialized + if rr != nil && rr.RegistryClient == nil { + t.Error("expected RegistryClient to be initialized, but it was not") } }, - expectedErr: fmt.Errorf("admiral HA only supports %s mode", common.HAController), + expectedErr: nil, }, } for _, c := range testCases { t.Run(c.name, func(t *testing.T) { common.ResetSync() - rr, err := InitAdmiralHA(ctx, c.params) + rr, err := InitAdmiralOperator(ctx, c.params) if c.expectedErr == nil && err != nil { t.Errorf("expected: nil, got: %v", err) } diff --git a/admiral/pkg/clusters/serviceentry_test.go b/admiral/pkg/clusters/serviceentry_test.go index 3666e504b..767bfaa74 100644 --- a/admiral/pkg/clusters/serviceentry_test.go +++ b/admiral/pkg/clusters/serviceentry_test.go @@ -9417,6 +9417,9 @@ func compareServiceEntries(se1, se2 *istioNetworkingV1Alpha3.ServiceEntry) bool if se1.Resolution != se2.Resolution { return false } + if !reflect.DeepEqual(se1.ExportTo, se2.ExportTo) { + return false + } if !reflect.DeepEqual(se1.SubjectAltNames, se2.SubjectAltNames) { return false } diff --git a/admiral/pkg/clusters/shard_handler.go b/admiral/pkg/clusters/shard_handler.go new file mode 100644 index 000000000..48fe851d9 --- /dev/null +++ b/admiral/pkg/clusters/shard_handler.go @@ -0,0 +1,151 @@ +package clusters + +import ( + "context" + "fmt" + admiralapiv1 "github.com/istio-ecosystem/admiral-api/pkg/apis/admiral/v1" + "github.com/istio-ecosystem/admiral/admiral/pkg/registry" + "strings" + "sync" + + log "github.com/sirupsen/logrus" + k8sErrors "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/admiral" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" +) + +type ShardHandler struct { + RemoteRegistry *RemoteRegistry +} + +type ConfigWriterData struct { + IdentityConfig *registry.IdentityConfig + ClusterName string + // TODO: Could keep this result field or derive it from the passed along error, also could be Shard.Status type instead of string + Result string + Error error +} + +func (sh *ShardHandler) Added(ctx context.Context, obj *admiralapiv1.Shard) error { + err := HandleEventForShard(ctx, admiral.Add, obj, sh.RemoteRegistry) + if err != nil { + return fmt.Errorf(LogErrFormat, common.Add, common.ShardResourceType, obj.Name, "", err) + } + return nil +} + +func (sh *ShardHandler) Deleted(ctx context.Context, obj *admiralapiv1.Shard) error { + // TODO: Not yet implemented + //err := HandleEventForShard(ctx, admiral.Delete, obj, sh.RemoteRegistry) + //if err != nil { + // return fmt.Errorf(LogErrFormat, common.Delete, common.ShardResourceType, obj.Name, "", err) + //} + return nil +} + +// HandleEventForShardFunc is a handler function for shard events +type HandleEventForShardFunc func( + ctx context.Context, event admiral.EventType, obj *admiralapiv1.Shard, + remoteRegistry *RemoteRegistry, clusterName string) error + +// helper function to handle add and delete for ShardHandler +func HandleEventForShard(ctx context.Context, event admiral.EventType, obj *admiralapiv1.Shard, + remoteRegistry *RemoteRegistry) error { + ctxLogger := common.GetCtxLogger(ctx, obj.Name, "") + tmpShard := obj.DeepCopy() + ctxLogger.Infof(common.CtxLogFormat, "HandleEventForShard", obj.Name, "", "", "") + var consumerwg, resultswg sync.WaitGroup + configWriterData := make(chan *ConfigWriterData, 1000) + configWriterDataResults := make(chan *ConfigWriterData, 1000) + for i := 0; i < 5; i++ { + consumerwg.Add(1) + go ConsumeIdentityConfigs(ctxLogger, ctx, configWriterData, configWriterDataResults, remoteRegistry, &consumerwg) + } + // Get all ICs from shard and put into channel + go ProduceIdentityConfigsFromShard(ctxLogger, *obj, configWriterData, remoteRegistry) + // Start processing results + resultswg.Add(1) + go UpdateShard(ctxLogger, configWriterDataResults, &resultswg, tmpShard) + // wait for all consumers to finish + consumerwg.Wait() + // all consumers done,no more values sent to results + close(configWriterDataResults) + // wait for all results to be processed + resultswg.Wait() + //TODO: Need to write the new tmpShard with all the results to the cluster + return error for the item to be requeued + return nil +} + +// ProduceIdentityConfigsFromShard creates a registry client and uses it to get the identity configs +// of the assets on the shard, and puts those into configWriterData which go into the job channel +func ProduceIdentityConfigsFromShard(ctxLogger *log.Entry, shard admiralapiv1.Shard, configWriterData chan<- *ConfigWriterData, rr *RemoteRegistry) { + for _, clusterShard := range shard.Spec.Clusters { + for _, identityItem := range clusterShard.Identities { + identityConfig, err := rr.RegistryClient.GetIdentityConfigByIdentityName(identityItem.Name, ctxLogger) + if err != nil { + ctxLogger.Warnf(common.CtxLogFormat, "ProduceIdentityConfig", identityItem.Name, shard.Namespace, clusterShard.Name, err) + } + ctxLogger.Infof(common.CtxLogFormat, "ProduceIdentityConfig", identityConfig.IdentityName, shard.Namespace, clusterShard.Name, "successfully produced IdentityConfig") + configWriterData <- &ConfigWriterData{ + IdentityConfig: &identityConfig, + ClusterName: clusterShard.Name, + Error: err, + } + } + } + close(configWriterData) +} + +// ConsumeIdentityConfigs takes a configWriterData from the data channel and produces the networking resources for the +// identity in the config. It then returns the result to the results channel. +func ConsumeIdentityConfigs(ctxLogger *log.Entry, ctx context.Context, configWriterData <-chan *ConfigWriterData, configWriterDataResults chan<- *ConfigWriterData, rr *RemoteRegistry, wg *sync.WaitGroup) { + defer wg.Done() + for data := range configWriterData { + identityConfig := data.IdentityConfig + assetName := identityConfig.IdentityName + clientCluster := data.ClusterName + ctxLogger.Infof(common.CtxLogFormat, "ConsumeIdentityConfig", assetName, "", clientCluster, "starting to consume identityConfig") + //TODO: doesn't make much sense to have this as a struct, easier to just pass in the cluster and remote registry + serviceEntryBuilder := ServiceEntryBuilder{ClientCluster: clientCluster, RemoteRegistry: rr} + serviceEntries, err := serviceEntryBuilder.BuildServiceEntriesFromIdentityConfig(ctxLogger, *identityConfig) + if err != nil { + ctxLogger.Warnf(common.CtxLogFormat, "ConsumeIdentityConfig", assetName, "", clientCluster, err) + data.Result = err.Error() + } + for _, se := range serviceEntries { + rc := rr.GetRemoteController(clientCluster) + seName := strings.ToLower(se.Hosts[0]) + "-se" + sec := rc.ServiceEntryController + //TODO: se reconciliation cache + oldServiceEntry := sec.Cache.Get(seName, clientCluster) + if oldServiceEntry == nil { + ctxLogger.Infof(common.CtxLogFormat, "ConsumeIdentityConfig", seName, "", clientCluster, "starting to write se to cluster") + oldServiceEntry, err = rc.ServiceEntryController.IstioClient.NetworkingV1alpha3().ServiceEntries(common.GetOperatorSyncNamespace()).Get(ctx, seName, metav1.GetOptions{}) + // if old service entry not find, just create a new service entry instead + if err != nil && k8sErrors.IsNotFound(err) { + ctxLogger.Infof(common.CtxLogFormat, "ConsumeIdentityConfig", seName, "", clientCluster, fmt.Sprintf("failed fetching old service entry, error=%v", err)) + oldServiceEntry = nil + } + } + newServiceEntry := createServiceEntrySkeleton(*se, seName, common.GetOperatorSyncNamespace()) + err = addUpdateServiceEntry(ctxLogger, ctx, newServiceEntry, oldServiceEntry, common.GetOperatorSyncNamespace(), rc) + if err != nil { + ctxLogger.Warnf(common.CtxLogFormat, "ConsumeIdentityConfig", seName, "", clientCluster, err) + data.Result = err.Error() + } + } + configWriterDataResults <- data + } +} + +// UpdateShard reads the job object from the results channel and updates the original shard object with the proper result. +func UpdateShard(ctxLogger *log.Entry, results <-chan *ConfigWriterData, resultswg *sync.WaitGroup, shard *admiralapiv1.Shard) { + defer resultswg.Done() + for job := range results { + ctxLogger.Infof(common.CtxLogFormat, "UpdateShard", shard.Name, "", job.ClusterName, job.Result) + //ctxLogger.Infof(common.CtxLogFormat, "UpdateShard", shard.Name, "", job.ClusterName, shard.Status.Conditions[0].Message) + //TODO: need to get updated shard crd spec and set status here + } +} diff --git a/admiral/pkg/clusters/shard_handler_test.go b/admiral/pkg/clusters/shard_handler_test.go new file mode 100644 index 000000000..db0159aa3 --- /dev/null +++ b/admiral/pkg/clusters/shard_handler_test.go @@ -0,0 +1,177 @@ +package clusters + +import ( + "context" + "encoding/json" + "fmt" + admiralapiv1 "github.com/istio-ecosystem/admiral-api/pkg/apis/admiral/v1" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/istio" + "github.com/sirupsen/logrus" + istioNetworkingV1Alpha3 "istio.io/api/networking/v1alpha3" + istiofake "istio.io/client-go/pkg/clientset/versioned/fake" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "sync" + "testing" +) + +var shardTestSingleton sync.Once + +func setupForShardTests() common.AdmiralParams { + var initHappened bool + admiralParams := admiralParamsForServiceEntryTests() + admiralParams.EnableAbsoluteFQDN = true + admiralParams.EnableAbsoluteFQDNForLocalEndpoints = true + admiralParams.SANPrefix = "pre-prod.api.intuit.com" + admiralParams.ExportToMaxNamespaces = 35 + admiralParams.AdmiralOperatorMode = true + admiralParams.OperatorSyncNamespace = "shard-namespace" + shardTestSingleton.Do(func() { + common.ResetSync() + initHappened = true + common.InitializeConfig(admiralParams) + }) + if !initHappened { + logrus.Warn("InitializeConfig was NOT called from setupForShardTests") + } else { + logrus.Info("InitializeConfig was called setupForShardTests") + } + return admiralParams +} + +func createMockShard(shardName string, clusterName string, identityName string, identityEnv string) *admiralapiv1.Shard { + identityItem := admiralapiv1.IdentityItem{ + Name: identityName, + Environment: identityEnv, + } + clusterShard := admiralapiv1.ClusterShards{ + Name: clusterName, + Locality: "us-west-2", + Identities: []admiralapiv1.IdentityItem{identityItem}, + } + shardStatusCondition := admiralapiv1.ShardStatusCondition{ + Message: "sync not started", + Reason: "notStarted", + Status: "false", + Type: "SyncComplete", + LastUpdatedTime: v1.Now(), + } + shard := admiralapiv1.Shard{ + ObjectMeta: v1.ObjectMeta{Name: shardName, Namespace: "shard-namespace"}, + Spec: admiralapiv1.ShardSpec{Clusters: []admiralapiv1.ClusterShards{clusterShard}}, + Status: admiralapiv1.ShardStatus{ + ClustersMonitored: 1, + Conditions: []admiralapiv1.ShardStatusCondition{shardStatusCondition}, + FailureDetails: admiralapiv1.FailureDetails{}, + LastUpdatedTime: v1.Time{}, + }, + } + return &shard +} + +func jsonPrint(v any) { + s, _ := json.MarshalIndent(v, "", "\t") + fmt.Println(string(s)) +} + +func TestShardHandler_Added(t *testing.T) { + admiralParams := setupForShardTests() + rr, _ := InitAdmiralOperator(context.Background(), admiralParams) + rc1 := &RemoteController{ + ClusterID: "cg-tax-ppd-usw2-k8s", + ServiceEntryController: &istio.ServiceEntryController{ + IstioClient: istiofake.NewSimpleClientset(), + Cache: istio.NewServiceEntryCache(), + }, + } + rc2 := &RemoteController{ + ClusterID: "multi-long-1026-usw2-k8s", + ServiceEntryController: &istio.ServiceEntryController{ + IstioClient: istiofake.NewSimpleClientset(), + Cache: istio.NewServiceEntryCache(), + }, + } + rr.PutRemoteController("cg-tax-ppd-usw2-k8s", rc1) + rr.PutRemoteController("multi-long-1026-usw2-k8s", rc2) + sampleShard1 := createMockShard("shard-sample", "cg-tax-ppd-usw2-k8s", "sample", "e2e") + sampleShard2 := createMockShard("blackhole-shard", "multi-long-1026-usw2-k8s", "intuit.services.gateway.ppdmeshtestblackhole", "multi-long-1026-usw2-k8s") + shardHandler := &ShardHandler{ + RemoteRegistry: rr, + } + se1 := &istioNetworkingV1Alpha3.ServiceEntry{ + Hosts: []string{"e2e.intuit.ctg.taxprep.partnerdatatotax.mesh"}, + Ports: []*istioNetworkingV1Alpha3.ServicePort{{Number: 80, Protocol: "http", Name: "http"}}, + Location: 1, + Resolution: 2, + Endpoints: []*istioNetworkingV1Alpha3.WorkloadEntry{{Address: "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-e2e.svc.cluster.local.", Ports: map[string]uint32{"http": 8090}, Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, Locality: "us-west-2"}}, + ExportTo: []string{"ctg-taxprep-partnerdatatotax-usw2-e2e", "ctg-taxprep-partnerdatatotax-usw2-prf", "ctg-taxprep-partnerdatatotax-usw2-qal", common.NamespaceIstioSystem}, + SubjectAltNames: []string{"spiffe://pre-prod.api.intuit.com/Intuit.ctg.taxprep.partnerdatatotax"}, + } + se2 := &istioNetworkingV1Alpha3.ServiceEntry{ + Hosts: []string{"multi-long-1026-use2-k8s.intuit.services.gateway.ppdmeshtestblackhole.mesh"}, + Ports: []*istioNetworkingV1Alpha3.ServicePort{{Number: 80, Protocol: "http", Name: "http"}}, + Location: 1, + Resolution: 2, + Endpoints: []*istioNetworkingV1Alpha3.WorkloadEntry{ + {Address: "internal-ff96ae9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-east-2.elb.amazonaws.com.", Ports: map[string]uint32{"http": 15443}, Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "deployment"}, Locality: "us-east-2"}, + }, + ExportTo: []string{common.NamespaceIstioSystem, "services-inboundd268-usw2-dev"}, + SubjectAltNames: []string{"spiffe://pre-prod.api.intuit.com/intuit.services.gateway.ppdmeshtestblackhole"}, + } + testCases := []struct { + name string + rc *RemoteController + shard *admiralapiv1.Shard + expectedSEName string + expectedSE *istioNetworkingV1Alpha3.ServiceEntry + }{ + { + name: "Given the server asset we want to write resources for is deployed on the client cluster " + + "And it is a client of itself " + + "Then an SE with local endpoint and istio-system in exportTo should be built", + rc: rc1, + shard: sampleShard1, + expectedSEName: "e2e.intuit.ctg.taxprep.partnerdatatotax.mesh-se", + expectedSE: se1, + }, + { + name: "Given the server asset we want to write resources for is deployed on a remote cluster in env A and a client cluster in env B" + + "Then an SE with only remote endpoint and istio-system in exportTo should be built for env B", + rc: rc2, + shard: sampleShard2, + expectedSEName: "multi-long-1026-use2-k8s.intuit.services.gateway.ppdmeshtestblackhole.mesh-se", + expectedSE: se2, + }, + //TODO: Given the server asset we want to write resources for is deployed remotely and locally in the same env, se should have local and remote endpoint and istio-system + } + + for _, tt := range testCases { + t.Run(tt.name, func(t *testing.T) { + shErr := shardHandler.Added(context.Background(), tt.shard) + if shErr != nil { + t.Errorf("failed to produce SE with err: %v", shErr) + } + actualSE, seErr := tt.rc.ServiceEntryController.IstioClient.NetworkingV1alpha3().ServiceEntries(common.GetOperatorSyncNamespace()).Get(context.Background(), tt.expectedSEName, v1.GetOptions{}) + if seErr != nil { + t.Errorf("failed to get SE with err %v", seErr) + } + if !compareServiceEntries(&actualSE.Spec, tt.expectedSE) { + jsonPrint(actualSE.Spec) + jsonPrint(tt.expectedSE) + t.Errorf("expected se did not match actual se") + } + }) + } +} + +func TestShardHandler_Deleted(t *testing.T) { + admiralParams := setupForShardTests() + rr, _ := InitAdmiralOperator(context.Background(), admiralParams) + shardHandler := &ShardHandler{ + RemoteRegistry: rr, + } + err := shardHandler.Deleted(context.Background(), nil) + if err != nil { + t.Errorf("expected nil err for delete, for %v", err) + } +} diff --git a/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json b/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json new file mode 100644 index 000000000..3cead8471 --- /dev/null +++ b/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json @@ -0,0 +1,123 @@ +{ + "identityName": "intuit.services.gateway.ppdmeshtestblackhole", + "clusters": [ + { + "_comment-1": "THIS SECTION CONTAINS CLUSTER LEVEL DETAILS, WHICH ARE THE SAME FOR THE ASSET IN A GIVEN CLUSTER", + "name": "multi-long-1026-usw2-k8s", + "locality": "us-west-2", + "ingressEndpoint": "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", + "ingressPort": "15443", + "ingressPortName": "http", + "_comment-2": "THIS SECTION CONTAINS ENVIRONMENT LEVEL DETAILS, FOR THE ASSET IN A GIVEN CLUSTER", + "environment": [ + { + "name": "multi-long-1026-usw2-k8s", + "namespace": "services-blackholed268-usw2-dev", + "serviceName": "blackhole-gw", + "type": "deployment", + "selectors": { + "app": "blackhole-gw" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + } + ], + "clientAssets": [ + { + "name": "intuit.services.gateway.ppdmeshtestinbounds" + } + ] + }, + { + "_comment-1": "THIS SECTION CONTAINS CLUSTER LEVEL DETAILS, WHICH ARE THE SAME FOR THE ASSET IN A GIVEN CLUSTER", + "name": "multi-long-1026-use2-k8s", + "locality": "us-east-2", + "ingressEndpoint": "internal-ff96ae9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-east-2.elb.amazonaws.com.", + "ingressPort": "15443", + "ingressPortName": "http", + "_comment-2": "THIS SECTION CONTAINS ENVIRONMENT LEVEL DETAILS, FOR THE ASSET IN A GIVEN CLUSTER", + "environment": [ + { + "name": "multi-long-1026-use2-k8s", + "namespace": "services-blackholesh45-use2-dev", + "serviceName": "blackhole-gw", + "type": "deployment", + "selectors": { + "app": "blackhole-gw" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + } + ] + } + ], + "clientAssets": [ + { + "name": "intuit.services.gateway.ppdmeshtestinbounds" + } + ] +} \ No newline at end of file diff --git a/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json b/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json new file mode 100644 index 000000000..9bfa80e07 --- /dev/null +++ b/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json @@ -0,0 +1,64 @@ +{ + "identityName": "intuit.services.gateway.ppdmeshtestinbounds", + "clusters": [ + { + "_comment-1": "THIS SECTION CONTAINS CLUSTER LEVEL DETAILS, WHICH ARE THE SAME FOR THE ASSET IN A GIVEN CLUSTER", + "name": "multi-long-1026-usw2-k8s", + "locality": "us-west-2", + "ingressEndpoint": "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", + "ingressPort": "15443", + "ingressPortName": "http", + "_comment-2": "THIS SECTION CONTAINS ENVIRONMENT LEVEL DETAILS, FOR THE ASSET IN A GIVEN CLUSTER", + "environment": [ + { + "name": "multi-long-1026-usw2-k8s", + "namespace": "services-inboundd268-usw2-dev", + "serviceName": "inbound-gw", + "type": "deployment", + "selectors": { + "app": "inbound-gw" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + } + ] + } + ], + "clientAssets": [ + { + "name": "intuit.services.gateway.ppdmeshtestinbounds" + } + ] +} \ No newline at end of file diff --git a/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json b/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json new file mode 100644 index 000000000..bebfabbca --- /dev/null +++ b/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json @@ -0,0 +1,159 @@ +{ + "identityName": "Intuit.ctg.taxprep.partnerdatatotax", + "clusters": [ + { + "_comment-1": "THIS SECTION CONTAINS CLUSTER LEVEL DETAILS, WHICH ARE THE SAME FOR THE ASSET IN A GIVEN CLUSTER", + "name": "cg-tax-ppd-usw2-k8s", + "locality": "us-west-2", + "ingressEndpoint": "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", + "ingressPort": "15443", + "ingressPortName": "http", + "_comment-2": "THIS SECTION CONTAINS ENVIRONMENT LEVEL DETAILS, FOR THE ASSET IN A GIVEN CLUSTER", + "environment": [ + { + "name": "prf", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-prf", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + }, + { + "name": "e2e", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-e2e", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + }, + { + "name": "qal", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-qal", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + } + ] + } + ], + "clientAssets": [ + { + "name": "intuit.services.gateway.ppdmeshtestinbounds" + }, + { + "name": "intuit.platform.servicesgateway.servicesgateway" + }, + { + "name": "intuit.ctg.taxprep.partnerdatatotax" + }, + { + "name": "sample" + } + ] +} \ No newline at end of file diff --git a/admiral/pkg/clusters/types.go b/admiral/pkg/clusters/types.go index b98a10421..75a81ead6 100644 --- a/admiral/pkg/clusters/types.go +++ b/admiral/pkg/clusters/types.go @@ -90,9 +90,11 @@ type RemoteRegistry struct { ServiceEntrySuspender ServiceEntrySuspender AdmiralDatabaseClient AdmiralDatabaseManager DependencyController *admiral.DependencyController + ShardController *admiral.ShardController ClientLoader loader.ClientLoader ClusterShardHandler registry.ClusterShardStore ClusterIdentityStoreHandler registry.ClusterIdentityStore + RegistryClient registry.IdentityConfiguration } // ModifySEFunc is a function that follows the dependency injection pattern which is used by HandleEventForGlobalTrafficPolicy @@ -169,7 +171,7 @@ func NewRemoteRegistry(ctx context.Context, params common.AdmiralParams) *Remote clientLoader = loader.GetKubeClientLoader() } - return &RemoteRegistry{ + rr := &RemoteRegistry{ ctx: ctx, StartTime: time.Now(), remoteControllers: make(map[string]*RemoteController), @@ -178,21 +180,12 @@ func NewRemoteRegistry(ctx context.Context, params common.AdmiralParams) *Remote AdmiralDatabaseClient: admiralDatabaseClient, ClientLoader: clientLoader, } -} -// NewRemoteRegistryForHAController - creates an instance of RemoteRegistry -// which initializes properties relevant to database builder functionality -func NewRemoteRegistryForHAController(ctx context.Context) *RemoteRegistry { - return &RemoteRegistry{ - ctx: ctx, - StartTime: time.Now(), - remoteControllers: make(map[string]*RemoteController), - ClientLoader: loader.GetKubeClientLoader(), - AdmiralCache: &AdmiralCache{ - IdentityClusterCache: common.NewMapOfMaps(), - IdentityDependencyCache: common.NewMapOfMaps(), - }, + if common.IsAdmiralOperatorMode() { + rr.RegistryClient = registry.NewRegistryClient(registry.WithRegistryEndpoint("PLACEHOLDER")) } + + return rr } type sourceToDestinations struct { diff --git a/admiral/pkg/controller/admiral/shard.go b/admiral/pkg/controller/admiral/shard.go new file mode 100644 index 000000000..649c793d2 --- /dev/null +++ b/admiral/pkg/controller/admiral/shard.go @@ -0,0 +1,243 @@ +package admiral + +import ( + "context" + "fmt" + admiralapiv1 "github.com/istio-ecosystem/admiral-api/pkg/apis/admiral/v1" + admiralapi "github.com/istio-ecosystem/admiral-api/pkg/client/clientset/versioned" + v1 "github.com/istio-ecosystem/admiral-api/pkg/client/informers/externalversions/admiral/v1" + "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/util" + log "github.com/sirupsen/logrus" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/informers" + "k8s.io/client-go/kubernetes" + "k8s.io/client-go/tools/cache" + "sync" + "time" +) + +type ShardHandler interface { + Added(ctx context.Context, obj *admiralapiv1.Shard) error + Deleted(ctx context.Context, obj *admiralapiv1.Shard) error +} + +type ShardItem struct { + Shard *admiralapiv1.Shard + Status string +} + +type ShardController struct { + K8sClient kubernetes.Interface + CrdClient admiralapi.Interface + Cache *shardCache + informer cache.SharedIndexInformer + mutex sync.Mutex + ShardHandler ShardHandler +} + +func (d *ShardController) DoesGenerationMatch(entry *log.Entry, i interface{}, i2 interface{}) (bool, error) { + return false, nil +} + +// shardCache is a map from shard name to corresponding ShardItem +type shardCache struct { + cache map[string]*ShardItem + mutex *sync.Mutex +} + +func newShardCache() *shardCache { + return &shardCache{ + cache: make(map[string]*ShardItem), + mutex: &sync.Mutex{}, + } +} + +func (p *shardCache) getKey(shard *admiralapiv1.Shard) string { + return shard.Name +} + +func (p *shardCache) Get(key string) *admiralapiv1.Shard { + defer p.mutex.Unlock() + p.mutex.Lock() + + shardItem, ok := p.cache[key] + if ok { + return shardItem.Shard + } + + return nil +} + +func (p *shardCache) GetShardProcessStatus(shard *admiralapiv1.Shard) string { + defer p.mutex.Unlock() + p.mutex.Lock() + + key := p.getKey(shard) + + shardItem, ok := p.cache[key] + if ok { + return shardItem.Status + } + + return common.NotProcessed +} + +func (p *shardCache) UpdateShardProcessStatus(shard *admiralapiv1.Shard, status string) error { + defer p.mutex.Unlock() + p.mutex.Lock() + key := p.getKey(shard) + + shardItem, ok := p.cache[key] + if ok { + shardItem.Status = status + p.cache[key] = shardItem + return nil + } else { + return fmt.Errorf(LogCacheFormat, "Update", "Shard", + shard.Name, shard.Namespace, "", "nothing to update, shard not found in cache") + } + +} + +func (p *shardCache) UpdateShardToClusterCache(key string, shard *admiralapiv1.Shard) { + defer p.mutex.Unlock() + p.mutex.Lock() + shardItem := &ShardItem{ + Shard: shard, + Status: common.ProcessingInProgress, + } + p.cache[key] = shardItem +} + +func (p *shardCache) DeleteFromShardClusterCache(key string, shard *admiralapiv1.Shard) { + defer p.mutex.Unlock() + p.mutex.Lock() + shardItem := p.cache[key] + + if shardItem != nil { + if shardItem.Shard != nil && shardItem.Shard.Name == shard.Name { + log.Infof("op=%s type=%v name=%v namespace=%s cluster=%s message=%s", "Delete", "Shard", + shard.Name, shard.Namespace, "", "ignoring shard and deleting from cache") + delete(p.cache, key) + } else { + log.Warnf("op=%s type=%v name=%v namespace=%s cluster=%s message=%s", "Get", "Shard", + shard.Name, shard.Namespace, "", "ignoring shard delete as it doesn't match the one in cache") + } + } else { + log.Infof("op=%s type=%v name=%v namespace=%s cluster=%s message=%s", "Delete", "Shard", + shard.Name, shard.Namespace, "", "nothing to delete, shard not found in cache") + } +} + +func NewShardController(stopCh <-chan struct{}, handler ShardHandler, configPath string, namespace string, resyncPeriod time.Duration, clientLoader loader.ClientLoader) (*ShardController, error) { + shardController := ShardController{ + K8sClient: nil, + CrdClient: nil, + Cache: newShardCache(), + informer: nil, + mutex: sync.Mutex{}, + ShardHandler: handler, + } + var err error + shardController.K8sClient, err = clientLoader.LoadKubeClientFromPath(configPath) + if err != nil { + return nil, fmt.Errorf("failed to create shard controller k8s client: %v", err) + } + shardController.CrdClient, err = clientLoader.LoadAdmiralApiClientFromPath(configPath) + if err != nil { + return nil, fmt.Errorf("failed to create shard controller crd client: %v", err) + } + //TODO: should not be hardcoded, fetch actual expected operator and shard identities from env variables + //labelOptions := informers.WithTweakListOptions(func(opts *metav1.ListOptions) { + // opts.LabelSelector = "admiral.io/operatorIdentity=operatorIdentity, admiral.io/shardIdentity=dev" + //}) + //informerFactory := informers.NewSharedInformerFactoryWithOptions(shardController.K8sClient, resyncPeriod, labelOptions) + informerFactory := informers.NewSharedInformerFactoryWithOptions(shardController.K8sClient, resyncPeriod) + informerFactory.Start(stopCh) + shardController.informer = v1.NewShardInformer(shardController.CrdClient, + namespace, + resyncPeriod, + cache.Indexers{}) + NewController("shard-ctrl", "", stopCh, &shardController, shardController.informer) + return &shardController, nil +} + +func (d *ShardController) Added(ctx context.Context, obj interface{}) error { + return HandleAddUpdateShard(ctx, obj, d) +} + +func (d *ShardController) Updated(ctx context.Context, obj interface{}, oldObj interface{}) error { + return HandleAddUpdateShard(ctx, obj, d) +} + +func (d *ShardController) GetProcessItemStatus(obj interface{}) (string, error) { + shard, ok := obj.(*admiralapiv1.Shard) + if !ok { + return common.NotProcessed, fmt.Errorf("type assertion failed, %v is not of type *admiralapiv1.Shard", obj) + } + return d.Cache.GetShardProcessStatus(shard), nil +} + +func (d *ShardController) UpdateProcessItemStatus(obj interface{}, status string) error { + shard, ok := obj.(*admiralapiv1.Shard) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *admiralapiv1.Shard", obj) + } + return d.Cache.UpdateShardProcessStatus(shard, status) +} + +func HandleAddUpdateShard(ctx context.Context, obj interface{}, d *ShardController) error { + shard, ok := obj.(*admiralapiv1.Shard) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *admiralapiv1.Shard", obj) + } + key := d.Cache.getKey(shard) + defer util.LogElapsedTime("HandleAddUpdateShard", key, shard.Name+"_"+shard.Namespace, "")() + if len(key) > 0 { + d.Cache.UpdateShardToClusterCache(key, shard) + } + err := d.ShardHandler.Added(ctx, shard) + return err +} + +func (d *ShardController) Deleted(ctx context.Context, obj interface{}) error { + shard, ok := obj.(*admiralapiv1.Shard) + if !ok { + return fmt.Errorf("type assertion failed, %v is not of type *admiralapiv1.Shard", obj) + } + key := d.Cache.getKey(shard) + var err error + if err == nil && len(key) > 0 { + d.Cache.DeleteFromShardClusterCache(key, shard) + } + return err +} + +func (d *ShardController) LogValueOfAdmiralIoIgnore(obj interface{}) { + shard, ok := obj.(*admiralapiv1.Shard) + if !ok { + return + } + if d.K8sClient != nil { + ns, err := d.K8sClient.CoreV1().Namespaces().Get(context.Background(), shard.Namespace, metav1.GetOptions{}) + if err != nil { + log.Warnf("failed to get namespace object for shard with namespace %v, err: %v", shard.Namespace, err) + } else if (ns != nil && ns.Annotations[common.AdmiralIgnoreAnnotation] == "true") || shard.Annotations[common.AdmiralIgnoreAnnotation] == "true" { + log.Infof("op=%s type=%v name=%v namespace=%s cluster=%s message=%s", "admiralIoIgnoreAnnotationCheck", common.ShardResourceType, + shard.Name, shard.Namespace, "", "Value=true") + } + } +} + +func (d *ShardController) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error) { + shard, ok := obj.(*admiralapiv1.Shard) + if ok && isRetry { + return d.Cache.Get(shard.Name), nil + } + if ok && d.CrdClient != nil { + return d.CrdClient.AdmiralV1().Shards(shard.Namespace).Get(ctx, shard.Name, metav1.GetOptions{}) + } + return nil, fmt.Errorf("kubernetes client is not initialized, txId=%s", ctx.Value("txId")) +} diff --git a/admiral/pkg/controller/admiral/shard_test.go b/admiral/pkg/controller/admiral/shard_test.go new file mode 100644 index 000000000..67e4e8165 --- /dev/null +++ b/admiral/pkg/controller/admiral/shard_test.go @@ -0,0 +1,300 @@ +package admiral + +import ( + "context" + "errors" + "fmt" + admiralapiv1 "github.com/istio-ecosystem/admiral-api/pkg/apis/admiral/v1" + "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" + "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + "github.com/istio-ecosystem/admiral/admiral/pkg/test" + "github.com/stretchr/testify/assert" + coreV1 "k8s.io/api/core/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/kubernetes/fake" + "testing" +) + +func GetMockShard() *admiralapiv1.Shard { + identityItem := admiralapiv1.IdentityItem{ + Name: "sample", + Environment: "e2e", + } + clusterShard := admiralapiv1.ClusterShards{ + Name: "cg-tax-ppd-usw2-k8s", + Locality: "us-west-2", + Identities: []admiralapiv1.IdentityItem{identityItem}, + } + shardStatusCondition := admiralapiv1.ShardStatusCondition{ + Message: "sync not started", + Reason: "notStarted", + Status: "false", + Type: "SyncComplete", + LastUpdatedTime: v1.Now(), + } + shard := admiralapiv1.Shard{ + ObjectMeta: v1.ObjectMeta{Name: "shard-sample", Namespace: "admiral-sync"}, + Spec: admiralapiv1.ShardSpec{Clusters: []admiralapiv1.ClusterShards{clusterShard}}, + Status: admiralapiv1.ShardStatus{ + ClustersMonitored: 1, + Conditions: []admiralapiv1.ShardStatusCondition{shardStatusCondition}, + FailureDetails: admiralapiv1.FailureDetails{}, + LastUpdatedTime: v1.Time{}, + }, + } + return &shard +} + +func TestShardController_Added(t *testing.T) { + shard := GetMockShard() + shardController, _ := getNewMockShardController() + err := shardController.Added(context.Background(), shard) + if err != nil { + t.Errorf("err: %v", err) + } +} + +func TestShardController_Deleted(t *testing.T) { + shardController, _ := getNewMockShardController() + shard := admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}} + shard2 := admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test2"}} + shard3 := admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test3"}} + shardController.Cache.UpdateShardToClusterCache("test", &shard) + shardController.Cache.UpdateShardToClusterCache("test3", &shard2) + + testCases := []struct { + name string + shard *admiralapiv1.Shard + expectedErr error + expectedCacheLen int + }{ + { + name: "Expects shard to be deleted from the cache", + shard: &shard, + expectedErr: nil, + expectedCacheLen: 1, + }, + { + name: "Given shard to be deleted name doesn't match shard name in cache, no delete or err", + shard: &shard3, + expectedErr: nil, + expectedCacheLen: 1, + }, + { + name: "Expects no error thrown if calling delete on a shard not in the cache", + shard: &shard2, + expectedErr: nil, + expectedCacheLen: 1, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + err := shardController.Deleted(context.Background(), c.shard) + if !errors.Is(err, c.expectedErr) { + t.Errorf("Got err: %v but expected to get err: %v", err, c.expectedErr) + } + if c.expectedCacheLen != len(shardController.Cache.cache) { + t.Errorf("Expected cache to have len: %v, but it had len: %v", c.expectedCacheLen, len(shardController.Cache.cache)) + } + }) + } +} + +func getNewMockShardController() (*ShardController, error) { + shardHandler := test.MockShardHandler{} + shardController, err := NewShardController(context.Background().Done(), &shardHandler, "../../test/resources/admins@fake-cluster.k8s.local", "test-ns", 0, loader.GetFakeClientLoader()) + return shardController, err +} + +func TestNewShardController(t *testing.T) { + shardController, _ := getNewMockShardController() + if shardController == nil { + t.Errorf("Shard controller should not be nil") + } +} + +func TestShardCache_Get(t *testing.T) { + shardController, _ := getNewMockShardController() + shard := admiralapiv1.Shard{ + ObjectMeta: v1.ObjectMeta{Name: "test"}, + } + shardController.Cache.UpdateShardToClusterCache("test", &shard) + testCases := []struct { + name string + key string + expectedShard *admiralapiv1.Shard + }{ + { + name: "Given the shard exists in the cache with matching key, returns the shard", + key: "test", + expectedShard: &shard, + }, + { + name: "Given there is no shard in the cache with matching key, returns nil", + key: "test2", + expectedShard: nil, + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + resultShard := shardController.Cache.Get(c.key) + if c.expectedShard != resultShard { + t.Errorf("Expected shard: %v, but got %v", c.expectedShard, resultShard) + } + }) + } +} + +func TestUpdateProcessItemStatusShard(t *testing.T) { + shardController, _ := getNewMockShardController() + shardController.Cache.UpdateShardToClusterCache("test", &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}}) + testCases := []struct { + name string + obj interface{} + statusToSet string + expectedErr error + expectedStatus string + }{ + { + name: "Given shard cache has a valid shard in its cache, " + + "Then, the status for the valid shard should be updated to processed", + obj: &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}}, + statusToSet: common.Processed, + expectedErr: nil, + expectedStatus: common.Processed, + }, + { + name: "Given shard cache has a valid shard in its cache, " + + "Then, the status for the valid shard should be updated to not processed", + obj: &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}}, + statusToSet: common.NotProcessed, + expectedErr: nil, + expectedStatus: common.NotProcessed, + }, + { + name: "Given shard cache does not have a valid shard in its cache, " + + "Then, the status for the valid shard should be not processed, " + + "And an error should be returned with the shard not found message", + obj: &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test2", Namespace: "test-ns"}}, + statusToSet: common.NotProcessed, + expectedErr: fmt.Errorf(LogCacheFormat, "Update", "Shard", "test2", "test-ns", "", "nothing to update, shard not found in cache"), + expectedStatus: common.NotProcessed, + }, + { + name: "Given non-shard obj is passed to the function, " + + "Then, the function should not panic, " + + "And return an error", + obj: "not a shard", + expectedErr: fmt.Errorf("type assertion failed"), + expectedStatus: common.NotProcessed, + }, + } + + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + err := shardController.UpdateProcessItemStatus(c.obj, c.statusToSet) + if c.expectedErr != nil && err == nil || c.expectedErr == nil && err != nil { + t.Errorf("expected error: %v but got error: %v", c.expectedErr, err) + } + status, _ := shardController.GetProcessItemStatus(c.obj) + assert.Equal(t, c.expectedStatus, status) + }) + } +} + +func TestGetProcessItemStatusShard(t *testing.T) { + shardController, _ := getNewMockShardController() + shard := admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}} + shardController.Cache.UpdateShardToClusterCache("test", &shard) + shardController.Cache.UpdateShardProcessStatus(&shard, common.Processed) + testCases := []struct { + name string + obj interface{} + expectedErr error + expectedResult string + }{ + { + name: "Given shard cache has a valid Shard in its cache, " + + "And the Shard is processed" + + "Then, we should be able to get the status as processed", + obj: &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test"}}, + expectedResult: common.Processed, + }, + { + name: "Given shard cache does not have a valid shard in its cache, " + + "Then, the returned status should be not processed", + obj: &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Name: "test2"}}, + expectedResult: common.NotProcessed, + }, + { + name: "Given non-shard obj is passed to the function, " + + "Then, the function should not panic, " + + "And return an error", + obj: "not a shard", + expectedErr: fmt.Errorf("type assertion failed"), + expectedResult: common.NotProcessed, + }, + } + + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + res, err := shardController.GetProcessItemStatus(c.obj) + if c.expectedErr != nil && err == nil || c.expectedErr == nil && err != nil { + t.Errorf("expected error: %v but got error: %v", c.expectedErr, err) + } + assert.Equal(t, c.expectedResult, res) + }) + } +} + +func TestShardLogValueOfAdmiralIoIgnore(t *testing.T) { + // Test case 1: obj is not a Shard object + s := &ShardController{} + s.LogValueOfAdmiralIoIgnore("not a shard") + // No error should occur + + // Test case 2: K8sClient is nil + s = &ShardController{} + s.LogValueOfAdmiralIoIgnore(&admiralapiv1.Shard{}) + // No error should occur + + // Test case 3: Namespace is not found + mockClient := fake.NewSimpleClientset() + s = &ShardController{K8sClient: mockClient} + s.LogValueOfAdmiralIoIgnore(&admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Namespace: "test-ns"}}) + // No error should occur + + // Test case 4: AdmiralIgnoreAnnotation is not set + mockClient = fake.NewSimpleClientset(&coreV1.Namespace{ObjectMeta: v1.ObjectMeta{Name: "test-ns"}}) + s = &ShardController{K8sClient: mockClient} + s.LogValueOfAdmiralIoIgnore(&admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Namespace: "test-ns"}}) + // No error should occur + + // Test case 5: AdmiralIgnoreAnnotation is set in Shard object + mockClient = fake.NewSimpleClientset(&coreV1.Namespace{ObjectMeta: v1.ObjectMeta{Name: "test-ns"}}) + s = &ShardController{K8sClient: mockClient} + shard := &admiralapiv1.Shard{ + ObjectMeta: v1.ObjectMeta{ + Namespace: "test-ns", + Annotations: map[string]string{ + common.AdmiralIgnoreAnnotation: "true", + }, + }, + } + s.LogValueOfAdmiralIoIgnore(shard) + // No error should occur + + // Test case 6: AdmiralIgnoreAnnotation is set in Namespace object + mockClient = fake.NewSimpleClientset(&coreV1.Namespace{ + ObjectMeta: v1.ObjectMeta{ + Name: "test-ns", + Annotations: map[string]string{ + common.AdmiralIgnoreAnnotation: "true", + }, + }, + }) + s = &ShardController{K8sClient: mockClient} + shard = &admiralapiv1.Shard{ObjectMeta: v1.ObjectMeta{Namespace: "test-ns"}} + s.LogValueOfAdmiralIoIgnore(shard) + // No error should occur +} diff --git a/admiral/pkg/controller/common/common.go b/admiral/pkg/controller/common/common.go index 507935997..9f61474e6 100644 --- a/admiral/pkg/controller/common/common.go +++ b/admiral/pkg/controller/common/common.go @@ -89,7 +89,6 @@ const ( Deployment = "deployment" Rollout = "rollout" GTP = "gtp" - HAController = "ha-controller" EventType = "eventType" ProcessingInProgress = "ProcessingInProgress" NotProcessed = "NotProcessed" @@ -138,6 +137,7 @@ const ( DependencyProxyResourceType ResourceType = "DependencyProxy" GlobalTrafficPolicyResourceType ResourceType = "GlobalTrafficPolicy" RoutingPolicyResourceType ResourceType = "RoutingPolicy" + ShardResourceType ResourceType = "Shard" // Istio Resource Types VirtualServiceResourceType ResourceType = "VirtualService" diff --git a/admiral/pkg/controller/common/config.go b/admiral/pkg/controller/common/config.go index cc6f8d4b8..49972bff7 100644 --- a/admiral/pkg/controller/common/config.go +++ b/admiral/pkg/controller/common/config.go @@ -464,3 +464,15 @@ func GetDefaultWarmupDurationSecs() int64 { defer wrapper.RUnlock() return wrapper.params.DefaultWarmupDurationSecs } + +func IsAdmiralOperatorMode() bool { + wrapper.RLock() + defer wrapper.RUnlock() + return wrapper.params.AdmiralOperatorMode +} + +func GetOperatorSyncNamespace() string { + wrapper.RLock() + defer wrapper.RUnlock() + return wrapper.params.OperatorSyncNamespace +} diff --git a/admiral/pkg/controller/common/config_test.go b/admiral/pkg/controller/common/config_test.go index ce271aaf3..a4be2f55e 100644 --- a/admiral/pkg/controller/common/config_test.go +++ b/admiral/pkg/controller/common/config_test.go @@ -41,6 +41,8 @@ func setupForConfigTests() { EnableSWAwareNSCaches: true, ExportToIdentityList: []string{"*"}, ExportToMaxNamespaces: 35, + AdmiralOperatorMode: false, + OperatorSyncNamespace: "admiral-sync", } ResetSync() initHappened = true @@ -152,6 +154,14 @@ func TestConfigManagement(t *testing.T) { if GetExportToMaxNamespaces() != 35 { t.Errorf("exportTo max namespaces mismatch, expected 35, got %v", GetExportToMaxNamespaces()) } + + if IsAdmiralOperatorMode() { + t.Errorf("enable operator mode mismatch, expected false, got %v", IsAdmiralOperatorMode()) + } + + if GetOperatorSyncNamespace() != "admiral-sync" { + t.Errorf("operator sync namespace mismatch, expected admiral-sync, got %v", GetOperatorSyncNamespace()) + } } func TestGetCRDIdentityLabelWithCRDIdentity(t *testing.T) { diff --git a/admiral/pkg/controller/common/types.go b/admiral/pkg/controller/common/types.go index 9df6cbc36..fa06f3aa1 100644 --- a/admiral/pkg/controller/common/types.go +++ b/admiral/pkg/controller/common/types.go @@ -112,6 +112,10 @@ type AdmiralParams struct { // Air specific GatewayAssetAliases []string + + //Admiral 2.0 params + AdmiralOperatorMode bool + OperatorSyncNamespace string } func (b AdmiralParams) String() string { diff --git a/admiral/pkg/registry/registry.go b/admiral/pkg/registry/registry.go index 67c34583c..52644326d 100644 --- a/admiral/pkg/registry/registry.go +++ b/admiral/pkg/registry/registry.go @@ -1,13 +1,18 @@ package registry import ( - "context" "encoding/json" "os" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" + log "github.com/sirupsen/logrus" networkingV1Alpha3 "istio.io/api/networking/v1alpha3" coreV1 "k8s.io/api/core/v1" +<<<<<<< HEAD +======= + "os" + "strings" +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) ) // IdentityConfiguration is an interface to fetch configuration from a registry @@ -15,13 +20,12 @@ import ( // or if given a cluster name, it will provide the configurations for all // the identities present in that cluster. type IdentityConfiguration interface { - GetByIdentityName(identityAlias string, ctx context.Context) (IdentityConfig, error) - GetByClusterName(clusterName string, ctx context.Context) ([]IdentityConfig, error) + GetIdentityConfigByIdentityName(identityAlias string, ctxLogger *log.Entry) (IdentityConfig, error) + GetIdentityConfigByClusterName(clusterName string, ctxLogger *log.Entry) ([]IdentityConfig, error) } type registryClient struct { registryEndpoint string - operatorCluster string } func NewRegistryClient(options ...func(client *registryClient)) *registryClient { @@ -38,15 +42,10 @@ func WithRegistryEndpoint(registryEndpoint string) func(*registryClient) { } } -func WithOperatorCluster(operatorCluster string) func(*registryClient) { - return func(c *registryClient) { - c.operatorCluster = operatorCluster - } -} - type IdentityConfig struct { - Assetname string `json:"assetname"` - Clusters []IdentityConfigCluster `json:"clusters"` + IdentityName string `json:"identityName"` + Clusters []IdentityConfigCluster `json:"clusters"` + ClientAssets []map[string]string `json:"clientAssets"` } type IdentityConfigCluster struct { @@ -56,8 +55,6 @@ type IdentityConfigCluster struct { IngressPort string `json:"ingressPort"` IngressPortName string `json:"ingressPortName"` Environment []IdentityConfigEnvironment `json:"environment"` - ClientAssets []map[string]string `json:"clientAssets"` - // Why is clientAssets under cluster? shouldn't it be regardless of cluster??/??? } type IdentityConfigEnvironment struct { @@ -70,36 +67,42 @@ type IdentityConfigEnvironment struct { TrafficPolicy networkingV1Alpha3.TrafficPolicy `json:"trafficPolicy"` } -// GetByIdentityName calls the registry API to fetch the IdentityConfig for +// GetIdentityConfigByIdentityName calls the registry API to fetch the IdentityConfig for // the given identityAlias -func (c *registryClient) GetByIdentityName(identityAlias string, ctx context.Context) (IdentityConfig, error) { - //jsonResult = os.request(/asset/identityAlias/configurations) - ctxLogger := common.GetCtxLogger(ctx, identityAlias, "") - ctxLogger.Infof(common.CtxLogFormat, "GetByIdentityName", identityAlias, "", c.operatorCluster, "") - byteValue, err := os.ReadFile("testdata/" + identityAlias + "IdentityConfiguration.json") +func (c *registryClient) GetIdentityConfigByIdentityName(identityAlias string, ctxLogger *log.Entry) (IdentityConfig, error) { + //TODO: Use real result from registry and remove string splitting to match test file names + byteValue, err := readIdentityConfigFromFile(strings.Split(identityAlias, ".")) if err != nil { - ctxLogger.Infof(common.CtxLogFormat, "GetByIdentityName", identityAlias, "", c.operatorCluster, err) + ctxLogger.Infof(common.CtxLogFormat, "GetByIdentityName", identityAlias, "", "", err) } var identityConfigUnmarshalResult IdentityConfig err = json.Unmarshal(byteValue, &identityConfigUnmarshalResult) if err != nil { - ctxLogger.Infof(common.CtxLogFormat, "GetByIdentityName", identityAlias, "", c.operatorCluster, err) + ctxLogger.Infof(common.CtxLogFormat, "GetByIdentityName", identityAlias, "", "", err) } return identityConfigUnmarshalResult, err } -// GetByClusterName calls the registry API to fetch the IdentityConfigs for +func readIdentityConfigFromFile(shortAlias []string) ([]byte, error) { + pathName := "testdata/" + shortAlias[len(shortAlias)-1] + "IdentityConfiguration.json" + if common.GetSecretFilterTags() == "admiral/syncrtay" { + pathName = "/etc/serviceregistry/config/" + shortAlias[len(shortAlias)-1] + "IdentityConfiguration.json" + } + return os.ReadFile(pathName) +} + +// GetIdentityConfigByClusterName calls the registry API to fetch the IdentityConfigs for // every identity on the cluster. -func (c *registryClient) GetByClusterName(clusterName string, ctx context.Context) ([]IdentityConfig, error) { +func (c *registryClient) GetIdentityConfigByClusterName(clusterName string, ctxLogger *log.Entry) ([]IdentityConfig, error) { + //TODO: need to call this function once during startup time to warm the cache //jsonResult = os.request(/cluster/{cluster_id}/configurations - ctxLogger := common.GetCtxLogger(ctx, "", "") ctxLogger.Infof(common.CtxLogFormat, "GetByClusterName", "", "", clusterName, "") //identities := getIdentitiesForCluster(clusterName) - either queries shard CRD or shard CRD controller calls this func with those as parameters identities := []string{clusterName} identityConfigs := []IdentityConfig{} var err error for _, identity := range identities { - identityConfig, identityErr := c.GetByIdentityName(identity, ctx) + identityConfig, identityErr := c.GetIdentityConfigByIdentityName(identity, ctxLogger) if identityErr != nil { err = identityErr ctxLogger.Infof(common.CtxLogFormat, "GetByClusterName", "", "", clusterName, identityErr) diff --git a/admiral/pkg/registry/registry_test.go b/admiral/pkg/registry/registry_test.go index c0e5425e9..7d7f6ae15 100644 --- a/admiral/pkg/registry/registry_test.go +++ b/admiral/pkg/registry/registry_test.go @@ -7,6 +7,7 @@ import ( "github.com/golang/protobuf/ptypes/duration" "github.com/golang/protobuf/ptypes/wrappers" +<<<<<<< HEAD networkingV1Alpha3 "istio.io/api/networking/v1alpha3" coreV1 "k8s.io/api/core/v1" "k8s.io/apimachinery/pkg/util/intstr" @@ -68,8 +69,18 @@ func getSampleIdentityConfig() IdentityConfig { return identityConfig } +======= + "github.com/google/go-cmp/cmp" + "github.com/google/go-cmp/cmp/cmpopts" + log "github.com/sirupsen/logrus" + networkingV1Alpha3 "istio.io/api/networking/v1alpha3" + "reflect" + "testing" +) + +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) func TestParseIdentityConfigJSON(t *testing.T) { - identityConfig := getSampleIdentityConfig() + identityConfig := GetSampleIdentityConfig() testCases := []struct { name string identityConfig IdentityConfig @@ -98,3 +109,99 @@ func TestParseIdentityConfigJSON(t *testing.T) { }) } } +<<<<<<< HEAD +======= + +func TestIdentityConfigGetByIdentityName(t *testing.T) { + sampleIdentityConfig := GetSampleIdentityConfig() + registryClient := NewRegistryClient(WithRegistryEndpoint("endpoint")) + var jsonErr *json.SyntaxError + ctxLogger := log.WithContext(context.Background()) + testCases := []struct { + name string + expectedIdentityConfig IdentityConfig + expectedError any + identityAlias string + }{ + { + name: "Given an identity, " + + "When the identity config JSON is parsed, " + + "Then the resulting struct should match the expected config", + expectedIdentityConfig: sampleIdentityConfig, + expectedError: nil, + identityAlias: "sample", + }, + { + name: "Given an identity, " + + "When the identity config JSON doesn't exist for it, " + + "Then there should be a non-nil error", + expectedIdentityConfig: IdentityConfig{}, + expectedError: jsonErr, + identityAlias: "failed", + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + + identityConfig, err := registryClient.GetIdentityConfigByIdentityName(c.identityAlias, ctxLogger) + if err != nil && c.expectedError == nil { + t.Errorf("error while getting identityConfig by name with error: %v", err) + } else if err != nil && c.expectedError != nil && !errors.As(err, &c.expectedError) { + t.Errorf("failed to get correct error: %v, instead got error: %v", c.expectedError, err) + } else { + opts := cmpopts.IgnoreUnexported(networkingV1Alpha3.TrafficPolicy{}, networkingV1Alpha3.LoadBalancerSettings{}, networkingV1Alpha3.LocalityLoadBalancerSetting{}, networkingV1Alpha3.LocalityLoadBalancerSetting_Distribute{}, duration.Duration{}, networkingV1Alpha3.ConnectionPoolSettings{}, networkingV1Alpha3.ConnectionPoolSettings_HTTPSettings{}, networkingV1Alpha3.OutlierDetection{}, wrappers.UInt32Value{}) + if !cmp.Equal(identityConfig, c.expectedIdentityConfig, opts) { + t.Errorf("mismatch between parsed JSON file and expected identity config for alias: %s", c.identityAlias) + t.Errorf(cmp.Diff(identityConfig, c.expectedIdentityConfig, opts)) + } + } + }) + } +} + +func TestGetIdentityConfigByClusterName(t *testing.T) { + sampleIdentityConfig := GetSampleIdentityConfig() + registryClient := NewRegistryClient(WithRegistryEndpoint("endpoint")) + var jsonErr *json.SyntaxError + ctxLogger := log.WithContext(context.Background()) + testCases := []struct { + name string + expectedIdentityConfig IdentityConfig + expectedError any + clusterName string + }{ + { + name: "Given a cluster name, " + + "When all the identity configs for the identities in that cluster are processed, " + + "Then the structs returned should match the expected configs", + expectedIdentityConfig: sampleIdentityConfig, + expectedError: nil, + clusterName: "sample", + }, + { + name: "Given a cluster name, " + + "When there exists no identity config for that cluster, " + + "Then there should be a non-nil error", + expectedIdentityConfig: IdentityConfig{}, + expectedError: jsonErr, + clusterName: "failed", + }, + } + for _, c := range testCases { + t.Run(c.name, func(t *testing.T) { + identityConfigs, err := registryClient.GetIdentityConfigByClusterName(c.clusterName, ctxLogger) + if err != nil && c.expectedError == nil { + t.Errorf("error while getting identityConfigs by cluster name with error: %v", err) + } else if err != nil && c.expectedError != nil && !errors.As(err, &c.expectedError) { + t.Errorf("failed to get correct error: %v, instead got error: %v", c.expectedError, err) + } else { + opts := cmpopts.IgnoreUnexported(networkingV1Alpha3.TrafficPolicy{}, networkingV1Alpha3.LoadBalancerSettings{}, networkingV1Alpha3.LocalityLoadBalancerSetting{}, networkingV1Alpha3.LocalityLoadBalancerSetting_Distribute{}, duration.Duration{}, networkingV1Alpha3.ConnectionPoolSettings{}, networkingV1Alpha3.ConnectionPoolSettings_HTTPSettings{}, networkingV1Alpha3.OutlierDetection{}, wrappers.UInt32Value{}) + if !cmp.Equal(identityConfigs[0], c.expectedIdentityConfig, opts) { + t.Errorf("mismatch between parsed JSON file and expected identity config for file: %s", c.clusterName) + t.Errorf(cmp.Diff(identityConfigs[0], c.expectedIdentityConfig, opts)) + } + } + }) + } +} +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) diff --git a/admiral/pkg/registry/serviceentry.go b/admiral/pkg/registry/serviceentry.go deleted file mode 100644 index d6dc9e79f..000000000 --- a/admiral/pkg/registry/serviceentry.go +++ /dev/null @@ -1,204 +0,0 @@ -package registry - -import ( - "context" - "errors" - "sort" - "strconv" - "strings" - - "github.com/istio-ecosystem/admiral/admiral/pkg/controller/admiral" - "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" - "github.com/istio-ecosystem/admiral/admiral/pkg/util" - "github.com/sirupsen/logrus" - networkingV1Alpha3 "istio.io/api/networking/v1alpha3" -) - -// IstioSEBuilder is an interface to construct Service Entry objects -// from IdentityConfig objects. It can construct multiple Service Entries -// from an IdentityConfig or construct just one given a IdentityConfigEnvironment. -type IstioSEBuilder interface { - BuildServiceEntriesFromIdentityConfig(ctxLogger *logrus.Entry, ctx context.Context, event admiral.EventType, identityConfig IdentityConfig) ([]*networkingV1Alpha3.ServiceEntry, error) -} - -type ServiceEntryBuilder struct { - OperatorCluster string -} - -// BuildServiceEntriesFromIdentityConfig builds service entries to write to the operator cluster -// by looping through the IdentityConfig clusters and environments to get spec information. It -// builds one SE per environment per cluster the identity is deployed in. -func (b *ServiceEntryBuilder) BuildServiceEntriesFromIdentityConfig(ctxLogger *logrus.Entry, ctx context.Context, event admiral.EventType, identityConfig IdentityConfig) ([]*networkingV1Alpha3.ServiceEntry, error) { - identity := identityConfig.Assetname - serviceEntries := []*networkingV1Alpha3.ServiceEntry{} - var err error - if event == admiral.Add || event == admiral.Update { - ctxLogger.Infof(common.CtxLogFormat, "buildServiceEntry", identity, common.GetSyncNamespace(), b.OperatorCluster, "Beginning to build the SE spec") - ingressEndpoints, ingressErr := getIngressEndpoints(identityConfig.Clusters) - if ingressErr != nil { - err = ingressErr - return serviceEntries, err - } - for i, identityConfigCluster := range identityConfig.Clusters { - sourceCluster := identityConfigCluster.Name - for _, identityConfigEnvironment := range identityConfigCluster.Environment { - se, buildErr := buildServiceEntryForClusterByEnv(ctxLogger, ctx, b.OperatorCluster, sourceCluster, identity, identityConfigCluster.ClientAssets, ingressEndpoints, ingressEndpoints[i].Address, identityConfigEnvironment) - if buildErr != nil { - err = buildErr - } - serviceEntries = append(serviceEntries, se) - } - } - return serviceEntries, err - } - return serviceEntries, err -} - -// buildServiceEntryForClusterByEnv builds a service entry based on cluster and IdentityConfigEnvironment information -// to be written to the operator cluster. -func buildServiceEntryForClusterByEnv(ctxLogger *logrus.Entry, ctx context.Context, operatorCluster string, sourceCluster string, identity string, clientAssets []map[string]string, ingressEndpoints []*networkingV1Alpha3.WorkloadEntry, remoteEndpointAddress string, identityConfigEnvironment IdentityConfigEnvironment) (*networkingV1Alpha3.ServiceEntry, error) { - ctxLogger.Infof(common.CtxLogFormat, "buildServiceEntry", identity, common.GetSyncNamespace(), operatorCluster, "build the SE spec from IdentityConfigEnvironment") - env := identityConfigEnvironment.Name - fqdn := common.GetCnameVal([]string{env, strings.ToLower(identity), common.GetHostnameSuffix()}) - san := common.SpiffePrefix + common.GetSANPrefix() + common.Slash + identity - ports, err := getServiceEntryPorts(identityConfigEnvironment) - if err != nil { - return nil, err - } - endpoints, err := getServiceEntryEndpoints(ctxLogger, operatorCluster, sourceCluster, ingressEndpoints, remoteEndpointAddress, identityConfigEnvironment) - if err != nil { - return nil, err - } - dependentNamespaces, err := getSortedDependentNamespaces(ctxLogger, ctx, operatorCluster, sourceCluster, fqdn, env, clientAssets) - if err != nil { - return nil, err - } - return &networkingV1Alpha3.ServiceEntry{ - Hosts: []string{fqdn}, - Ports: ports, - Location: networkingV1Alpha3.ServiceEntry_MESH_INTERNAL, - Resolution: networkingV1Alpha3.ServiceEntry_DNS, - SubjectAltNames: []string{san}, - Endpoints: endpoints, - ExportTo: dependentNamespaces, - }, err -} - -// getIngressEndpoint constructs the endpoint of the ingress gateway/remote endpoint for an identity -// by reading the information directly from the IdentityConfigCluster. -func getIngressEndpoints(clusters []IdentityConfigCluster) ([]*networkingV1Alpha3.WorkloadEntry, error) { - ingressEndpoints := []*networkingV1Alpha3.WorkloadEntry{} - var err error - for _, cluster := range clusters { - portNumber, parseErr := strconv.ParseInt(cluster.IngressPort, 10, 64) - if parseErr != nil { - err = parseErr - continue - } - ingressEndpoint := &networkingV1Alpha3.WorkloadEntry{ - Address: cluster.IngressEndpoint, - Locality: cluster.Locality, - Ports: map[string]uint32{cluster.IngressPortName: uint32(portNumber)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, - } - ingressEndpoints = append(ingressEndpoints, ingressEndpoint) - } - return ingressEndpoints, err -} - -// getServiceEntryPorts constructs the ServicePorts of the service entry that should be built -// for the given identityConfigEnvironment. -func getServiceEntryPorts(identityConfigEnvironment IdentityConfigEnvironment) ([]*networkingV1Alpha3.ServicePort, error) { - //TODO: Verify this is how ports should be set - //Find Port with targetPort that matches inbound common.SidecarEnabledPorts - //Set port name and protocol based on that - port := &networkingV1Alpha3.ServicePort{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http} - var err error - if len(identityConfigEnvironment.Ports) == 0 { - err = errors.New("identityConfigEnvironment had no ports for: " + identityConfigEnvironment.Name) - } - for _, servicePort := range identityConfigEnvironment.Ports { - //TODO: 8090 is supposed to be set as the common.SidecarEnabledPorts (includeInboundPorts), and we check that in the rollout, but we don't have that information here - if servicePort.TargetPort.IntValue() == 8090 { - protocol := util.GetPortProtocol(servicePort.Name) - port.Name = protocol - port.Protocol = protocol - } - } - ports := []*networkingV1Alpha3.ServicePort{port} - return ports, err -} - -// getServiceEntryEndpoints constructs the remote or local endpoint of the service entry that -// should be built for the given identityConfigEnvironment. -func getServiceEntryEndpoints(ctxLogger *logrus.Entry, operatorCluster string, sourceCluster string, ingressEndpoints []*networkingV1Alpha3.WorkloadEntry, remoteEndpointAddress string, identityConfigEnvironment IdentityConfigEnvironment) ([]*networkingV1Alpha3.WorkloadEntry, error) { - //TODO: Verify Local and Remote Endpoints are constructed correctly - endpoints := []*networkingV1Alpha3.WorkloadEntry{} - var err error - for _, endpoint := range ingressEndpoints { - tmpEp := endpoint.DeepCopy() - tmpEp.Labels["type"] = identityConfigEnvironment.Type - if operatorCluster == sourceCluster && tmpEp.Address == remoteEndpointAddress { - //Local Endpoint Address if the identity is deployed on the same cluster as it's client and the endpoint is the remote endpoint for the cluster - tmpEp.Address = identityConfigEnvironment.ServiceName + common.Sep + identityConfigEnvironment.Namespace + common.GetLocalDomainSuffix() - for _, servicePort := range identityConfigEnvironment.Ports { - //There should only be one mesh port here (http-service-mesh), but we are preserving ability to have multiple ports - protocol := util.GetPortProtocol(servicePort.Name) - if _, ok := tmpEp.Ports[protocol]; ok { - tmpEp.Ports[protocol] = uint32(servicePort.Port) - ctxLogger.Infof(common.CtxLogFormat, "LocalMeshPort", servicePort.Port, "", sourceCluster, "Protocol: "+protocol) - } else { - err = errors.New("failed to get Port for protocol: " + protocol) - } - } - } - endpoints = append(endpoints, tmpEp) - } - return endpoints, err -} - -// getSortedDependentNamespaces constructs a sorted list of unique namespaces for a given cluster, client assets, -// and cname, where each namespace is where a client asset of the cname is deployed on the cluster. If the cname -// is also deployed on the cluster then the istio-system namespace is also in the list. -func getSortedDependentNamespaces(ctxLogger *logrus.Entry, ctx context.Context, operatorCluster string, sourceCluster string, cname string, env string, clientAssets []map[string]string) ([]string, error) { - clientNamespaces := []string{} - var err error - var clientIdentityConfig IdentityConfig - for _, clientAsset := range clientAssets { - //TODO: Need to do registry client initialization better, maybe pass it in - registryClient := NewRegistryClient(WithRegistryEndpoint("endpoint"), WithOperatorCluster(operatorCluster)) - // For each client asset of cname, we fetch its identityConfig - clientIdentityConfig, err = registryClient.GetByIdentityName(clientAsset["name"], ctx) - if err != nil { - ctxLogger.Infof(common.CtxLogFormat, "buildServiceEntry", cname, common.GetSyncNamespace(), clientAsset["name"], "Failed to fetch IdentityConfig: "+err.Error()) - continue - } - for _, clientIdentityConfigCluster := range clientIdentityConfig.Clusters { - // For each cluster the client asset is deployed on, we check if that cluster is the operator cluster we are writing to - if operatorCluster == clientIdentityConfigCluster.Name { - for _, clientIdentityConfigEnvironment := range clientIdentityConfigCluster.Environment { - // For each environment of the client asset on the operator cluster, we add the namespace to our list - if clientIdentityConfigEnvironment.Name == env { - //Do we need to check if ENV matches here for exportTo? - clientNamespaces = append(clientNamespaces, clientIdentityConfigEnvironment.Namespace) - } - } - } - } - } - if operatorCluster == sourceCluster { - clientNamespaces = append(clientNamespaces, common.NamespaceIstioSystem) - } - if len(clientNamespaces) > common.GetExportToMaxNamespaces() { - clientNamespaces = []string{"*"} - ctxLogger.Infof("exceeded max namespaces for cname=%s in cluster=%s", cname, operatorCluster) - } - sort.Strings(clientNamespaces) - var dedupClientNamespaces []string - for i := 0; i < len(clientNamespaces); i++ { - if i == 0 || clientNamespaces[i] != clientNamespaces[i-1] { - dedupClientNamespaces = append(dedupClientNamespaces, clientNamespaces[i]) - } - } - return clientNamespaces, err -} diff --git a/admiral/pkg/registry/serviceentry_test.go b/admiral/pkg/registry/serviceentry_test.go deleted file mode 100644 index 52fc34052..000000000 --- a/admiral/pkg/registry/serviceentry_test.go +++ /dev/null @@ -1,197 +0,0 @@ -package registry - -import ( - "context" - "reflect" - "strings" - "testing" - - "github.com/google/go-cmp/cmp" - "github.com/google/go-cmp/cmp/cmpopts" - "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" - "github.com/istio-ecosystem/admiral/admiral/pkg/util" - networkingV1Alpha3 "istio.io/api/networking/v1alpha3" -) - -func admiralParamsForServiceEntryTests() common.AdmiralParams { - return common.AdmiralParams{ - KubeconfigPath: "testdata/fake.config", - LabelSet: &common.LabelSet{ - GatewayApp: "gatewayapp", - WorkloadIdentityKey: "identity", - PriorityKey: "priority", - EnvKey: "env", - AdmiralCRDIdentityLabel: "identity", - }, - EnableSAN: true, - SANPrefix: "prefix", - HostnameSuffix: "mesh", - SyncNamespace: "ns", - CacheReconcileDuration: 0, - ClusterRegistriesNamespace: "default", - DependenciesNamespace: "default", - WorkloadSidecarName: "default", - Profile: common.AdmiralProfileDefault, - DependentClusterWorkerConcurrency: 5, - EnableSWAwareNSCaches: true, - ExportToIdentityList: []string{"*"}, - ExportToMaxNamespaces: 35, - EnableAbsoluteFQDN: true, - EnableAbsoluteFQDNForLocalEndpoints: true, - } -} - -func createMockServiceEntry(env string, identity string, endpointAddress string, endpointPort int, exportTo []string) networkingV1Alpha3.ServiceEntry { - serviceEntry := networkingV1Alpha3.ServiceEntry{ - Hosts: []string{env + "." + strings.ToLower(identity) + ".mesh"}, - Addresses: nil, - Ports: []*networkingV1Alpha3.ServicePort{{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http}}, - Location: 1, - Resolution: 2, - Endpoints: []*networkingV1Alpha3.WorkloadEntry{{Address: endpointAddress, - Locality: "us-west-2", - Ports: map[string]uint32{"http": uint32(endpointPort)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}}}, - WorkloadSelector: nil, - ExportTo: exportTo, - SubjectAltNames: []string{"spiffe://prefix/" + identity}, - } - return serviceEntry -} - -func TestGetIngressEndpoints(t *testing.T) { - identityConfig := getSampleIdentityConfig() - expectedIngressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", - Locality: "us-west-2", - Ports: map[string]uint32{"http": uint32(15443)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, - }} - testCases := []struct { - name string - identityConfigClusters []IdentityConfigCluster - expectedIngressEndpoints []*networkingV1Alpha3.WorkloadEntry - }{ - { - name: "Given an IdentityConfigCluster, " + - "Then the constructed endpoint should be the ingress endpoint", - identityConfigClusters: identityConfig.Clusters, - expectedIngressEndpoints: expectedIngressEndpoints, - }, - } - for _, c := range testCases { - t.Run(c.name, func(t *testing.T) { - ingressEndpoints, err := getIngressEndpoints(c.identityConfigClusters) - if err != nil { - t.Errorf("While constructing ingressEndpoint, got error: %v", err) - } - if !reflect.DeepEqual(ingressEndpoints, c.expectedIngressEndpoints) { - t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") - } - }) - } -} - -func TestGetServiceEntryPorts(t *testing.T) { - e2eEnv := getSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") - expectedSEPorts := []*networkingV1Alpha3.ServicePort{{Number: uint32(common.DefaultServiceEntryPort), Name: util.Http, Protocol: util.Http}} - testCases := []struct { - name string - identityConfigEnvironment IdentityConfigEnvironment - expectedSEPorts []*networkingV1Alpha3.ServicePort - }{ - { - name: "Given an IdentityConfigEnvironment, " + - "Then the constructed ServiceEntryPorts should be as expected", - identityConfigEnvironment: e2eEnv, - expectedSEPorts: expectedSEPorts, - }, - } - for _, c := range testCases { - t.Run(c.name, func(t *testing.T) { - sePorts, err := getServiceEntryPorts(e2eEnv) - if err != nil { - t.Errorf("While constructing serviceEntryPorts, got error: %v", err) - } - if !reflect.DeepEqual(sePorts, c.expectedSEPorts) { - t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") - } - }) - } -} - -func TestGetServiceEntryEndpoints(t *testing.T) { - admiralParams := admiralParamsForServiceEntryTests() - common.ResetSync() - common.InitializeConfig(admiralParams) - e2eEnv := getSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") - ingressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", - Locality: "us-west-2", - Ports: map[string]uint32{"http": uint32(15443)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, - }} - remoteEndpoint := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", - Locality: "us-west-2", - Ports: map[string]uint32{"http": uint32(15443)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, - }} - localEndpoint := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "partner-data-to-tax-spk-root-service.ctg-taxprep-partnerdatatotax-usw2-e2e.svc.cluster.local.", - Locality: "us-west-2", - Ports: map[string]uint32{"http": uint32(8090)}, - Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, - }} - ctx := context.Background() - ctxLogger := common.GetCtxLogger(ctx, "ctg-taxprep-partnerdatatotax", "") - testCases := []struct { - name string - identityConfigEnvironment IdentityConfigEnvironment - ingressEndpoints []*networkingV1Alpha3.WorkloadEntry - operatorCluster string - sourceCluster string - remoteEndpointAddress string - expectedSEEndpoints []*networkingV1Alpha3.WorkloadEntry - }{ - { - name: "Given an IdentityConfigEnvironment and ingressEndpoint, " + - "When the operator cluster is not the same as the source cluster" + - "Then the constructed endpoint should be a remote endpoint", - identityConfigEnvironment: e2eEnv, - ingressEndpoints: ingressEndpoints, - operatorCluster: "cg-tax-ppd-usw2-k8s", - sourceCluster: "apigw-cx-ppd-usw2-k8s", - remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", - expectedSEEndpoints: remoteEndpoint, - }, - { - name: "Given an IdentityConfigEnvironment and ingressEndpoint, " + - "When the operator cluster is the same as the source cluster" + - "Then the constructed endpoint should be a local endpoint", - identityConfigEnvironment: e2eEnv, - ingressEndpoints: ingressEndpoints, - operatorCluster: "cg-tax-ppd-usw2-k8s", - sourceCluster: "cg-tax-ppd-usw2-k8s", - remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", - expectedSEEndpoints: localEndpoint, - }, - } - for _, c := range testCases { - t.Run(c.name, func(t *testing.T) { - seEndpoint, err := getServiceEntryEndpoints(ctxLogger, c.operatorCluster, c.sourceCluster, c.ingressEndpoints, c.remoteEndpointAddress, c.identityConfigEnvironment) - if err != nil { - t.Errorf("While constructing serviceEntryPortEndpoint, got error: %v", err) - } - opts := cmpopts.IgnoreUnexported(networkingV1Alpha3.WorkloadEntry{}) - if !cmp.Equal(seEndpoint, c.expectedSEEndpoints, opts) { - t.Errorf("Mismatch between constructed ingressEndpoint and expected ingressEndpoint") - t.Errorf(cmp.Diff(seEndpoint, c.expectedSEEndpoints, opts)) - } - }) - } -} - -func TestBuildServiceEntriesFromIdentityConfig(t *testing.T) { - -} diff --git a/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json b/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json new file mode 100644 index 000000000..61387d2f3 --- /dev/null +++ b/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json @@ -0,0 +1,174 @@ +{ + "identityName": "Intuit.ctg.taxprep.partnerdatatotax", + "clusters": [ + { + "_comment-1": "THIS SECTION CONTAINS CLUSTER LEVEL DETAILS, WHICH ARE THE SAME FOR THE ASSET IN A GIVEN CLUSTER", + "name": "cg-tax-ppd-usw2-k8s", + "locality": "us-west-2", + "ingressEndpoint": "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", + "ingressPort": "15443", + "ingressPortName": "http", + "_comment-2": "THIS SECTION CONTAINS ENVIRONMENT LEVEL DETAILS, FOR THE ASSET IN A GIVEN CLUSTER", + "environment": [ + { + "name": "prf", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-prf", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + }, + { + "name": "e2e", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-e2e", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + }, + { + "name": "qal", + "namespace": "ctg-taxprep-partnerdatatotax-usw2-qal", + "serviceName": "partner-data-to-tax-spk-root-service", + "type": "rollout", + "selectors": { + "app": "partner-data-to-tax" + }, + "ports": [ + { + "name": "http-service-mesh", + "port": 8090, + "protocol": "TCP", + "targetPort": 8090 + } + ], + "trafficPolicy": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "loadBalancer": { + "localityLbSetting": { + "distribute": [ + { + "from": "*", + "to": { + "us-west-2": 100 + } + } + ] + }, + "simple": "LEAST_REQUEST", + "warmupDurationSecs": "45s" + }, + "outlierDetection": { + "consecutive5xxErrors": 0, + "consecutiveGatewayErrors": 0 + } + } + } + ] + } + ], + "clientAssets": [ + { + "name": "intuit.cto.dev_portal" + }, + { + "name": "intuit.ctg.tto.browserclient" + }, + { + "name": "intuit.ctg.taxprep.partnerdatatotaxtestclient" + }, + { + "name": "intuit.productmarketing.ipu.pmec" + }, + { + "name": "intuit.tax.taxdev.txo" + }, + { + "name": "intuit.CTO.oauth2" + }, + { + "name": "intuit.platform.servicesgateway.servicesgateway" + }, + { + "name": "intuit.ctg.taxprep.partnerdatatotax" + }, + { + "name": "sample" + } + ] +} \ No newline at end of file diff --git a/admiral/pkg/registry/testutils.go b/admiral/pkg/registry/testutils.go new file mode 100644 index 000000000..9566124e5 --- /dev/null +++ b/admiral/pkg/registry/testutils.go @@ -0,0 +1,65 @@ +package registry + +import ( + "github.com/golang/protobuf/ptypes/duration" + "github.com/golang/protobuf/ptypes/wrappers" + networkingV1Alpha3 "istio.io/api/networking/v1alpha3" + coreV1 "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/util/intstr" +) + +func GetSampleIdentityConfigEnvironment(env string, namespace string) IdentityConfigEnvironment { + identityConfigEnvironment := IdentityConfigEnvironment{ + Name: env, + Namespace: namespace, + ServiceName: "partner-data-to-tax-spk-root-service", + Type: "rollout", + Selectors: map[string]string{"app": "partner-data-to-tax"}, + Ports: []coreV1.ServicePort{{Name: "http-service-mesh", Port: int32(8090), Protocol: coreV1.ProtocolTCP, TargetPort: intstr.FromInt(8090)}}, + TrafficPolicy: networkingV1Alpha3.TrafficPolicy{ + LoadBalancer: &networkingV1Alpha3.LoadBalancerSettings{ + LbPolicy: &networkingV1Alpha3.LoadBalancerSettings_Simple{Simple: networkingV1Alpha3.LoadBalancerSettings_LEAST_REQUEST}, + LocalityLbSetting: &networkingV1Alpha3.LocalityLoadBalancerSetting{ + Distribute: []*networkingV1Alpha3.LocalityLoadBalancerSetting_Distribute{{ + From: "*", + To: map[string]uint32{"us-west-2": 100}, + }}, + }, + WarmupDurationSecs: &duration.Duration{Seconds: 45}, + }, + ConnectionPool: &networkingV1Alpha3.ConnectionPoolSettings{ + Http: &networkingV1Alpha3.ConnectionPoolSettings_HTTPSettings{ + Http2MaxRequests: 1000, + MaxRequestsPerConnection: 5, + }, + }, + OutlierDetection: &networkingV1Alpha3.OutlierDetection{ + ConsecutiveGatewayErrors: &wrappers.UInt32Value{Value: 0}, + Consecutive_5XxErrors: &wrappers.UInt32Value{Value: 0}, + }, + }, + } + return identityConfigEnvironment +} + +func GetSampleIdentityConfig() IdentityConfig { + prfEnv := GetSampleIdentityConfigEnvironment("prf", "ctg-taxprep-partnerdatatotax-usw2-prf") + e2eEnv := GetSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") + qalEnv := GetSampleIdentityConfigEnvironment("qal", "ctg-taxprep-partnerdatatotax-usw2-qal") + environments := []IdentityConfigEnvironment{prfEnv, e2eEnv, qalEnv} + clientAssets := []map[string]string{{"name": "intuit.cto.dev_portal"}, {"name": "intuit.ctg.tto.browserclient"}, {"name": "intuit.ctg.taxprep.partnerdatatotaxtestclient"}, {"name": "intuit.productmarketing.ipu.pmec"}, {"name": "intuit.tax.taxdev.txo"}, {"name": "intuit.CTO.oauth2"}, {"name": "intuit.platform.servicesgateway.servicesgateway"}, {"name": "intuit.ctg.taxprep.partnerdatatotax"}, {"name": "sample"}} + cluster := IdentityConfigCluster{ + Name: "cg-tax-ppd-usw2-k8s", + Locality: "us-west-2", + IngressEndpoint: "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", + IngressPort: "15443", + IngressPortName: "http", + Environment: environments, + } + identityConfig := IdentityConfig{ + IdentityName: "Intuit.ctg.taxprep.partnerdatatotax", + Clusters: []IdentityConfigCluster{cluster}, + ClientAssets: clientAssets, + } + return identityConfig +} diff --git a/admiral/pkg/test/mock.go b/admiral/pkg/test/mock.go index bffd775f7..1e23c43bc 100644 --- a/admiral/pkg/test/mock.go +++ b/admiral/pkg/test/mock.go @@ -3,6 +3,7 @@ package test import ( "context" "errors" + admiralapiv1 "github.com/istio-ecosystem/admiral-api/pkg/apis/admiral/v1" argoprojv1alpha1 "github.com/argoproj/argo-rollouts/pkg/client/clientset/versioned/typed/rollouts/v1alpha1" metaV1 "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -412,3 +413,14 @@ func (m *MockOutlierDetectionHandler) Deleted(ctx context.Context, obj *admiralV m.Obj = nil return nil } + +type MockShardHandler struct { +} + +func (m *MockShardHandler) Added(ctx context.Context, obj *admiralapiv1.Shard) error { + return nil +} + +func (m *MockShardHandler) Deleted(ctx context.Context, obj *admiralapiv1.Shard) error { + return nil +} diff --git a/go.mod b/go.mod index 69197c490..e37690fb6 100644 --- a/go.mod +++ b/go.mod @@ -1,11 +1,13 @@ module github.com/istio-ecosystem/admiral -go 1.21 +go 1.21.7 + +toolchain go1.21.11 require ( github.com/argoproj/argo-rollouts v1.2.1 github.com/cenkalti/backoff v2.2.1+incompatible - github.com/go-openapi/swag v0.22.3 // indirect + github.com/go-openapi/swag v0.22.9 // indirect github.com/golang/protobuf v1.5.3 github.com/google/go-cmp v0.6.0 github.com/gorilla/mux v1.8.0 @@ -17,19 +19,27 @@ require ( github.com/sirupsen/logrus v1.8.1 github.com/spf13/cobra v1.5.0 github.com/stretchr/testify v1.9.0 - golang.org/x/net v0.20.0 // indirect - golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect + golang.org/x/net v0.21.0 // indirect + golang.org/x/time v0.5.0 // indirect gopkg.in/yaml.v2 v2.4.0 istio.io/api v1.19.6 istio.io/client-go v1.14.0 - k8s.io/api v0.28.0 - k8s.io/apimachinery v0.28.0 - k8s.io/client-go v0.24.2 - sigs.k8s.io/yaml v1.3.0 // indirect + k8s.io/api v0.29.2 + k8s.io/apimachinery v0.29.2 + k8s.io/client-go v0.29.2 + sigs.k8s.io/yaml v1.4.0 // indirect ) require ( +<<<<<<< HEAD github.com/aws/aws-sdk-go v1.55.2 +======= + github.com/aws/aws-sdk-go v1.44.105 + github.com/golang/glog v1.1.0 + github.com/istio-ecosystem/admiral-api v1.1.0 + github.com/jamiealquiza/tachymeter v2.0.0+incompatible + github.com/jedib0t/go-pretty/v6 v6.5.3 +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/prometheus/common v0.53.0 go.opentelemetry.io/otel v1.27.0 go.opentelemetry.io/otel/exporters/prometheus v0.49.0 @@ -47,6 +57,10 @@ require ( github.com/rogpeppe/go-internal v1.12.0 // indirect go.opentelemetry.io/otel/sdk v1.27.0 // indirect go.opentelemetry.io/otel/trace v1.27.0 // indirect +<<<<<<< HEAD +======= + golang.org/x/tools v0.16.1 // indirect +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13 // indirect ) @@ -57,15 +71,22 @@ require ( github.com/beorn7/perks v1.0.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect +<<<<<<< HEAD github.com/emicklei/go-restful/v3 v3.10.1 // indirect github.com/evanphx/json-patch v4.12.0+incompatible // indirect +======= + github.com/emicklei/go-restful/v3 v3.11.2 // indirect + github.com/evanphx/json-patch v5.9.0+incompatible // indirect + github.com/fsnotify/fsnotify v1.7.0 // indirect + github.com/go-co-op/gocron v1.13.0 // indirect +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/go-logr/logr v1.4.1 // indirect - github.com/go-openapi/jsonpointer v0.19.6 // indirect - github.com/go-openapi/jsonreference v0.20.2 // indirect + github.com/go-openapi/jsonpointer v0.20.2 // indirect + github.com/go-openapi/jsonreference v0.20.4 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/google/gnostic v0.6.9 // indirect github.com/google/gofuzz v1.2.0 // indirect - github.com/google/uuid v1.3.0 + github.com/google/uuid v1.6.0 github.com/inconshreveable/mousetrap v1.0.0 // indirect github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect @@ -74,25 +95,48 @@ require ( github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect +<<<<<<< HEAD github.com/onsi/ginkgo/v2 v2.13.2 // indirect +======= + github.com/onsi/ginkgo/v2 v2.14.0 + github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8 // indirect +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/prometheus/procfs v0.15.0 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/stretchr/objx v0.5.2 // indirect +<<<<<<< HEAD golang.org/x/oauth2 v0.16.0 // indirect +======= + github.com/tevino/abool v1.2.0 // indirect + github.com/ugorji/go/codec v1.2.7 // indirect + github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7 // indirect + github.intuit.com/idps/idps-go-commons/v3 v3.4.4 // indirect + github.intuit.com/idps/idps-go-swagger-clients v1.8.1 // indirect + go.opencensus.io v0.24.0 // indirect + golang.org/x/crypto v0.19.0 // indirect + golang.org/x/oauth2 v0.17.0 // indirect + golang.org/x/sync v0.7.0 // indirect +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.20.0 // indirect - golang.org/x/term v0.16.0 // indirect + golang.org/x/term v0.17.0 // indirect golang.org/x/text v0.14.0 // indirect +<<<<<<< HEAD google.golang.org/appengine v1.6.7 // indirect +======= + google.golang.org/api v0.126.0 // indirect + google.golang.org/appengine v1.6.8 // indirect + google.golang.org/grpc v1.57.0 // indirect +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) gopkg.in/alecthomas/kingpin.v2 v2.2.6 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/klog/v2 v2.100.1 // indirect - k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5 // indirect - k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 // indirect + k8s.io/klog/v2 v2.120.1 // indirect + k8s.io/kube-openapi v0.0.0-20240209001042-7a0d5b415232 // indirect + k8s.io/utils v0.0.0-20240102154912-e7106e64919e // indirect sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect - sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect + sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect ) replace ( @@ -115,6 +159,7 @@ replace ( k8s.io/csi-translation-lib => k8s.io/csi-translation-lib v0.24.2 k8s.io/kube-aggregator => k8s.io/kube-aggregator v0.24.2 k8s.io/kube-controller-manager => k8s.io/kube-controller-manager v0.24.2 + k8s.io/kube-openapi => k8s.io/kube-openapi v0.0.0-20230525220651-2546d827e515 k8s.io/kube-proxy => k8s.io/kube-proxy v0.24.2 k8s.io/kube-scheduler => k8s.io/kube-scheduler v0.24.2 k8s.io/kubectl => k8s.io/kubectl v0.24.2 diff --git a/go.sum b/go.sum index 7c93c5514..b4e62b48f 100644 --- a/go.sum +++ b/go.sum @@ -231,8 +231,9 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= -github.com/emicklei/go-restful/v3 v3.10.1 h1:rc42Y5YTp7Am7CS630D7JmhRjq4UlEUuEKfrDac4bSQ= -github.com/emicklei/go-restful/v3 v3.10.1/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/emicklei/go-restful/v3 v3.8.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/emicklei/go-restful/v3 v3.11.2 h1:1onLa9DcsMYO9P+CXaL0dStDqQ2EHHXLiz+BtnqkLAU= +github.com/emicklei/go-restful/v3 v3.11.2/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -240,16 +241,19 @@ github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5y github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/evanphx/json-patch v4.12.0+incompatible h1:4onqiflcdA9EOZ4RxV643DvftH5pOlLGNtQ5lPWQu84= github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= +<<<<<<< HEAD github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4= github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d/go.mod h1:ZZMPRZwes7CROmyNKgQzC3XPs6L/G2EJLHddWejkmf4= github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +======= +github.com/evanphx/json-patch v5.9.0+incompatible h1:fBXyNpNMuTTDdquAq/uisOr2lShz4oaXpDTX2bLe7ls= +github.com/evanphx/json-patch v5.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/flowstack/go-jsonschema v0.1.1/go.mod h1:yL7fNggx1o8rm9RlgXv7hTBWxdBM0rVwpMwimd3F3N0= github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU= -github.com/getkin/kin-openapi v0.76.0/go.mod h1:660oXbgy5JFMKreazJaQTw7o+X00qeSyhcnluiMv+Xg= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32/go.mod h1:GIjDIg/heH5DOkXY3YJ/wNhfHsQHoXGjl8G8amsYQ1I= github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= @@ -267,18 +271,20 @@ github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ4 github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE= github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs= -github.com/go-openapi/jsonreference v0.19.3/go.mod h1:rjx6GuL8TTa9VaixXglHmQmIL98+wF9xc8zWvFonSJ8= +github.com/go-openapi/jsonpointer v0.20.2 h1:mQc3nmndL8ZBzStEo3JYF8wzmeWffDH4VbXz58sAx6Q= +github.com/go-openapi/jsonpointer v0.20.2/go.mod h1:bHen+N0u1KEO3YlmqOjTT9Adn1RfD91Ar825/PuiRVs= github.com/go-openapi/jsonreference v0.19.5/go.mod h1:RdybgQwPxbL4UEjuAruzK1x3nE69AqPYEJeo/TWfEeg= -github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE= -github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= +github.com/go-openapi/jsonreference v0.20.1/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= +github.com/go-openapi/jsonreference v0.20.4 h1:bKlDxQxQJgwpUSgOENiMPzCTBVuc7vTdXSSgNeAhojU= +github.com/go-openapi/jsonreference v0.20.4/go.mod h1:5pZJyJP2MnYCpoeoMAql78cCHauHj0V9Lhc506VOpw4= github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-openapi/swag v0.19.14/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= -github.com/go-openapi/swag v0.22.3 h1:yMBqmnQ0gyZvEb/+KzuWZOXgllrXT4SADYbvDaXHv/g= github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= +github.com/go-openapi/swag v0.22.9 h1:XX2DssF+mQKM2DHsbgZK74y/zj4mo9I99+89xUmuZCE= +github.com/go-openapi/swag v0.22.9/go.mod h1:3/OXnFfnMAwBD099SwYRk7GD3xOrr1iL7d/XNLXVVwE= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= github.com/go-telegram-bot-api/telegram-bot-api/v5 v5.4.0/go.mod h1:A2S0CWkNylc2phvKXWBBdD3K0iGnDBGbzRpISP2zBl8= @@ -336,6 +342,12 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +<<<<<<< HEAD +======= +github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= +github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-github/v41 v41.0.0/go.mod h1:XgmCA5H323A9rtgExdTcnDkcqp6S30AVACCBDOonIxg= @@ -358,13 +370,27 @@ github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +<<<<<<< HEAD +======= +github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/google/pprof v0.0.0-20211214055906-6f57359322fd h1:1FjCyPC+syAzJ5/2S8fqdZK1R22vvA0J7JZKcuOIQ7Y= github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +<<<<<<< HEAD github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +======= +github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= +github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/googleapis/enterprise-certificate-proxy v0.2.3 h1:yk9/cqRKtT9wXZSsRH9aurXEpJX+U6FLtpYTdC3R06k= +github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= @@ -389,6 +415,27 @@ github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= +<<<<<<< HEAD +======= +github.com/intuit/funnel v1.0.0 h1:DL7tQjXpRXmTb6C/xU2Hn9hcHh7/VnHC0+vep4e3P7E= +github.com/intuit/funnel v1.0.0/go.mod h1:mDE1DfyEnFN29i8pcDDjNvVRKiZU+/N3YCuEl3CGQEU= +github.com/istio-ecosystem/admiral-api v1.1.0 h1:SLRgKRdZP31G0Q2uaYcVb3JxkjAbTxbSsze2N5ncapE= +github.com/istio-ecosystem/admiral-api v1.1.0/go.mod h1:xB+G1v2H/cOxuR6koi/3kLHgF+oc3y905Lt12NCyMCI= +github.com/jacobsa/crypto v0.0.0-20190317225127-9f44e2d11115 h1:YuDUUFNM21CAbyPOpOP8BicaTD/0klJEKt5p8yuw+uY= +github.com/jacobsa/crypto v0.0.0-20190317225127-9f44e2d11115/go.mod h1:LadVJg0XuawGk+8L1rYnIED8451UyNxEMdTWCEt5kmU= +github.com/jacobsa/oglematchers v0.0.0-20150720000706-141901ea67cd h1:9GCSedGjMcLZCrusBZuo4tyKLpKUPenUUqi34AkuFmA= +github.com/jacobsa/oglematchers v0.0.0-20150720000706-141901ea67cd/go.mod h1:TlmyIZDpGmwRoTWiakdr+HA1Tukze6C6XbRVidYq02M= +github.com/jacobsa/oglemock v0.0.0-20150831005832-e94d794d06ff h1:2xRHTvkpJ5zJmglXLRqHiZQNjUoOkhUyhTAhEQvPAWw= +github.com/jacobsa/oglemock v0.0.0-20150831005832-e94d794d06ff/go.mod h1:gJWba/XXGl0UoOmBQKRWCJdHrr3nE0T65t6ioaj3mLI= +github.com/jacobsa/ogletest v0.0.0-20170503003838-80d50a735a11 h1:BMb8s3ENQLt5ulwVIHVDWFHp8eIXmbfSExkvdn9qMXI= +github.com/jacobsa/ogletest v0.0.0-20170503003838-80d50a735a11/go.mod h1:+DBdDyfoO2McrOyDemRBq0q9CMEByef7sYl7JH5Q3BI= +github.com/jacobsa/reqtrace v0.0.0-20150505043853-245c9e0234cb h1:uSWBjJdMf47kQlXMwWEfmc864bA1wAC+Kl3ApryuG9Y= +github.com/jacobsa/reqtrace v0.0.0-20150505043853-245c9e0234cb/go.mod h1:ivcmUvxXWjb27NsPEaiYK7AidlZXS7oQ5PowUS9z3I4= +github.com/jamiealquiza/tachymeter v2.0.0+incompatible h1:mGiF1DGo8l6vnGT8FXNNcIXht/YmjzfraiUprXYwJ6g= +github.com/jamiealquiza/tachymeter v2.0.0+incompatible/go.mod h1:Ayf6zPZKEnLsc3winWEXJRkTBhdHo58HODAu1oFJkYU= +github.com/jedib0t/go-pretty/v6 v6.5.3 h1:GIXn6Er/anHTkVUoufs7ptEvxdD6KIhR7Axa2wYCPF0= +github.com/jedib0t/go-pretty/v6 v6.5.3/go.mod h1:5LQIxa52oJ/DlDSLv0HEkWOFMDGoWkJb9ss5KqPpJBg= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= @@ -430,11 +477,14 @@ github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27k github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= +<<<<<<< HEAD github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/reflectwalk v1.0.1/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +======= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= github.com/moby/term v0.0.0-20210610120745-9d4ed1856297/go.mod h1:vgPCkQMyxTZ7IDy8SXRufE172gr8+K/JE/7hHFxHW3A= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -453,15 +503,19 @@ github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+ github.com/newrelic/newrelic-client-go v0.72.0/go.mod h1:VXjhsfui0rvhM9cVwnKwlidF8NbXlHZvh63ZKi6fImA= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= +github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= -github.com/onsi/ginkgo/v2 v2.13.2 h1:Bi2gGVkfn6gQcjNjZJVO8Gf0FHzMPf2phUei9tejVMs= -github.com/onsi/ginkgo/v2 v2.13.2/go.mod h1:XStQ8QcGwLyF4HdfcZB8SFOS/MWCgDuXMSBe6zrvLgM= -github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= +github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= +github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= +github.com/onsi/ginkgo/v2 v2.1.4/go.mod h1:um6tUpWM/cxCK3/FK8BXqEiUMUwRgSM4JXG47RKZmLU= +github.com/onsi/ginkgo/v2 v2.14.0 h1:vSmGj2Z5YPb9JwCWT6z6ihcUvDhuXLc3sJiqd3jMKAY= +github.com/onsi/ginkgo/v2 v2.14.0/go.mod h1:JkUdW7JkN0V6rFvsHcJ478egV3XH9NxpD27Hal/PhZw= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= +github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= +github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= @@ -534,6 +588,19 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +<<<<<<< HEAD +======= +github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7 h1:nSypwHIJ7o0IzWYVfVzmogrF5HIz/HCiSeMo0Mo3ymU= +github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7/go.mod h1:maAd/rJYgSC2c9PvkGZZD/NrkVyhZL9/jDU75iTzgKE= +github.intuit.com/idps/idps-go-commons/v3 v3.4.4 h1:DxyPs+Q6wi7doX/2Ers2KnTv5B+vRclKCNVeCgkt01Y= +github.intuit.com/idps/idps-go-commons/v3 v3.4.4/go.mod h1:NMUz/MLrhUE4/SdxPGGc5KMk3kC9B8UdUAuelSYgA/0= +github.intuit.com/idps/idps-go-sdk/v3 v3.9909.0 h1:NtujYowO6tlJTmSHS1OoVAJ1ftTMCYWnuQSvVML1agI= +github.intuit.com/idps/idps-go-sdk/v3 v3.9909.0/go.mod h1:IIy+JIbUnqhjVqB+g6XXK1/Wd1J1Mnd26W1DPELs4Fo= +github.intuit.com/idps/idps-go-swagger-clients v1.8.1 h1:f7unZbxkR4WQRxHOL5B97HfoAwnkHjfUW1xLvK6GcHg= +github.intuit.com/idps/idps-go-swagger-clients v1.8.1/go.mod h1:L0XVKcoVv71IoVZBIgmQfJ0ux0E0cguZsxTyos9v6kg= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= @@ -562,7 +629,14 @@ golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +<<<<<<< HEAD golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= +======= +golang.org/x/crypto v0.0.0-20220314234659-1baeb1ce4c0b/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20220427172511-eb4f295cb31f/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.19.0 h1:ENy+Az/9Y1vSrlrvBSyna3PITt4tiZLf7sgCjZBX7Wo= +golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -597,7 +671,13 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +<<<<<<< HEAD golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +======= +golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -633,11 +713,29 @@ golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= +<<<<<<< HEAD +======= +golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= +golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +<<<<<<< HEAD golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo= golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= +======= +golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.3.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= +golang.org/x/net v0.4.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= +golang.org/x/net v0.21.0 h1:AQyQV4dYCvJ7vGmJyKki9+PBdyvhkSd8EIx/qb0AYv4= +golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -650,8 +748,16 @@ golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +<<<<<<< HEAD golang.org/x/oauth2 v0.16.0 h1:aDkGMBSYxElaoP81NpoUoz2oo2R2wHdZpGToUxfyQrQ= golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= +======= +golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.17.0 h1:6m3ZPmLEFdVxKKWnKq4VqZ60gutO35zm+zrAHVmHyDQ= +golang.org/x/oauth2 v0.17.0/go.mod h1:OzPDGQiuQMguemayvdylqddI7qcD9lnSDb+1FiwQ5HA= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -663,6 +769,12 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +<<<<<<< HEAD +======= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -703,6 +815,7 @@ golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -714,14 +827,32 @@ golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +<<<<<<< HEAD +======= +golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +<<<<<<< HEAD +======= +golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y= golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.16.0 h1:m+B6fahuftsE9qjo0VWp2FW0mB3MTJvR0BaMQrq0pmE= -golang.org/x/term v0.16.0/go.mod h1:yn7UURbUtPyrVJPGPq404EukNFxcm/foM+bV/bfcDsY= +golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA= +golang.org/x/term v0.17.0 h1:mkTF7LCd6WGJNL3K1Ad7kwxNfYAW6a8a8QqtMblp/4U= +golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -730,13 +861,19 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +<<<<<<< HEAD +======= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 h1:vVKdlvoWBphwdxWKrFZEuM0kGgGLxUOYcY4U/2Vjg44= golang.org/x/time v0.0.0-20220210224613-90d013bbcef8/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= +golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -783,19 +920,33 @@ golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82u golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +<<<<<<< HEAD golang.org/x/tools v0.14.0 h1:jvNa2pY0M4r62jkRQ6RwEZZyPcymeL9XZMLBbV7U2nc= golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= +======= +golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/tools v0.4.0/go.mod h1:UE5sM2OK9E/d67R0ANs2xJizIymRP5gJU295PvKXxjQ= +golang.org/x/tools v0.16.1 h1:TLyB3WofjdOEepBHAU20JdNC1Zbg87elYofWYAY5oZA= +golang.org/x/tools v0.16.1/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +<<<<<<< HEAD golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gomodules.xyz/envconfig v1.3.1-0.20190308184047-426f31af0d45/go.mod h1:41y72mzHT7+jFNgyBpJRrZWuZJcLmLrTpq6iGgOFJMQ= gomodules.xyz/notify v0.1.0/go.mod h1:wGy0vLXGpabCg0j9WbjzXf7pM7Khz11FqCLtBbTujP0= +======= +golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -823,8 +974,9 @@ google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7 google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= +google.golang.org/appengine v1.6.8 h1:IhEN5q69dyKagZPYMSdIjS2HqprW324FRQZJcGqPAsM= +google.golang.org/appengine v1.6.8/go.mod h1:1jJ3jBArFh5pcgW8gCtRJnepW8FzD1V44FJffLiz/Ds= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= @@ -925,7 +1077,6 @@ gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -965,6 +1116,7 @@ k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAE k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= k8s.io/klog/v2 v2.60.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= +<<<<<<< HEAD k8s.io/klog/v2 v2.100.1 h1:7WCHKK6K8fNhTqfBhISHQ97KrnJNFZMcQvKp7gP/tmg= k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= @@ -972,22 +1124,32 @@ k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5 h1:/zkKSeCtGRHYqRmrpa9uPY k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5/go.mod h1:/BYxry62FuDzmI+i9B+X2pqfySRmSOW2ARmj5Zbqhj0= k8s.io/kubectl v0.24.2/go.mod h1:+HIFJc0bA6Tzu5O/YcuUt45APAxnNL8LeMuXwoiGsPg= k8s.io/kubernetes v1.23.1/go.mod h1:baMGbPpwwP0kT/+eAPtdqoWNRoXyyTJ2Zf+fw/Y8t04= +======= +k8s.io/klog/v2 v2.120.1 h1:QXU6cPEOIslTGvZaXvFWiP9VKyeet3sawzTOvdXb4Vw= +k8s.io/klog/v2 v2.120.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= +k8s.io/kube-openapi v0.0.0-20230525220651-2546d827e515 h1:OmK1d0WrkD3IPfkskvroRykOulHVHf0s0ZIFRjyt+UI= +k8s.io/kube-openapi v0.0.0-20230525220651-2546d827e515/go.mod h1:kzo02I3kQ4BTtEfVLaPbjvCkX97YqGve33wzlb3fofQ= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= -k8s.io/utils v0.0.0-20230406110748-d93618cff8a2 h1:qY1Ad8PODbnymg2pRbkyMT/ylpTrCM8P2RJ0yroCyIk= -k8s.io/utils v0.0.0-20230406110748-d93618cff8a2/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +k8s.io/utils v0.0.0-20240102154912-e7106e64919e h1:eQ/4ljkx21sObifjzXwlPKpdGLrCfRziVtos3ofG/sQ= +k8s.io/utils v0.0.0-20240102154912-e7106e64919e/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2/go.mod h1:B+TnT182UBxE84DiCz4CVE26eOSDAeYCpfDnC2kdKMY= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +<<<<<<< HEAD sigs.k8s.io/kustomize/api v0.10.1/go.mod h1:2FigT1QN6xKdcnGS2Ppp1uIWrtWN28Ms8A3OZUZhwr8= sigs.k8s.io/kustomize/kyaml v0.13.0/go.mod h1:FTJxEZ86ScK184NpGSAQcfEqee0nul8oLCK30D47m4E= sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= +======= +>>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) sigs.k8s.io/structured-merge-diff/v4 v4.2.1/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= -sigs.k8s.io/structured-merge-diff/v4 v4.2.3 h1:PRbqxJClWWYMNV1dhaG4NsibJbArud9kFxnAMREiWFE= sigs.k8s.io/structured-merge-diff/v4 v4.2.3/go.mod h1:qjx8mGObPmV2aSZepjQjbmb2ihdVs8cGKBraizNC69E= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1/go.mod h1:N8hJocpFajUSSeSJ9bOZ77VzejKZaXsTtZo4/u7Io08= sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc= -sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= -sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= +sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= +sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= From a95bd85b0aa288d90216836f91a86f356983d133 Mon Sep 17 00:00:00 2001 From: rtay1188 Date: Mon, 29 Jul 2024 16:19:24 -0400 Subject: [PATCH 3/8] admiral crds * add sample identity configuration json response * struct for identityConfig * basic cache structure * implemented interface for config discovery * add ctxLoggers * include type in CRD * first pass at building SE from identityConfig * comments * function to make IdentityConfigEnvironment * edit ctx and function names * change struct names * drafted of SEbuilder * test * shard controller setup * change names * placeholder * factor out parts of build se * factor out ingressendpoint * merge in master * linter error * add comments and make methods private * added some tests * add tests * finish tests for sebuilder * testing * test * shard controller first pass * add registry client to controller * add concurrent processing of IdentityConfig * pin kube-openapi version and fix tests * fix concurrent test issue * add some tests for shard controller * add more tests * add logvalueofadmiraltoignore test * add processitem tests * add test * addUpdateSE * fix import cycle * shard handler basic test * add config options and label selector * additional test files * minor changes to tests * change shard controller to not be per cluster * change sebuilder to use destination cluster * remove unused operator cluster of registry client * abstract readFile * fix config path * change var and func names * make registryClient private * remove labeloptions * additional test coverage * update tests * fix test names * fix comments * fixed some review comments * removed HA * consolidate ctx and ctxlogger * remove controllers for operator * remove unnecessary equals * rework endpoint processing * move client asset out of cluster scope * change bool * fix test name typo * fix review comments * add function comments * cater to review comments * edit port comments * add AddSEwithDRWorker func to shardhandler * change soureCluster to serverCluster * add admiral crds to identityConfig * MESH-5198: abstracted operator code in drworker (#755) * merge master changes * added Generation back * fix review comments Signed-off-by: Shriram Sharma --- .../pkg/clusters/destinationrule_handler.go | 3 +- admiral/pkg/clusters/serviceentry.go | 47 ++- admiral/pkg/clusters/shard_handler.go | 30 ++ ...eshtestblackholeIdentityConfiguration.json | 119 ++++-- ...meshtestinboundsIdentityConfiguration.json | 57 ++- .../testdata/sampleIdentityConfiguration.json | 171 ++++++--- admiral/pkg/registry/registry.go | 29 +- .../testdata/sampleIdentityConfiguration.json | 171 ++++++--- admiral/pkg/registry/testutils.go | 68 +++- go.mod | 43 +-- go.sum | 338 +----------------- 11 files changed, 519 insertions(+), 557 deletions(-) diff --git a/admiral/pkg/clusters/destinationrule_handler.go b/admiral/pkg/clusters/destinationrule_handler.go index 633ef78b6..16c2647b7 100644 --- a/admiral/pkg/clusters/destinationrule_handler.go +++ b/admiral/pkg/clusters/destinationrule_handler.go @@ -43,7 +43,8 @@ func getDestinationRule(se *networkingV1Alpha3.ServiceEntry, locality string, gt ) dr.Host = se.Hosts[0] - if common.EnableExportTo(dr.Host) { + // In Operator mode, exportTo will be present in the se as well + if common.EnableExportTo(dr.Host) || common.IsAdmiralOperatorMode() { dr.ExportTo = se.ExportTo } dr.TrafficPolicy = &networkingV1Alpha3.TrafficPolicy{ diff --git a/admiral/pkg/clusters/serviceentry.go b/admiral/pkg/clusters/serviceentry.go index 8e5caec58..8d93c938a 100644 --- a/admiral/pkg/clusters/serviceentry.go +++ b/admiral/pkg/clusters/serviceentry.go @@ -653,6 +653,9 @@ func modifyServiceEntryForNewServiceOrPod( // Given an identity with a partition prefix, returns the identity without the prefix that is stored in the PartitionIdentityCache // If the identity did not have a partition prefix, returns the passed in identity func getNonPartitionedIdentity(admiralCache *AdmiralCache, sourceIdentity string) string { + if common.IsAdmiralOperatorMode() { + return sourceIdentity + } if common.EnableSWAwareNSCaches() && admiralCache.PartitionIdentityCache != nil { nonPartitionedIdentity := admiralCache.PartitionIdentityCache.Get(sourceIdentity) if len(nonPartitionedIdentity) > 0 { @@ -1055,7 +1058,9 @@ func AddServiceEntriesWithDrWorker( //partitionedIdentity holds the originally passed in identity which could have a partition prefix partitionedIdentity := identityId //identityId is guaranteed to have the non-partitioned identity + // Operator Branch 1: since partition cache will not be filled, return identityId from getNonPartitionedIdentity identityId = getNonPartitionedIdentity(rr.AdmiralCache, identityId) + // Operator: When calling this function make a channel with one cluster in it for cluster := range clusters { // TODO log cluster / service entry se := copyServiceEntry(seObj) var ( @@ -1066,13 +1071,20 @@ func AddServiceEntriesWithDrWorker( ) rc := rr.GetRemoteController(cluster) - if rc == nil || rc.NodeController == nil || rc.NodeController.Locality == nil { - ctxLogger.Warnf(common.CtxLogFormat, "AddServiceEntriesWithDrWorker", "", "", cluster, "remote controller not found for the cluster") // TODO: add service entry name + if rc == nil { + ctxLogger.Warnf(common.CtxLogFormat, "AddServiceEntriesWithDrWorker", "", "", cluster, "remote controller not found for the cluster") + errors <- nil + continue + } + region, err := getClusterRegion(rr, cluster, rc) + if err != nil { + ctxLogger.Warnf(common.CtxLogFormat, "AddServiceEntriesWithDrWorker", "", "", cluster, "region not found for the cluster") errors <- nil continue } //this get is within the loop to avoid race condition when one event could update destination rule on stale data + // TODO: Operator: Fill these caches in AdmiralCache in shardHandler globalTrafficPolicy, err := cache.GlobalTrafficCache.GetFromIdentity(partitionedIdentity, env) if err != nil { ctxLogger.Errorf(LogErrFormat, "GlobalTrafficCache", "", "", cluster, err.Error()) @@ -1104,7 +1116,7 @@ func AddServiceEntriesWithDrWorker( start = time.Now() currentDR := getCurrentDRForLocalityLbSetting(rr, isServiceEntryModifyCalledForSourceCluster, cluster, se, partitionedIdentity) ctxLogger.Infof("currentDR set for dr=%v cluster=%v", getIstioResourceName(se.Hosts[0], "-default-dr"), cluster) - var seDrSet = createSeAndDrSetFromGtp(ctxLogger, ctx, env, rc.NodeController.Locality.Region, cluster, se, + var seDrSet = createSeAndDrSetFromGtp(ctxLogger, ctx, env, region, cluster, se, globalTrafficPolicy, outlierDetection, clientConnectionSettings, cache, currentDR) util.LogElapsedTimeSinceForModifySE(ctxLogger, "AdmiralCacheCreateSeAndDrSetFromGtp", "", "", cluster, "", start) @@ -1272,11 +1284,12 @@ func AddServiceEntriesWithDrWorker( // build list of gateway clusters gwClusters := []string{} for _, gwAlias := range common.GetGatewayAssetAliases() { + // TODO: Operator fills this cache in produceIdentityConfigs dependents := rr.AdmiralCache.IdentityDependencyCache.Get(partitionedIdentity) if dependents != nil && dependents.Len() > 0 { dependents.Range(func(_ string, dependent string) { if strings.Contains(strings.ToLower(dependent), strings.ToLower(gwAlias)) { - gwClustersMap := rr.AdmiralCache.IdentityClusterCache.Get(dependent) + gwClustersMap := getClusters(rr, dependent) if gwClustersMap != nil { for _, cluster := range gwClustersMap.GetKeys() { gwClusters = append(gwClusters, cluster) @@ -1312,7 +1325,7 @@ func AddServiceEntriesWithDrWorker( ctxLogger.Infof(LogFormat, "Create", "VirtualService", env+"."+identityId, cluster, "skipped creating additional endpoints through VirtualService in "+syncNamespace+" namespace") } - //update worklaodEndpoint entry to dynamoDB workloadData table only for source entry + //update workloadEndpoint entry to dynamoDB workloadData table only for source entry if isServiceEntryModifyCalledForSourceCluster { start = time.Now() err = storeWorkloadData(cluster, newServiceEntry, globalTrafficPolicy, additionalEndpoints, rr, ctxLogger, *seDr.DestinationRule, true) @@ -1356,6 +1369,24 @@ func AddServiceEntriesWithDrWorker( } } +func getClusterRegion(rr *RemoteRegistry, cluster string, rc *RemoteController) (string, error) { + if common.IsAdmiralOperatorMode() && rr.AdmiralCache.ClusterLocalityCache != nil { + return rr.AdmiralCache.ClusterLocalityCache.Get(cluster).Get(cluster), nil + } + if rc.NodeController != nil && rc.NodeController.Locality != nil { + return rc.NodeController.Locality.Region, nil + } + return "", fmt.Errorf("failed to get region of cluster %v", cluster) +} + +func getClusters(rr *RemoteRegistry, dependent string) *common.Map { + if common.IsAdmiralOperatorMode() { + // TODO: go through registry client to pull dependent identity clusters and construct map... + return nil + } + return rr.AdmiralCache.IdentityClusterCache.Get(dependent) +} + // getDNSPrefixFromServiceEntry returns DNSPrefix set on SE DR Tuple, // if nothing is set, then it returns default func getDNSPrefixFromServiceEntry(seDR *SeDrTuple) string { @@ -1508,7 +1539,7 @@ func storeWorkloadData(clusterName string, serviceEntry *v1alpha3.ServiceEntry, return fmt.Errorf("dynamodb client for workload data table is not initialized") } - //get worklaod data based on service entry, globaltrafficpolicy and additional endpoints + //get workload data based on service entry, globaltrafficpolicy and additional endpoints workloadData := getWorkloadData(ctxLogger, serviceEntry, globalTrafficPolicy, additionalEndpoints, dr, clusterName, isSuccess) err := pushWorkloadDataToDynamodbTable(workloadData, serviceEntry.Spec.Hosts[0], clusterName, rr, ctxLogger) @@ -1891,6 +1922,7 @@ func createSeAndDrSetFromGtp(ctxLogger *logrus.Entry, ctx context.Context, env, seDrSet = make(map[string]*SeDrTuple) ) + // TODO: Operator needs to add the EventResourceType to the ctx in shardHandler ConsumeIdentityConfigs eventResourceType, ok := ctx.Value(common.EventResourceType).(string) if !ok { ctxLogger.Errorf(AlertLogMsg, ctx.Value(common.EventResourceType)) @@ -1906,7 +1938,8 @@ func createSeAndDrSetFromGtp(ctxLogger *logrus.Entry, ctx context.Context, env, } } - if common.EnableExportTo(se.Hosts[0]) && se != nil { + // This is calculated elsewhere for Operator + if !common.IsAdmiralOperatorMode() && common.EnableExportTo(se.Hosts[0]) && se != nil { sortedDependentNamespaces := getSortedDependentNamespaces(cache, se.Hosts[0], cluster, ctxLogger) se.ExportTo = sortedDependentNamespaces } diff --git a/admiral/pkg/clusters/shard_handler.go b/admiral/pkg/clusters/shard_handler.go index 48fe851d9..262e70228 100644 --- a/admiral/pkg/clusters/shard_handler.go +++ b/admiral/pkg/clusters/shard_handler.go @@ -88,6 +88,12 @@ func ProduceIdentityConfigsFromShard(ctxLogger *log.Entry, shard admiralapiv1.Sh ctxLogger.Warnf(common.CtxLogFormat, "ProduceIdentityConfig", identityItem.Name, shard.Namespace, clusterShard.Name, err) } ctxLogger.Infof(common.CtxLogFormat, "ProduceIdentityConfig", identityConfig.IdentityName, shard.Namespace, clusterShard.Name, "successfully produced IdentityConfig") + //TODO: Fill rr.AdmiralCache + //1. IdentityDependencyCache (identityConfig.IdentityName -> clientAssets) + //2. GlobalTrafficCache (id + env -> gtp) + //3. OutlierDetectionCache (id + env -> od) + //4. ClientConnectionConfigCache (id + env -> ccc) + //5. ClusterLocalityCache (cluster -> cluster -> locality) (don't care about set functionality, only one locality per cluster) configWriterData <- &ConfigWriterData{ IdentityConfig: &identityConfig, ClusterName: clusterShard.Name, @@ -114,7 +120,31 @@ func ConsumeIdentityConfigs(ctxLogger *log.Entry, ctx context.Context, configWri ctxLogger.Warnf(common.CtxLogFormat, "ConsumeIdentityConfig", assetName, "", clientCluster, err) data.Result = err.Error() } + // service deployed in cluster 1 with 2 env qal, e2e, cluster 2 with 3 env qal, e2e, prod + // write SEs to cluster 1 + // env -> list of cluster + // env -> se + // check if any of the clusters are a source cluster -> rethink this, won't work if one env is on a cluster but not on another + //isServiceEntryModifyCalledForSourceCluster := false + //for _, cluster := range identityConfig.Clusters { + // if cluster.Name == clientCluster { + // isServiceEntryModifyCalledForSourceCluster = true + // break + // } + //} + //ctx = context.WithValue(ctx, common.EventResourceType, identityConfig.Clusters[0].Environment[0].Type) for _, se := range serviceEntries { + //clusters := make(chan string, 1) + //errors := make(chan error, 1) + //clusters <- clientCluster + //AddServiceEntriesWithDrWorker(ctxLogger, ctx, rr, + // true, //doGenerateAdditionalEndpoints() + // isServiceEntryModifyCalledForSourceCluster, + // assetName, + // strings.Split(se.Hosts[0], common.Sep)[0], + // se, + // clusters, + // errors) rc := rr.GetRemoteController(clientCluster) seName := strings.ToLower(se.Hosts[0]) + "-se" sec := rc.ServiceEntryController diff --git a/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json b/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json index 3cead8471..936becb75 100644 --- a/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json +++ b/admiral/pkg/clusters/testdata/ppdmeshtestblackholeIdentityConfiguration.json @@ -27,37 +27,59 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } } - ], - "clientAssets": [ - { - "name": "intuit.services.gateway.ppdmeshtestinbounds" - } ] }, { @@ -86,29 +108,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } } diff --git a/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json b/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json index 9bfa80e07..89cff6ab3 100644 --- a/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json +++ b/admiral/pkg/clusters/testdata/ppdmeshtestinboundsIdentityConfiguration.json @@ -27,29 +27,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } } diff --git a/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json b/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json index bebfabbca..4f39c0f6b 100644 --- a/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json +++ b/admiral/pkg/clusters/testdata/sampleIdentityConfiguration.json @@ -27,29 +27,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } }, @@ -70,29 +97,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } }, @@ -113,29 +167,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } } diff --git a/admiral/pkg/registry/registry.go b/admiral/pkg/registry/registry.go index 52644326d..64e9125b6 100644 --- a/admiral/pkg/registry/registry.go +++ b/admiral/pkg/registry/registry.go @@ -2,17 +2,14 @@ package registry import ( "encoding/json" + "os" + "strings" + "github.com/istio-ecosystem/admiral/admiral/pkg/apis/admiral/v1alpha1" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" log "github.com/sirupsen/logrus" - networkingV1Alpha3 "istio.io/api/networking/v1alpha3" coreV1 "k8s.io/api/core/v1" -<<<<<<< HEAD -======= - "os" - "strings" ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) ) // IdentityConfiguration is an interface to fetch configuration from a registry @@ -58,13 +55,19 @@ type IdentityConfigCluster struct { } type IdentityConfigEnvironment struct { - Name string `json:"name"` - Namespace string `json:"namespace"` - ServiceName string `json:"serviceName"` - Type string `json:"type"` - Selectors map[string]string `json:"selectors"` - Ports []coreV1.ServicePort `json:"ports"` - TrafficPolicy networkingV1Alpha3.TrafficPolicy `json:"trafficPolicy"` + Name string `json:"name"` + Namespace string `json:"namespace"` + ServiceName string `json:"serviceName"` + Type string `json:"type"` + Selectors map[string]string `json:"selectors"` + Ports []coreV1.ServicePort `json:"ports"` + TrafficPolicy TrafficPolicy `json:"trafficPolicy"` +} + +type TrafficPolicy struct { + ClientConnectionConfig v1alpha1.ClientConnectionConfig `json:"clientConnectionConfig"` + GlobalTrafficPolicy v1alpha1.GlobalTrafficPolicy `json:"globalTrafficPolicy"` + OutlierDetection v1alpha1.OutlierDetection `json:"outlierDetection"` } // GetIdentityConfigByIdentityName calls the registry API to fetch the IdentityConfig for diff --git a/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json b/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json index 61387d2f3..5c7101622 100644 --- a/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json +++ b/admiral/pkg/registry/testdata/sampleIdentityConfiguration.json @@ -27,29 +27,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } }, @@ -70,29 +97,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } }, @@ -113,29 +167,56 @@ } ], "trafficPolicy": { - "connectionPool": { - "http": { - "http2MaxRequests": 1000, - "maxRequestsPerConnection": 5 + "clientConnectionConfig": { + "metadata": { + "name": "sampleCCC" + }, + "spec": { + "connectionPool": { + "http": { + "http2MaxRequests": 1000, + "maxRequestsPerConnection": 5 + } + }, + "tunnel": {} } }, - "loadBalancer": { - "localityLbSetting": { - "distribute": [ + "globalTrafficPolicy": { + "metadata": { + "name": "sampleGTP" + }, + "spec": { + "policy": [ { - "from": "*", - "to": { - "us-west-2": 100 + "target": [ + { + "region": "us-west-2", + "weight": 50 + }, + { + "region": "us-east-2", + "weight": 50 + } + ], + "dnsPrefix": "testDnsPrefix", + "outlier_detection": { + "consecutive_gateway_errors": 5, + "interval": 5 } } ] - }, - "simple": "LEAST_REQUEST", - "warmupDurationSecs": "45s" + } }, "outlierDetection": { - "consecutive5xxErrors": 0, - "consecutiveGatewayErrors": 0 + "metadata": { + "name": "sampleOD" + }, + "spec": { + "outlier_config": { + "consecutive_gateway_errors": 10, + "interval": 10 + } + } } } } diff --git a/admiral/pkg/registry/testutils.go b/admiral/pkg/registry/testutils.go index 9566124e5..b2bbec965 100644 --- a/admiral/pkg/registry/testutils.go +++ b/admiral/pkg/registry/testutils.go @@ -1,10 +1,10 @@ package registry import ( - "github.com/golang/protobuf/ptypes/duration" - "github.com/golang/protobuf/ptypes/wrappers" - networkingV1Alpha3 "istio.io/api/networking/v1alpha3" + "github.com/istio-ecosystem/admiral/admiral/pkg/apis/admiral/model" + "github.com/istio-ecosystem/admiral/admiral/pkg/apis/admiral/v1alpha1" coreV1 "k8s.io/api/core/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/util/intstr" ) @@ -16,26 +16,58 @@ func GetSampleIdentityConfigEnvironment(env string, namespace string) IdentityCo Type: "rollout", Selectors: map[string]string{"app": "partner-data-to-tax"}, Ports: []coreV1.ServicePort{{Name: "http-service-mesh", Port: int32(8090), Protocol: coreV1.ProtocolTCP, TargetPort: intstr.FromInt(8090)}}, - TrafficPolicy: networkingV1Alpha3.TrafficPolicy{ - LoadBalancer: &networkingV1Alpha3.LoadBalancerSettings{ - LbPolicy: &networkingV1Alpha3.LoadBalancerSettings_Simple{Simple: networkingV1Alpha3.LoadBalancerSettings_LEAST_REQUEST}, - LocalityLbSetting: &networkingV1Alpha3.LocalityLoadBalancerSetting{ - Distribute: []*networkingV1Alpha3.LocalityLoadBalancerSetting_Distribute{{ - From: "*", - To: map[string]uint32{"us-west-2": 100}, + TrafficPolicy: TrafficPolicy{ + ClientConnectionConfig: v1alpha1.ClientConnectionConfig{ + ObjectMeta: v1.ObjectMeta{ + Name: "sampleCCC", + }, + Spec: v1alpha1.ClientConnectionConfigSpec{ + ConnectionPool: model.ConnectionPool{Http: &model.ConnectionPool_HTTP{ + Http2MaxRequests: 1000, + MaxRequestsPerConnection: 5, }}, + Tunnel: model.Tunnel{}, }, - WarmupDurationSecs: &duration.Duration{Seconds: 45}, }, - ConnectionPool: &networkingV1Alpha3.ConnectionPoolSettings{ - Http: &networkingV1Alpha3.ConnectionPoolSettings_HTTPSettings{ - Http2MaxRequests: 1000, - MaxRequestsPerConnection: 5, + GlobalTrafficPolicy: v1alpha1.GlobalTrafficPolicy{ + ObjectMeta: v1.ObjectMeta{ + Name: "sampleGTP", + }, + Spec: model.GlobalTrafficPolicy{ + Policy: []*model.TrafficPolicy{ + { + LbType: 0, + Target: []*model.TrafficGroup{ + { + Region: "us-west-2", + Weight: 50, + }, + { + Region: "us-east-2", + Weight: 50, + }, + }, + DnsPrefix: "testDnsPrefix", + OutlierDetection: &model.TrafficPolicy_OutlierDetection{ + ConsecutiveGatewayErrors: 5, + Interval: 5, + }, + }, + }, + Selector: nil, }, }, - OutlierDetection: &networkingV1Alpha3.OutlierDetection{ - ConsecutiveGatewayErrors: &wrappers.UInt32Value{Value: 0}, - Consecutive_5XxErrors: &wrappers.UInt32Value{Value: 0}, + OutlierDetection: v1alpha1.OutlierDetection{ + ObjectMeta: v1.ObjectMeta{ + Name: "sampleOD", + }, + Spec: model.OutlierDetection{ + OutlierConfig: &model.OutlierConfig{ + ConsecutiveGatewayErrors: 10, + Interval: 10, + }, + Selector: nil, + }, }, }, } diff --git a/go.mod b/go.mod index e37690fb6..dda63ca6f 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/mailru/easyjson v0.7.7 // indirect github.com/onsi/gomega v1.30.0 github.com/prometheus/client_golang v1.19.1 - github.com/prometheus/client_model v0.6.1 + github.com/prometheus/client_model v0.6.1 // indirect github.com/sirupsen/logrus v1.8.1 github.com/spf13/cobra v1.5.0 github.com/stretchr/testify v1.9.0 @@ -31,15 +31,9 @@ require ( ) require ( -<<<<<<< HEAD github.com/aws/aws-sdk-go v1.55.2 -======= - github.com/aws/aws-sdk-go v1.44.105 - github.com/golang/glog v1.1.0 github.com/istio-ecosystem/admiral-api v1.1.0 github.com/jamiealquiza/tachymeter v2.0.0+incompatible - github.com/jedib0t/go-pretty/v6 v6.5.3 ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/prometheus/common v0.53.0 go.opentelemetry.io/otel v1.27.0 go.opentelemetry.io/otel/exporters/prometheus v0.49.0 @@ -57,10 +51,6 @@ require ( github.com/rogpeppe/go-internal v1.12.0 // indirect go.opentelemetry.io/otel/sdk v1.27.0 // indirect go.opentelemetry.io/otel/trace v1.27.0 // indirect -<<<<<<< HEAD -======= - golang.org/x/tools v0.16.1 // indirect ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13 // indirect ) @@ -71,15 +61,8 @@ require ( github.com/beorn7/perks v1.0.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect -<<<<<<< HEAD - github.com/emicklei/go-restful/v3 v3.10.1 // indirect - github.com/evanphx/json-patch v4.12.0+incompatible // indirect -======= github.com/emicklei/go-restful/v3 v3.11.2 // indirect github.com/evanphx/json-patch v5.9.0+incompatible // indirect - github.com/fsnotify/fsnotify v1.7.0 // indirect - github.com/go-co-op/gocron v1.13.0 // indirect ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/go-logr/logr v1.4.1 // indirect github.com/go-openapi/jsonpointer v0.20.2 // indirect github.com/go-openapi/jsonreference v0.20.4 // indirect @@ -95,40 +78,16 @@ require ( github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect -<<<<<<< HEAD - github.com/onsi/ginkgo/v2 v2.13.2 // indirect -======= - github.com/onsi/ginkgo/v2 v2.14.0 - github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8 // indirect ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/prometheus/procfs v0.15.0 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/stretchr/objx v0.5.2 // indirect -<<<<<<< HEAD - golang.org/x/oauth2 v0.16.0 // indirect -======= - github.com/tevino/abool v1.2.0 // indirect - github.com/ugorji/go/codec v1.2.7 // indirect - github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7 // indirect - github.intuit.com/idps/idps-go-commons/v3 v3.4.4 // indirect - github.intuit.com/idps/idps-go-swagger-clients v1.8.1 // indirect - go.opencensus.io v0.24.0 // indirect - golang.org/x/crypto v0.19.0 // indirect golang.org/x/oauth2 v0.17.0 // indirect - golang.org/x/sync v0.7.0 // indirect ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.20.0 // indirect golang.org/x/term v0.17.0 // indirect golang.org/x/text v0.14.0 // indirect -<<<<<<< HEAD - google.golang.org/appengine v1.6.7 // indirect -======= - google.golang.org/api v0.126.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/grpc v1.57.0 // indirect ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) gopkg.in/alecthomas/kingpin.v2 v2.2.6 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/go.sum b/go.sum index b4e62b48f..2612a068a 100644 --- a/go.sum +++ b/go.sum @@ -18,142 +18,24 @@ cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmW cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= -cloud.google.com/go v0.110.8/go.mod h1:Iz8AkXJf1qmxC3Oxoep8R1T36w8B92yU29PcBhHO5fk= -cloud.google.com/go/accessapproval v1.7.1/go.mod h1:JYczztsHRMK7NTXb6Xw+dwbs/WnOJxbo/2mTI+Kgg68= -cloud.google.com/go/accesscontextmanager v1.8.1/go.mod h1:JFJHfvuaTC+++1iL1coPiG1eu5D24db2wXCDWDjIrxo= -cloud.google.com/go/aiplatform v1.50.0/go.mod h1:IRc2b8XAMTa9ZmfJV1BCCQbieWWvDnP1A8znyz5N7y4= -cloud.google.com/go/analytics v0.21.3/go.mod h1:U8dcUtmDmjrmUTnnnRnI4m6zKn/yaA5N9RlEkYFHpQo= -cloud.google.com/go/apigateway v1.6.1/go.mod h1:ufAS3wpbRjqfZrzpvLC2oh0MFlpRJm2E/ts25yyqmXA= -cloud.google.com/go/apigeeconnect v1.6.1/go.mod h1:C4awq7x0JpLtrlQCr8AzVIzAaYgngRqWf9S5Uhg+wWs= -cloud.google.com/go/apigeeregistry v0.7.1/go.mod h1:1XgyjZye4Mqtw7T9TsY4NW10U7BojBvG4RMD+vRDrIw= -cloud.google.com/go/appengine v1.8.1/go.mod h1:6NJXGLVhZCN9aQ/AEDvmfzKEfoYBlfB80/BHiKVputY= -cloud.google.com/go/area120 v0.8.1/go.mod h1:BVfZpGpB7KFVNxPiQBuHkX6Ed0rS51xIgmGyjrAfzsg= -cloud.google.com/go/artifactregistry v1.14.1/go.mod h1:nxVdG19jTaSTu7yA7+VbWL346r3rIdkZ142BSQqhn5E= -cloud.google.com/go/asset v1.14.1/go.mod h1:4bEJ3dnHCqWCDbWJ/6Vn7GVI9LerSi7Rfdi03hd+WTQ= -cloud.google.com/go/assuredworkloads v1.11.1/go.mod h1:+F04I52Pgn5nmPG36CWFtxmav6+7Q+c5QyJoL18Lry0= -cloud.google.com/go/automl v1.13.1/go.mod h1:1aowgAHWYZU27MybSCFiukPO7xnyawv7pt3zK4bheQE= -cloud.google.com/go/baremetalsolution v1.2.0/go.mod h1:68wi9AwPYkEWIUT4SvSGS9UJwKzNpshjHsH4lzk8iOw= -cloud.google.com/go/batch v1.4.1/go.mod h1:KdBmDD61K0ovcxoRHGrN6GmOBWeAOyCgKD0Mugx4Fkk= -cloud.google.com/go/beyondcorp v1.0.0/go.mod h1:YhxDWw946SCbmcWo3fAhw3V4XZMSpQ/VYfcKGAEU8/4= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= -cloud.google.com/go/bigquery v1.55.0/go.mod h1:9Y5I3PN9kQWuid6183JFhOGOW3GcirA5LpsKCUn+2ec= -cloud.google.com/go/billing v1.17.0/go.mod h1:Z9+vZXEq+HwH7bhJkyI4OQcR6TSbeMrjlpEjO2vzY64= -cloud.google.com/go/binaryauthorization v1.7.0/go.mod h1:Zn+S6QqTMn6odcMU1zDZCJxPjU2tZPV1oDl45lWY154= -cloud.google.com/go/certificatemanager v1.7.1/go.mod h1:iW8J3nG6SaRYImIa+wXQ0g8IgoofDFRp5UMzaNk1UqI= -cloud.google.com/go/channel v1.17.0/go.mod h1:RpbhJsGi/lXWAUM1eF4IbQGbsfVlg2o8Iiy2/YLfVT0= -cloud.google.com/go/cloudbuild v1.14.0/go.mod h1:lyJg7v97SUIPq4RC2sGsz/9tNczhyv2AjML/ci4ulzU= -cloud.google.com/go/clouddms v1.7.0/go.mod h1:MW1dC6SOtI/tPNCciTsXtsGNEM0i0OccykPvv3hiYeM= -cloud.google.com/go/cloudtasks v1.12.1/go.mod h1:a9udmnou9KO2iulGscKR0qBYjreuX8oHwpmFsKspEvM= -cloud.google.com/go/compute v1.23.0/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= -cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= -cloud.google.com/go/contactcenterinsights v1.10.0/go.mod h1:bsg/R7zGLYMVxFFzfh9ooLTruLRCG9fnzhH9KznHhbM= -cloud.google.com/go/container v1.26.0/go.mod h1:YJCmRet6+6jnYYRS000T6k0D0xUXQgBSaJ7VwI8FBj4= -cloud.google.com/go/containeranalysis v0.11.0/go.mod h1:4n2e99ZwpGxpNcz+YsFT1dfOHPQFGcAC8FN2M2/ne/U= -cloud.google.com/go/datacatalog v1.17.1/go.mod h1:nCSYFHgtxh2MiEktWIz71s/X+7ds/UT9kp0PC7waCzE= -cloud.google.com/go/dataflow v0.9.1/go.mod h1:Wp7s32QjYuQDWqJPFFlnBKhkAtiFpMTdg00qGbnIHVw= -cloud.google.com/go/dataform v0.8.1/go.mod h1:3BhPSiw8xmppbgzeBbmDvmSWlwouuJkXsXsb8UBih9M= -cloud.google.com/go/datafusion v1.7.1/go.mod h1:KpoTBbFmoToDExJUso/fcCiguGDk7MEzOWXUsJo0wsI= -cloud.google.com/go/datalabeling v0.8.1/go.mod h1:XS62LBSVPbYR54GfYQsPXZjTW8UxCK2fkDciSrpRFdY= -cloud.google.com/go/dataplex v1.9.1/go.mod h1:7TyrDT6BCdI8/38Uvp0/ZxBslOslP2X2MPDucliyvSE= -cloud.google.com/go/dataproc/v2 v2.2.0/go.mod h1:lZR7AQtwZPvmINx5J87DSOOpTfof9LVZju6/Qo4lmcY= -cloud.google.com/go/dataqna v0.8.1/go.mod h1:zxZM0Bl6liMePWsHA8RMGAfmTG34vJMapbHAxQ5+WA8= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= -cloud.google.com/go/datastore v1.14.0/go.mod h1:GAeStMBIt9bPS7jMJA85kgkpsMkvseWWXiaHya9Jes8= -cloud.google.com/go/datastream v1.10.0/go.mod h1:hqnmr8kdUBmrnk65k5wNRoHSCYksvpdZIcZIEl8h43Q= -cloud.google.com/go/deploy v1.13.0/go.mod h1:tKuSUV5pXbn67KiubiUNUejqLs4f5cxxiCNCeyl0F2g= -cloud.google.com/go/dialogflow v1.43.0/go.mod h1:pDUJdi4elL0MFmt1REMvFkdsUTYSHq+rTCS8wg0S3+M= -cloud.google.com/go/dlp v1.10.1/go.mod h1:IM8BWz1iJd8njcNcG0+Kyd9OPnqnRNkDV8j42VT5KOI= -cloud.google.com/go/documentai v1.22.1/go.mod h1:LKs22aDHbJv7ufXuPypzRO7rG3ALLJxzdCXDPutw4Qc= -cloud.google.com/go/domains v0.9.1/go.mod h1:aOp1c0MbejQQ2Pjf1iJvnVyT+z6R6s8pX66KaCSDYfE= -cloud.google.com/go/edgecontainer v1.1.1/go.mod h1:O5bYcS//7MELQZs3+7mabRqoWQhXCzenBu0R8bz2rwk= -cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= -cloud.google.com/go/essentialcontacts v1.6.2/go.mod h1:T2tB6tX+TRak7i88Fb2N9Ok3PvY3UNbUsMag9/BARh4= -cloud.google.com/go/eventarc v1.13.0/go.mod h1:mAFCW6lukH5+IZjkvrEss+jmt2kOdYlN8aMx3sRJiAI= -cloud.google.com/go/filestore v1.7.1/go.mod h1:y10jsorq40JJnjR/lQ8AfFbbcGlw3g+Dp8oN7i7FjV4= -cloud.google.com/go/firestore v1.13.0/go.mod h1:QojqqOh8IntInDUSTAh0c8ZsPYAr68Ma8c5DWOy8xb8= -cloud.google.com/go/functions v1.15.1/go.mod h1:P5yNWUTkyU+LvW/S9O6V+V423VZooALQlqoXdoPz5AE= -cloud.google.com/go/gkebackup v1.3.1/go.mod h1:vUDOu++N0U5qs4IhG1pcOnD1Mac79xWy6GoBFlWCWBU= -cloud.google.com/go/gkeconnect v0.8.1/go.mod h1:KWiK1g9sDLZqhxB2xEuPV8V9NYzrqTUmQR9shJHpOZw= -cloud.google.com/go/gkehub v0.14.1/go.mod h1:VEXKIJZ2avzrbd7u+zeMtW00Y8ddk/4V9511C9CQGTY= -cloud.google.com/go/gkemulticloud v1.0.0/go.mod h1:kbZ3HKyTsiwqKX7Yw56+wUGwwNZViRnxWK2DVknXWfw= -cloud.google.com/go/gsuiteaddons v1.6.1/go.mod h1:CodrdOqRZcLp5WOwejHWYBjZvfY0kOphkAKpF/3qdZY= -cloud.google.com/go/iam v1.1.2/go.mod h1:A5avdyVL2tCppe4unb0951eI9jreack+RJ0/d+KUZOU= -cloud.google.com/go/iap v1.9.0/go.mod h1:01OFxd1R+NFrg78S+hoPV5PxEzv22HXaNqUUlmNHFuY= -cloud.google.com/go/ids v1.4.1/go.mod h1:np41ed8YMU8zOgv53MMMoCntLTn2lF+SUzlM+O3u/jw= -cloud.google.com/go/iot v1.7.1/go.mod h1:46Mgw7ev1k9KqK1ao0ayW9h0lI+3hxeanz+L1zmbbbk= -cloud.google.com/go/kms v1.15.2/go.mod h1:3hopT4+7ooWRCjc2DxgnpESFxhIraaI2IpAVUEhbT/w= -cloud.google.com/go/language v1.11.0/go.mod h1:uDx+pFDdAKTY8ehpWbiXyQdz8tDSYLJbQcXsCkjYyvQ= -cloud.google.com/go/lifesciences v0.9.1/go.mod h1:hACAOd1fFbCGLr/+weUKRAJas82Y4vrL3O5326N//Wc= -cloud.google.com/go/logging v1.8.1/go.mod h1:TJjR+SimHwuC8MZ9cjByQulAMgni+RkXeI3wwctHJEI= -cloud.google.com/go/longrunning v0.5.1/go.mod h1:spvimkwdz6SPWKEt/XBij79E9fiTkHSQl/fRUUQJYJc= -cloud.google.com/go/managedidentities v1.6.1/go.mod h1:h/irGhTN2SkZ64F43tfGPMbHnypMbu4RB3yl8YcuEak= -cloud.google.com/go/maps v1.4.0/go.mod h1:6mWTUv+WhnOwAgjVsSW2QPPECmW+s3PcRyOa9vgG/5s= -cloud.google.com/go/mediatranslation v0.8.1/go.mod h1:L/7hBdEYbYHQJhX2sldtTO5SZZ1C1vkapubj0T2aGig= -cloud.google.com/go/memcache v1.10.1/go.mod h1:47YRQIarv4I3QS5+hoETgKO40InqzLP6kpNLvyXuyaA= -cloud.google.com/go/metastore v1.12.0/go.mod h1:uZuSo80U3Wd4zi6C22ZZliOUJ3XeM/MlYi/z5OAOWRA= -cloud.google.com/go/monitoring v1.16.0/go.mod h1:Ptp15HgAyM1fNICAojDMoNc/wUmn67mLHQfyqbw+poY= -cloud.google.com/go/networkconnectivity v1.13.0/go.mod h1:SAnGPes88pl7QRLUen2HmcBSE9AowVAcdug8c0RSBFk= -cloud.google.com/go/networkmanagement v1.9.0/go.mod h1:UTUaEU9YwbCAhhz3jEOHr+2/K/MrBk2XxOLS89LQzFw= -cloud.google.com/go/networksecurity v0.9.1/go.mod h1:MCMdxOKQ30wsBI1eI659f9kEp4wuuAueoC9AJKSPWZQ= -cloud.google.com/go/notebooks v1.10.0/go.mod h1:SOPYMZnttHxqot0SGSFSkRrwE29eqnKPBJFqgWmiK2k= -cloud.google.com/go/optimization v1.5.0/go.mod h1:evo1OvTxeBRBu6ydPlrIRizKY/LJKo/drDMMRKqGEUU= -cloud.google.com/go/orchestration v1.8.1/go.mod h1:4sluRF3wgbYVRqz7zJ1/EUNc90TTprliq9477fGobD8= -cloud.google.com/go/orgpolicy v1.11.1/go.mod h1:8+E3jQcpZJQliP+zaFfayC2Pg5bmhuLK755wKhIIUCE= -cloud.google.com/go/osconfig v1.12.1/go.mod h1:4CjBxND0gswz2gfYRCUoUzCm9zCABp91EeTtWXyz0tE= -cloud.google.com/go/oslogin v1.10.1/go.mod h1:x692z7yAue5nE7CsSnoG0aaMbNoRJRXO4sn73R+ZqAs= -cloud.google.com/go/phishingprotection v0.8.1/go.mod h1:AxonW7GovcA8qdEk13NfHq9hNx5KPtfxXNeUxTDxB6I= -cloud.google.com/go/policytroubleshooter v1.9.0/go.mod h1:+E2Lga7TycpeSTj2FsH4oXxTnrbHJGRlKhVZBLGgU64= -cloud.google.com/go/privatecatalog v0.9.1/go.mod h1:0XlDXW2unJXdf9zFz968Hp35gl/bhF4twwpXZAW50JA= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= -cloud.google.com/go/pubsub v1.33.0/go.mod h1:f+w71I33OMyxf9VpMVcZbnG5KSUkCOUHYpFd5U1GdRc= -cloud.google.com/go/pubsublite v1.8.1/go.mod h1:fOLdU4f5xldK4RGJrBMm+J7zMWNj/k4PxwEZXy39QS0= -cloud.google.com/go/recaptchaenterprise/v2 v2.7.2/go.mod h1:kR0KjsJS7Jt1YSyWFkseQ756D45kaYNTlDPPaRAvDBU= -cloud.google.com/go/recommendationengine v0.8.1/go.mod h1:MrZihWwtFYWDzE6Hz5nKcNz3gLizXVIDI/o3G1DLcrE= -cloud.google.com/go/recommender v1.11.0/go.mod h1:kPiRQhPyTJ9kyXPCG6u/dlPLbYfFlkwHNRwdzPVAoII= -cloud.google.com/go/redis v1.13.1/go.mod h1:VP7DGLpE91M6bcsDdMuyCm2hIpB6Vp2hI090Mfd1tcg= -cloud.google.com/go/resourcemanager v1.9.1/go.mod h1:dVCuosgrh1tINZ/RwBufr8lULmWGOkPS8gL5gqyjdT8= -cloud.google.com/go/resourcesettings v1.6.1/go.mod h1:M7mk9PIZrC5Fgsu1kZJci6mpgN8o0IUzVx3eJU3y4Jw= -cloud.google.com/go/retail v1.14.1/go.mod h1:y3Wv3Vr2k54dLNIrCzenyKG8g8dhvhncT2NcNjb/6gE= -cloud.google.com/go/run v1.2.0/go.mod h1:36V1IlDzQ0XxbQjUx6IYbw8H3TJnWvhii963WW3B/bo= -cloud.google.com/go/scheduler v1.10.1/go.mod h1:R63Ldltd47Bs4gnhQkmNDse5w8gBRrhObZ54PxgR2Oo= -cloud.google.com/go/secretmanager v1.11.1/go.mod h1:znq9JlXgTNdBeQk9TBW/FnR/W4uChEKGeqQWAJ8SXFw= -cloud.google.com/go/security v1.15.1/go.mod h1:MvTnnbsWnehoizHi09zoiZob0iCHVcL4AUBj76h9fXA= -cloud.google.com/go/securitycenter v1.23.0/go.mod h1:8pwQ4n+Y9WCWM278R8W3nF65QtY172h4S8aXyI9/hsQ= -cloud.google.com/go/servicedirectory v1.11.0/go.mod h1:Xv0YVH8s4pVOwfM/1eMTl0XJ6bzIOSLDt8f8eLaGOxQ= -cloud.google.com/go/shell v1.7.1/go.mod h1:u1RaM+huXFaTojTbW4g9P5emOrrmLE69KrxqQahKn4g= -cloud.google.com/go/spanner v1.49.0/go.mod h1:eGj9mQGK8+hkgSVbHNQ06pQ4oS+cyc4tXXd6Dif1KoM= -cloud.google.com/go/speech v1.19.0/go.mod h1:8rVNzU43tQvxDaGvqOhpDqgkJTFowBpDvCJ14kGlJYo= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= -cloud.google.com/go/storagetransfer v1.10.0/go.mod h1:DM4sTlSmGiNczmV6iZyceIh2dbs+7z2Ayg6YAiQlYfA= -cloud.google.com/go/talent v1.6.2/go.mod h1:CbGvmKCG61mkdjcqTcLOkb2ZN1SrQI8MDyma2l7VD24= -cloud.google.com/go/texttospeech v1.7.1/go.mod h1:m7QfG5IXxeneGqTapXNxv2ItxP/FS0hCZBwXYqucgSk= -cloud.google.com/go/tpu v1.6.1/go.mod h1:sOdcHVIgDEEOKuqUoi6Fq53MKHJAtOwtz0GuKsWSH3E= -cloud.google.com/go/trace v1.10.1/go.mod h1:gbtL94KE5AJLH3y+WVpfWILmqgc6dXcqgNXdOPAQTYk= -cloud.google.com/go/translate v1.9.0/go.mod h1:d1ZH5aaOA0CNhWeXeC8ujd4tdCFw8XoNWRljklu5RHs= -cloud.google.com/go/video v1.20.0/go.mod h1:U3G3FTnsvAGqglq9LxgqzOiBc/Nt8zis8S+850N2DUM= -cloud.google.com/go/videointelligence v1.11.1/go.mod h1:76xn/8InyQHarjTWsBR058SmlPCwQjgcvoW0aZykOvo= -cloud.google.com/go/vision/v2 v2.7.2/go.mod h1:jKa8oSYBWhYiXarHPvP4USxYANYUEdEsQrloLjrSwJU= -cloud.google.com/go/vmmigration v1.7.1/go.mod h1:WD+5z7a/IpZ5bKK//YmT9E047AD+rjycCAvyMxGJbro= -cloud.google.com/go/vmwareengine v1.0.0/go.mod h1:Px64x+BvjPZwWuc4HdmVhoygcXqEkGHXoa7uyfTgSI0= -cloud.google.com/go/vpcaccess v1.7.1/go.mod h1:FogoD46/ZU+JUBX9D606X21EnxiszYi2tArQwLY4SXs= -cloud.google.com/go/webrisk v1.9.1/go.mod h1:4GCmXKcOa2BZcZPn6DCEvE7HypmEJcJkr4mtM+sqYPc= -cloud.google.com/go/websecurityscanner v1.6.1/go.mod h1:Njgaw3rttgRHXzwCB8kgCYqv5/rGpFCsBOvPbYgszpg= -cloud.google.com/go/workflows v1.12.0/go.mod h1:PYhSk2b6DhZ508tj8HXKaBh+OFe+xdl0dHF/tJdzPQM= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= github.com/Azure/go-autorest/autorest v0.11.18/go.mod h1:dSiJPy22c3u0OtOKDNttNgqpNFY/GeWa7GH/Pz56QRA= github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M= @@ -163,46 +45,23 @@ github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZ github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/MakeNowJust/heredoc v0.0.0-20170808103936-bb23615498cd/go.mod h1:64YHyfSL2R96J44Nlwm39UHepQbyR5q10x7iYa1ks2E= -github.com/Masterminds/goutils v1.1.0/go.mod h1:8cTjp+g8YejhMuvIA5y2vz3BpJxksy863GQaJW2MFNU= -github.com/Masterminds/semver v1.5.0/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y= -github.com/Masterminds/sprig v2.22.0+incompatible/go.mod h1:y6hNFY5UBTIWBxnzTeuNhlNS5hqE0NB0E6fgfo2Br3o= github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46/go.mod h1:3wb06e3pkSAbeQ52E9H9iFoQsEEwGN64994WTCIhntQ= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/RocketChat/Rocket.Chat.Go.SDK v0.0.0-20210112200207-10ab4d695d60/go.mod h1:rjP7sIipbZcagro/6TCk6X0ZeFT2eyudH5+fve/cbBA= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d h1:UQZhZ2O0vMHr2cI+DC1Mbh0TJxzA3RcLoMsFw+aXw7E= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= -github.com/antonmedv/expr v1.9.0/go.mod h1:5qsM3oLGDND7sDmQGDXHkYfkjYMUX14qsgqmHhwGEk8= github.com/argoproj/argo-rollouts v1.2.1 h1:4hSgKEqpQsZreZBv+XcLsB+oBaRGMVW19nMScx5ikIQ= github.com/argoproj/argo-rollouts v1.2.1/go.mod h1:ETmWr9Lysxr9SgbqalMMBdytBcDHUt9qulFoKJ9b9ZU= -github.com/argoproj/notifications-engine v0.3.1-0.20220129012210-32519f8f68ec/go.mod h1:QF4tr3wfWOnhkKSaRpx7k/KEErQAh8iwKQ2pYFu/SfA= -github.com/argoproj/pkg v0.9.0/go.mod h1:ra+bQPmbVAoEL+gYSKesuigt4m49i3Qa3mE/xQcjCiA= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/aws/aws-sdk-go v1.55.2 h1:/2OFM8uFfK9e+cqHTw9YPrvTzIXT2XkFGXRM7WbJb7E= github.com/aws/aws-sdk-go v1.55.2/go.mod h1:eRwEWoyTWFMVYVQzKMNHWP5/RV4xIUGMQfXQHfHkpNU= -github.com/aws/aws-sdk-go-v2 v1.13.0/go.mod h1:L6+ZpqHaLbAaxsqV0L4cvxZY7QupWJB4fhkf8LXvC7w= -github.com/aws/aws-sdk-go-v2/config v1.13.1/go.mod h1:Ba5Z4yL/UGbjQUzsiaN378YobhFo0MLfueXGiOsYtEs= -github.com/aws/aws-sdk-go-v2/credentials v1.8.0/go.mod h1:gnMo58Vwx3Mu7hj1wpcG8DI0s57c9o42UQ6wgTQT5to= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.10.0/go.mod h1:I6/fHT/fH460v09eg2gVrd8B/IqskhNdpcLH0WNO3QI= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.4/go.mod h1:XHgQ7Hz2WY2GAn//UXHofLfPXWh+s62MbMOijrg12Lw= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.2.0/go.mod h1:BsCSJHx5DnDXIrOcqB8KN1/B+hXLG/bi4Y6Vjcx/x9E= -github.com/aws/aws-sdk-go-v2/internal/ini v1.3.5/go.mod h1:R3sWUqPcfXSiF/LSFJhjyJmpg9uV6yP2yv3YZZjldVI= -github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.15.0/go.mod h1:bPS4S6vXEGUVMabXYHOJRFvoWrztb38v4i84i8Hd6ZY= -github.com/aws/aws-sdk-go-v2/service/elasticloadbalancingv2 v1.16.0/go.mod h1:5rsn/Fxs9Rnq28KLB8n1pJcRR3UtrHY787uapxrvDRA= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.7.0/go.mod h1:K/qPe6AP2TGYv4l6n7c88zh9jWBDf6nHhvg1fx/EWfU= -github.com/aws/aws-sdk-go-v2/service/sso v1.9.0/go.mod h1:vCV4glupK3tR7pw7ks7Y4jYRL86VvxS+g5qk04YeWrU= -github.com/aws/aws-sdk-go-v2/service/sts v1.14.0/go.mod h1:u0xMJKDvvfocRjiozsoZglVNXRG19043xzp3r2ivLIk= -github.com/aws/smithy-go v1.10.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk= -github.com/bradleyfalzon/ghinstallation/v2 v2.0.4/go.mod h1:B40qPqJxWE0jDZgOR1JmaMy+4AY1eBP+IByOvqyAKp0= github.com/buger/jsonparser v1.1.1/go.mod h1:6RYKKt7H4d4+iWqouImQ9R2FZql3VbhNgx27UK13J/0= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -211,7 +70,6 @@ github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghf github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/chai2010/gettext-go v0.0.0-20160711120539-c6fed771bfd5/go.mod h1:/iP1qXHoty45bqomnu2LM+VVyAEdWN+vtSHGlQgyxbw= github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927 h1:SKI1/fuSdodxmNNyVBR8d7X/HuLnRpvvFO0AgyQk764= github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927/go.mod h1:h/aW8ynjgkuj+NQRlZcDbAbM1ORAbXjXX77sX7T289U= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= @@ -224,11 +82,9 @@ github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnht github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= github.com/emicklei/go-restful v2.9.5+incompatible/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= github.com/emicklei/go-restful/v3 v3.8.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= @@ -242,21 +98,13 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/evanphx/json-patch v4.12.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= -<<<<<<< HEAD -github.com/evanphx/json-patch/v5 v5.6.0/go.mod h1:G79N1coSVB93tBe7j6PhzjmR3/2VvlbKOFpnXhI9Bw4= -github.com/exponent-io/jsonpath v0.0.0-20151013193312-d6023ce2651d/go.mod h1:ZZMPRZwes7CROmyNKgQzC3XPs6L/G2EJLHddWejkmf4= -github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= -======= github.com/evanphx/json-patch v5.9.0+incompatible h1:fBXyNpNMuTTDdquAq/uisOr2lShz4oaXpDTX2bLe7ls= github.com/evanphx/json-patch v5.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/flowstack/go-jsonschema v0.1.1/go.mod h1:yL7fNggx1o8rm9RlgXv7hTBWxdBM0rVwpMwimd3F3N0= github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k= github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32/go.mod h1:GIjDIg/heH5DOkXY3YJ/wNhfHsQHoXGjl8G8amsYQ1I= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -287,12 +135,9 @@ github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/me github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= -github.com/go-telegram-bot-api/telegram-bot-api/v5 v5.4.0/go.mod h1:A2S0CWkNylc2phvKXWBBdD3K0iGnDBGbzRpISP2zBl8= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/golang-jwt/jwt/v4 v4.0.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -305,7 +150,6 @@ github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -342,16 +186,9 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -<<<<<<< HEAD -======= -github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-github/v41 v41.0.0/go.mod h1:XgmCA5H323A9rtgExdTcnDkcqp6S30AVACCBDOonIxg= -github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -370,43 +207,23 @@ github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -<<<<<<< HEAD -======= github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= -github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/google/pprof v0.0.0-20211214055906-6f57359322fd h1:1FjCyPC+syAzJ5/2S8fqdZK1R22vvA0J7JZKcuOIQ7Y= github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -<<<<<<< HEAD -github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= -github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -======= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/googleapis/enterprise-certificate-proxy v0.2.3 h1:yk9/cqRKtT9wXZSsRH9aurXEpJX+U6FLtpYTdC3R06k= -github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= -github.com/googleapis/gnostic v0.5.5/go.mod h1:7+EbHbldMins07ALC74bsA81Ovc97DwqyJO1AENw9kA= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gregdel/pushover v1.1.0/go.mod h1:EcaO66Nn1StkpEm1iKtBTV3d2A16SoMsVER1PthX7to= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= -github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= -github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= -github.com/hashicorp/go-retryablehttp v0.7.0/go.mod h1:vAew36LZh98gCBJNLH42IQ1ER/9wtLZZ8meHqQvEYWY= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/huandu/xstrings v1.3.2/go.mod h1:y5/lhBue+AyNmUVz9RLU9xbLR0o4KIIExikq4ovT0aE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20210905161508-09a460cdf81d/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= @@ -415,27 +232,10 @@ github.com/imdario/mergo v0.3.12 h1:b6R2BslTbIEToALKP7LxUvijTsNI9TAe80pLWN2g/HU= github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -<<<<<<< HEAD -======= -github.com/intuit/funnel v1.0.0 h1:DL7tQjXpRXmTb6C/xU2Hn9hcHh7/VnHC0+vep4e3P7E= -github.com/intuit/funnel v1.0.0/go.mod h1:mDE1DfyEnFN29i8pcDDjNvVRKiZU+/N3YCuEl3CGQEU= github.com/istio-ecosystem/admiral-api v1.1.0 h1:SLRgKRdZP31G0Q2uaYcVb3JxkjAbTxbSsze2N5ncapE= github.com/istio-ecosystem/admiral-api v1.1.0/go.mod h1:xB+G1v2H/cOxuR6koi/3kLHgF+oc3y905Lt12NCyMCI= -github.com/jacobsa/crypto v0.0.0-20190317225127-9f44e2d11115 h1:YuDUUFNM21CAbyPOpOP8BicaTD/0klJEKt5p8yuw+uY= -github.com/jacobsa/crypto v0.0.0-20190317225127-9f44e2d11115/go.mod h1:LadVJg0XuawGk+8L1rYnIED8451UyNxEMdTWCEt5kmU= -github.com/jacobsa/oglematchers v0.0.0-20150720000706-141901ea67cd h1:9GCSedGjMcLZCrusBZuo4tyKLpKUPenUUqi34AkuFmA= -github.com/jacobsa/oglematchers v0.0.0-20150720000706-141901ea67cd/go.mod h1:TlmyIZDpGmwRoTWiakdr+HA1Tukze6C6XbRVidYq02M= -github.com/jacobsa/oglemock v0.0.0-20150831005832-e94d794d06ff h1:2xRHTvkpJ5zJmglXLRqHiZQNjUoOkhUyhTAhEQvPAWw= -github.com/jacobsa/oglemock v0.0.0-20150831005832-e94d794d06ff/go.mod h1:gJWba/XXGl0UoOmBQKRWCJdHrr3nE0T65t6ioaj3mLI= -github.com/jacobsa/ogletest v0.0.0-20170503003838-80d50a735a11 h1:BMb8s3ENQLt5ulwVIHVDWFHp8eIXmbfSExkvdn9qMXI= -github.com/jacobsa/ogletest v0.0.0-20170503003838-80d50a735a11/go.mod h1:+DBdDyfoO2McrOyDemRBq0q9CMEByef7sYl7JH5Q3BI= -github.com/jacobsa/reqtrace v0.0.0-20150505043853-245c9e0234cb h1:uSWBjJdMf47kQlXMwWEfmc864bA1wAC+Kl3ApryuG9Y= -github.com/jacobsa/reqtrace v0.0.0-20150505043853-245c9e0234cb/go.mod h1:ivcmUvxXWjb27NsPEaiYK7AidlZXS7oQ5PowUS9z3I4= github.com/jamiealquiza/tachymeter v2.0.0+incompatible h1:mGiF1DGo8l6vnGT8FXNNcIXht/YmjzfraiUprXYwJ6g= github.com/jamiealquiza/tachymeter v2.0.0+incompatible/go.mod h1:Ayf6zPZKEnLsc3winWEXJRkTBhdHo58HODAu1oFJkYU= -github.com/jedib0t/go-pretty/v6 v6.5.3 h1:GIXn6Er/anHTkVUoufs7ptEvxdD6KIhR7Axa2wYCPF0= -github.com/jedib0t/go-pretty/v6 v6.5.3/go.mod h1:5LQIxa52oJ/DlDSLv0HEkWOFMDGoWkJb9ss5KqPpJBg= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= @@ -449,7 +249,6 @@ github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnr github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/juju/ansiterm v0.0.0-20180109212912-720a0952cc2a/go.mod h1:UJSiEoRfvx3hP73CvoARgeLjaIOjybY9vj8PUPPFGeU= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= @@ -463,8 +262,6 @@ github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de/go.mod h1:zAbeS9B/r2mtpb6U+EI2rYA5OAXxsYw6wTamcNW+zcE= -github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= @@ -472,21 +269,10 @@ github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0 github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/matryer/resync v0.0.0-20161211202428-d39c09a11215 h1:hDa3vAq/Zo5gjfJ46XMsGFbH+hTizpR4fUzQCk2nxgk= github.com/matryer/resync v0.0.0-20161211202428-d39c09a11215/go.mod h1:LH+NgPY9AJpDfqAFtzyer01N9MYNsAKUf3DC9DV1xIY= -github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= -github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -<<<<<<< HEAD -github.com/mitchellh/copystructure v1.0.0/go.mod h1:SNtv71yrdKgLRyLFxmLdkAbkKEFWgYaq1OVrnRcwhnw= -github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= -github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/reflectwalk v1.0.1/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= -======= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/moby/term v0.0.0-20210610120745-9d4ed1856297/go.mod h1:vgPCkQMyxTZ7IDy8SXRufE172gr8+K/JE/7hHFxHW3A= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -494,19 +280,18 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= github.com/munnerz/goautoneg v0.0.0-20120707110453-a547fc61f48d/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= -github.com/newrelic/newrelic-client-go v0.72.0/go.mod h1:VXjhsfui0rvhM9cVwnKwlidF8NbXlHZvh63ZKi6fImA= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= +github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= github.com/onsi/ginkgo/v2 v2.1.4/go.mod h1:um6tUpWM/cxCK3/FK8BXqEiUMUwRgSM4JXG47RKZmLU= @@ -518,9 +303,6 @@ github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAl github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= -github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0= -github.com/opsgenie/opsgenie-go-sdk-v2 v1.0.5/go.mod h1:f0ezb0R/mrB9Hpm5RrIS6EX3ydjsR2nAB88nYYXZcNY= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -542,15 +324,10 @@ github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6L github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/servicemeshinterface/smi-sdk-go v0.4.1/go.mod h1:9rsLPBNcqfDNmEgyYwpopn93aE9yz46d2EHFBNOYj/w= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.8.1 h1:dJKuHgqk1NNQlqoA6BTlM1Wf9DOH3NBjQyu0h9+AZZE= github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/slack-go/slack v0.10.1/go.mod h1:wWL//kk0ho+FcQXcBTmEafUI5dz4qz5f4mMk8oIkioQ= -github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0= -github.com/spaceapegames/go-wavefront v1.8.1/go.mod h1:GtdIjtJ0URkfPmaKx0+7vMSDvT/MON9v+4pbdagA8As= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/cobra v1.5.0 h1:X+jTBEBqF0bHN+9cSMgmfuvv2VHJ9ezmFNf9Y/XstYU= @@ -574,33 +351,15 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/tj/assert v0.0.3/go.mod h1:Ne6X72Q+TB1AteidzQncjw9PabbMp4PBMZ1k+vd1Pvk= -github.com/tomnomnom/linkheader v0.0.0-20180905144013-02ca5825eb80/go.mod h1:iFyPdL66DjUD96XmzVL3ZntbzcflLnznH0fr99w5VqE= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/whilp/git-urls v0.0.0-20191001220047-6db9661140c0/go.mod h1:2rx5KE5FLD0HRfkkpyn8JwbVLBdhgeiOb2D2D9LLKM4= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= -github.com/xlab/treeprint v0.0.0-20181112141820-a009c3971eca/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -<<<<<<< HEAD -======= github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7 h1:nSypwHIJ7o0IzWYVfVzmogrF5HIz/HCiSeMo0Mo3ymU= -github.intuit.com/idps/device-grant-flow/go/dgfsdk v0.0.0-20220428022612-cf054cda65f7/go.mod h1:maAd/rJYgSC2c9PvkGZZD/NrkVyhZL9/jDU75iTzgKE= -github.intuit.com/idps/idps-go-commons/v3 v3.4.4 h1:DxyPs+Q6wi7doX/2Ers2KnTv5B+vRclKCNVeCgkt01Y= -github.intuit.com/idps/idps-go-commons/v3 v3.4.4/go.mod h1:NMUz/MLrhUE4/SdxPGGc5KMk3kC9B8UdUAuelSYgA/0= -github.intuit.com/idps/idps-go-sdk/v3 v3.9909.0 h1:NtujYowO6tlJTmSHS1OoVAJ1ftTMCYWnuQSvVML1agI= -github.intuit.com/idps/idps-go-sdk/v3 v3.9909.0/go.mod h1:IIy+JIbUnqhjVqB+g6XXK1/Wd1J1Mnd26W1DPELs4Fo= -github.intuit.com/idps/idps-go-swagger-clients v1.8.1 h1:f7unZbxkR4WQRxHOL5B97HfoAwnkHjfUW1xLvK6GcHg= -github.intuit.com/idps/idps-go-swagger-clients v1.8.1/go.mod h1:L0XVKcoVv71IoVZBIgmQfJ0ux0E0cguZsxTyos9v6kg= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= @@ -621,22 +380,14 @@ go.opentelemetry.io/otel/sdk/metric v1.27.0/go.mod h1:we7jJVrYN2kh3mVBlswtPU22K0 go.opentelemetry.io/otel/trace v1.27.0 h1:IqYb813p7cmbHk0a5y6pD5JPakbVfftRXABGt5/Rscw= go.opentelemetry.io/otel/trace v1.27.0/go.mod h1:6RiD1hkAprV4/q+yd2ln1HG9GoPx39SuvvstaLBl+l4= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= -go.starlark.net v0.0.0-20200306205701-8dd3e2ee1dd5/go.mod h1:nmDLcffg48OtT/PSW0Hg7FvpRQsQh5OSqIylirxKC7o= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -<<<<<<< HEAD -golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= -======= -golang.org/x/crypto v0.0.0-20220314234659-1baeb1ce4c0b/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.0.0-20220427172511-eb4f295cb31f/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.19.0 h1:ENy+Az/9Y1vSrlrvBSyna3PITt4tiZLf7sgCjZBX7Wo= -golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -670,14 +421,9 @@ golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -<<<<<<< HEAD -golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -======= golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -713,29 +459,17 @@ golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= -<<<<<<< HEAD -======= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= -golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -<<<<<<< HEAD -golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo= -golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= -======= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.3.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= golang.org/x/net v0.4.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= golang.org/x/net v0.21.0 h1:AQyQV4dYCvJ7vGmJyKki9+PBdyvhkSd8EIx/qb0AYv4= golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -748,16 +482,8 @@ golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -<<<<<<< HEAD -golang.org/x/oauth2 v0.16.0 h1:aDkGMBSYxElaoP81NpoUoz2oo2R2wHdZpGToUxfyQrQ= -golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= -======= -golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= -golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= -golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.17.0 h1:6m3ZPmLEFdVxKKWnKq4VqZ60gutO35zm+zrAHVmHyDQ= golang.org/x/oauth2 v0.17.0/go.mod h1:OzPDGQiuQMguemayvdylqddI7qcD9lnSDb+1FiwQ5HA= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -769,13 +495,8 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -<<<<<<< HEAD -======= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) -golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -827,25 +548,13 @@ golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -<<<<<<< HEAD -======= golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -<<<<<<< HEAD -======= -golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/sys v0.20.0 h1:Od9JTbYCk261bKm4M/mw7AklTlFYIa0bIp9BgSm1S8Y= golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -861,11 +570,8 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -<<<<<<< HEAD -======= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -924,29 +630,16 @@ golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= -golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -<<<<<<< HEAD -golang.org/x/tools v0.14.0 h1:jvNa2pY0M4r62jkRQ6RwEZZyPcymeL9XZMLBbV7U2nc= -golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= -======= golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.4.0/go.mod h1:UE5sM2OK9E/d67R0ANs2xJizIymRP5gJU295PvKXxjQ= golang.org/x/tools v0.16.1 h1:TLyB3WofjdOEepBHAU20JdNC1Zbg87elYofWYAY5oZA= golang.org/x/tools v0.16.1/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -<<<<<<< HEAD golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= -gomodules.xyz/envconfig v1.3.1-0.20190308184047-426f31af0d45/go.mod h1:41y72mzHT7+jFNgyBpJRrZWuZJcLmLrTpq6iGgOFJMQ= -gomodules.xyz/notify v0.1.0/go.mod h1:wGy0vLXGpabCg0j9WbjzXf7pM7Khz11FqCLtBbTujP0= -======= -golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -1023,7 +716,6 @@ google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 h1:SeZZZx0cP0fqUyA google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97/go.mod h1:t1VqOqqvce95G3hIDCT5FeO3YUc6Q4Oe24L/+rNMxRk= google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13 h1:U7+wNaVuSTaUqNvK2+osJ9ejEZxbjHHk8F2b6Hpx0AE= google.golang.org/genproto/googleapis/api v0.0.0-20230920204549-e6e6cdab5c13/go.mod h1:RdyHbowztCGQySiCvQPgWQWgWhGnouTdCflKoDBt32U= -google.golang.org/genproto/googleapis/rpc v0.0.0-20230920204549-e6e6cdab5c13/go.mod h1:KSqppvjFjtoCI+KGd4PELB0qLNxdJHRGqRI09mB6pQA= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -1044,7 +736,6 @@ google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAG google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= -google.golang.org/grpc v1.57.0/go.mod h1:Sd+9RMTACXwmub0zcNY2c4arhtrbBYD1AUHI/dt16Mo= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -1062,7 +753,6 @@ google.golang.org/protobuf v1.34.1 h1:9ddQBjfCyZPOHPUiPxpYESBLc+T8P3E+Vo4IbKZgFW google.golang.org/protobuf v1.34.1/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= -gopkg.in/alexcesaro/quotedprintable.v3 v3.0.0-20150716171945-2caba252f4dc/go.mod h1:m7x9LTH6d71AHyAX77c9yqWCCa3UKHcVEj9y7hAtKDk= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1071,7 +761,6 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/gomail.v2 v2.0.0-20160411212932-81ebce5c23df/go.mod h1:LRQQ+SO6ZHR7tOkpBDuZnXENFzX8qRjMDMyPD6BRkCw= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= @@ -1101,35 +790,18 @@ istio.io/client-go v1.14.0 h1:KKXMnxXx3U2866OP8FBYlJhjKdI3yIUQnt8L6hSzDHE= istio.io/client-go v1.14.0/go.mod h1:C7K0CKQlvY84yQKkZhxQbD1riqvnsgXJm3jF5GOmzNg= k8s.io/api v0.24.2 h1:g518dPU/L7VRLxWfcadQn2OnsiGWVOadTLpdnqgY2OI= k8s.io/api v0.24.2/go.mod h1:AHqbSkTm6YrQ0ObxjO3Pmp/ubFF/KuM7jU+3khoBsOg= -k8s.io/apiextensions-apiserver v0.24.2/go.mod h1:e5t2GMFVngUEHUd0wuCJzw8YDwZoqZfJiGOW6mm2hLQ= k8s.io/apimachinery v0.24.2 h1:5QlH9SL2C8KMcrNJPor+LbXVTaZRReml7svPEh4OKDM= k8s.io/apimachinery v0.24.2/go.mod h1:82Bi4sCzVBdpYjyI4jY6aHX+YCUchUIrZrXKedjd2UM= -k8s.io/apiserver v0.24.2/go.mod h1:pSuKzr3zV+L+MWqsEo0kHHYwCo77AT5qXbFXP2jbvFI= -k8s.io/cli-runtime v0.24.2/go.mod h1:1LIhKL2RblkhfG4v5lZEt7FtgFG5mVb8wqv5lE9m5qY= k8s.io/client-go v0.24.2 h1:CoXFSf8if+bLEbinDqN9ePIDGzcLtqhfd6jpfnwGOFA= k8s.io/client-go v0.24.2/go.mod h1:zg4Xaoo+umDsfCWr4fCnmLEtQXyCNXCvJuSsglNcV30= -k8s.io/cluster-bootstrap v0.24.2/go.mod h1:eIHV338K03vBm3u/ROZiNXxWJ4AJRoTR9PEUhcTvYkg= -k8s.io/code-generator v0.24.2/go.mod h1:dpVhs00hTuTdTY6jvVxvTFCk6gSMrtfRydbhZwHI15w= -k8s.io/component-base v0.24.2/go.mod h1:ucHwW76dajvQ9B7+zecZAP3BVqvrHoOxm8olHEg0nmM= -k8s.io/component-helpers v0.24.2/go.mod h1:TRQPBQKfmqkmV6c0HAmUs8cXVNYYYLsXy4zu8eODi9g= k8s.io/gengo v0.0.0-20210813121822-485abfe95c7c/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E= k8s.io/klog/v2 v2.0.0/go.mod h1:PBfzABfn139FHAV07az/IF9Wp1bkk3vpT2XSJ76fSDE= k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y= k8s.io/klog/v2 v2.60.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -<<<<<<< HEAD -k8s.io/klog/v2 v2.100.1 h1:7WCHKK6K8fNhTqfBhISHQ97KrnJNFZMcQvKp7gP/tmg= -k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/kube-openapi v0.0.0-20220328201542-3ee0da9b0b42/go.mod h1:Z/45zLw8lUo4wdiUkI+v/ImEGAvu3WatcZl3lPMR4Rk= -k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5 h1:/zkKSeCtGRHYqRmrpa9uPYDWMpmQ5bZijBSoOpW384c= -k8s.io/kube-openapi v0.0.0-20230210211930-4b0756abdef5/go.mod h1:/BYxry62FuDzmI+i9B+X2pqfySRmSOW2ARmj5Zbqhj0= -k8s.io/kubectl v0.24.2/go.mod h1:+HIFJc0bA6Tzu5O/YcuUt45APAxnNL8LeMuXwoiGsPg= -k8s.io/kubernetes v1.23.1/go.mod h1:baMGbPpwwP0kT/+eAPtdqoWNRoXyyTJ2Zf+fw/Y8t04= -======= k8s.io/klog/v2 v2.120.1 h1:QXU6cPEOIslTGvZaXvFWiP9VKyeet3sawzTOvdXb4Vw= k8s.io/klog/v2 v2.120.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= k8s.io/kube-openapi v0.0.0-20230525220651-2546d827e515 h1:OmK1d0WrkD3IPfkskvroRykOulHVHf0s0ZIFRjyt+UI= k8s.io/kube-openapi v0.0.0-20230525220651-2546d827e515/go.mod h1:kzo02I3kQ4BTtEfVLaPbjvCkX97YqGve33wzlb3fofQ= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) k8s.io/utils v0.0.0-20210802155522-efc7438f0176/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9/go.mod h1:jPW/WVKK9YHAvNhRxK0md/EJ228hCsBRufyofKtW8HA= k8s.io/utils v0.0.0-20240102154912-e7106e64919e h1:eQ/4ljkx21sObifjzXwlPKpdGLrCfRziVtos3ofG/sQ= @@ -1140,12 +812,6 @@ rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2/go.mod h1:B+TnT182UBxE84DiCz4CVE26eOSDAeYCpfDnC2kdKMY= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= -<<<<<<< HEAD -sigs.k8s.io/kustomize/api v0.10.1/go.mod h1:2FigT1QN6xKdcnGS2Ppp1uIWrtWN28Ms8A3OZUZhwr8= -sigs.k8s.io/kustomize/kyaml v0.13.0/go.mod h1:FTJxEZ86ScK184NpGSAQcfEqee0nul8oLCK30D47m4E= -sigs.k8s.io/structured-merge-diff/v4 v4.0.2/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK1F7G282QMXDPYydCw= -======= ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) sigs.k8s.io/structured-merge-diff/v4 v4.2.1/go.mod h1:j/nl6xW8vLS49O8YvXW1ocPhZawJtm+Yrr7PPRQ0Vg4= sigs.k8s.io/structured-merge-diff/v4 v4.2.3/go.mod h1:qjx8mGObPmV2aSZepjQjbmb2ihdVs8cGKBraizNC69E= sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= From 0e069bfb014cbd315a585fdc016e24db33aef5c4 Mon Sep 17 00:00:00 2001 From: Punakshi Date: Mon, 29 Jul 2024 14:18:46 -0700 Subject: [PATCH 4/8] MESH-0000: Merge v2.10 (#766) * MESH-0000: Local-ELB-Fix (#754) Signed-off-by: Shriram Sharma --- admiral/pkg/clusters/serviceentry.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/admiral/pkg/clusters/serviceentry.go b/admiral/pkg/clusters/serviceentry.go index 8d93c938a..9594645be 100644 --- a/admiral/pkg/clusters/serviceentry.go +++ b/admiral/pkg/clusters/serviceentry.go @@ -445,7 +445,8 @@ func modifyServiceEntryForNewServiceOrPod( ctxLogger.Warnf(common.CtxLogFormat, "Event", deploymentOrRolloutName, deploymentOrRolloutNS, sourceCluster, "unable to find label for rollout or deployment in source cluster: "+sourceCluster) } if createResourcesOnlyInDependentOverrideClusters { - continue + ctxLogger.Infof(common.CtxLogFormat, "Event", deploymentOrRolloutName, deploymentOrRolloutNS, sourceCluster, "processing service entry creation in source clusters as well as there can be a client in the source cluster ") + //continue } // For Deployment <-> Rollout migration // This is maintaining the behavior like before if there was no serviceInstance @@ -633,7 +634,10 @@ func modifyServiceEntryForNewServiceOrPod( if createResourcesOnlyInDependentOverrideClusters { var clusters = make(map[string]string, 0) dependentClusterOverride.Range(func(k string, v string) { - clusters[k] = v + // ensure source clusters are not part of this + if _, ok := sourceServices[k]; !ok { + clusters[k] = v + } }) ctxLogger.Infof(common.CtxLogFormat, "WriteServiceEntryToDependentClusters", deploymentOrRolloutName, deploymentOrRolloutNS, "", fmt.Sprintf("Using override values of dependent clusters: %v, count: %v", clusters, len(clusters))) dependentClusters = clusters From 6c0ab62786d1f8b9f81607f9eb3e42f584760393 Mon Sep 17 00:00:00 2001 From: Punakshi Date: Mon, 5 Aug 2024 13:07:17 -0700 Subject: [PATCH 5/8] Delete secret from cache on secret delete event Signed-off-by: Shriram Sharma --- .../secret/resolver/idpsresolver.go | 67 +++++++++++++++++++ .../pkg/controller/secret/secretcontroller.go | 5 ++ 2 files changed, 72 insertions(+) create mode 100644 admiral/pkg/controller/secret/resolver/idpsresolver.go diff --git a/admiral/pkg/controller/secret/resolver/idpsresolver.go b/admiral/pkg/controller/secret/resolver/idpsresolver.go new file mode 100644 index 000000000..0e1ab9690 --- /dev/null +++ b/admiral/pkg/controller/secret/resolver/idpsresolver.go @@ -0,0 +1,67 @@ +package resolver + +import ( + "fmt" + "io/ioutil" + "sync" + + v1 "github.com/istio-ecosystem/admiral/admiral/apis/v1" + "github.com/istio-ecosystem/admiral/admiral/pkg/client" + log "github.com/sirupsen/logrus" + "gopkg.in/yaml.v2" +) + +type IDPSResolver struct { + IdpsConfig *v1.AdmiralConfig + IdpsClient client.IdpsClientAPI + KubeConfigCache *sync.Map +} + +var Config = &v1.AdmiralConfig{} + +func (r IDPSResolver) FetchKubeConfig(secretName string, _ []byte) ([]byte, error) { + idpsKubeConfig, ok := r.KubeConfigCache.Load(secretName) + if ok { + return idpsKubeConfig.([]byte), nil + } else { + if r.IdpsConfig.IdpsConfig.KubeConfigSecretFolder != "" { + secretName = r.IdpsConfig.IdpsConfig.KubeConfigSecretFolder + "/" + secretName + } + idpsKubeConfig, err := r.IdpsClient.GetSecret(secretName) + if err != nil { + log.Errorf("Failed to fetch kubeconfig with name: %v with error: %v", secretName, err) + return nil, err + } else { + kubeConfig := []byte(idpsKubeConfig) + r.KubeConfigCache.Store(secretName, kubeConfig) + return kubeConfig, nil + } + } +} + +func NewIDPSResolver(configFile string, clientProvider client.IdpsSdkProvider) (SecretResolver, error) { + + data, err := ioutil.ReadFile(configFile) + + if err != nil { + return nil, fmt.Errorf("error reading secret resolver config file err: %v", err) + } + + err = yaml.Unmarshal(data, &Config) + + if err != nil { + return nil, fmt.Errorf("error unmarshaling config file err: %v", err) + } + + IdpsClient, err := client.NewIdpsClient(Config, clientProvider) + if err != nil { + log.Infof("Failed to init IDPS clients in err%v", err) + return nil, err + } + + return IDPSResolver{ + IdpsConfig: Config, + IdpsClient: IdpsClient, + KubeConfigCache: &sync.Map{}, + }, nil +} diff --git a/admiral/pkg/controller/secret/secretcontroller.go b/admiral/pkg/controller/secret/secretcontroller.go index 096c63f40..43de19f95 100644 --- a/admiral/pkg/controller/secret/secretcontroller.go +++ b/admiral/pkg/controller/secret/secretcontroller.go @@ -355,6 +355,11 @@ func (c *Controller) deleteMemberCluster(secretName string) { log.Errorf("error during cluster delete: %s %v", clusterID, err) } delete(c.Cs.RemoteClusters, clusterID) + resolver, ok := c.secretResolver.(resolver.IDPSResolver) + if ok { + log.Infof("Deleting kubeconfig from cache for secret: %s", clusterID) + resolver.KubeConfigCache.Delete(clusterID) + } } } remoteClustersMetric.Set(float64(len(c.Cs.RemoteClusters))) From 28185808a396fdfd02149d7bd4ffd7faa373ab1c Mon Sep 17 00:00:00 2001 From: adilfulara Date: Fri, 9 Aug 2024 11:00:53 -0700 Subject: [PATCH 6/8] lbType should not be null for new services Signed-off-by: Shriram Sharma --- admiral/pkg/clusters/serviceentry.go | 1 + admiral/pkg/clusters/serviceentry_test.go | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/admiral/pkg/clusters/serviceentry.go b/admiral/pkg/clusters/serviceentry.go index 9594645be..e4af10ddd 100644 --- a/admiral/pkg/clusters/serviceentry.go +++ b/admiral/pkg/clusters/serviceentry.go @@ -1599,6 +1599,7 @@ func getWorkloadData(ctxLogger *logrus.Entry, serviceEntry *v1alpha3.ServiceEntr dr.TrafficPolicy.LoadBalancer.LocalityLbSetting.Distribute[0].From == "*" { for region, weight := range dr.TrafficPolicy.LoadBalancer.LocalityLbSetting.Distribute[0].To { trafficDistribution[region] = int32(weight) + lbType = model.TrafficPolicy_LbType_name[int32(model.TrafficPolicy_FAILOVER)] } } } diff --git a/admiral/pkg/clusters/serviceentry_test.go b/admiral/pkg/clusters/serviceentry_test.go index 767bfaa74..775de37c2 100644 --- a/admiral/pkg/clusters/serviceentry_test.go +++ b/admiral/pkg/clusters/serviceentry_test.go @@ -5959,6 +5959,7 @@ func TestGetWorkloadDataActivePassiveEnabled(t *testing.T) { Env: "dev", Aliases: []string{"dev.custom.testsuffix"}, TrafficDistribution: map[string]int32{"us-west-2": 100}, + LbType: model.TrafficPolicy_LbType_name[int32(model.TrafficPolicy_FAILOVER)], } var workloadDataWithFailoverGTP = WorkloadData{ @@ -6100,7 +6101,7 @@ func TestGetWorkloadDataActivePassiveEnabled(t *testing.T) { t.Run(c.name, func(t *testing.T) { workloadData := getWorkloadData(ctxLogger, c.serviceEntry, c.globalTrafficPolicy, c.additionalEndpoints, c.dr, "dev", c.isSuccess) if !reflect.DeepEqual(workloadData, c.expectedWorkloadData) { - assert.Fail(t, "actual and expected workload data do not match. Actual : %v. Expected : %v.", workloadData, c.expectedWorkloadData) + assert.Fail(t, "actual and expected workload data do not match.", "Actual : %v. Expected : %v.", workloadData, c.expectedWorkloadData) } }) } From 18133e85f6e0e0111ea9ca7c297a614848697b1d Mon Sep 17 00:00:00 2001 From: Shriram Sharma Date: Sat, 10 Aug 2024 02:57:42 +0530 Subject: [PATCH 7/8] mistakenly added a file Signed-off-by: Shriram Sharma --- .../secret/resolver/idpsresolver.go | 67 ------------------- 1 file changed, 67 deletions(-) delete mode 100644 admiral/pkg/controller/secret/resolver/idpsresolver.go diff --git a/admiral/pkg/controller/secret/resolver/idpsresolver.go b/admiral/pkg/controller/secret/resolver/idpsresolver.go deleted file mode 100644 index 0e1ab9690..000000000 --- a/admiral/pkg/controller/secret/resolver/idpsresolver.go +++ /dev/null @@ -1,67 +0,0 @@ -package resolver - -import ( - "fmt" - "io/ioutil" - "sync" - - v1 "github.com/istio-ecosystem/admiral/admiral/apis/v1" - "github.com/istio-ecosystem/admiral/admiral/pkg/client" - log "github.com/sirupsen/logrus" - "gopkg.in/yaml.v2" -) - -type IDPSResolver struct { - IdpsConfig *v1.AdmiralConfig - IdpsClient client.IdpsClientAPI - KubeConfigCache *sync.Map -} - -var Config = &v1.AdmiralConfig{} - -func (r IDPSResolver) FetchKubeConfig(secretName string, _ []byte) ([]byte, error) { - idpsKubeConfig, ok := r.KubeConfigCache.Load(secretName) - if ok { - return idpsKubeConfig.([]byte), nil - } else { - if r.IdpsConfig.IdpsConfig.KubeConfigSecretFolder != "" { - secretName = r.IdpsConfig.IdpsConfig.KubeConfigSecretFolder + "/" + secretName - } - idpsKubeConfig, err := r.IdpsClient.GetSecret(secretName) - if err != nil { - log.Errorf("Failed to fetch kubeconfig with name: %v with error: %v", secretName, err) - return nil, err - } else { - kubeConfig := []byte(idpsKubeConfig) - r.KubeConfigCache.Store(secretName, kubeConfig) - return kubeConfig, nil - } - } -} - -func NewIDPSResolver(configFile string, clientProvider client.IdpsSdkProvider) (SecretResolver, error) { - - data, err := ioutil.ReadFile(configFile) - - if err != nil { - return nil, fmt.Errorf("error reading secret resolver config file err: %v", err) - } - - err = yaml.Unmarshal(data, &Config) - - if err != nil { - return nil, fmt.Errorf("error unmarshaling config file err: %v", err) - } - - IdpsClient, err := client.NewIdpsClient(Config, clientProvider) - if err != nil { - log.Infof("Failed to init IDPS clients in err%v", err) - return nil, err - } - - return IDPSResolver{ - IdpsConfig: Config, - IdpsClient: IdpsClient, - KubeConfigCache: &sync.Map{}, - }, nil -} From fd4da91ade416674ca8e01fff14b82e3c3ff992d Mon Sep 17 00:00:00 2001 From: Shriram Sharma Date: Sat, 10 Aug 2024 03:19:11 +0530 Subject: [PATCH 8/8] fixed tests Signed-off-by: Shriram Sharma --- admiral/pkg/clusters/configwriter_test.go | 43 +--- .../pkg/controller/admiral/dependencyproxy.go | 206 ------------------ .../secret/resolver/defaultresolver.go | 4 + .../controller/secret/resolver/resolver.go | 1 + .../pkg/controller/secret/secretcontroller.go | 8 +- admiral/pkg/registry/registry_test.go | 71 +----- tests/perf/perf_service_test.go | 136 ------------ 7 files changed, 15 insertions(+), 454 deletions(-) delete mode 100644 admiral/pkg/controller/admiral/dependencyproxy.go delete mode 100644 tests/perf/perf_service_test.go diff --git a/admiral/pkg/clusters/configwriter_test.go b/admiral/pkg/clusters/configwriter_test.go index 98e1027d2..388152f15 100644 --- a/admiral/pkg/clusters/configwriter_test.go +++ b/admiral/pkg/clusters/configwriter_test.go @@ -2,15 +2,16 @@ package clusters import ( "context" + "reflect" + "strings" + "testing" + "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" "github.com/istio-ecosystem/admiral/admiral/pkg/registry" "github.com/istio-ecosystem/admiral/admiral/pkg/util" networkingV1Alpha3 "istio.io/api/networking/v1alpha3" - "reflect" - "strings" - "testing" ) func admiralParamsForConfigWriterTests() common.AdmiralParams { @@ -63,15 +64,9 @@ func createMockServiceEntry(env string, identity string, endpointAddress string, } func TestGetIngressEndpoints(t *testing.T) { -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go - identityConfig := getSampleIdentityConfig() - expectedIngressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", -======= identityConfig := registry.GetSampleIdentityConfig() expectedIngressEndpoints := map[string]*networkingV1Alpha3.WorkloadEntry{"cg-tax-ppd-usw2-k8s": { Address: "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go Locality: "us-west-2", Ports: map[string]uint32{"http": uint32(15443)}, Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, @@ -133,15 +128,9 @@ func TestGetServiceEntryEndpoint(t *testing.T) { admiralParams := admiralParamsForConfigWriterTests() common.ResetSync() common.InitializeConfig(admiralParams) -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go - e2eEnv := getSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") - ingressEndpoints := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", -======= e2eEnv := registry.GetSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") ingressEndpoints := map[string]*networkingV1Alpha3.WorkloadEntry{"cg-tax-ppd-usw2-k8s": { Address: "internal-a96ffe9cdbb4c4d81b796cc6a37d3e1d-2123389388.us-west-2.elb.amazonaws.com.", ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go Locality: "us-west-2", Ports: map[string]uint32{"http": uint32(15443)}, Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, @@ -151,13 +140,8 @@ func TestGetServiceEntryEndpoint(t *testing.T) { Ports: map[string]uint32{"http": uint32(15443)}, Labels: map[string]string{"security.istio.io/tlsMode": "istio"}, }} -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go - remoteEndpoint := []*networkingV1Alpha3.WorkloadEntry{{ - Address: "a-elb.us-west-2.elb.amazonaws.com.", -======= remoteEndpoint := &networkingV1Alpha3.WorkloadEntry{ Address: "internal-a1cbfde75adbe1fed9763495dfd07960-2123389388.us-west-2.elb.amazonaws.com.", ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go Locality: "us-west-2", Ports: map[string]uint32{"http": uint32(15443)}, Labels: map[string]string{"security.istio.io/tlsMode": "istio", "type": "rollout"}, @@ -184,16 +168,9 @@ func TestGetServiceEntryEndpoint(t *testing.T) { "Then the constructed endpoint should be a remote endpoint", identityConfigEnvironment: e2eEnv, ingressEndpoints: ingressEndpoints, -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go - operatorCluster: "cg-tax-ppd-usw2-k8s", - sourceCluster: "apigw-cx-ppd-usw2-k8s", - remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", - expectedSEEndpoints: remoteEndpoint, -======= clientCluster: "cg-tax-ppd-usw2-k8s", serverCluster: "apigw-cx-ppd-usw2-k8s", expectedSEEndpoint: remoteEndpoint, ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go }, { name: "Given an IdentityConfigEnvironment and ingressEndpoint, " + @@ -201,16 +178,9 @@ func TestGetServiceEntryEndpoint(t *testing.T) { "Then the constructed endpoint should be a local endpoint", identityConfigEnvironment: e2eEnv, ingressEndpoints: ingressEndpoints, -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go - operatorCluster: "cg-tax-ppd-usw2-k8s", - sourceCluster: "cg-tax-ppd-usw2-k8s", - remoteEndpointAddress: "a-elb.us-west-2.elb.amazonaws.com.", - expectedSEEndpoints: localEndpoint, -======= clientCluster: "cg-tax-ppd-usw2-k8s", serverCluster: "cg-tax-ppd-usw2-k8s", expectedSEEndpoint: localEndpoint, ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go }, } for _, c := range testCases { @@ -228,10 +198,6 @@ func TestGetServiceEntryEndpoint(t *testing.T) { } } -<<<<<<< HEAD:admiral/pkg/registry/serviceentry_test.go -func TestBuildServiceEntriesFromIdentityConfig(t *testing.T) { - -======= func TestGetExportTo(t *testing.T) { admiralParams := admiralParamsForConfigWriterTests() common.ResetSync() @@ -320,5 +286,4 @@ func TestBuildServiceEntriesFromIdentityConfig(t *testing.T) { } }) } ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)):admiral/pkg/clusters/configwriter_test.go } diff --git a/admiral/pkg/controller/admiral/dependencyproxy.go b/admiral/pkg/controller/admiral/dependencyproxy.go deleted file mode 100644 index 6459fe1f5..000000000 --- a/admiral/pkg/controller/admiral/dependencyproxy.go +++ /dev/null @@ -1,206 +0,0 @@ -package admiral - -import ( - "context" - "fmt" - "sync" - "time" - - "github.com/istio-ecosystem/admiral/admiral/pkg/controller/common" - log "github.com/sirupsen/logrus" - meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - - v1 "github.com/istio-ecosystem/admiral/admiral/pkg/apis/admiral/v1alpha1" - "k8s.io/client-go/kubernetes" - "k8s.io/client-go/tools/cache" - - clientset "github.com/istio-ecosystem/admiral/admiral/pkg/client/clientset/versioned" - informerV1 "github.com/istio-ecosystem/admiral/admiral/pkg/client/informers/externalversions/admiral/v1alpha1" - "github.com/istio-ecosystem/admiral/admiral/pkg/client/loader" -) - -// DependencyProxyHandler interface contains the methods that are required -type DependencyProxyHandler interface { - Added(ctx context.Context, obj *v1.DependencyProxy) error - Updated(ctx context.Context, obj *v1.DependencyProxy) error - Deleted(ctx context.Context, obj *v1.DependencyProxy) error -} - -type DependencyProxyController struct { - K8sClient kubernetes.Interface - admiralCRDClient clientset.Interface - DependencyProxyHandler DependencyProxyHandler - Cache *dependencyProxyCache - informer cache.SharedIndexInformer -} - -func (d *DependencyProxyController) DoesGenerationMatch(*log.Entry, interface{}, interface{}) (bool, error) { - return false, nil -} - -type DependencyProxyItem struct { - DependencyProxy *v1.DependencyProxy - Status string -} - -type dependencyProxyCache struct { - //map of dependencies key=identity value array of onboarded identitys - cache map[string]*DependencyProxyItem - mutex *sync.Mutex -} - -func (d *dependencyProxyCache) Put(dep *v1.DependencyProxy) { - defer d.mutex.Unlock() - d.mutex.Lock() - - key := d.getKey(dep) - d.cache[key] = &DependencyProxyItem{ - DependencyProxy: dep, - Status: common.ProcessingInProgress, - } -} - -func (d *dependencyProxyCache) getKey(dep *v1.DependencyProxy) string { - return dep.Name -} - -func (d *dependencyProxyCache) Get(identity string) *v1.DependencyProxy { - defer d.mutex.Unlock() - d.mutex.Lock() - - depItem, ok := d.cache[identity] - if ok { - return depItem.DependencyProxy - } - - return nil -} - -func (d *dependencyProxyCache) Delete(dep *v1.DependencyProxy) { - defer d.mutex.Unlock() - d.mutex.Lock() - delete(d.cache, d.getKey(dep)) -} - -func (d *dependencyProxyCache) GetDependencyProxyProcessStatus(dep *v1.DependencyProxy) string { - defer d.mutex.Unlock() - d.mutex.Lock() - - key := d.getKey(dep) - - depItem, ok := d.cache[key] - if ok { - return depItem.Status - } - - return common.NotProcessed -} - -func (d *dependencyProxyCache) UpdateDependencyProxyProcessStatus(dep *v1.DependencyProxy, status string) error { - defer d.mutex.Unlock() - d.mutex.Lock() - - key := d.getKey(dep) - - depItem, ok := d.cache[key] - if ok { - depItem.Status = status - d.cache[key] = depItem - return nil - } - - return fmt.Errorf(LogCacheFormat, "Update", "DependencyProxy", - dep.Name, dep.Namespace, "", "nothing to update, dependency proxy not found in cache") -} - -func NewDependencyProxyController(stopCh <-chan struct{}, handler DependencyProxyHandler, configPath string, namespace string, resyncPeriod time.Duration, clientLoader loader.ClientLoader) (*DependencyProxyController, error) { - - controller := DependencyProxyController{} - controller.DependencyProxyHandler = handler - - depProxyCache := dependencyProxyCache{} - depProxyCache.cache = make(map[string]*DependencyProxyItem) - depProxyCache.mutex = &sync.Mutex{} - - controller.Cache = &depProxyCache - var err error - - controller.K8sClient, err = clientLoader.LoadKubeClientFromPath(configPath) - if err != nil { - return nil, fmt.Errorf("failed to create dependency controller k8s client: %v", err) - } - - controller.admiralCRDClient, err = clientLoader.LoadAdmiralClientFromPath(configPath) - if err != nil { - return nil, fmt.Errorf("failed to create dependency controller crd client: %v", err) - - } - - controller.informer = informerV1.NewDependencyProxyInformer( - controller.admiralCRDClient, - namespace, - resyncPeriod, - cache.Indexers{}, - ) - - NewController("dependencyproxy-ctrl", "", stopCh, &controller, controller.informer) - - return &controller, nil -} - -func (d *DependencyProxyController) Added(ctx context.Context, obj interface{}) error { - dep, ok := obj.(*v1.DependencyProxy) - if !ok { - return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) - } - d.Cache.Put(dep) - return d.DependencyProxyHandler.Added(ctx, dep) -} - -func (d *DependencyProxyController) Updated(ctx context.Context, obj interface{}, oldObj interface{}) error { - dep, ok := obj.(*v1.DependencyProxy) - if !ok { - return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) - } - d.Cache.Put(dep) - return d.DependencyProxyHandler.Updated(ctx, dep) -} - -func (d *DependencyProxyController) Deleted(ctx context.Context, obj interface{}) error { - dep, ok := obj.(*v1.DependencyProxy) - if !ok { - return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) - } - d.Cache.Delete(dep) - return d.DependencyProxyHandler.Deleted(ctx, dep) -} - -func (d *DependencyProxyController) GetProcessItemStatus(obj interface{}) (string, error) { - dependencyProxy, ok := obj.(*v1.DependencyProxy) - if !ok { - return common.NotProcessed, fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) - } - return d.Cache.GetDependencyProxyProcessStatus(dependencyProxy), nil -} - -func (d *DependencyProxyController) UpdateProcessItemStatus(obj interface{}, status string) error { - dependencyProxy, ok := obj.(*v1.DependencyProxy) - if !ok { - return fmt.Errorf("type assertion failed, %v is not of type *v1.DependencyProxy", obj) - } - return d.Cache.UpdateDependencyProxyProcessStatus(dependencyProxy, status) -} - -func (d *DependencyProxyController) LogValueOfAdmiralIoIgnore(obj interface{}) { -} - -func (d *DependencyProxyController) Get(ctx context.Context, isRetry bool, obj interface{}) (interface{}, error) { - dependencyProxy, ok := obj.(*v1.DependencyProxy) - if ok && isRetry { - return d.Cache.Get(dependencyProxy.Name), nil - } - if ok && d.admiralCRDClient != nil { - return d.admiralCRDClient.AdmiralV1alpha1().DependencyProxies(dependencyProxy.Namespace).Get(ctx, dependencyProxy.Name, meta_v1.GetOptions{}) - } - return nil, fmt.Errorf("admiralcrd client is not initialized, txId=%s", ctx.Value("txId")) -} diff --git a/admiral/pkg/controller/secret/resolver/defaultresolver.go b/admiral/pkg/controller/secret/resolver/defaultresolver.go index fc2d5b90b..afe05c1d0 100644 --- a/admiral/pkg/controller/secret/resolver/defaultresolver.go +++ b/admiral/pkg/controller/secret/resolver/defaultresolver.go @@ -9,6 +9,10 @@ func (r DefaultResolver) FetchKubeConfig(secretName string, kubeConfig []byte) ( type DefaultResolver struct { } +func (r DefaultResolver) DeleteClusterFromCache(clusterName string) error { + return nil +} + func NewDefaultResolver() (SecretResolver, error) { resolver := DefaultResolver{} return resolver, nil diff --git a/admiral/pkg/controller/secret/resolver/resolver.go b/admiral/pkg/controller/secret/resolver/resolver.go index 4a6ddc9b3..21f93b0c0 100644 --- a/admiral/pkg/controller/secret/resolver/resolver.go +++ b/admiral/pkg/controller/secret/resolver/resolver.go @@ -4,4 +4,5 @@ package resolver type SecretResolver interface { FetchKubeConfig(secretName string, kubeConfig []byte) ([]byte, error) + DeleteClusterFromCache(clusterName string) error } diff --git a/admiral/pkg/controller/secret/secretcontroller.go b/admiral/pkg/controller/secret/secretcontroller.go index 43de19f95..a7c0ca23d 100644 --- a/admiral/pkg/controller/secret/secretcontroller.go +++ b/admiral/pkg/controller/secret/secretcontroller.go @@ -355,10 +355,10 @@ func (c *Controller) deleteMemberCluster(secretName string) { log.Errorf("error during cluster delete: %s %v", clusterID, err) } delete(c.Cs.RemoteClusters, clusterID) - resolver, ok := c.secretResolver.(resolver.IDPSResolver) - if ok { - log.Infof("Deleting kubeconfig from cache for secret: %s", clusterID) - resolver.KubeConfigCache.Delete(clusterID) + log.Infof("Deleting kubeconfig from cache for secret: %s", clusterID) + err = c.secretResolver.DeleteClusterFromCache(clusterID) + if err != nil { + log.Errorf("error deleting cluster from cache: %s %v", clusterID, err) } } } diff --git a/admiral/pkg/registry/registry_test.go b/admiral/pkg/registry/registry_test.go index 7d7f6ae15..0ae0733db 100644 --- a/admiral/pkg/registry/registry_test.go +++ b/admiral/pkg/registry/registry_test.go @@ -1,84 +1,20 @@ package registry import ( + "context" json "encoding/json" + "errors" "reflect" "testing" "github.com/golang/protobuf/ptypes/duration" "github.com/golang/protobuf/ptypes/wrappers" -<<<<<<< HEAD - networkingV1Alpha3 "istio.io/api/networking/v1alpha3" - coreV1 "k8s.io/api/core/v1" - "k8s.io/apimachinery/pkg/util/intstr" -) - -func getSampleIdentityConfigEnvironment(env string, namespace string) IdentityConfigEnvironment { - identityConfigEnvironment := IdentityConfigEnvironment{ - Name: env, - Namespace: namespace, - ServiceName: "partner-data-to-tax-spk-root-service", - Type: "rollout", - Selectors: map[string]string{"app": "partner-data-to-tax"}, - Ports: []coreV1.ServicePort{{Name: "http-service-mesh", Port: int32(8090), Protocol: coreV1.ProtocolTCP, TargetPort: intstr.FromInt(8090)}}, - TrafficPolicy: networkingV1Alpha3.TrafficPolicy{ - LoadBalancer: &networkingV1Alpha3.LoadBalancerSettings{ - LbPolicy: &networkingV1Alpha3.LoadBalancerSettings_Simple{Simple: networkingV1Alpha3.LoadBalancerSettings_LEAST_REQUEST}, - LocalityLbSetting: &networkingV1Alpha3.LocalityLoadBalancerSetting{ - Distribute: []*networkingV1Alpha3.LocalityLoadBalancerSetting_Distribute{{ - From: "*", - To: map[string]uint32{"us-west-2": 100}, - }}, - }, - WarmupDurationSecs: &duration.Duration{Seconds: 45}, - }, - ConnectionPool: &networkingV1Alpha3.ConnectionPoolSettings{ - Http: &networkingV1Alpha3.ConnectionPoolSettings_HTTPSettings{ - Http2MaxRequests: 1000, - MaxRequestsPerConnection: 5, - }, - }, - OutlierDetection: &networkingV1Alpha3.OutlierDetection{ - ConsecutiveGatewayErrors: &wrappers.UInt32Value{Value: 0}, - Consecutive_5XxErrors: &wrappers.UInt32Value{Value: 0}, - }, - }, - } - return identityConfigEnvironment -} - -func getSampleIdentityConfig() IdentityConfig { - prfEnv := getSampleIdentityConfigEnvironment("prf", "ctg-taxprep-partnerdatatotax-usw2-prf") - e2eEnv := getSampleIdentityConfigEnvironment("e2e", "ctg-taxprep-partnerdatatotax-usw2-e2e") - qalEnv := getSampleIdentityConfigEnvironment("qal", "ctg-taxprep-partnerdatatotax-usw2-qal") - environments := []IdentityConfigEnvironment{prfEnv, e2eEnv, qalEnv} - clientAssets := []map[string]string{{"name": "intuit.cto.dev_portal"}, {"name": "intuit.ctg.tto.browserclient"}, {"name": "intuit.ctg.taxprep.partnerdatatotaxtestclient"}, {"name": "intuit.productmarketing.ipu.pmec"}, {"name": "intuit.tax.taxdev.txo"}, {"name": "intuit.CTO.oauth2"}, {"name": "intuit.platform.servicesgateway.servicesgateway"}, {"name": "intuit.ctg.taxprep.partnerdatatotax"}, {"name": "sample"}} - cluster := IdentityConfigCluster{ - Name: "cg-tax-ppd-usw2-k8s", - Locality: "us-west-2", - IngressEndpoint: "a-elb.us-west-2.elb.amazonaws.com.", - IngressPort: "15443", - IngressPortName: "http", - Environment: environments, - ClientAssets: clientAssets, - } - identityConfig := IdentityConfig{ - Assetname: "Intuit.ctg.taxprep.partnerdatatotax", - Clusters: []IdentityConfigCluster{cluster}, - } - return identityConfig -} - -======= "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" log "github.com/sirupsen/logrus" networkingV1Alpha3 "istio.io/api/networking/v1alpha3" - "reflect" - "testing" ) ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) func TestParseIdentityConfigJSON(t *testing.T) { identityConfig := GetSampleIdentityConfig() testCases := []struct { @@ -109,8 +45,6 @@ func TestParseIdentityConfigJSON(t *testing.T) { }) } } -<<<<<<< HEAD -======= func TestIdentityConfigGetByIdentityName(t *testing.T) { sampleIdentityConfig := GetSampleIdentityConfig() @@ -204,4 +138,3 @@ func TestGetIdentityConfigByClusterName(t *testing.T) { }) } } ->>>>>>> 508caceb (MESH-5069: Operator Shards (#749)) diff --git a/tests/perf/perf_service_test.go b/tests/perf/perf_service_test.go deleted file mode 100644 index d053a1b7c..000000000 --- a/tests/perf/perf_service_test.go +++ /dev/null @@ -1,136 +0,0 @@ -package perf - -import ( - "fmt" - "time" - - "github.com/jamiealquiza/tachymeter" - . "github.com/onsi/gomega" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" -) - -var _ PerfHandler = (*ServicePerfHandler)(nil) - -type ServicePerfHandler struct { - source ClusterAssetMap - destination ClusterAssetMap -} - -func NewServicePerfHandler(sourceClusterAssetMap, destinationClusterAssetMap ClusterAssetMap) *tachymeter.Metrics { - a := &ServicePerfHandler{ - source: sourceClusterAssetMap, - destination: destinationClusterAssetMap, - } - - return a.Run() -} - -func (a *ServicePerfHandler) Run() *tachymeter.Metrics { - defer a.Revert() - return computeMetrics(a.Action(), a.Reaction()) -} - -func (a *ServicePerfHandler) Action() TimeMap { - timeMap := make(TimeMap) - - for destinationAsset, destinationClusters := range a.destination { - client := getKubeClient(destinationClusters.west) - namespace := getNamespaceName(destinationAsset) - dep, err := client.AppsV1().Deployments(namespace).Get(ctx, getDeploymentName(destinationAsset), metav1.GetOptions{}) - if dep != nil && err == nil { - timeMap[destinationAsset] = handleDeployment(destinationClusters.west, destinationAsset, RegionWest, TempServiceIdentifier) - } else { - timeMap[destinationAsset] = handleRollout(destinationClusters.west, destinationAsset, TempServiceIdentifier) - } - } - - return timeMap -} - -func (a *ServicePerfHandler) Reaction() TimeMultiMap { - timeMap := make(TimeMultiMap) - - for sourceAsset, sourceClusters := range a.source { - timeMap[sourceAsset] = make([]time.Time, 0) - - fmt.Printf("\twaiting for service entries to get updated in cluster %q\n", sourceClusters.west) - - for destinationAsset, destinationClusters := range a.destination { - if sourceClusters.west == destinationClusters.west { - timeMap[destinationAsset] = append(timeMap[destinationAsset], a.wait(sourceClusters.west, sourceAsset, destinationAsset)) - } - } - } - - return timeMap -} - -func (a *ServicePerfHandler) Revert() { - for destinationAsset, destinationClusters := range a.destination { - client := getKubeClient(destinationClusters.west) - namespace := getNamespaceName(destinationAsset) - deploymentName := getDeploymentName(destinationAsset) - dep, err := client.AppsV1().Deployments(namespace).Get(ctx, deploymentName, metav1.GetOptions{}) - if dep != nil && err == nil { - handleDeployment(destinationClusters.west, destinationAsset, TempServiceIdentifier, RegionWest) - } else { - handleRollout(destinationClusters.west, destinationAsset, StableServiceIdentifier) - } - } -} - -func (a *ServicePerfHandler) wait(sourceCluster, sourceAsset, destinationAsset string) time.Time { - var ts time.Time - serviceEntryName := getServiceEntryName(destinationAsset) - - Eventually(func(g Gomega) { - se, err := getIstioClient(sourceCluster).NetworkingV1alpha3().ServiceEntries(SyncNamespace).Get(ctx, serviceEntryName, metav1.GetOptions{}) - g.Expect(err).ToNot(HaveOccurred()) - g.Expect(se).ToNot(BeNil()) - g.Expect(se.Spec.ExportTo).To(ContainElement(getNamespaceName(sourceAsset))) - g.Expect(len(se.Spec.Hosts)).To(Equal(1)) - g.Expect(len(se.Spec.Addresses)).To(Equal(1)) - g.Expect(len(se.Spec.Endpoints)).To(Equal(2)) - localAddress := getLocalServiceEntryAddress(getServiceName(destinationAsset, TempServiceIdentifier), getNamespaceName(destinationAsset)) - g.Expect(se.Spec.Endpoints).To(ContainElement(HaveField("Address", Equal(localAddress)))) - ts = getLastUpdatedTime(se.GetAnnotations()) - }).WithTimeout(ServiceEntryWaitTime).WithPolling(time.Second).Should(Succeed()) - - return ts -} - -func handleDeployment(cluster, asset, oldServiceIdentifier, newServiceIdentifier string) time.Time { - namespace := getNamespaceName(asset) - client := getKubeClient(cluster) - Expect(client.CoreV1().Services(namespace).Delete(ctx, getServiceName(asset, oldServiceIdentifier), metav1.DeleteOptions{})).ToNot(HaveOccurred()) - - svc, err := client.CoreV1().Services(namespace).Create(ctx, getServiceSpec(asset, newServiceIdentifier), metav1.CreateOptions{}) - Expect(err).ToNot(HaveOccurred()) - Expect(svc).ToNot(BeNil()) - - return getLastUpdatedTime(svc.GetAnnotations()) -} - -func handleRollout(cluster, asset, serviceIdentifier string) time.Time { - kubeClient := getKubeClient(cluster) - argoClient := getArgoClient(cluster) - namespace := getNamespaceName(asset) - - if serviceIdentifier == TempServiceIdentifier { - kubeClient.CoreV1().Services(namespace).Create(ctx, getServiceSpec(asset, TempServiceIdentifier), metav1.CreateOptions{}) - } - - ro, err := argoClient.ArgoprojV1alpha1().Rollouts(namespace).Get(ctx, getRolloutName(asset), metav1.GetOptions{}) - Expect(err).ToNot(HaveOccurred()) - Expect(ro).ToNot(BeNil()) - - ro.Spec.Strategy.Canary.StableService = getServiceName(asset, serviceIdentifier) - - ro.Generation++ - - ro, err = argoClient.ArgoprojV1alpha1().Rollouts(namespace).Update(ctx, ro, metav1.UpdateOptions{}) - Expect(err).ToNot(HaveOccurred()) - Expect(ro).ToNot(BeNil()) - - return getLastUpdatedTime(ro.GetAnnotations()) -}