diff --git a/go.mod b/go.mod index ec0f3053d937..0f976df35858 100644 --- a/go.mod +++ b/go.mod @@ -13,7 +13,7 @@ require ( github.com/google/go-cmp v0.5.8 github.com/google/uuid v1.1.2 github.com/hashicorp/go-azure-helpers v0.34.0 - github.com/hashicorp/go-azure-sdk v0.20220623.1064317 + github.com/hashicorp/go-azure-sdk v0.20220627.1082008 github.com/hashicorp/go-multierror v1.1.1 github.com/hashicorp/go-uuid v1.0.2 github.com/hashicorp/go-version v1.4.0 diff --git a/go.sum b/go.sum index fa6bdb83fe45..49c54ce466ae 100644 --- a/go.sum +++ b/go.sum @@ -259,8 +259,8 @@ github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brv github.com/hashicorp/go-azure-helpers v0.12.0/go.mod h1:Zc3v4DNeX6PDdy7NljlYpnrdac1++qNW0I4U+ofGwpg= github.com/hashicorp/go-azure-helpers v0.34.0 h1:Lvk3IgwFT51WVu1IK5rpUMd+rKnRylg9vMTt6Qx6xn4= github.com/hashicorp/go-azure-helpers v0.34.0/go.mod h1:gcutZ/Hf/O7YN9M3UIvyZ9l0Rxv7Yrc9x5sSfM9cuSw= -github.com/hashicorp/go-azure-sdk v0.20220623.1064317 h1:ebBEfxlNZ4VlWvlcRqTsx9fyhhyWeBEsAVFr42arDzk= -github.com/hashicorp/go-azure-sdk v0.20220623.1064317/go.mod h1:jPd83zRme0J5C+rUQaU6bzrWg/AS5WN1TiilFzRoKU0= +github.com/hashicorp/go-azure-sdk v0.20220627.1082008 h1:tOdphusgZe249qWqERFXNza7rgqpJ+gV0CkhI2UwUyI= +github.com/hashicorp/go-azure-sdk v0.20220627.1082008/go.mod h1:jPd83zRme0J5C+rUQaU6bzrWg/AS5WN1TiilFzRoKU0= github.com/hashicorp/go-checkpoint v0.5.0 h1:MFYpPZCnQqQTE18jFwSII6eUQrD/oxMFp3mlgcqk5mU= github.com/hashicorp/go-checkpoint v0.5.0/go.mod h1:7nfLNL10NsxqO4iWuW6tWW0HjZuDrwkBuEQsVcpCOgg= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/constants.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/constants.go deleted file mode 100644 index c6cf8a346015..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/constants.go +++ /dev/null @@ -1,31 +0,0 @@ -package tenantconfiguration - -import "strings" - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ConfigurationName string - -const ( - ConfigurationNameDefault ConfigurationName = "default" -) - -func PossibleValuesForConfigurationName() []string { - return []string{ - string(ConfigurationNameDefault), - } -} - -func parseConfigurationName(input string) (*ConfigurationName, error) { - vals := map[string]ConfigurationName{ - "default": ConfigurationNameDefault, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := ConfigurationName(input) - return &out, nil -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/id_configuration.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/id_configuration.go deleted file mode 100644 index a0f22df44787..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/id_configuration.go +++ /dev/null @@ -1,112 +0,0 @@ -package tenantconfiguration - -import ( - "fmt" - "strings" - - "github.com/hashicorp/go-azure-helpers/resourcemanager/resourceids" -) - -var _ resourceids.ResourceId = ConfigurationId{} - -// ConfigurationId is a struct representing the Resource ID for a Configuration -type ConfigurationId struct { - ConfigurationName ConfigurationName -} - -// NewConfigurationID returns a new ConfigurationId struct -func NewConfigurationID(configurationName ConfigurationName) ConfigurationId { - return ConfigurationId{ - ConfigurationName: configurationName, - } -} - -// ParseConfigurationID parses 'input' into a ConfigurationId -func ParseConfigurationID(input string) (*ConfigurationId, error) { - parser := resourceids.NewParserFromResourceIdType(ConfigurationId{}) - parsed, err := parser.Parse(input, false) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ConfigurationId{} - - if v, ok := parsed.Parsed["configurationName"]; true { - if !ok { - return nil, fmt.Errorf("the segment 'configurationName' was not found in the resource id %q", input) - } - - configurationName, err := parseConfigurationName(v) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", v, err) - } - id.ConfigurationName = *configurationName - } - - return &id, nil -} - -// ParseConfigurationIDInsensitively parses 'input' case-insensitively into a ConfigurationId -// note: this method should only be used for API response data and not user input -func ParseConfigurationIDInsensitively(input string) (*ConfigurationId, error) { - parser := resourceids.NewParserFromResourceIdType(ConfigurationId{}) - parsed, err := parser.Parse(input, true) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ConfigurationId{} - - if v, ok := parsed.Parsed["configurationName"]; true { - if !ok { - return nil, fmt.Errorf("the segment 'configurationName' was not found in the resource id %q", input) - } - - configurationName, err := parseConfigurationName(v) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", v, err) - } - id.ConfigurationName = *configurationName - } - - return &id, nil -} - -// ValidateConfigurationID checks that 'input' can be parsed as a Configuration ID -func ValidateConfigurationID(input interface{}, key string) (warnings []string, errors []error) { - v, ok := input.(string) - if !ok { - errors = append(errors, fmt.Errorf("expected %q to be a string", key)) - return - } - - if _, err := ParseConfigurationID(v); err != nil { - errors = append(errors, err) - } - - return -} - -// ID returns the formatted Configuration ID -func (id ConfigurationId) ID() string { - fmtString := "/providers/Microsoft.Portal/tenantConfigurations/%s" - return fmt.Sprintf(fmtString, string(id.ConfigurationName)) -} - -// Segments returns a slice of Resource ID Segments which comprise this Configuration ID -func (id ConfigurationId) Segments() []resourceids.Segment { - return []resourceids.Segment{ - resourceids.StaticSegment("staticProviders", "providers", "providers"), - resourceids.ResourceProviderSegment("staticMicrosoftPortal", "Microsoft.Portal", "Microsoft.Portal"), - resourceids.StaticSegment("staticTenantConfigurations", "tenantConfigurations", "tenantConfigurations"), - resourceids.ConstantSegment("configurationName", PossibleValuesForConfigurationName(), "default"), - } -} - -// String returns a human-readable description of this Configuration ID -func (id ConfigurationId) String() string { - components := []string{ - fmt.Sprintf("Configuration Name: %q", string(id.ConfigurationName)), - } - return fmt.Sprintf("Configuration (%s)", strings.Join(components, "\n")) -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationscreate_autorest.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationscreate_autorest.go index f261c92147bb..8d9a936f255b 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationscreate_autorest.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationscreate_autorest.go @@ -17,8 +17,8 @@ type TenantConfigurationsCreateOperationResponse struct { } // TenantConfigurationsCreate ... -func (c TenantConfigurationClient) TenantConfigurationsCreate(ctx context.Context, id ConfigurationId, input Configuration) (result TenantConfigurationsCreateOperationResponse, err error) { - req, err := c.preparerForTenantConfigurationsCreate(ctx, id, input) +func (c TenantConfigurationClient) TenantConfigurationsCreate(ctx context.Context, input Configuration) (result TenantConfigurationsCreateOperationResponse, err error) { + req, err := c.preparerForTenantConfigurationsCreate(ctx, input) if err != nil { err = autorest.NewErrorWithError(err, "tenantconfiguration.TenantConfigurationClient", "TenantConfigurationsCreate", nil, "Failure preparing request") return @@ -40,7 +40,7 @@ func (c TenantConfigurationClient) TenantConfigurationsCreate(ctx context.Contex } // preparerForTenantConfigurationsCreate prepares the TenantConfigurationsCreate request. -func (c TenantConfigurationClient) preparerForTenantConfigurationsCreate(ctx context.Context, id ConfigurationId, input Configuration) (*http.Request, error) { +func (c TenantConfigurationClient) preparerForTenantConfigurationsCreate(ctx context.Context, input Configuration) (*http.Request, error) { queryParameters := map[string]interface{}{ "api-version": defaultApiVersion, } @@ -49,7 +49,7 @@ func (c TenantConfigurationClient) preparerForTenantConfigurationsCreate(ctx con autorest.AsContentType("application/json; charset=utf-8"), autorest.AsPut(), autorest.WithBaseURL(c.baseUri), - autorest.WithPath(id.ID()), + autorest.WithPath("/providers/Microsoft.Portal/tenantConfigurations/default"), autorest.WithJSON(input), autorest.WithQueryParameters(queryParameters)) return preparer.Prepare((&http.Request{}).WithContext(ctx)) diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsdelete_autorest.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsdelete_autorest.go index aa37b23f8a40..e4f1837a0f34 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsdelete_autorest.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsdelete_autorest.go @@ -16,8 +16,8 @@ type TenantConfigurationsDeleteOperationResponse struct { } // TenantConfigurationsDelete ... -func (c TenantConfigurationClient) TenantConfigurationsDelete(ctx context.Context, id ConfigurationId) (result TenantConfigurationsDeleteOperationResponse, err error) { - req, err := c.preparerForTenantConfigurationsDelete(ctx, id) +func (c TenantConfigurationClient) TenantConfigurationsDelete(ctx context.Context) (result TenantConfigurationsDeleteOperationResponse, err error) { + req, err := c.preparerForTenantConfigurationsDelete(ctx) if err != nil { err = autorest.NewErrorWithError(err, "tenantconfiguration.TenantConfigurationClient", "TenantConfigurationsDelete", nil, "Failure preparing request") return @@ -39,7 +39,7 @@ func (c TenantConfigurationClient) TenantConfigurationsDelete(ctx context.Contex } // preparerForTenantConfigurationsDelete prepares the TenantConfigurationsDelete request. -func (c TenantConfigurationClient) preparerForTenantConfigurationsDelete(ctx context.Context, id ConfigurationId) (*http.Request, error) { +func (c TenantConfigurationClient) preparerForTenantConfigurationsDelete(ctx context.Context) (*http.Request, error) { queryParameters := map[string]interface{}{ "api-version": defaultApiVersion, } @@ -48,7 +48,7 @@ func (c TenantConfigurationClient) preparerForTenantConfigurationsDelete(ctx con autorest.AsContentType("application/json; charset=utf-8"), autorest.AsDelete(), autorest.WithBaseURL(c.baseUri), - autorest.WithPath(id.ID()), + autorest.WithPath("/providers/Microsoft.Portal/tenantConfigurations/default"), autorest.WithQueryParameters(queryParameters)) return preparer.Prepare((&http.Request{}).WithContext(ctx)) } diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsget_autorest.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsget_autorest.go index 2c78aec4b930..2b6a381dcf61 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsget_autorest.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/tenantconfiguration/method_tenantconfigurationsget_autorest.go @@ -17,8 +17,8 @@ type TenantConfigurationsGetOperationResponse struct { } // TenantConfigurationsGet ... -func (c TenantConfigurationClient) TenantConfigurationsGet(ctx context.Context, id ConfigurationId) (result TenantConfigurationsGetOperationResponse, err error) { - req, err := c.preparerForTenantConfigurationsGet(ctx, id) +func (c TenantConfigurationClient) TenantConfigurationsGet(ctx context.Context) (result TenantConfigurationsGetOperationResponse, err error) { + req, err := c.preparerForTenantConfigurationsGet(ctx) if err != nil { err = autorest.NewErrorWithError(err, "tenantconfiguration.TenantConfigurationClient", "TenantConfigurationsGet", nil, "Failure preparing request") return @@ -40,7 +40,7 @@ func (c TenantConfigurationClient) TenantConfigurationsGet(ctx context.Context, } // preparerForTenantConfigurationsGet prepares the TenantConfigurationsGet request. -func (c TenantConfigurationClient) preparerForTenantConfigurationsGet(ctx context.Context, id ConfigurationId) (*http.Request, error) { +func (c TenantConfigurationClient) preparerForTenantConfigurationsGet(ctx context.Context) (*http.Request, error) { queryParameters := map[string]interface{}{ "api-version": defaultApiVersion, } @@ -49,7 +49,7 @@ func (c TenantConfigurationClient) preparerForTenantConfigurationsGet(ctx contex autorest.AsContentType("application/json; charset=utf-8"), autorest.AsGet(), autorest.WithBaseURL(c.baseUri), - autorest.WithPath(id.ID()), + autorest.WithPath("/providers/Microsoft.Portal/tenantConfigurations/default"), autorest.WithQueryParameters(queryParameters)) return preparer.Prepare((&http.Request{}).WithContext(ctx)) } diff --git a/vendor/modules.txt b/vendor/modules.txt index e6d14bdcb263..52f2f7f11b82 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -211,7 +211,7 @@ github.com/hashicorp/go-azure-helpers/resourcemanager/zones github.com/hashicorp/go-azure-helpers/resourceproviders github.com/hashicorp/go-azure-helpers/sender github.com/hashicorp/go-azure-helpers/storage -# github.com/hashicorp/go-azure-sdk v0.20220623.1064317 +# github.com/hashicorp/go-azure-sdk v0.20220627.1082008 ## explicit; go 1.18 github.com/hashicorp/go-azure-sdk/resource-manager/aadb2c/2021-04-01-preview/tenants github.com/hashicorp/go-azure-sdk/resource-manager/analysisservices/2017-08-01/servers