diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/EndpointsOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/EndpointsOperations.cs
index 90c1757a29b7..ffd4e82741dd 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/EndpointsOperations.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/EndpointsOperations.cs
@@ -163,7 +163,7 @@ internal EndpointsOperations(FrontDoorManagementClient client)
{
contentFilePaths.Validate();
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClient.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClient.cs
index d8636ec3a54b..54aed6c0fca7 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClient.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClient.cs
@@ -20,8 +20,6 @@ namespace Microsoft.Azure.Management.FrontDoor
using System.Linq;
using System.Net;
using System.Net.Http;
- using System.Threading;
- using System.Threading.Tasks;
///
/// FrontDoor Client
@@ -93,6 +91,16 @@ public partial class FrontDoorManagementClient : ServiceClient
public virtual IReportsOperations Reports { get; private set; }
+ ///
+ /// Gets the IFrontDoorNameAvailabilityOperations.
+ ///
+ public virtual IFrontDoorNameAvailabilityOperations FrontDoorNameAvailability { get; private set; }
+
+ ///
+ /// Gets the IFrontDoorNameAvailabilityWithSubscriptionOperations.
+ ///
+ public virtual IFrontDoorNameAvailabilityWithSubscriptionOperations FrontDoorNameAvailabilityWithSubscription { get; private set; }
+
///
/// Gets the IFrontDoorsOperations.
///
@@ -368,6 +376,8 @@ private void Initialize()
PreconfiguredEndpoints = new PreconfiguredEndpointsOperations(this);
Experiments = new ExperimentsOperations(this);
Reports = new ReportsOperations(this);
+ FrontDoorNameAvailability = new FrontDoorNameAvailabilityOperations(this);
+ FrontDoorNameAvailabilityWithSubscription = new FrontDoorNameAvailabilityWithSubscriptionOperations(this);
FrontDoors = new FrontDoorsOperations(this);
FrontendEndpoints = new FrontendEndpointsOperations(this);
Endpoints = new EndpointsOperations(this);
@@ -410,378 +420,5 @@ private void Initialize()
DeserializationSettings.Converters.Add(new TransformationJsonConverter());
DeserializationSettings.Converters.Add(new CloudErrorJsonConverter());
}
- ///
- /// Check the availability of a Front Door resource name.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// Headers that will be added to request.
- ///
- ///
- /// The cancellation token.
- ///
- ///
- /// Thrown when the operation returned an invalid status code
- ///
- ///
- /// Thrown when unable to deserialize the response
- ///
- ///
- /// Thrown when a required parameter is null
- ///
- ///
- /// Thrown when a required parameter is null
- ///
- ///
- /// A response object containing the response body and response headers.
- ///
- public async Task> CheckFrontDoorNameAvailabilityWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken))
- {
- if (checkFrontDoorNameAvailabilityInput == null)
- {
- throw new ValidationException(ValidationRules.CannotBeNull, "checkFrontDoorNameAvailabilityInput");
- }
- if (checkFrontDoorNameAvailabilityInput != null)
- {
- checkFrontDoorNameAvailabilityInput.Validate();
- }
- string apiVersion = "2020-01-01";
- // Tracing
- bool _shouldTrace = ServiceClientTracing.IsEnabled;
- string _invocationId = null;
- if (_shouldTrace)
- {
- _invocationId = ServiceClientTracing.NextInvocationId.ToString();
- Dictionary tracingParameters = new Dictionary();
- tracingParameters.Add("checkFrontDoorNameAvailabilityInput", checkFrontDoorNameAvailabilityInput);
- tracingParameters.Add("apiVersion", apiVersion);
- tracingParameters.Add("cancellationToken", cancellationToken);
- ServiceClientTracing.Enter(_invocationId, this, "CheckFrontDoorNameAvailability", tracingParameters);
- }
- // Construct URL
- var _baseUrl = BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "providers/Microsoft.Network/checkFrontDoorNameAvailability").ToString();
- List _queryParameters = new List();
- if (apiVersion != null)
- {
- _queryParameters.Add(string.Format("api-version={0}", System.Uri.EscapeDataString(apiVersion)));
- }
- if (_queryParameters.Count > 0)
- {
- _url += (_url.Contains("?") ? "&" : "?") + string.Join("&", _queryParameters);
- }
- // Create HTTP transport objects
- var _httpRequest = new HttpRequestMessage();
- HttpResponseMessage _httpResponse = null;
- _httpRequest.Method = new HttpMethod("POST");
- _httpRequest.RequestUri = new System.Uri(_url);
- // Set Headers
- if (GenerateClientRequestId != null && GenerateClientRequestId.Value)
- {
- _httpRequest.Headers.TryAddWithoutValidation("x-ms-client-request-id", System.Guid.NewGuid().ToString());
- }
- if (AcceptLanguage != null)
- {
- if (_httpRequest.Headers.Contains("accept-language"))
- {
- _httpRequest.Headers.Remove("accept-language");
- }
- _httpRequest.Headers.TryAddWithoutValidation("accept-language", AcceptLanguage);
- }
-
-
- if (customHeaders != null)
- {
- foreach(var _header in customHeaders)
- {
- if (_httpRequest.Headers.Contains(_header.Key))
- {
- _httpRequest.Headers.Remove(_header.Key);
- }
- _httpRequest.Headers.TryAddWithoutValidation(_header.Key, _header.Value);
- }
- }
-
- // Serialize Request
- string _requestContent = null;
- if(checkFrontDoorNameAvailabilityInput != null)
- {
- _requestContent = SafeJsonConvert.SerializeObject(checkFrontDoorNameAvailabilityInput, SerializationSettings);
- _httpRequest.Content = new StringContent(_requestContent, System.Text.Encoding.UTF8);
- _httpRequest.Content.Headers.ContentType =System.Net.Http.Headers.MediaTypeHeaderValue.Parse("application/json; charset=utf-8");
- }
- // Set Credentials
- if (Credentials != null)
- {
- cancellationToken.ThrowIfCancellationRequested();
- await Credentials.ProcessHttpRequestAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
- }
- // Send Request
- if (_shouldTrace)
- {
- ServiceClientTracing.SendRequest(_invocationId, _httpRequest);
- }
- cancellationToken.ThrowIfCancellationRequested();
- _httpResponse = await HttpClient.SendAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
- if (_shouldTrace)
- {
- ServiceClientTracing.ReceiveResponse(_invocationId, _httpResponse);
- }
- HttpStatusCode _statusCode = _httpResponse.StatusCode;
- cancellationToken.ThrowIfCancellationRequested();
- string _responseContent = null;
- if ((int)_statusCode != 200)
- {
- var ex = new ErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
- try
- {
- _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- ErrorResponse _errorBody = SafeJsonConvert.DeserializeObject(_responseContent, DeserializationSettings);
- if (_errorBody != null)
- {
- ex.Body = _errorBody;
- }
- }
- catch (JsonException)
- {
- // Ignore the exception
- }
- ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
- ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_shouldTrace)
- {
- ServiceClientTracing.Error(_invocationId, ex);
- }
- _httpRequest.Dispose();
- if (_httpResponse != null)
- {
- _httpResponse.Dispose();
- }
- throw ex;
- }
- // Create Result
- var _result = new AzureOperationResponse();
- _result.Request = _httpRequest;
- _result.Response = _httpResponse;
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- _result.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
- // Deserialize Response
- if ((int)_statusCode == 200)
- {
- _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- try
- {
- _result.Body = SafeJsonConvert.DeserializeObject(_responseContent, DeserializationSettings);
- }
- catch (JsonException ex)
- {
- _httpRequest.Dispose();
- if (_httpResponse != null)
- {
- _httpResponse.Dispose();
- }
- throw new SerializationException("Unable to deserialize the response.", _responseContent, ex);
- }
- }
- if (_shouldTrace)
- {
- ServiceClientTracing.Exit(_invocationId, _result);
- }
- return _result;
- }
-
- ///
- /// Check the availability of a Front Door subdomain.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// Headers that will be added to request.
- ///
- ///
- /// The cancellation token.
- ///
- ///
- /// Thrown when the operation returned an invalid status code
- ///
- ///
- /// Thrown when unable to deserialize the response
- ///
- ///
- /// Thrown when a required parameter is null
- ///
- ///
- /// Thrown when a required parameter is null
- ///
- ///
- /// A response object containing the response body and response headers.
- ///
- public async Task> CheckFrontDoorNameAvailabilityWithSubscriptionWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken))
- {
- if (checkFrontDoorNameAvailabilityInput == null)
- {
- throw new ValidationException(ValidationRules.CannotBeNull, "checkFrontDoorNameAvailabilityInput");
- }
- if (checkFrontDoorNameAvailabilityInput != null)
- {
- checkFrontDoorNameAvailabilityInput.Validate();
- }
- if (SubscriptionId == null)
- {
- throw new ValidationException(ValidationRules.CannotBeNull, "this.SubscriptionId");
- }
- string apiVersion = "2020-01-01";
- // Tracing
- bool _shouldTrace = ServiceClientTracing.IsEnabled;
- string _invocationId = null;
- if (_shouldTrace)
- {
- _invocationId = ServiceClientTracing.NextInvocationId.ToString();
- Dictionary tracingParameters = new Dictionary();
- tracingParameters.Add("checkFrontDoorNameAvailabilityInput", checkFrontDoorNameAvailabilityInput);
- tracingParameters.Add("apiVersion", apiVersion);
- tracingParameters.Add("cancellationToken", cancellationToken);
- ServiceClientTracing.Enter(_invocationId, this, "CheckFrontDoorNameAvailabilityWithSubscription", tracingParameters);
- }
- // Construct URL
- var _baseUrl = BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/providers/Microsoft.Network/checkFrontDoorNameAvailability").ToString();
- _url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(SubscriptionId));
- List _queryParameters = new List();
- if (apiVersion != null)
- {
- _queryParameters.Add(string.Format("api-version={0}", System.Uri.EscapeDataString(apiVersion)));
- }
- if (_queryParameters.Count > 0)
- {
- _url += (_url.Contains("?") ? "&" : "?") + string.Join("&", _queryParameters);
- }
- // Create HTTP transport objects
- var _httpRequest = new HttpRequestMessage();
- HttpResponseMessage _httpResponse = null;
- _httpRequest.Method = new HttpMethod("POST");
- _httpRequest.RequestUri = new System.Uri(_url);
- // Set Headers
- if (GenerateClientRequestId != null && GenerateClientRequestId.Value)
- {
- _httpRequest.Headers.TryAddWithoutValidation("x-ms-client-request-id", System.Guid.NewGuid().ToString());
- }
- if (AcceptLanguage != null)
- {
- if (_httpRequest.Headers.Contains("accept-language"))
- {
- _httpRequest.Headers.Remove("accept-language");
- }
- _httpRequest.Headers.TryAddWithoutValidation("accept-language", AcceptLanguage);
- }
-
-
- if (customHeaders != null)
- {
- foreach(var _header in customHeaders)
- {
- if (_httpRequest.Headers.Contains(_header.Key))
- {
- _httpRequest.Headers.Remove(_header.Key);
- }
- _httpRequest.Headers.TryAddWithoutValidation(_header.Key, _header.Value);
- }
- }
-
- // Serialize Request
- string _requestContent = null;
- if(checkFrontDoorNameAvailabilityInput != null)
- {
- _requestContent = SafeJsonConvert.SerializeObject(checkFrontDoorNameAvailabilityInput, SerializationSettings);
- _httpRequest.Content = new StringContent(_requestContent, System.Text.Encoding.UTF8);
- _httpRequest.Content.Headers.ContentType =System.Net.Http.Headers.MediaTypeHeaderValue.Parse("application/json; charset=utf-8");
- }
- // Set Credentials
- if (Credentials != null)
- {
- cancellationToken.ThrowIfCancellationRequested();
- await Credentials.ProcessHttpRequestAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
- }
- // Send Request
- if (_shouldTrace)
- {
- ServiceClientTracing.SendRequest(_invocationId, _httpRequest);
- }
- cancellationToken.ThrowIfCancellationRequested();
- _httpResponse = await HttpClient.SendAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
- if (_shouldTrace)
- {
- ServiceClientTracing.ReceiveResponse(_invocationId, _httpResponse);
- }
- HttpStatusCode _statusCode = _httpResponse.StatusCode;
- cancellationToken.ThrowIfCancellationRequested();
- string _responseContent = null;
- if ((int)_statusCode != 200)
- {
- var ex = new ErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
- try
- {
- _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- ErrorResponse _errorBody = SafeJsonConvert.DeserializeObject(_responseContent, DeserializationSettings);
- if (_errorBody != null)
- {
- ex.Body = _errorBody;
- }
- }
- catch (JsonException)
- {
- // Ignore the exception
- }
- ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
- ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_shouldTrace)
- {
- ServiceClientTracing.Error(_invocationId, ex);
- }
- _httpRequest.Dispose();
- if (_httpResponse != null)
- {
- _httpResponse.Dispose();
- }
- throw ex;
- }
- // Create Result
- var _result = new AzureOperationResponse();
- _result.Request = _httpRequest;
- _result.Response = _httpResponse;
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- _result.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
- // Deserialize Response
- if ((int)_statusCode == 200)
- {
- _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- try
- {
- _result.Body = SafeJsonConvert.DeserializeObject(_responseContent, DeserializationSettings);
- }
- catch (JsonException ex)
- {
- _httpRequest.Dispose();
- if (_httpResponse != null)
- {
- _httpResponse.Dispose();
- }
- throw new SerializationException("Unable to deserialize the response.", _responseContent, ex);
- }
- }
- if (_shouldTrace)
- {
- ServiceClientTracing.Exit(_invocationId, _result);
- }
- return _result;
- }
-
}
}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClientExtensions.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClientExtensions.cs
deleted file mode 100644
index a1f19b5ecc2a..000000000000
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorManagementClientExtensions.cs
+++ /dev/null
@@ -1,93 +0,0 @@
-//
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License. See License.txt in the project root for
-// license information.
-//
-// Code generated by Microsoft (R) AutoRest Code Generator.
-// Changes may cause incorrect behavior and will be lost if the code is
-// regenerated.
-//
-
-namespace Microsoft.Azure.Management.FrontDoor
-{
- using Microsoft.Rest;
- using Microsoft.Rest.Azure;
- using Models;
- using System.Threading;
- using System.Threading.Tasks;
-
- ///
- /// Extension methods for FrontDoorManagementClient.
- ///
- public static partial class FrontDoorManagementClientExtensions
- {
- ///
- /// Check the availability of a Front Door resource name.
- ///
- ///
- /// The operations group for this extension method.
- ///
- ///
- /// Input to check.
- ///
- public static CheckNameAvailabilityOutput CheckFrontDoorNameAvailability(this IFrontDoorManagementClient operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput)
- {
- return operations.CheckFrontDoorNameAvailabilityAsync(checkFrontDoorNameAvailabilityInput).GetAwaiter().GetResult();
- }
-
- ///
- /// Check the availability of a Front Door resource name.
- ///
- ///
- /// The operations group for this extension method.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// The cancellation token.
- ///
- public static async Task CheckFrontDoorNameAvailabilityAsync(this IFrontDoorManagementClient operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, CancellationToken cancellationToken = default(CancellationToken))
- {
- using (var _result = await operations.CheckFrontDoorNameAvailabilityWithHttpMessagesAsync(checkFrontDoorNameAvailabilityInput, null, cancellationToken).ConfigureAwait(false))
- {
- return _result.Body;
- }
- }
-
- ///
- /// Check the availability of a Front Door subdomain.
- ///
- ///
- /// The operations group for this extension method.
- ///
- ///
- /// Input to check.
- ///
- public static CheckNameAvailabilityOutput CheckFrontDoorNameAvailabilityWithSubscription(this IFrontDoorManagementClient operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput)
- {
- return operations.CheckFrontDoorNameAvailabilityWithSubscriptionAsync(checkFrontDoorNameAvailabilityInput).GetAwaiter().GetResult();
- }
-
- ///
- /// Check the availability of a Front Door subdomain.
- ///
- ///
- /// The operations group for this extension method.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// The cancellation token.
- ///
- public static async Task CheckFrontDoorNameAvailabilityWithSubscriptionAsync(this IFrontDoorManagementClient operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, CancellationToken cancellationToken = default(CancellationToken))
- {
- using (var _result = await operations.CheckFrontDoorNameAvailabilityWithSubscriptionWithHttpMessagesAsync(checkFrontDoorNameAvailabilityInput, null, cancellationToken).ConfigureAwait(false))
- {
- return _result.Body;
- }
- }
-
- }
-}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperations.cs
new file mode 100644
index 000000000000..2a257d126651
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperations.cs
@@ -0,0 +1,238 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using Newtonsoft.Json;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Linq;
+ using System.Net;
+ using System.Net.Http;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// FrontDoorNameAvailabilityOperations operations.
+ ///
+ internal partial class FrontDoorNameAvailabilityOperations : IServiceOperations, IFrontDoorNameAvailabilityOperations
+ {
+ ///
+ /// Initializes a new instance of the FrontDoorNameAvailabilityOperations class.
+ ///
+ ///
+ /// Reference to the service client.
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ internal FrontDoorNameAvailabilityOperations(FrontDoorManagementClient client)
+ {
+ if (client == null)
+ {
+ throw new System.ArgumentNullException("client");
+ }
+ Client = client;
+ }
+
+ ///
+ /// Gets a reference to the FrontDoorManagementClient
+ ///
+ public FrontDoorManagementClient Client { get; private set; }
+
+ ///
+ /// Check the availability of a Front Door resource name.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// Headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ ///
+ /// Thrown when the operation returned an invalid status code
+ ///
+ ///
+ /// Thrown when unable to deserialize the response
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ ///
+ /// A response object containing the response body and response headers.
+ ///
+ public async Task> CheckWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ if (checkFrontDoorNameAvailabilityInput == null)
+ {
+ throw new ValidationException(ValidationRules.CannotBeNull, "checkFrontDoorNameAvailabilityInput");
+ }
+ if (checkFrontDoorNameAvailabilityInput != null)
+ {
+ checkFrontDoorNameAvailabilityInput.Validate();
+ }
+ string apiVersion = "2020-05-01";
+ // Tracing
+ bool _shouldTrace = ServiceClientTracing.IsEnabled;
+ string _invocationId = null;
+ if (_shouldTrace)
+ {
+ _invocationId = ServiceClientTracing.NextInvocationId.ToString();
+ Dictionary tracingParameters = new Dictionary();
+ tracingParameters.Add("checkFrontDoorNameAvailabilityInput", checkFrontDoorNameAvailabilityInput);
+ tracingParameters.Add("apiVersion", apiVersion);
+ tracingParameters.Add("cancellationToken", cancellationToken);
+ ServiceClientTracing.Enter(_invocationId, this, "Check", tracingParameters);
+ }
+ // Construct URL
+ var _baseUrl = Client.BaseUri.AbsoluteUri;
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "providers/Microsoft.Network/checkFrontDoorNameAvailability").ToString();
+ List _queryParameters = new List();
+ if (apiVersion != null)
+ {
+ _queryParameters.Add(string.Format("api-version={0}", System.Uri.EscapeDataString(apiVersion)));
+ }
+ if (_queryParameters.Count > 0)
+ {
+ _url += (_url.Contains("?") ? "&" : "?") + string.Join("&", _queryParameters);
+ }
+ // Create HTTP transport objects
+ var _httpRequest = new HttpRequestMessage();
+ HttpResponseMessage _httpResponse = null;
+ _httpRequest.Method = new HttpMethod("POST");
+ _httpRequest.RequestUri = new System.Uri(_url);
+ // Set Headers
+ if (Client.GenerateClientRequestId != null && Client.GenerateClientRequestId.Value)
+ {
+ _httpRequest.Headers.TryAddWithoutValidation("x-ms-client-request-id", System.Guid.NewGuid().ToString());
+ }
+ if (Client.AcceptLanguage != null)
+ {
+ if (_httpRequest.Headers.Contains("accept-language"))
+ {
+ _httpRequest.Headers.Remove("accept-language");
+ }
+ _httpRequest.Headers.TryAddWithoutValidation("accept-language", Client.AcceptLanguage);
+ }
+
+
+ if (customHeaders != null)
+ {
+ foreach(var _header in customHeaders)
+ {
+ if (_httpRequest.Headers.Contains(_header.Key))
+ {
+ _httpRequest.Headers.Remove(_header.Key);
+ }
+ _httpRequest.Headers.TryAddWithoutValidation(_header.Key, _header.Value);
+ }
+ }
+
+ // Serialize Request
+ string _requestContent = null;
+ if(checkFrontDoorNameAvailabilityInput != null)
+ {
+ _requestContent = Rest.Serialization.SafeJsonConvert.SerializeObject(checkFrontDoorNameAvailabilityInput, Client.SerializationSettings);
+ _httpRequest.Content = new StringContent(_requestContent, System.Text.Encoding.UTF8);
+ _httpRequest.Content.Headers.ContentType =System.Net.Http.Headers.MediaTypeHeaderValue.Parse("application/json; charset=utf-8");
+ }
+ // Set Credentials
+ if (Client.Credentials != null)
+ {
+ cancellationToken.ThrowIfCancellationRequested();
+ await Client.Credentials.ProcessHttpRequestAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
+ }
+ // Send Request
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.SendRequest(_invocationId, _httpRequest);
+ }
+ cancellationToken.ThrowIfCancellationRequested();
+ _httpResponse = await Client.HttpClient.SendAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.ReceiveResponse(_invocationId, _httpResponse);
+ }
+ HttpStatusCode _statusCode = _httpResponse.StatusCode;
+ cancellationToken.ThrowIfCancellationRequested();
+ string _responseContent = null;
+ if ((int)_statusCode != 200)
+ {
+ var ex = new ErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ try
+ {
+ _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
+ ErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ if (_errorBody != null)
+ {
+ ex.Body = _errorBody;
+ }
+ }
+ catch (JsonException)
+ {
+ // Ignore the exception
+ }
+ ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
+ ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.Error(_invocationId, ex);
+ }
+ _httpRequest.Dispose();
+ if (_httpResponse != null)
+ {
+ _httpResponse.Dispose();
+ }
+ throw ex;
+ }
+ // Create Result
+ var _result = new AzureOperationResponse();
+ _result.Request = _httpRequest;
+ _result.Response = _httpResponse;
+ if (_httpResponse.Headers.Contains("x-ms-request-id"))
+ {
+ _result.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
+ }
+ // Deserialize Response
+ if ((int)_statusCode == 200)
+ {
+ _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
+ try
+ {
+ _result.Body = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ }
+ catch (JsonException ex)
+ {
+ _httpRequest.Dispose();
+ if (_httpResponse != null)
+ {
+ _httpResponse.Dispose();
+ }
+ throw new SerializationException("Unable to deserialize the response.", _responseContent, ex);
+ }
+ }
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.Exit(_invocationId, _result);
+ }
+ return _result;
+ }
+
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperationsExtensions.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperationsExtensions.cs
new file mode 100644
index 000000000000..25efaec632b7
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityOperationsExtensions.cs
@@ -0,0 +1,59 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// Extension methods for FrontDoorNameAvailabilityOperations.
+ ///
+ public static partial class FrontDoorNameAvailabilityOperationsExtensions
+ {
+ ///
+ /// Check the availability of a Front Door resource name.
+ ///
+ ///
+ /// The operations group for this extension method.
+ ///
+ ///
+ /// Input to check.
+ ///
+ public static CheckNameAvailabilityOutput Check(this IFrontDoorNameAvailabilityOperations operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput)
+ {
+ return operations.CheckAsync(checkFrontDoorNameAvailabilityInput).GetAwaiter().GetResult();
+ }
+
+ ///
+ /// Check the availability of a Front Door resource name.
+ ///
+ ///
+ /// The operations group for this extension method.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ public static async Task CheckAsync(this IFrontDoorNameAvailabilityOperations operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ using (var _result = await operations.CheckWithHttpMessagesAsync(checkFrontDoorNameAvailabilityInput, null, cancellationToken).ConfigureAwait(false))
+ {
+ return _result.Body;
+ }
+ }
+
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperations.cs
new file mode 100644
index 000000000000..972d1fc80307
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperations.cs
@@ -0,0 +1,243 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using Newtonsoft.Json;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Linq;
+ using System.Net;
+ using System.Net.Http;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// FrontDoorNameAvailabilityWithSubscriptionOperations operations.
+ ///
+ internal partial class FrontDoorNameAvailabilityWithSubscriptionOperations : IServiceOperations, IFrontDoorNameAvailabilityWithSubscriptionOperations
+ {
+ ///
+ /// Initializes a new instance of the FrontDoorNameAvailabilityWithSubscriptionOperations class.
+ ///
+ ///
+ /// Reference to the service client.
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ internal FrontDoorNameAvailabilityWithSubscriptionOperations(FrontDoorManagementClient client)
+ {
+ if (client == null)
+ {
+ throw new System.ArgumentNullException("client");
+ }
+ Client = client;
+ }
+
+ ///
+ /// Gets a reference to the FrontDoorManagementClient
+ ///
+ public FrontDoorManagementClient Client { get; private set; }
+
+ ///
+ /// Check the availability of a Front Door subdomain.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// Headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ ///
+ /// Thrown when the operation returned an invalid status code
+ ///
+ ///
+ /// Thrown when unable to deserialize the response
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ ///
+ /// A response object containing the response body and response headers.
+ ///
+ public async Task> CheckWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ if (checkFrontDoorNameAvailabilityInput == null)
+ {
+ throw new ValidationException(ValidationRules.CannotBeNull, "checkFrontDoorNameAvailabilityInput");
+ }
+ if (checkFrontDoorNameAvailabilityInput != null)
+ {
+ checkFrontDoorNameAvailabilityInput.Validate();
+ }
+ if (Client.SubscriptionId == null)
+ {
+ throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
+ }
+ string apiVersion = "2020-05-01";
+ // Tracing
+ bool _shouldTrace = ServiceClientTracing.IsEnabled;
+ string _invocationId = null;
+ if (_shouldTrace)
+ {
+ _invocationId = ServiceClientTracing.NextInvocationId.ToString();
+ Dictionary tracingParameters = new Dictionary();
+ tracingParameters.Add("checkFrontDoorNameAvailabilityInput", checkFrontDoorNameAvailabilityInput);
+ tracingParameters.Add("apiVersion", apiVersion);
+ tracingParameters.Add("cancellationToken", cancellationToken);
+ ServiceClientTracing.Enter(_invocationId, this, "Check", tracingParameters);
+ }
+ // Construct URL
+ var _baseUrl = Client.BaseUri.AbsoluteUri;
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/providers/Microsoft.Network/checkFrontDoorNameAvailability").ToString();
+ _url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
+ List _queryParameters = new List();
+ if (apiVersion != null)
+ {
+ _queryParameters.Add(string.Format("api-version={0}", System.Uri.EscapeDataString(apiVersion)));
+ }
+ if (_queryParameters.Count > 0)
+ {
+ _url += (_url.Contains("?") ? "&" : "?") + string.Join("&", _queryParameters);
+ }
+ // Create HTTP transport objects
+ var _httpRequest = new HttpRequestMessage();
+ HttpResponseMessage _httpResponse = null;
+ _httpRequest.Method = new HttpMethod("POST");
+ _httpRequest.RequestUri = new System.Uri(_url);
+ // Set Headers
+ if (Client.GenerateClientRequestId != null && Client.GenerateClientRequestId.Value)
+ {
+ _httpRequest.Headers.TryAddWithoutValidation("x-ms-client-request-id", System.Guid.NewGuid().ToString());
+ }
+ if (Client.AcceptLanguage != null)
+ {
+ if (_httpRequest.Headers.Contains("accept-language"))
+ {
+ _httpRequest.Headers.Remove("accept-language");
+ }
+ _httpRequest.Headers.TryAddWithoutValidation("accept-language", Client.AcceptLanguage);
+ }
+
+
+ if (customHeaders != null)
+ {
+ foreach(var _header in customHeaders)
+ {
+ if (_httpRequest.Headers.Contains(_header.Key))
+ {
+ _httpRequest.Headers.Remove(_header.Key);
+ }
+ _httpRequest.Headers.TryAddWithoutValidation(_header.Key, _header.Value);
+ }
+ }
+
+ // Serialize Request
+ string _requestContent = null;
+ if(checkFrontDoorNameAvailabilityInput != null)
+ {
+ _requestContent = Rest.Serialization.SafeJsonConvert.SerializeObject(checkFrontDoorNameAvailabilityInput, Client.SerializationSettings);
+ _httpRequest.Content = new StringContent(_requestContent, System.Text.Encoding.UTF8);
+ _httpRequest.Content.Headers.ContentType =System.Net.Http.Headers.MediaTypeHeaderValue.Parse("application/json; charset=utf-8");
+ }
+ // Set Credentials
+ if (Client.Credentials != null)
+ {
+ cancellationToken.ThrowIfCancellationRequested();
+ await Client.Credentials.ProcessHttpRequestAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
+ }
+ // Send Request
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.SendRequest(_invocationId, _httpRequest);
+ }
+ cancellationToken.ThrowIfCancellationRequested();
+ _httpResponse = await Client.HttpClient.SendAsync(_httpRequest, cancellationToken).ConfigureAwait(false);
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.ReceiveResponse(_invocationId, _httpResponse);
+ }
+ HttpStatusCode _statusCode = _httpResponse.StatusCode;
+ cancellationToken.ThrowIfCancellationRequested();
+ string _responseContent = null;
+ if ((int)_statusCode != 200)
+ {
+ var ex = new ErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ try
+ {
+ _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
+ ErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ if (_errorBody != null)
+ {
+ ex.Body = _errorBody;
+ }
+ }
+ catch (JsonException)
+ {
+ // Ignore the exception
+ }
+ ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
+ ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.Error(_invocationId, ex);
+ }
+ _httpRequest.Dispose();
+ if (_httpResponse != null)
+ {
+ _httpResponse.Dispose();
+ }
+ throw ex;
+ }
+ // Create Result
+ var _result = new AzureOperationResponse();
+ _result.Request = _httpRequest;
+ _result.Response = _httpResponse;
+ if (_httpResponse.Headers.Contains("x-ms-request-id"))
+ {
+ _result.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
+ }
+ // Deserialize Response
+ if ((int)_statusCode == 200)
+ {
+ _responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
+ try
+ {
+ _result.Body = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ }
+ catch (JsonException ex)
+ {
+ _httpRequest.Dispose();
+ if (_httpResponse != null)
+ {
+ _httpResponse.Dispose();
+ }
+ throw new SerializationException("Unable to deserialize the response.", _responseContent, ex);
+ }
+ }
+ if (_shouldTrace)
+ {
+ ServiceClientTracing.Exit(_invocationId, _result);
+ }
+ return _result;
+ }
+
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperationsExtensions.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperationsExtensions.cs
new file mode 100644
index 000000000000..7e32b5025fa6
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorNameAvailabilityWithSubscriptionOperationsExtensions.cs
@@ -0,0 +1,59 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// Extension methods for FrontDoorNameAvailabilityWithSubscriptionOperations.
+ ///
+ public static partial class FrontDoorNameAvailabilityWithSubscriptionOperationsExtensions
+ {
+ ///
+ /// Check the availability of a Front Door subdomain.
+ ///
+ ///
+ /// The operations group for this extension method.
+ ///
+ ///
+ /// Input to check.
+ ///
+ public static CheckNameAvailabilityOutput Check(this IFrontDoorNameAvailabilityWithSubscriptionOperations operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput)
+ {
+ return operations.CheckAsync(checkFrontDoorNameAvailabilityInput).GetAwaiter().GetResult();
+ }
+
+ ///
+ /// Check the availability of a Front Door subdomain.
+ ///
+ ///
+ /// The operations group for this extension method.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ public static async Task CheckAsync(this IFrontDoorNameAvailabilityWithSubscriptionOperations operations, CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ using (var _result = await operations.CheckWithHttpMessagesAsync(checkFrontDoorNameAvailabilityInput, null, cancellationToken).ConfigureAwait(false))
+ {
+ return _result.Body;
+ }
+ }
+
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorsOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorsOperations.cs
index f89105f0aab3..b594b9589780 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorsOperations.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontDoorsOperations.cs
@@ -80,7 +80,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -273,7 +273,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "resourceGroupName", "^[a-zA-Z0-9_\\-\\(\\)\\.]*[^\\.]$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -491,7 +491,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontDoorName", "^[a-zA-Z0-9]+([-a-zA-Z0-9]?[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -770,7 +770,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
{
customDomainProperties.Validate();
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -1008,7 +1008,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
{
frontDoorParameters.Validate();
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -1267,7 +1267,7 @@ internal FrontDoorsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontDoorName", "^[a-zA-Z0-9]+([-a-zA-Z0-9]?[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontendEndpointsOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontendEndpointsOperations.cs
index a9394677e5e5..c48db14c46bc 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontendEndpointsOperations.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/FrontendEndpointsOperations.cs
@@ -124,7 +124,7 @@ internal FrontendEndpointsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontDoorName", "^[a-zA-Z0-9]+([-a-zA-Z0-9]?[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -366,7 +366,7 @@ internal FrontendEndpointsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontendEndpointName", "^[a-zA-Z0-9]+(-*[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -670,7 +670,7 @@ internal FrontendEndpointsOperations(FrontDoorManagementClient client)
{
customHttpsConfiguration.Validate();
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -899,7 +899,7 @@ internal FrontendEndpointsOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontendEndpointName", "^[a-zA-Z0-9]+(-*[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorManagementClient.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorManagementClient.cs
index d70706e3fe1c..d4327514f3b6 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorManagementClient.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorManagementClient.cs
@@ -14,10 +14,6 @@ namespace Microsoft.Azure.Management.FrontDoor
using Microsoft.Rest.Azure;
using Models;
using Newtonsoft.Json;
- using System.Collections;
- using System.Collections.Generic;
- using System.Threading;
- using System.Threading.Tasks;
///
/// FrontDoor Client
@@ -90,6 +86,16 @@ public partial interface IFrontDoorManagementClient : System.IDisposable
///
IReportsOperations Reports { get; }
+ ///
+ /// Gets the IFrontDoorNameAvailabilityOperations.
+ ///
+ IFrontDoorNameAvailabilityOperations FrontDoorNameAvailability { get; }
+
+ ///
+ /// Gets the IFrontDoorNameAvailabilityWithSubscriptionOperations.
+ ///
+ IFrontDoorNameAvailabilityWithSubscriptionOperations FrontDoorNameAvailabilityWithSubscription { get; }
+
///
/// Gets the IFrontDoorsOperations.
///
@@ -120,33 +126,5 @@ public partial interface IFrontDoorManagementClient : System.IDisposable
///
IManagedRuleSetsOperations ManagedRuleSets { get; }
- ///
- /// Check the availability of a Front Door resource name.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// The headers that will be added to request.
- ///
- ///
- /// The cancellation token.
- ///
- Task> CheckFrontDoorNameAvailabilityWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
-
- ///
- /// Check the availability of a Front Door subdomain.
- ///
- ///
- /// Input to check.
- ///
- ///
- /// The headers that will be added to request.
- ///
- ///
- /// The cancellation token.
- ///
- Task> CheckFrontDoorNameAvailabilityWithSubscriptionWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
-
}
}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityOperations.cs
new file mode 100644
index 000000000000..06ff23a2ac88
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityOperations.cs
@@ -0,0 +1,49 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// FrontDoorNameAvailabilityOperations operations.
+ ///
+ public partial interface IFrontDoorNameAvailabilityOperations
+ {
+ ///
+ /// Check the availability of a Front Door resource name.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ ///
+ /// Thrown when the operation returned an invalid status code
+ ///
+ ///
+ /// Thrown when unable to deserialize the response
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ Task> CheckWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityWithSubscriptionOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityWithSubscriptionOperations.cs
new file mode 100644
index 000000000000..cb0af605bcd6
--- /dev/null
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/IFrontDoorNameAvailabilityWithSubscriptionOperations.cs
@@ -0,0 +1,49 @@
+//
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for
+// license information.
+//
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is
+// regenerated.
+//
+
+namespace Microsoft.Azure.Management.FrontDoor
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// FrontDoorNameAvailabilityWithSubscriptionOperations operations.
+ ///
+ public partial interface IFrontDoorNameAvailabilityWithSubscriptionOperations
+ {
+ ///
+ /// Check the availability of a Front Door subdomain.
+ ///
+ ///
+ /// Input to check.
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ ///
+ /// Thrown when the operation returned an invalid status code
+ ///
+ ///
+ /// Thrown when unable to deserialize the response
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ Task> CheckWithHttpMessagesAsync(CheckNameAvailabilityInput checkFrontDoorNameAvailabilityInput, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ }
+}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/Backend.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/Backend.cs
index c76462908cc6..921ee85f71c0 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/Backend.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/Backend.cs
@@ -35,6 +35,12 @@ public Backend()
/// The Alias of the Private Link
/// resource. Populating this optional field indicates that this
/// backend is 'Private'
+ /// The Resource Id of the Private
+ /// Link resource. Populating this optional field indicates that this
+ /// backend is 'Private'
+ /// The location of the Private Link
+ /// resource. Required only if 'privateLinkResourceId' is
+ /// populated
/// The Approval status for the
/// connection to the Private Link. Possible values include: 'Pending',
/// 'Approved', 'Rejected', 'Disconnected', 'Timeout'
@@ -56,10 +62,12 @@ public Backend()
/// The value to use as the host header
/// sent to the backend. If blank or unspecified, this defaults to the
/// incoming host.
- public Backend(string address = default(string), string privateLinkAlias = default(string), PrivateEndpointStatus? privateEndpointStatus = default(PrivateEndpointStatus?), string privateLinkApprovalMessage = default(string), int? httpPort = default(int?), int? httpsPort = default(int?), string enabledState = default(string), int? priority = default(int?), int? weight = default(int?), string backendHostHeader = default(string))
+ public Backend(string address = default(string), string privateLinkAlias = default(string), string privateLinkResourceId = default(string), string privateLinkLocation = default(string), string privateEndpointStatus = default(string), string privateLinkApprovalMessage = default(string), int? httpPort = default(int?), int? httpsPort = default(int?), string enabledState = default(string), int? priority = default(int?), int? weight = default(int?), string backendHostHeader = default(string))
{
Address = address;
PrivateLinkAlias = privateLinkAlias;
+ PrivateLinkResourceId = privateLinkResourceId;
+ PrivateLinkLocation = privateLinkLocation;
PrivateEndpointStatus = privateEndpointStatus;
PrivateLinkApprovalMessage = privateLinkApprovalMessage;
HttpPort = httpPort;
@@ -89,13 +97,28 @@ public Backend()
[JsonProperty(PropertyName = "privateLinkAlias")]
public string PrivateLinkAlias { get; set; }
+ ///
+ /// Gets or sets the Resource Id of the Private Link resource.
+ /// Populating this optional field indicates that this backend is
+ /// 'Private'
+ ///
+ [JsonProperty(PropertyName = "privateLinkResourceId")]
+ public string PrivateLinkResourceId { get; set; }
+
+ ///
+ /// Gets or sets the location of the Private Link resource. Required
+ /// only if 'privateLinkResourceId' is populated
+ ///
+ [JsonProperty(PropertyName = "privateLinkLocation")]
+ public string PrivateLinkLocation { get; set; }
+
///
/// Gets the Approval status for the connection to the Private Link.
/// Possible values include: 'Pending', 'Approved', 'Rejected',
/// 'Disconnected', 'Timeout'
///
[JsonProperty(PropertyName = "privateEndpointStatus")]
- public PrivateEndpointStatus? PrivateEndpointStatus { get; private set; }
+ public string PrivateEndpointStatus { get; private set; }
///
/// Gets or sets a custom message to be included in the approval
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/PrivateEndpointStatus.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/PrivateEndpointStatus.cs
index 8aaca09cb4f4..9610a315b530 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/PrivateEndpointStatus.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/Models/PrivateEndpointStatus.cs
@@ -10,69 +10,16 @@
namespace Microsoft.Azure.Management.FrontDoor.Models
{
- using Newtonsoft.Json;
- using Newtonsoft.Json.Converters;
- using System.Runtime;
- using System.Runtime.Serialization;
///
/// Defines values for PrivateEndpointStatus.
///
- [JsonConverter(typeof(StringEnumConverter))]
- public enum PrivateEndpointStatus
+ public static class PrivateEndpointStatus
{
- [EnumMember(Value = "Pending")]
- Pending,
- [EnumMember(Value = "Approved")]
- Approved,
- [EnumMember(Value = "Rejected")]
- Rejected,
- [EnumMember(Value = "Disconnected")]
- Disconnected,
- [EnumMember(Value = "Timeout")]
- Timeout
- }
- internal static class PrivateEndpointStatusEnumExtension
- {
- internal static string ToSerializedValue(this PrivateEndpointStatus? value)
- {
- return value == null ? null : ((PrivateEndpointStatus)value).ToSerializedValue();
- }
-
- internal static string ToSerializedValue(this PrivateEndpointStatus value)
- {
- switch( value )
- {
- case PrivateEndpointStatus.Pending:
- return "Pending";
- case PrivateEndpointStatus.Approved:
- return "Approved";
- case PrivateEndpointStatus.Rejected:
- return "Rejected";
- case PrivateEndpointStatus.Disconnected:
- return "Disconnected";
- case PrivateEndpointStatus.Timeout:
- return "Timeout";
- }
- return null;
- }
-
- internal static PrivateEndpointStatus? ParsePrivateEndpointStatus(this string value)
- {
- switch( value )
- {
- case "Pending":
- return PrivateEndpointStatus.Pending;
- case "Approved":
- return PrivateEndpointStatus.Approved;
- case "Rejected":
- return PrivateEndpointStatus.Rejected;
- case "Disconnected":
- return PrivateEndpointStatus.Disconnected;
- case "Timeout":
- return PrivateEndpointStatus.Timeout;
- }
- return null;
- }
+ public const string Pending = "Pending";
+ public const string Approved = "Approved";
+ public const string Rejected = "Rejected";
+ public const string Disconnected = "Disconnected";
+ public const string Timeout = "Timeout";
}
}
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/RulesEnginesOperations.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/RulesEnginesOperations.cs
index b590e2d4f6dc..a4254bdaaca4 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/RulesEnginesOperations.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/RulesEnginesOperations.cs
@@ -124,7 +124,7 @@ internal RulesEnginesOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "frontDoorName", "^[a-zA-Z0-9]+([-a-zA-Z0-9]?[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -366,7 +366,7 @@ internal RulesEnginesOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "rulesEngineName", "^[a-zA-Z0-9]+(-*[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -674,7 +674,7 @@ internal RulesEnginesOperations(FrontDoorManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "rulesEngineParameters");
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -958,7 +958,7 @@ internal RulesEnginesOperations(FrontDoorManagementClient client)
throw new ValidationException(ValidationRules.Pattern, "rulesEngineName", "^[a-zA-Z0-9]+(-*[a-zA-Z0-9])*$");
}
}
- string apiVersion = "2020-01-01";
+ string apiVersion = "2020-05-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/SdkInfo_FrontDoorManagementClient.cs b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/SdkInfo_FrontDoorManagementClient.cs
index 885315462903..c6019fc8cd90 100644
--- a/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/SdkInfo_FrontDoorManagementClient.cs
+++ b/sdk/frontdoor/Microsoft.Azure.Management.FrontDoor/src/Generated/SdkInfo_FrontDoorManagementClient.cs
@@ -19,31 +19,20 @@ public static IEnumerable> ApiInfo_FrontDoorManage
{
return new Tuple[]
{
- new Tuple("Network", "CheckFrontDoorNameAvailability", "2020-01-01"),
- new Tuple("Network", "CheckFrontDoorNameAvailabilityWithSubscription", "2020-01-01"),
- new Tuple("Network", "Endpoints", "2020-01-01"),
+ new Tuple("Network", "Endpoints", "2020-05-01"),
new Tuple("Network", "Experiments", "2019-11-01"),
- new Tuple("Network", "FrontDoors", "2020-01-01"),
- new Tuple("Network", "FrontendEndpoints", "2020-01-01"),
+ new Tuple("Network", "FrontDoorNameAvailability", "2020-05-01"),
+ new Tuple("Network", "FrontDoorNameAvailabilityWithSubscription", "2020-05-01"),
+ new Tuple("Network", "FrontDoors", "2020-05-01"),
+ new Tuple("Network", "FrontendEndpoints", "2020-05-01"),
new Tuple("Network", "ManagedRuleSets", "2019-10-01"),
new Tuple("Network", "NetworkExperimentProfiles", "2019-11-01"),
new Tuple("Network", "Policies", "2019-10-01"),
new Tuple("Network", "PreconfiguredEndpoints", "2019-11-01"),
new Tuple("Network", "Reports", "2019-11-01"),
- new Tuple("Network", "RulesEngines", "2020-01-01"),
+ new Tuple("Network", "RulesEngines", "2020-05-01"),
}.AsEnumerable();
}
}
- // BEGIN: Code Generation Metadata Section
- public static readonly String AutoRestVersion = "2.0.4413";
- public static readonly String AutoRestBootStrapperVersion = "autorest@2.0.4413";
- public static readonly String AutoRestCmdExecuted = "cmd.exe /c autorest.cmd https://github.com/Azure/azure-rest-api-specs/blob/master/specification/frontdoor/resource-manager/readme.md --csharp --version=2.0.4413 --reflect-api-versions --csharp-sdks-folder=C:\\AFD\\azure-sdk-for-net\\sdk";
- public static readonly String GithubForkName = "Azure";
- public static readonly String GithubBranchName = "master";
- public static readonly String GithubCommidId = "1580acb8ce9108317cb629532ece1cea272450d3";
- public static readonly String CodeGenerationErrors = "";
- public static readonly String GithubRepoName = "azure-rest-api-specs";
- // END: Code Generation Metadata Section
}
}
-