diff --git a/chart/compass/values.yaml b/chart/compass/values.yaml index 426a4a8cec..18e46dd173 100644 --- a/chart/compass/values.yaml +++ b/chart/compass/values.yaml @@ -175,7 +175,7 @@ global: name: compass-pairing-adapter director: dir: dev/incubator/ - version: "PR-3787" + version: "PR-3849" name: compass-director hydrator: dir: dev/incubator/ @@ -228,7 +228,7 @@ global: name: compass-external-services-mock e2e_tests: dir: dev/incubator/ - version: "PR-3787" + version: "PR-3849" name: compass-e2e-tests isLocalEnv: false isForTesting: false diff --git a/components/director/internal/domain/apptemplate/resolver.go b/components/director/internal/domain/apptemplate/resolver.go index f86fb927fa..5d627df7cc 100644 --- a/components/director/internal/domain/apptemplate/resolver.go +++ b/components/director/internal/domain/apptemplate/resolver.go @@ -895,10 +895,10 @@ func (r *Resolver) retrieveAppTemplate(ctx context.Context, return appTemplate, nil } } - return nil, errors.Errorf("application template with id %s and consumer id %q not found", *appTemplateID, consumerID) + return nil, errors.Errorf("application template with id %s and consumer id REDACTED_%x not found", *appTemplateID, sha256.Sum256([]byte(consumerID))) } if len(templates) < 1 { - return nil, errors.Errorf("application template with name %q and consumer id %q not found", appTemplateName, consumerID) + return nil, errors.Errorf("application template with name %q and consumer id REDACTED_%x not found", appTemplateName, sha256.Sum256([]byte(consumerID))) } if len(templates) > 1 { return nil, errors.Errorf("unexpected number of application templates. found %d", len(appTemplates)) diff --git a/components/director/internal/domain/apptemplate/resolver_test.go b/components/director/internal/domain/apptemplate/resolver_test.go index 5a3f412743..311bb99d1c 100644 --- a/components/director/internal/domain/apptemplate/resolver_test.go +++ b/components/director/internal/domain/apptemplate/resolver_test.go @@ -2,6 +2,7 @@ package apptemplate_test import ( "context" + "crypto/sha256" "errors" "fmt" "testing" @@ -2103,7 +2104,7 @@ func TestResolver_RegisterApplicationFromTemplate(t *testing.T) { WebhookSvcFn: UnusedWebhookSvc, SystemFieldDiscoveryEngine: UnusedSystemFieldDiscoveryEngine, ExpectedOutput: nil, - ExpectedError: errors.New("application template with name \"bar\" and consumer id \"consumer-id\" not found"), + ExpectedError: fmt.Errorf("application template with name \"bar\" and consumer id REDACTED_%x not found", sha256.Sum256([]byte("consumer-id"))), }, { Name: "Returns error when list application templates by name return more than one application template", @@ -2442,7 +2443,7 @@ func TestResolver_RegisterApplicationFromTemplate(t *testing.T) { WebhookConvFn: UnusedWebhookConv, WebhookSvcFn: UnusedWebhookSvc, SystemFieldDiscoveryEngine: UnusedSystemFieldDiscoveryEngine, - ExpectedError: errors.New("application template with id customTemplateID and consumer id \"consumer-id\" not found"), + ExpectedError: fmt.Errorf("application template with id customTemplateID and consumer id REDACTED_%x not found", sha256.Sum256([]byte("consumer-id"))), }, } diff --git a/tests/director/tests/application/application_templates_api_test.go b/tests/director/tests/application/application_templates_api_test.go index e230c6d80c..5fa33f81da 100644 --- a/tests/director/tests/application/application_templates_api_test.go +++ b/tests/director/tests/application/application_templates_api_test.go @@ -2,6 +2,7 @@ package application import ( "context" + "crypto/sha256" "fmt" "testing" "time" @@ -2225,7 +2226,7 @@ func TestRegisterApplicationFromTemplate_DifferentSubaccount(t *testing.T) { // THEN require.NotNil(t, err) - require.Contains(t, err.Error(), fmt.Sprintf("application template with name %q and consumer id %q not found", appTemplateName, conf.TestProviderSubaccountIDRegion2)) + require.Contains(t, err.Error(), fmt.Sprintf("application template with name %q and consumer id REDACTED_%x not found", appTemplateName, sha256.Sum256([]byte(conf.TestProviderSubaccountIDRegion2)))) } func TestAddWebhookToApplicationTemplateWithTenant(t *testing.T) {