diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BMSPrepareDataMoveOperationResultOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BMSPrepareDataMoveOperationResultOperations.cs
index 5fd5d1afb701..8e6dcec3adf9 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BMSPrepareDataMoveOperationResultOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BMSPrepareDataMoveOperationResultOperations.cs
@@ -101,7 +101,7 @@ internal BMSPrepareDataMoveOperationResultOperations(RecoveryServicesBackupClien
{
throw new ValidationException(ValidationRules.CannotBeNull, "operationId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupEnginesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupEnginesOperations.cs
index 92fa6e2386ef..c7b98b90229f 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupEnginesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupEnginesOperations.cs
@@ -74,7 +74,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -103,7 +103,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -121,7 +121,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupEngines").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupEngines").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -202,14 +202,13 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -219,10 +218,6 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -292,7 +287,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -325,7 +320,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "backupEngineName");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -344,7 +339,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupEngines/{backupEngineName}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupEngines/{backupEngineName}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -426,14 +421,13 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -443,10 +437,6 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -504,7 +494,7 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -600,14 +590,13 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -617,10 +606,6 @@ internal BackupEnginesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupJobsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupJobsOperations.cs
index 1c9c0130e47e..fa18ae9533ff 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupJobsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupJobsOperations.cs
@@ -73,7 +73,7 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -102,7 +102,7 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -120,7 +120,7 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -201,14 +201,13 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -218,10 +217,6 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -278,7 +273,7 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -374,14 +369,13 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -391,10 +385,6 @@ internal BackupJobsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationResultsOperations.cs
index 882bbf0b709a..be5e6aa28e49 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationResultsOperations.cs
@@ -75,7 +75,7 @@ internal BackupOperationResultsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -105,7 +105,7 @@ internal BackupOperationResultsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "operationId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -122,7 +122,7 @@ internal BackupOperationResultsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupOperationResults/{operationId}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupOperationResults/{operationId}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -192,14 +192,13 @@ internal BackupOperationResultsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200 && (int)_statusCode != 202 && (int)_statusCode != 204)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -209,10 +208,6 @@ internal BackupOperationResultsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationStatusesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationStatusesOperations.cs
index 8d065c4f951f..2b4323d347c3 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationStatusesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupOperationStatusesOperations.cs
@@ -74,7 +74,7 @@ internal BackupOperationStatusesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -107,7 +107,7 @@ internal BackupOperationStatusesOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "operationId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -124,7 +124,7 @@ internal BackupOperationStatusesOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupOperations/{operationId}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupOperations/{operationId}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -194,14 +194,13 @@ internal BackupOperationStatusesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -211,10 +210,6 @@ internal BackupOperationStatusesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupPoliciesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupPoliciesOperations.cs
index b0c5b62574eb..d4e6ab0f634d 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupPoliciesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupPoliciesOperations.cs
@@ -72,7 +72,7 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -101,7 +101,7 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -118,7 +118,7 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupPolicies").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupPolicies").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -195,14 +195,13 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -212,10 +211,6 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -274,7 +269,7 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -370,14 +365,13 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -387,10 +381,6 @@ internal BackupPoliciesOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectableItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectableItemsOperations.cs
index 733366b083d5..23a4bc5cc8fc 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectableItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectableItemsOperations.cs
@@ -75,7 +75,7 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -104,7 +104,7 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -122,7 +122,7 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectableItems").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectableItems").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -203,14 +203,13 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -220,10 +219,6 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -282,7 +277,7 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -378,14 +373,13 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -395,10 +389,6 @@ internal BackupProtectableItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectedItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectedItemsOperations.cs
index 52a7a0b14d95..4fcaf2788e7f 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectedItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectedItemsOperations.cs
@@ -73,7 +73,7 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -102,7 +102,7 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -120,7 +120,7 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectedItems").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectedItems").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -201,14 +201,13 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -218,10 +217,6 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -278,7 +273,7 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -374,14 +369,13 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -391,10 +385,6 @@ internal BackupProtectedItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectionContainersOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectionContainersOperations.cs
index 0c71fc4cf3d1..7e2a2d4d0f2f 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectionContainersOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupProtectionContainersOperations.cs
@@ -70,7 +70,7 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -99,7 +99,7 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -116,7 +116,7 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectionContainers").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectionContainers").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -193,14 +193,13 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -210,10 +209,6 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -270,7 +265,7 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -366,14 +361,13 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -383,10 +377,6 @@ internal BackupProtectionContainersOperations(RecoveryServicesBackupClient clien
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceEncryptionConfigsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceEncryptionConfigsOperations.cs
index ecf960a15707..1510b5277661 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceEncryptionConfigsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceEncryptionConfigsOperations.cs
@@ -95,7 +95,7 @@ internal BackupResourceEncryptionConfigsOperations(RecoveryServicesBackupClient
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -289,7 +289,7 @@ internal BackupResourceEncryptionConfigsOperations(RecoveryServicesBackupClient
{
throw new ValidationException(ValidationRules.CannotBeNull, "parameters");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceVaultConfigsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceVaultConfigsOperations.cs
index 68233f916b46..6fa1a2f690fa 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceVaultConfigsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupResourceVaultConfigsOperations.cs
@@ -95,7 +95,7 @@ internal BackupResourceVaultConfigsOperations(RecoveryServicesBackupClient clien
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -292,7 +292,7 @@ internal BackupResourceVaultConfigsOperations(RecoveryServicesBackupClient clien
{
throw new ValidationException(ValidationRules.CannotBeNull, "parameters");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -496,7 +496,7 @@ internal BackupResourceVaultConfigsOperations(RecoveryServicesBackupClient clien
{
throw new ValidationException(ValidationRules.CannotBeNull, "parameters");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupWorkloadItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupWorkloadItemsOperations.cs
index 1b1e3b538320..d319ab869091 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupWorkloadItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupWorkloadItemsOperations.cs
@@ -81,7 +81,7 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -118,7 +118,7 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "containerName");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -138,7 +138,7 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/items").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/items").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -221,14 +221,13 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -238,10 +237,6 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -300,7 +295,7 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -396,14 +391,13 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -413,10 +407,6 @@ internal BackupWorkloadItemsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupsOperations.cs
index 7b0e5e6fd4a2..807e563f8b9e 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/BackupsOperations.cs
@@ -80,7 +80,7 @@ internal BackupsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -122,7 +122,7 @@ internal BackupsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "parameters");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -142,7 +142,7 @@ internal BackupsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/backup").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/backup").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -220,14 +220,13 @@ internal BackupsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -237,10 +236,6 @@ internal BackupsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ExportJobsOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ExportJobsOperationResultsOperations.cs
index 580b6090629e..6722a56cffe7 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ExportJobsOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ExportJobsOperationResultsOperations.cs
@@ -72,7 +72,7 @@ internal ExportJobsOperationResultsOperations(RecoveryServicesBackupClient clien
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -105,7 +105,7 @@ internal ExportJobsOperationResultsOperations(RecoveryServicesBackupClient clien
{
throw new ValidationException(ValidationRules.CannotBeNull, "operationId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -122,7 +122,7 @@ internal ExportJobsOperationResultsOperations(RecoveryServicesBackupClient clien
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/operationResults/{operationId}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/operationResults/{operationId}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -192,14 +192,13 @@ internal ExportJobsOperationResultsOperations(RecoveryServicesBackupClient clien
string _responseContent = null;
if ((int)_statusCode != 200 && (int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -209,10 +208,6 @@ internal ExportJobsOperationResultsOperations(RecoveryServicesBackupClient clien
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupEnginesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupEnginesOperations.cs
index d4655c357583..5755628ba4e9 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupEnginesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupEnginesOperations.cs
@@ -47,7 +47,7 @@ public partial interface IBackupEnginesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -83,7 +83,7 @@ public partial interface IBackupEnginesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -106,7 +106,7 @@ public partial interface IBackupEnginesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupJobsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupJobsOperations.cs
index 5b1d7af253dd..868e05c3fa2a 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupJobsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupJobsOperations.cs
@@ -46,7 +46,7 @@ public partial interface IBackupJobsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -68,7 +68,7 @@ public partial interface IBackupJobsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationResultsOperations.cs
index be5b3099a3ac..dfd5d9f690d2 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationResultsOperations.cs
@@ -48,7 +48,7 @@ public partial interface IBackupOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationStatusesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationStatusesOperations.cs
index f514a80af475..9a04842fad82 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationStatusesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupOperationStatusesOperations.cs
@@ -47,7 +47,7 @@ public partial interface IBackupOperationStatusesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupPoliciesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupPoliciesOperations.cs
index 0b5734870718..967b791be58b 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupPoliciesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupPoliciesOperations.cs
@@ -45,7 +45,7 @@ public partial interface IBackupPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -69,7 +69,7 @@ public partial interface IBackupPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectableItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectableItemsOperations.cs
index 94e07cee74b6..f39ccd746304 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectableItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectableItemsOperations.cs
@@ -48,7 +48,7 @@ public partial interface IBackupProtectableItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -72,7 +72,7 @@ public partial interface IBackupProtectableItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectedItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectedItemsOperations.cs
index 457b5e1a0528..ce512fc4e504 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectedItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectedItemsOperations.cs
@@ -47,7 +47,7 @@ public partial interface IBackupProtectedItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -70,7 +70,7 @@ public partial interface IBackupProtectedItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectionContainersOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectionContainersOperations.cs
index 716c158c6620..04bfbba923bf 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectionContainersOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupProtectionContainersOperations.cs
@@ -43,7 +43,7 @@ public partial interface IBackupProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -65,7 +65,7 @@ public partial interface IBackupProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupWorkloadItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupWorkloadItemsOperations.cs
index 74bdb3563556..22a66921d571 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupWorkloadItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupWorkloadItemsOperations.cs
@@ -54,7 +54,7 @@ public partial interface IBackupWorkloadItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -78,7 +78,7 @@ public partial interface IBackupWorkloadItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupsOperations.cs
index c152e3cd8a35..64e7d12e0ac4 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IBackupsOperations.cs
@@ -53,7 +53,7 @@ public partial interface IBackupsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IExportJobsOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IExportJobsOperationResultsOperations.cs
index ad084fd7013c..8d05b3c8b10d 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IExportJobsOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IExportJobsOperationResultsOperations.cs
@@ -45,7 +45,7 @@ public partial interface IExportJobsOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IItemLevelRecoveryConnectionsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IItemLevelRecoveryConnectionsOperations.cs
index 770a73544040..bbbc38c051e1 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IItemLevelRecoveryConnectionsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IItemLevelRecoveryConnectionsOperations.cs
@@ -60,7 +60,7 @@ public partial interface IItemLevelRecoveryConnectionsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -100,7 +100,7 @@ public partial interface IItemLevelRecoveryConnectionsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobCancellationsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobCancellationsOperations.cs
index 4eccb07fd16b..e961ca45f207 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobCancellationsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobCancellationsOperations.cs
@@ -44,7 +44,7 @@ public partial interface IJobCancellationsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobDetailsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobDetailsOperations.cs
index 4b9d658775ab..186ec12dbebd 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobDetailsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobDetailsOperations.cs
@@ -42,7 +42,7 @@ public partial interface IJobDetailsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobOperationResultsOperations.cs
index 12b9a3436927..b8d9af31239b 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobOperationResultsOperations.cs
@@ -46,7 +46,7 @@ public partial interface IJobOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobsOperations.cs
index f228dcdf6e5e..5a6c68759b0a 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IJobsOperations.cs
@@ -44,7 +44,7 @@ public partial interface IJobsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IOperationOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IOperationOperations.cs
index 178ed8961c01..daa82a406c4e 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IOperationOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IOperationOperations.cs
@@ -43,7 +43,7 @@ public partial interface IOperationOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IPrivateEndpointConnectionOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IPrivateEndpointConnectionOperations.cs
index 3b0d0dac9ad9..ea2d595a35f2 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IPrivateEndpointConnectionOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IPrivateEndpointConnectionOperations.cs
@@ -75,7 +75,7 @@ public partial interface IPrivateEndpointConnectionOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -105,7 +105,7 @@ public partial interface IPrivateEndpointConnectionOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -135,7 +135,7 @@ public partial interface IPrivateEndpointConnectionOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -165,7 +165,7 @@ public partial interface IPrivateEndpointConnectionOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectableContainersOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectableContainersOperations.cs
index cb141bd9cf19..ae0e74962875 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectableContainersOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectableContainersOperations.cs
@@ -46,7 +46,7 @@ public partial interface IProtectableContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -69,7 +69,7 @@ public partial interface IProtectableContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationResultsOperations.cs
index e20249fe28b2..d7f28c0f4a30 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationResultsOperations.cs
@@ -52,7 +52,7 @@ public partial interface IProtectedItemOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationStatusesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationStatusesOperations.cs
index 55f73b091aa0..5c4e99932095 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationStatusesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemOperationStatusesOperations.cs
@@ -57,7 +57,7 @@ public partial interface IProtectedItemOperationStatusesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemsOperations.cs
index 2ec2ff0b561c..0f107b4dbff5 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectedItemsOperations.cs
@@ -54,7 +54,7 @@ public partial interface IProtectedItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -95,7 +95,7 @@ public partial interface IProtectedItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -132,7 +132,7 @@ public partial interface IProtectedItemsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerOperationResultsOperations.cs
index 77f9daec1509..d1d073636417 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerOperationResultsOperations.cs
@@ -49,7 +49,7 @@ public partial interface IProtectionContainerOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerRefreshOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerRefreshOperationResultsOperations.cs
index 92fc918f3bbf..858b61323a8d 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerRefreshOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainerRefreshOperationResultsOperations.cs
@@ -47,7 +47,7 @@ public partial interface IProtectionContainerRefreshOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainersOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainersOperations.cs
index 6fefb5551645..90b1670dcbcc 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainersOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionContainersOperations.cs
@@ -47,7 +47,7 @@ public partial interface IProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -85,7 +85,7 @@ public partial interface IProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -121,7 +121,7 @@ public partial interface IProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -157,7 +157,7 @@ public partial interface IProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -189,7 +189,7 @@ public partial interface IProtectionContainersOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPoliciesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPoliciesOperations.cs
index f816e1096525..8dcfff20dace 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPoliciesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPoliciesOperations.cs
@@ -45,7 +45,7 @@ public partial interface IProtectionPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -79,7 +79,7 @@ public partial interface IProtectionPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -111,7 +111,7 @@ public partial interface IProtectionPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -140,7 +140,7 @@ public partial interface IProtectionPoliciesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationResultsOperations.cs
index 06c0549fe83e..7ea9a14e93d8 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationResultsOperations.cs
@@ -46,7 +46,7 @@ public partial interface IProtectionPolicyOperationResultsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationStatusesOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationStatusesOperations.cs
index 0a9ae300d3a3..5e7e321e3bc6 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationStatusesOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IProtectionPolicyOperationStatusesOperations.cs
@@ -51,7 +51,7 @@ public partial interface IProtectionPolicyOperationStatusesOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsOperations.cs
index 424a6ba65195..986597eef655 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsOperations.cs
@@ -52,7 +52,7 @@ public partial interface IRecoveryPointsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -93,7 +93,7 @@ public partial interface IRecoveryPointsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -157,7 +157,7 @@ public partial interface IRecoveryPointsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsRecommendedForMoveOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsRecommendedForMoveOperations.cs
new file mode 100644
index 000000000000..f976a3c6e4e4
--- /dev/null
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryPointsRecommendedForMoveOperations.cs
@@ -0,0 +1,84 @@
+//
+// 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.RecoveryServices.Backup
+{
+ using Microsoft.Rest;
+ using Microsoft.Rest.Azure;
+ using Models;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Threading;
+ using System.Threading.Tasks;
+
+ ///
+ /// RecoveryPointsRecommendedForMoveOperations operations.
+ ///
+ public partial interface IRecoveryPointsRecommendedForMoveOperations
+ {
+ ///
+ /// Lists the recovery points recommended for move to another tier
+ ///
+ ///
+ /// The name of the recovery services vault.
+ ///
+ ///
+ /// The name of the resource group where the recovery services vault is
+ /// present.
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ /// List Recovery points Recommended for Move Request
+ ///
+ ///
+ /// 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>> ListWithHttpMessagesAsync(string vaultName, string resourceGroupName, string fabricName, string containerName, string protectedItemName, ListRecoveryPointsRecommendedForMoveRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ ///
+ /// Lists the recovery points recommended for move to another tier
+ ///
+ ///
+ /// The NextLink from the previous successful call to List operation.
+ ///
+ ///
+ /// 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>> ListNextWithHttpMessagesAsync(string nextPageLink, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ }
+}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryServicesBackupClient.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryServicesBackupClient.cs
index caf5b20110a7..3bd92ffc82b0 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryServicesBackupClient.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRecoveryServicesBackupClient.cs
@@ -243,6 +243,11 @@ public partial interface IRecoveryServicesBackupClient : System.IDisposable
///
ISecurityPINsOperations SecurityPINs { get; }
+ ///
+ /// Gets the IRecoveryPointsRecommendedForMoveOperations.
+ ///
+ IRecoveryPointsRecommendedForMoveOperations RecoveryPointsRecommendedForMove { get; }
+
///
/// Gets the IAadPropertiesOperations.
///
@@ -380,6 +385,56 @@ public partial interface IRecoveryServicesBackupClient : System.IDisposable
///
Task BMSTriggerDataMoveWithHttpMessagesAsync(string vaultName, string resourceGroupName, TriggerDataMoveRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ ///
+ /// Move recovery point from one datastore to another store.
+ ///
+ ///
+ /// The name of the recovery services vault.
+ ///
+ ///
+ /// The name of the resource group where the recovery services vault is
+ /// present.
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ /// Move Resource Across Tiers Request
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ Task MoveRecoveryPointWithHttpMessagesAsync(string vaultName, string resourceGroupName, string fabricName, string containerName, string protectedItemName, string recoveryPointId, MoveRPAcrossTiersRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+
+ ///
+ /// Prepares source vault for Data Move operation
+ ///
+ ///
+ /// The name of the recovery services vault.
+ ///
+ ///
+ /// The name of the resource group where the recovery services vault is
+ /// present.
+ ///
+ ///
+ /// Prepare data move request
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ Task BeginBMSPrepareDataMoveWithHttpMessagesAsync(string vaultName, string resourceGroupName, PrepareDataMoveRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+
///
/// Triggers Data Move Operation on target vault
///
@@ -401,5 +456,34 @@ public partial interface IRecoveryServicesBackupClient : System.IDisposable
///
Task BeginBMSTriggerDataMoveWithHttpMessagesAsync(string vaultName, string resourceGroupName, TriggerDataMoveRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ ///
+ /// Move recovery point from one datastore to another store.
+ ///
+ ///
+ /// The name of the recovery services vault.
+ ///
+ ///
+ /// The name of the resource group where the recovery services vault is
+ /// present.
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ /// Move Resource Across Tiers Request
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ Task BeginMoveRecoveryPointWithHttpMessagesAsync(string vaultName, string resourceGroupName, string fabricName, string containerName, string protectedItemName, string recoveryPointId, MoveRPAcrossTiersRequest parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+
}
}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRestoresOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRestoresOperations.cs
index 2512fe932f92..5381baeeaf31 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRestoresOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/IRestoresOperations.cs
@@ -57,12 +57,53 @@ public partial interface IRestoresOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
/// Thrown when a required parameter is null
///
Task TriggerWithHttpMessagesAsync(string vaultName, string resourceGroupName, string fabricName, string containerName, string protectedItemName, string recoveryPointId, RestoreRequestResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
+ ///
+ /// Restores the specified backed up data. This is an asynchronous
+ /// operation. To know the status of this API call, use
+ /// GetProtectedItemOperationResult API.
+ ///
+ ///
+ /// The name of the recovery services vault.
+ ///
+ ///
+ /// The name of the resource group where the recovery services vault is
+ /// present.
+ ///
+ ///
+ /// Fabric name associated with the backed up items.
+ ///
+ ///
+ /// Container name associated with the backed up items.
+ ///
+ ///
+ /// Backed up item to be restored.
+ ///
+ ///
+ /// Recovery point ID which represents the backed up data to be
+ /// restored.
+ ///
+ ///
+ /// resource restore request
+ ///
+ ///
+ /// The headers that will be added to request.
+ ///
+ ///
+ /// The cancellation token.
+ ///
+ ///
+ /// Thrown when the operation returned an invalid status code
+ ///
+ ///
+ /// Thrown when a required parameter is null
+ ///
+ Task BeginTriggerWithHttpMessagesAsync(string vaultName, string resourceGroupName, string fabricName, string containerName, string protectedItemName, string recoveryPointId, RestoreRequestResource parameters, Dictionary> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
}
}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ISecurityPINsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ISecurityPINsOperations.cs
index 69daf6684fcb..109aead78969 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ISecurityPINsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ISecurityPINsOperations.cs
@@ -39,7 +39,7 @@ public partial interface ISecurityPINsOperations
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ItemLevelRecoveryConnectionsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ItemLevelRecoveryConnectionsOperations.cs
index 363717be4f54..5a3f407b4a7c 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ItemLevelRecoveryConnectionsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/ItemLevelRecoveryConnectionsOperations.cs
@@ -87,7 +87,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -133,7 +133,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
{
throw new ValidationException(ValidationRules.CannotBeNull, "parameters");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -154,7 +154,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/recoveryPoints/{recoveryPointId}/provisionInstantItemRecovery").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/recoveryPoints/{recoveryPointId}/provisionInstantItemRecovery").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -233,14 +233,13 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
string _responseContent = null;
if ((int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -250,10 +249,6 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
@@ -313,7 +308,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -355,7 +350,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
{
throw new ValidationException(ValidationRules.CannotBeNull, "recoveryPointId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -375,7 +370,7 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/recoveryPoints/{recoveryPointId}/revokeInstantItemRecovery").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}/recoveryPoints/{recoveryPointId}/revokeInstantItemRecovery").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -448,14 +443,13 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
string _responseContent = null;
if ((int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -465,10 +459,6 @@ internal ItemLevelRecoveryConnectionsOperations(RecoveryServicesBackupClient cli
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobCancellationsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobCancellationsOperations.cs
index 7095e50a219d..f612c722bab1 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobCancellationsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobCancellationsOperations.cs
@@ -71,7 +71,7 @@ internal JobCancellationsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -101,7 +101,7 @@ internal JobCancellationsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "jobName");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -118,7 +118,7 @@ internal JobCancellationsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}/cancel").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}/cancel").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -188,14 +188,13 @@ internal JobCancellationsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -205,10 +204,6 @@ internal JobCancellationsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobDetailsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobDetailsOperations.cs
index 0ad98a81ec4b..31749b6cbfd1 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobDetailsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobDetailsOperations.cs
@@ -69,7 +69,7 @@ internal JobDetailsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -102,7 +102,7 @@ internal JobDetailsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "jobName");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -119,7 +119,7 @@ internal JobDetailsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -189,14 +189,13 @@ internal JobDetailsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -206,10 +205,6 @@ internal JobDetailsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobOperationResultsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobOperationResultsOperations.cs
index d3bd34b68e36..db7758e08204 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobOperationResultsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobOperationResultsOperations.cs
@@ -72,7 +72,7 @@ internal JobOperationResultsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -106,7 +106,7 @@ internal JobOperationResultsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "operationId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -124,7 +124,7 @@ internal JobOperationResultsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}/operationResults/{operationId}").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobs/{jobName}/operationResults/{operationId}").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -195,14 +195,13 @@ internal JobOperationResultsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 200 && (int)_statusCode != 202 && (int)_statusCode != 204)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -212,10 +211,6 @@ internal JobOperationResultsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobsOperations.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobsOperations.cs
index b27cb5fb3fd2..cf3e3cb79a18 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobsOperations.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/JobsOperations.cs
@@ -71,7 +71,7 @@ internal JobsOperations(RecoveryServicesBackupClient client)
///
/// The cancellation token.
///
- ///
+ ///
/// Thrown when the operation returned an invalid status code
///
///
@@ -97,7 +97,7 @@ internal JobsOperations(RecoveryServicesBackupClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
- string apiVersion = "2020-12-01";
+ string apiVersion = "2021-01-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
@@ -114,7 +114,7 @@ internal JobsOperations(RecoveryServicesBackupClient client)
}
// Construct URL
var _baseUrl = Client.BaseUri.AbsoluteUri;
- var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobsExport").ToString();
+ var _url = new System.Uri(new System.Uri(_baseUrl + (_baseUrl.EndsWith("/") ? "" : "/")), "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupJobsExport").ToString();
_url = _url.Replace("{vaultName}", System.Uri.EscapeDataString(vaultName));
_url = _url.Replace("{resourceGroupName}", System.Uri.EscapeDataString(resourceGroupName));
_url = _url.Replace("{subscriptionId}", System.Uri.EscapeDataString(Client.SubscriptionId));
@@ -191,14 +191,13 @@ internal JobsOperations(RecoveryServicesBackupClient client)
string _responseContent = null;
if ((int)_statusCode != 202)
{
- var ex = new CloudException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
+ var ex = new NewErrorResponseException(string.Format("Operation returned an invalid status code '{0}'", _statusCode));
try
{
_responseContent = await _httpResponse.Content.ReadAsStringAsync().ConfigureAwait(false);
- CloudError _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
+ NewErrorResponse _errorBody = Rest.Serialization.SafeJsonConvert.DeserializeObject(_responseContent, Client.DeserializationSettings);
if (_errorBody != null)
{
- ex = new CloudException(_errorBody.Message);
ex.Body = _errorBody;
}
}
@@ -208,10 +207,6 @@ internal JobsOperations(RecoveryServicesBackupClient client)
}
ex.Request = new HttpRequestMessageWrapper(_httpRequest, _requestContent);
ex.Response = new HttpResponseMessageWrapper(_httpResponse, _responseContent);
- if (_httpResponse.Headers.Contains("x-ms-request-id"))
- {
- ex.RequestId = _httpResponse.Headers.GetValues("x-ms-request-id").FirstOrDefault();
- }
if (_shouldTrace)
{
ServiceClientTracing.Error(_invocationId, ex);
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadPointInTimeRecoveryPoint.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadPointInTimeRecoveryPoint.cs
index f84fe1896382..76f9509ee0ed 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadPointInTimeRecoveryPoint.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadPointInTimeRecoveryPoint.cs
@@ -37,9 +37,13 @@ public AzureWorkloadPointInTimeRecoveryPoint()
/// point was created
/// Type of restore point. Possible values include:
/// 'Invalid', 'Full', 'Log', 'Differential', 'Incremental'
+ /// Recovery point tier
+ /// information.
+ /// Eligibility of RP to
+ /// be moved to another tier
/// List of log ranges
- public AzureWorkloadPointInTimeRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList timeRanges = default(IList))
- : base(recoveryPointTimeInUTC, type)
+ public AzureWorkloadPointInTimeRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList recoveryPointTierDetails = default(IList), IDictionary recoveryPointMoveReadinessInfo = default(IDictionary), IList timeRanges = default(IList))
+ : base(recoveryPointTimeInUTC, type, recoveryPointTierDetails, recoveryPointMoveReadinessInfo)
{
TimeRanges = timeRanges;
CustomInit();
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadRecoveryPoint.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadRecoveryPoint.cs
index 42685a154ae6..1a2bad40f446 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadRecoveryPoint.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadRecoveryPoint.cs
@@ -11,6 +11,8 @@
namespace Microsoft.Azure.Management.RecoveryServices.Backup.Models
{
using Newtonsoft.Json;
+ using System.Collections;
+ using System.Collections.Generic;
using System.Linq;
///
@@ -34,10 +36,16 @@ public AzureWorkloadRecoveryPoint()
/// point was created
/// Type of restore point. Possible values include:
/// 'Invalid', 'Full', 'Log', 'Differential', 'Incremental'
- public AzureWorkloadRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string))
+ /// Recovery point tier
+ /// information.
+ /// Eligibility of RP to
+ /// be moved to another tier
+ public AzureWorkloadRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList recoveryPointTierDetails = default(IList), IDictionary recoveryPointMoveReadinessInfo = default(IDictionary))
{
RecoveryPointTimeInUTC = recoveryPointTimeInUTC;
Type = type;
+ RecoveryPointTierDetails = recoveryPointTierDetails;
+ RecoveryPointMoveReadinessInfo = recoveryPointMoveReadinessInfo;
CustomInit();
}
@@ -59,5 +67,17 @@ public AzureWorkloadRecoveryPoint()
[JsonProperty(PropertyName = "type")]
public string Type { get; private set; }
+ ///
+ /// Gets or sets recovery point tier information.
+ ///
+ [JsonProperty(PropertyName = "recoveryPointTierDetails")]
+ public IList RecoveryPointTierDetails { get; set; }
+
+ ///
+ /// Gets or sets eligibility of RP to be moved to another tier
+ ///
+ [JsonProperty(PropertyName = "recoveryPointMoveReadinessInfo")]
+ public IDictionary RecoveryPointMoveReadinessInfo { get; set; }
+
}
}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRecoveryPoint.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRecoveryPoint.cs
index 6eb65e572a6f..6b755417da25 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRecoveryPoint.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRecoveryPoint.cs
@@ -36,9 +36,13 @@ public AzureWorkloadSAPHanaPointInTimeRecoveryPoint()
/// point was created
/// Type of restore point. Possible values include:
/// 'Invalid', 'Full', 'Log', 'Differential', 'Incremental'
+ /// Recovery point tier
+ /// information.
+ /// Eligibility of RP to
+ /// be moved to another tier
/// List of log ranges
- public AzureWorkloadSAPHanaPointInTimeRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList timeRanges = default(IList))
- : base(recoveryPointTimeInUTC, type, timeRanges)
+ public AzureWorkloadSAPHanaPointInTimeRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList recoveryPointTierDetails = default(IList), IDictionary recoveryPointMoveReadinessInfo = default(IDictionary), IList timeRanges = default(IList))
+ : base(recoveryPointTimeInUTC, type, recoveryPointTierDetails, recoveryPointMoveReadinessInfo, timeRanges)
{
CustomInit();
}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest.cs
new file mode 100644
index 000000000000..a7ee5cdfa05a
--- /dev/null
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest.cs
@@ -0,0 +1,69 @@
+//
+// 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.RecoveryServices.Backup.Models
+{
+ using Newtonsoft.Json;
+ using System.Collections;
+ using System.Collections.Generic;
+ using System.Linq;
+
+ ///
+ /// AzureWorkload SAP Hana-specific restore with integrated rehydration of
+ /// recovery point.
+ ///
+ public partial class AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest : AzureWorkloadSAPHanaPointInTimeRestoreRequest
+ {
+ ///
+ /// Initializes a new instance of the
+ /// AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest class.
+ ///
+ public AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest()
+ {
+ CustomInit();
+ }
+
+ ///
+ /// Initializes a new instance of the
+ /// AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest class.
+ ///
+ /// Type of this recovery. Possible values
+ /// include: 'Invalid', 'OriginalLocation', 'AlternateLocation',
+ /// 'RestoreDisks', 'Offline'
+ /// Fully qualified ARM ID of the VM on
+ /// which workload that was running is being recovered.
+ /// Workload specific property bag.
+ /// Details of target database
+ /// Defines whether the current recovery
+ /// mode is file restore or database restore. Possible values include:
+ /// 'Invalid', 'FileRecovery', 'WorkloadRecovery'
+ /// PointInTime value
+ /// RP Rehydration
+ /// Info
+ public AzureWorkloadSAPHanaPointInTimeRestoreWithRehydrateRequest(string recoveryType = default(string), string sourceResourceId = default(string), IDictionary propertyBag = default(IDictionary), TargetRestoreInfo targetInfo = default(TargetRestoreInfo), string recoveryMode = default(string), System.DateTime? pointInTime = default(System.DateTime?), RecoveryPointRehydrationInfo recoveryPointRehydrationInfo = default(RecoveryPointRehydrationInfo))
+ : base(recoveryType, sourceResourceId, propertyBag, targetInfo, recoveryMode, pointInTime)
+ {
+ RecoveryPointRehydrationInfo = recoveryPointRehydrationInfo;
+ CustomInit();
+ }
+
+ ///
+ /// An initialization method that performs custom operations like setting defaults
+ ///
+ partial void CustomInit();
+
+ ///
+ /// Gets or sets RP Rehydration Info
+ ///
+ [JsonProperty(PropertyName = "recoveryPointRehydrationInfo")]
+ public RecoveryPointRehydrationInfo RecoveryPointRehydrationInfo { get; set; }
+
+ }
+}
diff --git a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaRecoveryPoint.cs b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaRecoveryPoint.cs
index 58388dd32502..8d921ce2b579 100644
--- a/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaRecoveryPoint.cs
+++ b/sdk/recoveryservices-backup/Microsoft.Azure.Management.RecoveryServices.Backup/src/Generated/Models/AzureWorkloadSAPHanaRecoveryPoint.cs
@@ -10,6 +10,8 @@
namespace Microsoft.Azure.Management.RecoveryServices.Backup.Models
{
+ using System.Collections;
+ using System.Collections.Generic;
using System.Linq;
///
@@ -35,8 +37,12 @@ public AzureWorkloadSAPHanaRecoveryPoint()
/// point was created
/// Type of restore point. Possible values include:
/// 'Invalid', 'Full', 'Log', 'Differential', 'Incremental'
- public AzureWorkloadSAPHanaRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string))
- : base(recoveryPointTimeInUTC, type)
+ /// Recovery point tier
+ /// information.
+ /// Eligibility of RP to
+ /// be moved to another tier
+ public AzureWorkloadSAPHanaRecoveryPoint(System.DateTime? recoveryPointTimeInUTC = default(System.DateTime?), string type = default(string), IList recoveryPointTierDetails = default(IList