From 1e20065abfd620b9ae04c94569975f0507cce2c0 Mon Sep 17 00:00:00 2001 From: "Kaihui (Kerwin) Sun" Date: Mon, 8 Feb 2021 11:23:39 +0800 Subject: [PATCH] T1 cdn 2021 02 07 (#16591) * CodeGen from PR 12421 in Azure/azure-rest-api-specs [Afdx] Changed all "accepted" to 202 (#12421) * changed all "accepted" to 202 * fix validation errors * adding 202 to examples * prettier check * updated maxRanking, removed certificate association, and reverted prettifier changes to KV * reverting prettifier changes again * revert yet again * fixed secrets examples * remove optimization type * add 202 for all PUT calls, change validateSecret from 200 to 202 for async, removed bypasscache for afdx * correct validation errors * fixes * add afdx into custom words * revert the validate secret api change * missed the message * change from afdx to afd * fix security policies * remove addtional properties * prettier Co-authored-by: Shirley Jiang * test,version,CHANGELOG * fix None Error Co-authored-by: SDKAuto Co-authored-by: Shirley Jiang --- sdk/cdn/azure-mgmt-cdn/CHANGELOG.md | 12 ++ .../azure/mgmt/cdn/_cdn_management_client.py | 9 +- .../azure/mgmt/cdn/_configuration.py | 13 +- .../azure/mgmt/cdn/models/__init__.py | 7 +- .../models/_cdn_management_client_enums.py | 14 +- .../azure/mgmt/cdn/models/_models.py | 188 ++++++++--------- .../azure/mgmt/cdn/models/_models_py3.py | 196 ++++++++---------- .../_afd_custom_domains_operations.py | 8 +- .../operations/_afd_endpoints_operations.py | 8 +- .../_afd_origin_groups_operations.py | 8 +- .../cdn/operations/_afd_origins_operations.py | 8 +- .../operations/_afd_profiles_operations.py | 2 +- .../operations/_custom_domains_operations.py | 2 +- .../cdn/operations/_edge_nodes_operations.py | 2 +- .../cdn/operations/_endpoints_operations.py | 2 +- .../operations/_log_analytics_operations.py | 10 +- .../_managed_rule_sets_operations.py | 2 +- .../azure/mgmt/cdn/operations/_operations.py | 2 +- .../operations/_origin_groups_operations.py | 2 +- .../cdn/operations/_origins_operations.py | 2 +- .../cdn/operations/_policies_operations.py | 2 +- .../cdn/operations/_profiles_operations.py | 2 +- .../operations/_resource_usage_operations.py | 2 +- .../mgmt/cdn/operations/_routes_operations.py | 8 +- .../cdn/operations/_rule_sets_operations.py | 8 +- .../mgmt/cdn/operations/_rules_operations.py | 8 +- .../cdn/operations/_secrets_operations.py | 8 +- .../_security_policies_operations.py | 26 +-- .../cdn/operations/_validate_operations.py | 2 +- .../azure-mgmt-cdn/azure/mgmt/cdn/version.py | 2 +- 30 files changed, 279 insertions(+), 286 deletions(-) diff --git a/sdk/cdn/azure-mgmt-cdn/CHANGELOG.md b/sdk/cdn/azure-mgmt-cdn/CHANGELOG.md index 55b7ebd7498d..df2ce3fbc478 100644 --- a/sdk/cdn/azure-mgmt-cdn/CHANGELOG.md +++ b/sdk/cdn/azure-mgmt-cdn/CHANGELOG.md @@ -1,5 +1,17 @@ # Release History +## 7.0.0 (2021-02-07) + +**Breaking changes** + + - Operation SecurityPoliciesOperations.patch has a new signature + - Model RouteUpdateParameters no longer has parameter optimization_type + - Model Route no longer has parameter optimization_type + - Model CustomerCertificateParameters no longer has parameter thumbprint + - Model CustomerCertificateParameters no longer has parameter expiration_date + - Model CustomerCertificateParameters no longer has parameter subject + - Model ManagedCertificateParameters has a new signature + ## 6.0.0 (2020-12-14) **Features** diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_cdn_management_client.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_cdn_management_client.py index 34ea3d89384f..9bd5a5644a49 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_cdn_management_client.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_cdn_management_client.py @@ -95,18 +95,13 @@ class CdnManagementClient(CdnManagementClientOperationsMixin, SDKClient): object` :param subscription_id: Azure Subscription ID. :type subscription_id: str - :param subscription_id1: Azure Subscription ID. - :type subscription_id1: str - :param api_version1: Version of the API to be used with the client - request. Current version is 2019-09-01. - :type api_version1: str :param str base_url: Service URL """ def __init__( - self, credentials, subscription_id, subscription_id1, api_version1, base_url=None): + self, credentials, subscription_id, base_url=None): - self.config = CdnManagementClientConfiguration(credentials, subscription_id, subscription_id1, api_version1, base_url) + self.config = CdnManagementClientConfiguration(credentials, subscription_id, base_url) super(CdnManagementClient, self).__init__(self.config.credentials, self.config) client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_configuration.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_configuration.py index 1dc1e0482e88..425d52e81a87 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_configuration.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/_configuration.py @@ -23,25 +23,16 @@ class CdnManagementClientConfiguration(AzureConfiguration): object` :param subscription_id: Azure Subscription ID. :type subscription_id: str - :param subscription_id1: Azure Subscription ID. - :type subscription_id1: str - :param api_version1: Version of the API to be used with the client - request. Current version is 2019-09-01. - :type api_version1: str :param str base_url: Service URL """ def __init__( - self, credentials, subscription_id, subscription_id1, api_version1, base_url=None): + self, credentials, subscription_id, base_url=None): if credentials is None: raise ValueError("Parameter 'credentials' must not be None.") if subscription_id is None: raise ValueError("Parameter 'subscription_id' must not be None.") - if subscription_id1 is None: - raise ValueError("Parameter 'subscription_id1' must not be None.") - if api_version1 is None: - raise ValueError("Parameter 'api_version1' must not be None.") if not base_url: base_url = 'https://management.azure.com' @@ -55,5 +46,3 @@ def __init__( self.credentials = credentials self.subscription_id = subscription_id - self.subscription_id1 = subscription_id1 - self.api_version1 = api_version1 diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/__init__.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/__init__.py index 4ad41246674d..3d626d8feb70 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/__init__.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/__init__.py @@ -145,6 +145,7 @@ from ._models_py3 import SecretProperties from ._models_py3 import SecurityPolicy from ._models_py3 import SecurityPolicyParameters + from ._models_py3 import SecurityPolicyProperties from ._models_py3 import SecurityPolicyWebApplicationFirewallAssociation from ._models_py3 import SecurityPolicyWebApplicationFirewallParameters from ._models_py3 import SharedPrivateLinkResourceProperties @@ -318,6 +319,7 @@ from ._models import SecretProperties from ._models import SecurityPolicy from ._models import SecurityPolicyParameters + from ._models import SecurityPolicyProperties from ._models import SecurityPolicyWebApplicationFirewallAssociation from ._models import SecurityPolicyWebApplicationFirewallParameters from ._models import SharedPrivateLinkResourceProperties @@ -423,8 +425,8 @@ DomainValidationState, EnabledState, AFDEndpointProtocols, - SecretType, SharedPrivateLinkResourceStatus, + AfdQueryStringCachingBehavior, ForwardingProtocol, LinkToDefaultDomain, HttpsRedirect, @@ -577,6 +579,7 @@ 'SecretProperties', 'SecurityPolicy', 'SecurityPolicyParameters', + 'SecurityPolicyProperties', 'SecurityPolicyWebApplicationFirewallAssociation', 'SecurityPolicyWebApplicationFirewallParameters', 'SharedPrivateLinkResourceProperties', @@ -681,8 +684,8 @@ 'DomainValidationState', 'EnabledState', 'AFDEndpointProtocols', - 'SecretType', 'SharedPrivateLinkResourceStatus', + 'AfdQueryStringCachingBehavior', 'ForwardingProtocol', 'LinkToDefaultDomain', 'HttpsRedirect', diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_cdn_management_client_enums.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_cdn_management_client_enums.py index 85f817f6e3fe..e83d6b47dc3e 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_cdn_management_client_enums.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_cdn_management_client_enums.py @@ -432,13 +432,6 @@ class AFDEndpointProtocols(str, Enum): https = "Https" -class SecretType(str, Enum): - - url_signing_key = "UrlSigningKey" - customer_certificate = "CustomerCertificate" - managed_certificate = "ManagedCertificate" - - class SharedPrivateLinkResourceStatus(str, Enum): pending = "Pending" @@ -448,6 +441,13 @@ class SharedPrivateLinkResourceStatus(str, Enum): timeout = "Timeout" +class AfdQueryStringCachingBehavior(str, Enum): + + ignore_query_string = "IgnoreQueryString" + use_query_string = "UseQueryString" + not_set = "NotSet" + + class ForwardingProtocol(str, Enum): http_only = "HttpOnly" diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models.py index cda643435643..3e40dc25b79b 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models.py @@ -1501,20 +1501,43 @@ def __init__(self, **kwargs): self.subject_alternative_names = kwargs.get('subject_alternative_names', None) -class CustomerCertificateParameters(Model): +class SecretParameters(Model): + """The json object containing secret parameters. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: UrlSigningKeyParameters, ManagedCertificateParameters, + CustomerCertificateParameters + + All required parameters must be populated in order to send to Azure. + + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'UrlSigningKey': 'UrlSigningKeyParameters', 'ManagedCertificate': 'ManagedCertificateParameters', 'CustomerCertificate': 'CustomerCertificateParameters'} + } + + def __init__(self, **kwargs): + super(SecretParameters, self).__init__(**kwargs) + self.type = None + + +class CustomerCertificateParameters(SecretParameters): """Customer Certificate used for https. All required parameters must be populated in order to send to Azure. - :param type: Required. The type of the Secret to create. Possible values - include: 'UrlSigningKey', 'CustomerCertificate', 'ManagedCertificate' - :type type: str or ~azure.mgmt.cdn.models.SecretType - :param subject: Subject name in the certificate. - :type subject: str - :param expiration_date: Certificate expiration date. - :type expiration_date: str - :param thumbprint: Certificate thumbprint. - :type thumbprint: str + :param type: Required. Constant filled by server. + :type type: str :param secret_source: Required. Resource reference to the KV secret :type secret_source: ~azure.mgmt.cdn.models.ResourceReference :param secret_version: Version of the secret to be used @@ -1535,9 +1558,6 @@ class CustomerCertificateParameters(Model): _attribute_map = { 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - 'expiration_date': {'key': 'expirationDate', 'type': 'str'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, 'secret_source': {'key': 'secretSource', 'type': 'ResourceReference'}, 'secret_version': {'key': 'secretVersion', 'type': 'str'}, 'certificate_authority': {'key': 'certificateAuthority', 'type': 'str'}, @@ -1547,15 +1567,12 @@ class CustomerCertificateParameters(Model): def __init__(self, **kwargs): super(CustomerCertificateParameters, self).__init__(**kwargs) - self.type = kwargs.get('type', None) - self.subject = kwargs.get('subject', None) - self.expiration_date = kwargs.get('expiration_date', None) - self.thumbprint = kwargs.get('thumbprint', None) self.secret_source = kwargs.get('secret_source', None) self.secret_version = kwargs.get('secret_version', None) self.certificate_authority = kwargs.get('certificate_authority', None) self.use_latest_version = kwargs.get('use_latest_version', None) self.subject_alternative_names = kwargs.get('subject_alternative_names', None) + self.type = 'CustomerCertificate' class CustomRule(Model): @@ -3246,20 +3263,13 @@ def __init__(self, **kwargs): super(ManagedCertificate, self).__init__(**kwargs) -class ManagedCertificateParameters(Model): +class ManagedCertificateParameters(SecretParameters): """Managed Certificate used for https. All required parameters must be populated in order to send to Azure. - :param type: Required. The type of the Secret to create. Possible values - include: 'UrlSigningKey', 'CustomerCertificate', 'ManagedCertificate' - :type type: str or ~azure.mgmt.cdn.models.SecretType - :param subject: Subject name in the certificate. - :type subject: str - :param expiration_date: Certificate expiration date. - :type expiration_date: str - :param thumbprint: Certificate thumbprint. - :type thumbprint: str + :param type: Required. Constant filled by server. + :type type: str """ _validation = { @@ -3268,17 +3278,11 @@ class ManagedCertificateParameters(Model): _attribute_map = { 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - 'expiration_date': {'key': 'expirationDate', 'type': 'str'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, } def __init__(self, **kwargs): super(ManagedCertificateParameters, self).__init__(**kwargs) - self.type = kwargs.get('type', None) - self.subject = kwargs.get('subject', None) - self.expiration_date = kwargs.get('expiration_date', None) - self.thumbprint = kwargs.get('thumbprint', None) + self.type = 'ManagedCertificate' class ManagedRuleDefinition(Model): @@ -5017,21 +5021,13 @@ class Route(ProxyResource): :type patterns_to_match: list[str] :param compression_settings: compression settings. :type compression_settings: object - :param query_string_caching_behavior: Defines how AzureFrontDoor caches - requests that include query strings. You can ignore any query strings when - caching, bypass caching to prevent requests that contain query strings - from being cached, or cache every request with a unique URL. Possible - values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', - 'NotSet' + :param query_string_caching_behavior: Defines how CDN caches requests that + include query strings. You can ignore any query strings when caching, + bypass caching to prevent requests that contain query strings from being + cached, or cache every request with a unique URL. Possible values include: + 'IgnoreQueryString', 'UseQueryString', 'NotSet' :type query_string_caching_behavior: str or - ~azure.mgmt.cdn.models.QueryStringCachingBehavior - :param optimization_type: Specifies what scenario the customer wants this - AzureFrontDoor endpoint to optimize for, e.g. Download, Media services. - With this information, AzureFrontDoor can apply scenario driven - optimization. Possible values include: 'GeneralWebDelivery', - 'GeneralMediaStreaming', 'VideoOnDemandMediaStreaming', - 'LargeFileDownload', 'DynamicSiteAcceleration' - :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType + ~azure.mgmt.cdn.models.AfdQueryStringCachingBehavior :param forwarding_protocol: Protocol this rule will use when forwarding traffic to backends. Possible values include: 'HttpOnly', 'HttpsOnly', 'MatchRequest' @@ -5081,8 +5077,7 @@ class Route(ProxyResource): 'supported_protocols': {'key': 'properties.supportedProtocols', 'type': '[str]'}, 'patterns_to_match': {'key': 'properties.patternsToMatch', 'type': '[str]'}, 'compression_settings': {'key': 'properties.compressionSettings', 'type': 'object'}, - 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'}, - 'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'}, + 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'AfdQueryStringCachingBehavior'}, 'forwarding_protocol': {'key': 'properties.forwardingProtocol', 'type': 'str'}, 'link_to_default_domain': {'key': 'properties.linkToDefaultDomain', 'type': 'str'}, 'https_redirect': {'key': 'properties.httpsRedirect', 'type': 'str'}, @@ -5101,7 +5096,6 @@ def __init__(self, **kwargs): self.patterns_to_match = kwargs.get('patterns_to_match', None) self.compression_settings = kwargs.get('compression_settings', None) self.query_string_caching_behavior = kwargs.get('query_string_caching_behavior', None) - self.optimization_type = kwargs.get('optimization_type', None) self.forwarding_protocol = kwargs.get('forwarding_protocol', None) self.link_to_default_domain = kwargs.get('link_to_default_domain', None) self.https_redirect = kwargs.get('https_redirect', None) @@ -5129,21 +5123,13 @@ class RouteUpdateParameters(Model): :type patterns_to_match: list[str] :param compression_settings: compression settings. :type compression_settings: object - :param query_string_caching_behavior: Defines how AzureFrontDoor caches - requests that include query strings. You can ignore any query strings when - caching, bypass caching to prevent requests that contain query strings - from being cached, or cache every request with a unique URL. Possible - values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', - 'NotSet' + :param query_string_caching_behavior: Defines how CDN caches requests that + include query strings. You can ignore any query strings when caching, + bypass caching to prevent requests that contain query strings from being + cached, or cache every request with a unique URL. Possible values include: + 'IgnoreQueryString', 'UseQueryString', 'NotSet' :type query_string_caching_behavior: str or - ~azure.mgmt.cdn.models.QueryStringCachingBehavior - :param optimization_type: Specifies what scenario the customer wants this - AzureFrontDoor endpoint to optimize for, e.g. Download, Media services. - With this information, AzureFrontDoor can apply scenario driven - optimization. Possible values include: 'GeneralWebDelivery', - 'GeneralMediaStreaming', 'VideoOnDemandMediaStreaming', - 'LargeFileDownload', 'DynamicSiteAcceleration' - :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType + ~azure.mgmt.cdn.models.AfdQueryStringCachingBehavior :param forwarding_protocol: Protocol this rule will use when forwarding traffic to backends. Possible values include: 'HttpOnly', 'HttpsOnly', 'MatchRequest' @@ -5172,8 +5158,7 @@ class RouteUpdateParameters(Model): 'supported_protocols': {'key': 'properties.supportedProtocols', 'type': '[str]'}, 'patterns_to_match': {'key': 'properties.patternsToMatch', 'type': '[str]'}, 'compression_settings': {'key': 'properties.compressionSettings', 'type': 'object'}, - 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'}, - 'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'}, + 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'AfdQueryStringCachingBehavior'}, 'forwarding_protocol': {'key': 'properties.forwardingProtocol', 'type': 'str'}, 'link_to_default_domain': {'key': 'properties.linkToDefaultDomain', 'type': 'str'}, 'https_redirect': {'key': 'properties.httpsRedirect', 'type': 'str'}, @@ -5190,7 +5175,6 @@ def __init__(self, **kwargs): self.patterns_to_match = kwargs.get('patterns_to_match', None) self.compression_settings = kwargs.get('compression_settings', None) self.query_string_caching_behavior = kwargs.get('query_string_caching_behavior', None) - self.optimization_type = kwargs.get('optimization_type', None) self.forwarding_protocol = kwargs.get('forwarding_protocol', None) self.link_to_default_domain = kwargs.get('link_to_default_domain', None) self.https_redirect = kwargs.get('https_redirect', None) @@ -5410,35 +5394,6 @@ def __init__(self, **kwargs): self.parameters = kwargs.get('parameters', None) -class SecretParameters(Model): - """The json object containing secret parameters. - - You probably want to use the sub-classes and not this class directly. Known - sub-classes are: UrlSigningKeyParameters - - All required parameters must be populated in order to send to Azure. - - :param type: Required. Constant filled by server. - :type type: str - """ - - _validation = { - 'type': {'required': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - } - - _subtype_map = { - 'type': {'UrlSigningKey': 'UrlSigningKeyParameters'} - } - - def __init__(self, **kwargs): - super(SecretParameters, self).__init__(**kwargs) - self.type = None - - class SecretProperties(AFDStateProperties): """The JSON object that contains the properties of the Secret to create. @@ -5494,8 +5449,7 @@ class SecurityPolicy(ProxyResource): 'InProgress', 'Succeeded', 'Failed' :vartype deployment_status: str or ~azure.mgmt.cdn.models.DeploymentStatus :param parameters: object which contains security policy parameters - :type parameters: - ~azure.mgmt.cdn.models.SecurityPolicyWebApplicationFirewallParameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters """ _validation = { @@ -5514,7 +5468,7 @@ class SecurityPolicy(ProxyResource): 'system_data': {'key': 'systemData', 'type': 'SystemData'}, 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, 'deployment_status': {'key': 'properties.deploymentStatus', 'type': 'str'}, - 'parameters': {'key': 'properties.parameters', 'type': 'SecurityPolicyWebApplicationFirewallParameters'}, + 'parameters': {'key': 'properties.parameters', 'type': 'SecurityPolicyParameters'}, } def __init__(self, **kwargs): @@ -5553,6 +5507,40 @@ def __init__(self, **kwargs): self.type = None +class SecurityPolicyProperties(AFDStateProperties): + """The json object that contains properties required to create a security + policy. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar provisioning_state: Provisioning status. Possible values include: + 'Succeeded', 'Failed', 'Updating', 'Deleting', 'Creating' + :vartype provisioning_state: str or + ~azure.mgmt.cdn.models.AfdProvisioningState + :ivar deployment_status: Possible values include: 'NotStarted', + 'InProgress', 'Succeeded', 'Failed' + :vartype deployment_status: str or ~azure.mgmt.cdn.models.DeploymentStatus + :param parameters: object which contains security policy parameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters + """ + + _validation = { + 'provisioning_state': {'readonly': True}, + 'deployment_status': {'readonly': True}, + } + + _attribute_map = { + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'deployment_status': {'key': 'deploymentStatus', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'SecurityPolicyParameters'}, + } + + def __init__(self, **kwargs): + super(SecurityPolicyProperties, self).__init__(**kwargs) + self.parameters = kwargs.get('parameters', None) + + class SecurityPolicyWebApplicationFirewallAssociation(Model): """settings for security policy patterns to match. diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models_py3.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models_py3.py index 7d64a4727054..44ed057fd0e0 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models_py3.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/models/_models_py3.py @@ -1501,20 +1501,43 @@ def __init__(self, *, certificate_url: str, subject: str=None, expiration_date: self.subject_alternative_names = subject_alternative_names -class CustomerCertificateParameters(Model): +class SecretParameters(Model): + """The json object containing secret parameters. + + You probably want to use the sub-classes and not this class directly. Known + sub-classes are: UrlSigningKeyParameters, ManagedCertificateParameters, + CustomerCertificateParameters + + All required parameters must be populated in order to send to Azure. + + :param type: Required. Constant filled by server. + :type type: str + """ + + _validation = { + 'type': {'required': True}, + } + + _attribute_map = { + 'type': {'key': 'type', 'type': 'str'}, + } + + _subtype_map = { + 'type': {'UrlSigningKey': 'UrlSigningKeyParameters', 'ManagedCertificate': 'ManagedCertificateParameters', 'CustomerCertificate': 'CustomerCertificateParameters'} + } + + def __init__(self, **kwargs) -> None: + super(SecretParameters, self).__init__(**kwargs) + self.type = None + + +class CustomerCertificateParameters(SecretParameters): """Customer Certificate used for https. All required parameters must be populated in order to send to Azure. - :param type: Required. The type of the Secret to create. Possible values - include: 'UrlSigningKey', 'CustomerCertificate', 'ManagedCertificate' - :type type: str or ~azure.mgmt.cdn.models.SecretType - :param subject: Subject name in the certificate. - :type subject: str - :param expiration_date: Certificate expiration date. - :type expiration_date: str - :param thumbprint: Certificate thumbprint. - :type thumbprint: str + :param type: Required. Constant filled by server. + :type type: str :param secret_source: Required. Resource reference to the KV secret :type secret_source: ~azure.mgmt.cdn.models.ResourceReference :param secret_version: Version of the secret to be used @@ -1535,9 +1558,6 @@ class CustomerCertificateParameters(Model): _attribute_map = { 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - 'expiration_date': {'key': 'expirationDate', 'type': 'str'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, 'secret_source': {'key': 'secretSource', 'type': 'ResourceReference'}, 'secret_version': {'key': 'secretVersion', 'type': 'str'}, 'certificate_authority': {'key': 'certificateAuthority', 'type': 'str'}, @@ -1545,17 +1565,14 @@ class CustomerCertificateParameters(Model): 'subject_alternative_names': {'key': 'subjectAlternativeNames', 'type': '[str]'}, } - def __init__(self, *, type, secret_source, subject: str=None, expiration_date: str=None, thumbprint: str=None, secret_version: str=None, certificate_authority: str=None, use_latest_version: bool=None, subject_alternative_names=None, **kwargs) -> None: + def __init__(self, *, secret_source, secret_version: str=None, certificate_authority: str=None, use_latest_version: bool=None, subject_alternative_names=None, **kwargs) -> None: super(CustomerCertificateParameters, self).__init__(**kwargs) - self.type = type - self.subject = subject - self.expiration_date = expiration_date - self.thumbprint = thumbprint self.secret_source = secret_source self.secret_version = secret_version self.certificate_authority = certificate_authority self.use_latest_version = use_latest_version self.subject_alternative_names = subject_alternative_names + self.type = 'CustomerCertificate' class CustomRule(Model): @@ -3246,20 +3263,13 @@ def __init__(self, *, subject: str=None, expiration_date: str=None, thumbprint: super(ManagedCertificate, self).__init__(subject=subject, expiration_date=expiration_date, thumbprint=thumbprint, **kwargs) -class ManagedCertificateParameters(Model): +class ManagedCertificateParameters(SecretParameters): """Managed Certificate used for https. All required parameters must be populated in order to send to Azure. - :param type: Required. The type of the Secret to create. Possible values - include: 'UrlSigningKey', 'CustomerCertificate', 'ManagedCertificate' - :type type: str or ~azure.mgmt.cdn.models.SecretType - :param subject: Subject name in the certificate. - :type subject: str - :param expiration_date: Certificate expiration date. - :type expiration_date: str - :param thumbprint: Certificate thumbprint. - :type thumbprint: str + :param type: Required. Constant filled by server. + :type type: str """ _validation = { @@ -3268,17 +3278,11 @@ class ManagedCertificateParameters(Model): _attribute_map = { 'type': {'key': 'type', 'type': 'str'}, - 'subject': {'key': 'subject', 'type': 'str'}, - 'expiration_date': {'key': 'expirationDate', 'type': 'str'}, - 'thumbprint': {'key': 'thumbprint', 'type': 'str'}, } - def __init__(self, *, type, subject: str=None, expiration_date: str=None, thumbprint: str=None, **kwargs) -> None: + def __init__(self, **kwargs) -> None: super(ManagedCertificateParameters, self).__init__(**kwargs) - self.type = type - self.subject = subject - self.expiration_date = expiration_date - self.thumbprint = thumbprint + self.type = 'ManagedCertificate' class ManagedRuleDefinition(Model): @@ -5017,21 +5021,13 @@ class Route(ProxyResource): :type patterns_to_match: list[str] :param compression_settings: compression settings. :type compression_settings: object - :param query_string_caching_behavior: Defines how AzureFrontDoor caches - requests that include query strings. You can ignore any query strings when - caching, bypass caching to prevent requests that contain query strings - from being cached, or cache every request with a unique URL. Possible - values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', - 'NotSet' + :param query_string_caching_behavior: Defines how CDN caches requests that + include query strings. You can ignore any query strings when caching, + bypass caching to prevent requests that contain query strings from being + cached, or cache every request with a unique URL. Possible values include: + 'IgnoreQueryString', 'UseQueryString', 'NotSet' :type query_string_caching_behavior: str or - ~azure.mgmt.cdn.models.QueryStringCachingBehavior - :param optimization_type: Specifies what scenario the customer wants this - AzureFrontDoor endpoint to optimize for, e.g. Download, Media services. - With this information, AzureFrontDoor can apply scenario driven - optimization. Possible values include: 'GeneralWebDelivery', - 'GeneralMediaStreaming', 'VideoOnDemandMediaStreaming', - 'LargeFileDownload', 'DynamicSiteAcceleration' - :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType + ~azure.mgmt.cdn.models.AfdQueryStringCachingBehavior :param forwarding_protocol: Protocol this rule will use when forwarding traffic to backends. Possible values include: 'HttpOnly', 'HttpsOnly', 'MatchRequest' @@ -5081,8 +5077,7 @@ class Route(ProxyResource): 'supported_protocols': {'key': 'properties.supportedProtocols', 'type': '[str]'}, 'patterns_to_match': {'key': 'properties.patternsToMatch', 'type': '[str]'}, 'compression_settings': {'key': 'properties.compressionSettings', 'type': 'object'}, - 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'}, - 'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'}, + 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'AfdQueryStringCachingBehavior'}, 'forwarding_protocol': {'key': 'properties.forwardingProtocol', 'type': 'str'}, 'link_to_default_domain': {'key': 'properties.linkToDefaultDomain', 'type': 'str'}, 'https_redirect': {'key': 'properties.httpsRedirect', 'type': 'str'}, @@ -5091,7 +5086,7 @@ class Route(ProxyResource): 'deployment_status': {'key': 'properties.deploymentStatus', 'type': 'str'}, } - def __init__(self, *, origin_group, custom_domains=None, origin_path: str=None, rule_sets=None, supported_protocols=None, patterns_to_match=None, compression_settings=None, query_string_caching_behavior=None, optimization_type=None, forwarding_protocol=None, link_to_default_domain=None, https_redirect=None, enabled_state=None, **kwargs) -> None: + def __init__(self, *, origin_group, custom_domains=None, origin_path: str=None, rule_sets=None, supported_protocols=None, patterns_to_match=None, compression_settings=None, query_string_caching_behavior=None, forwarding_protocol=None, link_to_default_domain=None, https_redirect=None, enabled_state=None, **kwargs) -> None: super(Route, self).__init__(**kwargs) self.custom_domains = custom_domains self.origin_group = origin_group @@ -5101,7 +5096,6 @@ def __init__(self, *, origin_group, custom_domains=None, origin_path: str=None, self.patterns_to_match = patterns_to_match self.compression_settings = compression_settings self.query_string_caching_behavior = query_string_caching_behavior - self.optimization_type = optimization_type self.forwarding_protocol = forwarding_protocol self.link_to_default_domain = link_to_default_domain self.https_redirect = https_redirect @@ -5129,21 +5123,13 @@ class RouteUpdateParameters(Model): :type patterns_to_match: list[str] :param compression_settings: compression settings. :type compression_settings: object - :param query_string_caching_behavior: Defines how AzureFrontDoor caches - requests that include query strings. You can ignore any query strings when - caching, bypass caching to prevent requests that contain query strings - from being cached, or cache every request with a unique URL. Possible - values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', - 'NotSet' + :param query_string_caching_behavior: Defines how CDN caches requests that + include query strings. You can ignore any query strings when caching, + bypass caching to prevent requests that contain query strings from being + cached, or cache every request with a unique URL. Possible values include: + 'IgnoreQueryString', 'UseQueryString', 'NotSet' :type query_string_caching_behavior: str or - ~azure.mgmt.cdn.models.QueryStringCachingBehavior - :param optimization_type: Specifies what scenario the customer wants this - AzureFrontDoor endpoint to optimize for, e.g. Download, Media services. - With this information, AzureFrontDoor can apply scenario driven - optimization. Possible values include: 'GeneralWebDelivery', - 'GeneralMediaStreaming', 'VideoOnDemandMediaStreaming', - 'LargeFileDownload', 'DynamicSiteAcceleration' - :type optimization_type: str or ~azure.mgmt.cdn.models.OptimizationType + ~azure.mgmt.cdn.models.AfdQueryStringCachingBehavior :param forwarding_protocol: Protocol this rule will use when forwarding traffic to backends. Possible values include: 'HttpOnly', 'HttpsOnly', 'MatchRequest' @@ -5172,15 +5158,14 @@ class RouteUpdateParameters(Model): 'supported_protocols': {'key': 'properties.supportedProtocols', 'type': '[str]'}, 'patterns_to_match': {'key': 'properties.patternsToMatch', 'type': '[str]'}, 'compression_settings': {'key': 'properties.compressionSettings', 'type': 'object'}, - 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'QueryStringCachingBehavior'}, - 'optimization_type': {'key': 'properties.optimizationType', 'type': 'str'}, + 'query_string_caching_behavior': {'key': 'properties.queryStringCachingBehavior', 'type': 'AfdQueryStringCachingBehavior'}, 'forwarding_protocol': {'key': 'properties.forwardingProtocol', 'type': 'str'}, 'link_to_default_domain': {'key': 'properties.linkToDefaultDomain', 'type': 'str'}, 'https_redirect': {'key': 'properties.httpsRedirect', 'type': 'str'}, 'enabled_state': {'key': 'properties.enabledState', 'type': 'str'}, } - def __init__(self, *, custom_domains=None, origin_group=None, origin_path: str=None, rule_sets=None, supported_protocols=None, patterns_to_match=None, compression_settings=None, query_string_caching_behavior=None, optimization_type=None, forwarding_protocol=None, link_to_default_domain=None, https_redirect=None, enabled_state=None, **kwargs) -> None: + def __init__(self, *, custom_domains=None, origin_group=None, origin_path: str=None, rule_sets=None, supported_protocols=None, patterns_to_match=None, compression_settings=None, query_string_caching_behavior=None, forwarding_protocol=None, link_to_default_domain=None, https_redirect=None, enabled_state=None, **kwargs) -> None: super(RouteUpdateParameters, self).__init__(**kwargs) self.custom_domains = custom_domains self.origin_group = origin_group @@ -5190,7 +5175,6 @@ def __init__(self, *, custom_domains=None, origin_group=None, origin_path: str=N self.patterns_to_match = patterns_to_match self.compression_settings = compression_settings self.query_string_caching_behavior = query_string_caching_behavior - self.optimization_type = optimization_type self.forwarding_protocol = forwarding_protocol self.link_to_default_domain = link_to_default_domain self.https_redirect = https_redirect @@ -5410,35 +5394,6 @@ def __init__(self, *, parameters=None, **kwargs) -> None: self.parameters = parameters -class SecretParameters(Model): - """The json object containing secret parameters. - - You probably want to use the sub-classes and not this class directly. Known - sub-classes are: UrlSigningKeyParameters - - All required parameters must be populated in order to send to Azure. - - :param type: Required. Constant filled by server. - :type type: str - """ - - _validation = { - 'type': {'required': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - } - - _subtype_map = { - 'type': {'UrlSigningKey': 'UrlSigningKeyParameters'} - } - - def __init__(self, **kwargs) -> None: - super(SecretParameters, self).__init__(**kwargs) - self.type = None - - class SecretProperties(AFDStateProperties): """The JSON object that contains the properties of the Secret to create. @@ -5494,8 +5449,7 @@ class SecurityPolicy(ProxyResource): 'InProgress', 'Succeeded', 'Failed' :vartype deployment_status: str or ~azure.mgmt.cdn.models.DeploymentStatus :param parameters: object which contains security policy parameters - :type parameters: - ~azure.mgmt.cdn.models.SecurityPolicyWebApplicationFirewallParameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters """ _validation = { @@ -5514,7 +5468,7 @@ class SecurityPolicy(ProxyResource): 'system_data': {'key': 'systemData', 'type': 'SystemData'}, 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, 'deployment_status': {'key': 'properties.deploymentStatus', 'type': 'str'}, - 'parameters': {'key': 'properties.parameters', 'type': 'SecurityPolicyWebApplicationFirewallParameters'}, + 'parameters': {'key': 'properties.parameters', 'type': 'SecurityPolicyParameters'}, } def __init__(self, *, parameters=None, **kwargs) -> None: @@ -5553,6 +5507,40 @@ def __init__(self, **kwargs) -> None: self.type = None +class SecurityPolicyProperties(AFDStateProperties): + """The json object that contains properties required to create a security + policy. + + Variables are only populated by the server, and will be ignored when + sending a request. + + :ivar provisioning_state: Provisioning status. Possible values include: + 'Succeeded', 'Failed', 'Updating', 'Deleting', 'Creating' + :vartype provisioning_state: str or + ~azure.mgmt.cdn.models.AfdProvisioningState + :ivar deployment_status: Possible values include: 'NotStarted', + 'InProgress', 'Succeeded', 'Failed' + :vartype deployment_status: str or ~azure.mgmt.cdn.models.DeploymentStatus + :param parameters: object which contains security policy parameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters + """ + + _validation = { + 'provisioning_state': {'readonly': True}, + 'deployment_status': {'readonly': True}, + } + + _attribute_map = { + 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, + 'deployment_status': {'key': 'deploymentStatus', 'type': 'str'}, + 'parameters': {'key': 'parameters', 'type': 'SecurityPolicyParameters'}, + } + + def __init__(self, *, parameters=None, **kwargs) -> None: + super(SecurityPolicyProperties, self).__init__(**kwargs) + self.parameters = parameters + + class SecurityPolicyWebApplicationFirewallAssociation(Model): """settings for security policy patterns to match. diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_custom_domains_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_custom_domains_operations.py index 86e2959220e4..5d2c98ff96d8 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_custom_domains_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_custom_domains_operations.py @@ -26,7 +26,7 @@ class AFDCustomDomainsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -215,7 +215,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -224,6 +224,8 @@ def _create_initial( deserialized = self._deserialize('AFDDomain', response) if response.status_code == 201: deserialized = self._deserialize('AFDDomain', response) + if response.status_code == 202: + deserialized = self._deserialize('AFDDomain', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -434,7 +436,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_endpoints_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_endpoints_operations.py index 8cfd9eccfd18..62b57c3ec187 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_endpoints_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_endpoints_operations.py @@ -26,7 +26,7 @@ class AFDEndpointsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -215,7 +215,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -224,6 +224,8 @@ def _create_initial( deserialized = self._deserialize('AFDEndpoint', response) if response.status_code == 201: deserialized = self._deserialize('AFDEndpoint', response) + if response.status_code == 202: + deserialized = self._deserialize('AFDEndpoint', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -433,7 +435,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origin_groups_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origin_groups_operations.py index 05a9588ed036..145f27067bcf 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origin_groups_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origin_groups_operations.py @@ -26,7 +26,7 @@ class AFDOriginGroupsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -214,7 +214,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -223,6 +223,8 @@ def _create_initial( deserialized = self._deserialize('AFDOriginGroup', response) if response.status_code == 201: deserialized = self._deserialize('AFDOriginGroup', response) + if response.status_code == 202: + deserialized = self._deserialize('AFDOriginGroup', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -426,7 +428,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origins_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origins_operations.py index 18a2b390d635..3b9ed3cccc99 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origins_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_origins_operations.py @@ -26,7 +26,7 @@ class AFDOriginsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -223,7 +223,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -232,6 +232,8 @@ def _create_initial( deserialized = self._deserialize('AFDOrigin', response) if response.status_code == 201: deserialized = self._deserialize('AFDOrigin', response) + if response.status_code == 202: + deserialized = self._deserialize('AFDOrigin', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -445,7 +447,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_profiles_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_profiles_operations.py index 1bf4e8d3b026..db21e839f1bc 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_profiles_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_afd_profiles_operations.py @@ -24,7 +24,7 @@ class AFDProfilesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_custom_domains_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_custom_domains_operations.py index 39145f46c127..e896f243d8ba 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_custom_domains_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_custom_domains_operations.py @@ -26,7 +26,7 @@ class CustomDomainsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_edge_nodes_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_edge_nodes_operations.py index d4fbc8f07f0a..56061d27bc1d 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_edge_nodes_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_edge_nodes_operations.py @@ -24,7 +24,7 @@ class EdgeNodesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_endpoints_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_endpoints_operations.py index 9167752285e3..e88c2ea39d8f 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_endpoints_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_endpoints_operations.py @@ -26,7 +26,7 @@ class EndpointsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_log_analytics_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_log_analytics_operations.py index 4e445ed9a4cd..575b997eaae8 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_log_analytics_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_log_analytics_operations.py @@ -24,7 +24,7 @@ class LogAnalyticsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -147,7 +147,7 @@ def get_log_analytics_rankings( :param metrics: :type metrics: list[str] :param max_ranking: - :type max_ranking: float + :type max_ranking: int :param date_time_begin: :type date_time_begin: datetime :param date_time_end: @@ -179,7 +179,7 @@ def get_log_analytics_rankings( query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') query_parameters['rankings'] = self._serialize.query("rankings", rankings, '[str]', div=',') query_parameters['metrics'] = self._serialize.query("metrics", metrics, '[str]', div=',') - query_parameters['maxRanking'] = self._serialize.query("max_ranking", max_ranking, 'float') + query_parameters['maxRanking'] = self._serialize.query("max_ranking", max_ranking, 'int') query_parameters['dateTimeBegin'] = self._serialize.query("date_time_begin", date_time_begin, 'iso-8601') query_parameters['dateTimeEnd'] = self._serialize.query("date_time_end", date_time_end, 'iso-8601') if custom_domains is not None: @@ -440,7 +440,7 @@ def get_waf_log_analytics_rankings( :param date_time_end: :type date_time_end: datetime :param max_ranking: - :type max_ranking: float + :type max_ranking: int :param rankings: :type rankings: list[str] :param actions: @@ -473,7 +473,7 @@ def get_waf_log_analytics_rankings( query_parameters['metrics'] = self._serialize.query("metrics", metrics, '[str]', div=',') query_parameters['dateTimeBegin'] = self._serialize.query("date_time_begin", date_time_begin, 'iso-8601') query_parameters['dateTimeEnd'] = self._serialize.query("date_time_end", date_time_end, 'iso-8601') - query_parameters['maxRanking'] = self._serialize.query("max_ranking", max_ranking, 'float') + query_parameters['maxRanking'] = self._serialize.query("max_ranking", max_ranking, 'int') query_parameters['rankings'] = self._serialize.query("rankings", rankings, '[str]', div=',') if actions is not None: query_parameters['actions'] = self._serialize.query("actions", actions, '[str]', div=',') diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_managed_rule_sets_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_managed_rule_sets_operations.py index 97f632d5c08e..f6510fa75cc2 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_managed_rule_sets_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_managed_rule_sets_operations.py @@ -24,7 +24,7 @@ class ManagedRuleSetsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2019-09-01. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_operations.py index 4e7a6589eb78..80043c6b05c5 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_operations.py @@ -24,7 +24,7 @@ class Operations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origin_groups_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origin_groups_operations.py index 05c76d06f9ea..1070e2097077 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origin_groups_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origin_groups_operations.py @@ -26,7 +26,7 @@ class OriginGroupsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origins_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origins_operations.py index a2ada82c5a64..fef5e6c141b4 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origins_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_origins_operations.py @@ -26,7 +26,7 @@ class OriginsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_policies_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_policies_operations.py index ffdc0647524a..ad765c9a90a7 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_policies_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_policies_operations.py @@ -27,7 +27,7 @@ class PoliciesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2019-09-01. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_profiles_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_profiles_operations.py index 72f5d550787c..5e01a5717cc1 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_profiles_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_profiles_operations.py @@ -26,7 +26,7 @@ class ProfilesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_resource_usage_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_resource_usage_operations.py index e5870dd55ab8..fa6683a72f4e 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_resource_usage_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_resource_usage_operations.py @@ -24,7 +24,7 @@ class ResourceUsageOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_routes_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_routes_operations.py index 32088b1f70c0..743231a78a91 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_routes_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_routes_operations.py @@ -26,7 +26,7 @@ class RoutesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -224,7 +224,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -233,6 +233,8 @@ def _create_initial( deserialized = self._deserialize('Route', response) if response.status_code == 201: deserialized = self._deserialize('Route', response) + if response.status_code == 202: + deserialized = self._deserialize('Route', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -447,7 +449,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rule_sets_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rule_sets_operations.py index 892b484bc6c4..b97da5fa1618 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rule_sets_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rule_sets_operations.py @@ -26,7 +26,7 @@ class RuleSetsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -183,7 +183,7 @@ def get( def _create_initial( self, resource_group_name, profile_name, rule_set_name, custom_headers=None, raw=False, **operation_config): - rule_set = None + rule_set = {} # Construct URL url = self.create.metadata['url'] @@ -217,7 +217,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -226,6 +226,8 @@ def _create_initial( deserialized = self._deserialize('RuleSet', response) if response.status_code == 201: deserialized = self._deserialize('RuleSet', response) + if response.status_code == 202: + deserialized = self._deserialize('RuleSet', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rules_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rules_operations.py index b5cfe70a2de9..ecdc75b46eff 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rules_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_rules_operations.py @@ -26,7 +26,7 @@ class RulesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -220,7 +220,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -229,6 +229,8 @@ def _create_initial( deserialized = self._deserialize('Rule', response) if response.status_code == 201: deserialized = self._deserialize('Rule', response) + if response.status_code == 202: + deserialized = self._deserialize('Rule', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -440,7 +442,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_secrets_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_secrets_operations.py index 4fa09ec2c18b..b424b5e5296c 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_secrets_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_secrets_operations.py @@ -26,7 +26,7 @@ class SecretsOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -215,7 +215,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -224,6 +224,8 @@ def _create_initial( deserialized = self._deserialize('Secret', response) if response.status_code == 201: deserialized = self._deserialize('Secret', response) + if response.status_code == 202: + deserialized = self._deserialize('Secret', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -426,7 +428,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_security_policies_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_security_policies_operations.py index 7bd985045447..bc049f634063 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_security_policies_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_security_policies_operations.py @@ -26,7 +26,7 @@ class SecurityPoliciesOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models @@ -216,7 +216,7 @@ def _create_initial( request = self._client.put(url, query_parameters, header_parameters, body_content) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 201]: + if response.status_code not in [200, 201, 202]: raise models.AfdErrorResponseException(self._deserialize, response) deserialized = None @@ -225,6 +225,8 @@ def _create_initial( deserialized = self._deserialize('SecurityPolicy', response) if response.status_code == 201: deserialized = self._deserialize('SecurityPolicy', response) + if response.status_code == 202: + deserialized = self._deserialize('SecurityPolicy', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) @@ -246,8 +248,7 @@ def create( profile. :type security_policy_name: str :param parameters: object which contains security policy parameters - :type parameters: - ~azure.mgmt.cdn.models.SecurityPolicyWebApplicationFirewallParameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -292,7 +293,9 @@ def get_long_running_output(response): def _patch_initial( - self, resource_group_name, profile_name, security_policy_name, security_policy_parameters, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, profile_name, security_policy_name, parameters=None, custom_headers=None, raw=False, **operation_config): + security_policy_properties = models.SecurityPolicyProperties(parameters=parameters) + # Construct URL url = self.patch.metadata['url'] path_format_arguments = { @@ -319,7 +322,7 @@ def _patch_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(security_policy_parameters, 'SecurityPolicyWebApplicationFirewallParameters') + body_content = self._serialize.body(security_policy_properties, 'SecurityPolicyProperties') # Construct and send request request = self._client.patch(url, query_parameters, header_parameters, body_content) @@ -342,7 +345,7 @@ def _patch_initial( return deserialized def patch( - self, resource_group_name, profile_name, security_policy_name, security_policy_parameters, custom_headers=None, raw=False, polling=True, **operation_config): + self, resource_group_name, profile_name, security_policy_name, parameters=None, custom_headers=None, raw=False, polling=True, **operation_config): """Updates an existing Secret within a profile. :param resource_group_name: Name of the Resource group within the @@ -354,9 +357,8 @@ def patch( :param security_policy_name: Name of the security policy under the profile. :type security_policy_name: str - :param security_policy_parameters: Security policy update properties - :type security_policy_parameters: - ~azure.mgmt.cdn.models.SecurityPolicyWebApplicationFirewallParameters + :param parameters: object which contains security policy parameters + :type parameters: ~azure.mgmt.cdn.models.SecurityPolicyParameters :param dict custom_headers: headers that will be added to the request :param bool raw: The poller return type is ClientRawResponse, the direct response alongside the deserialized response @@ -375,7 +377,7 @@ def patch( resource_group_name=resource_group_name, profile_name=profile_name, security_policy_name=security_policy_name, - security_policy_parameters=security_policy_parameters, + parameters=parameters, custom_headers=custom_headers, raw=True, **operation_config @@ -429,7 +431,7 @@ def _delete_initial( request = self._client.delete(url, query_parameters, header_parameters) response = self._client.send(request, stream=False, **operation_config) - if response.status_code not in [200, 204]: + if response.status_code not in [200, 202, 204]: raise models.AfdErrorResponseException(self._deserialize, response) if raw: diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_validate_operations.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_validate_operations.py index f712f1b96bd5..2fbe98990b9b 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_validate_operations.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/operations/_validate_operations.py @@ -24,7 +24,7 @@ class ValidateOperations(object): :param config: Configuration of service client. :param serializer: An object model serializer. :param deserializer: An object model deserializer. - :ivar api_version: Version of the API to be used with the client request. Current version is 2017-04-02. Constant value: "2020-09-01". + :ivar api_version: Version of the API to be used with the client request. Current version is 2020-09-01. Constant value: "2020-09-01". """ models = models diff --git a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/version.py b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/version.py index 37725706ef72..785988ce8633 100644 --- a/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/version.py +++ b/sdk/cdn/azure-mgmt-cdn/azure/mgmt/cdn/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "6.0.0" +VERSION = "7.0.0"