diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/backupapi/interfaces.go b/services/recoveryservices/mgmt/2019-06-15/backup/backupapi/interfaces.go index 7b20b6a876fb..b5fe4994b64f 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/backupapi/interfaces.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/backupapi/interfaces.go @@ -26,6 +26,7 @@ import ( // ResourceVaultConfigsClientAPI contains the set of methods on the ResourceVaultConfigsClient type. type ResourceVaultConfigsClientAPI interface { Get(ctx context.Context, vaultName string, resourceGroupName string) (result backup.ResourceVaultConfigResource, err error) + Put(ctx context.Context, vaultName string, resourceGroupName string, parameters backup.ResourceVaultConfigResource) (result backup.ResourceVaultConfigResource, err error) Update(ctx context.Context, vaultName string, resourceGroupName string, parameters backup.ResourceVaultConfigResource) (result backup.ResourceVaultConfigResource, err error) } diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/backups.go b/services/recoveryservices/mgmt/2019-06-15/backup/backups.go index 2a389bc1f90f..f887309cc63d 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/backups.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/backups.go @@ -111,8 +111,7 @@ func (client BackupsClient) TriggerPreparer(ctx context.Context, vaultName strin // TriggerSender sends the Trigger request. The method will close the // http.Response Body if it receives an error. func (client BackupsClient) TriggerSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // TriggerResponder handles the response to the Trigger request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/engines.go b/services/recoveryservices/mgmt/2019-06-15/backup/engines.go index fc9aa41d61e5..9ee3414d00cb 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/engines.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/engines.go @@ -111,8 +111,7 @@ func (client EnginesClient) GetPreparer(ctx context.Context, vaultName string, r // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client EnginesClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -197,8 +196,7 @@ func (client EnginesClient) ListPreparer(ctx context.Context, vaultName string, // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client EnginesClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/exportjobsoperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/exportjobsoperationresults.go index b0fd8d037b93..3082195aefef 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/exportjobsoperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/exportjobsoperationresults.go @@ -106,8 +106,7 @@ func (client ExportJobsOperationResultsClient) GetPreparer(ctx context.Context, // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ExportJobsOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/featuresupport.go b/services/recoveryservices/mgmt/2019-06-15/backup/featuresupport.go index 92881d841fd9..21b28511417c 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/featuresupport.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/featuresupport.go @@ -102,8 +102,7 @@ func (client FeatureSupportClient) ValidatePreparer(ctx context.Context, azureRe // ValidateSender sends the Validate request. The method will close the // http.Response Body if it receives an error. func (client FeatureSupportClient) ValidateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ValidateResponder handles the response to the Validate request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/itemlevelrecoveryconnections.go b/services/recoveryservices/mgmt/2019-06-15/backup/itemlevelrecoveryconnections.go index d6ba8b5e4037..fb24b7f5b891 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/itemlevelrecoveryconnections.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/itemlevelrecoveryconnections.go @@ -117,8 +117,7 @@ func (client ItemLevelRecoveryConnectionsClient) ProvisionPreparer(ctx context.C // ProvisionSender sends the Provision request. The method will close the // http.Response Body if it receives an error. func (client ItemLevelRecoveryConnectionsClient) ProvisionSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ProvisionResponder handles the response to the Provision request. The method always @@ -204,8 +203,7 @@ func (client ItemLevelRecoveryConnectionsClient) RevokePreparer(ctx context.Cont // RevokeSender sends the Revoke request. The method will close the // http.Response Body if it receives an error. func (client ItemLevelRecoveryConnectionsClient) RevokeSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // RevokeResponder handles the response to the Revoke request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/jobcancellations.go b/services/recoveryservices/mgmt/2019-06-15/backup/jobcancellations.go index 61147c164b44..efea13d8ffd8 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/jobcancellations.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/jobcancellations.go @@ -105,8 +105,7 @@ func (client JobCancellationsClient) TriggerPreparer(ctx context.Context, vaultN // TriggerSender sends the Trigger request. The method will close the // http.Response Body if it receives an error. func (client JobCancellationsClient) TriggerSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // TriggerResponder handles the response to the Trigger request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/jobdetails.go b/services/recoveryservices/mgmt/2019-06-15/backup/jobdetails.go index 5e586acecdc1..1e48df53c38e 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/jobdetails.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/jobdetails.go @@ -103,8 +103,7 @@ func (client JobDetailsClient) GetPreparer(ctx context.Context, vaultName string // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client JobDetailsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/joboperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/joboperationresults.go index 1c3b83e0a088..f372117778f2 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/joboperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/joboperationresults.go @@ -106,8 +106,7 @@ func (client JobOperationResultsClient) GetPreparer(ctx context.Context, vaultNa // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client JobOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/jobs.go b/services/recoveryservices/mgmt/2019-06-15/backup/jobs.go index 9fb75355a0a3..25af5d9e814c 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/jobs.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/jobs.go @@ -110,8 +110,7 @@ func (client JobsClient) ListPreparer(ctx context.Context, vaultName string, res // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client JobsClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/jobsgroup.go b/services/recoveryservices/mgmt/2019-06-15/backup/jobsgroup.go index 9dbc1f3d7e44..85542a78ccff 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/jobsgroup.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/jobsgroup.go @@ -105,8 +105,7 @@ func (client JobsGroupClient) ExportPreparer(ctx context.Context, vaultName stri // ExportSender sends the Export request. The method will close the // http.Response Body if it receives an error. func (client JobsGroupClient) ExportSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ExportResponder handles the response to the Export request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/models.go b/services/recoveryservices/mgmt/2019-06-15/backup/models.go index c6f7ec3067df..8cce8a41d291 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/models.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/models.go @@ -12481,6 +12481,14 @@ type EngineExtendedInfo struct { AzureProtectedInstances *int32 `json:"azureProtectedInstances,omitempty"` } +// ErrorAdditionalInfo the resource management error additional info. +type ErrorAdditionalInfo struct { + // Type - READ-ONLY; The additional info type. + Type *string `json:"type,omitempty"` + // Info - READ-ONLY; The additional info. + Info interface{} `json:"info,omitempty"` +} + // ErrorDetail error Detail class which encapsulates Code, Message and Recommendations. type ErrorDetail struct { // Code - READ-ONLY; Error code. @@ -12491,6 +12499,20 @@ type ErrorDetail struct { Recommendations *[]string `json:"recommendations,omitempty"` } +// ErrorResponse the resource management error response. +type ErrorResponse struct { + // Code - READ-ONLY; The error code. + Code *string `json:"code,omitempty"` + // Message - READ-ONLY; The error message. + Message *string `json:"message,omitempty"` + // Target - READ-ONLY; The error target. + Target *string `json:"target,omitempty"` + // Details - READ-ONLY; The error details. + Details *[]ErrorResponse `json:"details,omitempty"` + // AdditionalInfo - READ-ONLY; The error additional info. + AdditionalInfo *[]ErrorAdditionalInfo `json:"additionalInfo,omitempty"` +} + // ExportJobsOperationResultInfo this class is used to send blob details after exporting jobs. type ExportJobsOperationResultInfo struct { // BlobURL - URL of the blob into which the serialized string of list of jobs is exported. diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/operation.go b/services/recoveryservices/mgmt/2019-06-15/backup/operation.go index 9daf7d7dc1b4..5c7cdbc7cfd5 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/operation.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/operation.go @@ -104,8 +104,7 @@ func (client OperationClient) ValidatePreparer(ctx context.Context, vaultName st // ValidateSender sends the Validate request. The method will close the // http.Response Body if it receives an error. func (client OperationClient) ValidateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ValidateResponder handles the response to the Validate request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/operationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/operationresults.go index 4b9e75433bb0..570b865f95f9 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/operationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/operationresults.go @@ -108,8 +108,7 @@ func (client OperationResultsClient) GetPreparer(ctx context.Context, vaultName // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client OperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/operations.go b/services/recoveryservices/mgmt/2019-06-15/backup/operations.go index 188a37bf8c15..850bd6ef7af6 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/operations.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/operations.go @@ -93,8 +93,7 @@ func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client OperationsClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/operationstatuses.go b/services/recoveryservices/mgmt/2019-06-15/backup/operationstatuses.go index c8c1b383eb8e..3f3627256b9e 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/operationstatuses.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/operationstatuses.go @@ -107,8 +107,7 @@ func (client OperationStatusesClient) GetPreparer(ctx context.Context, vaultName // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client OperationStatusesClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/policies.go b/services/recoveryservices/mgmt/2019-06-15/backup/policies.go index 9b61c58c8539..bd595d2c2404 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/policies.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/policies.go @@ -107,8 +107,7 @@ func (client PoliciesClient) ListPreparer(ctx context.Context, vaultName string, // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client PoliciesClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectablecontainers.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectablecontainers.go index 6340a1c1fd61..848fbf5a46bb 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectablecontainers.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectablecontainers.go @@ -108,8 +108,7 @@ func (client ProtectableContainersClient) ListPreparer(ctx context.Context, vaul // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client ProtectableContainersClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectableitems.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectableitems.go index 137522a855fb..832558603898 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectableitems.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectableitems.go @@ -112,8 +112,7 @@ func (client ProtectableItemsClient) ListPreparer(ctx context.Context, vaultName // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client ProtectableItemsClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationresults.go index cd8435b50ff7..2ed37669b592 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationresults.go @@ -110,8 +110,7 @@ func (client ProtectedItemOperationResultsClient) GetPreparer(ctx context.Contex // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationstatuses.go b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationstatuses.go index 2c488d23be42..564cb83712fa 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationstatuses.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemoperationstatuses.go @@ -113,8 +113,7 @@ func (client ProtectedItemOperationStatusesClient) GetPreparer(ctx context.Conte // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemOperationStatusesClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditems.go b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditems.go index 8acbf47b0016..d6495e853e8d 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditems.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditems.go @@ -112,8 +112,7 @@ func (client ProtectedItemsClient) CreateOrUpdatePreparer(ctx context.Context, v // CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always @@ -197,8 +196,7 @@ func (client ProtectedItemsClient) DeletePreparer(ctx context.Context, vaultName // DeleteSender sends the Delete request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemsClient) DeleteSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // DeleteResponder handles the response to the Delete request. The method always @@ -285,8 +283,7 @@ func (client ProtectedItemsClient) GetPreparer(ctx context.Context, vaultName st // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemsgroup.go b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemsgroup.go index 9bb26c9a3131..5431fd7fa8d0 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemsgroup.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protecteditemsgroup.go @@ -111,8 +111,7 @@ func (client ProtectedItemsGroupClient) ListPreparer(ctx context.Context, vaultN // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client ProtectedItemsGroupClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontaineroperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontaineroperationresults.go index 6e8533cf1194..7c681d77a383 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontaineroperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontaineroperationresults.go @@ -109,8 +109,7 @@ func (client ProtectionContainerOperationResultsClient) GetPreparer(ctx context. // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainerOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainerrefreshoperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainerrefreshoperationresults.go index 5fde7c63f5c0..2fad27def222 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainerrefreshoperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainerrefreshoperationresults.go @@ -107,8 +107,7 @@ func (client ProtectionContainerRefreshOperationResultsClient) GetPreparer(ctx c // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainerRefreshOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainers.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainers.go index 7c40fe0d2cc9..19fcfe5eb11a 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainers.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainers.go @@ -106,8 +106,7 @@ func (client ProtectionContainersClient) GetPreparer(ctx context.Context, vaultN // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -191,8 +190,7 @@ func (client ProtectionContainersClient) InquirePreparer(ctx context.Context, va // InquireSender sends the Inquire request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersClient) InquireSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // InquireResponder handles the response to the Inquire request. The method always @@ -275,8 +273,7 @@ func (client ProtectionContainersClient) RefreshPreparer(ctx context.Context, va // RefreshSender sends the Refresh request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersClient) RefreshSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // RefreshResponder handles the response to the Refresh request. The method always @@ -360,8 +357,7 @@ func (client ProtectionContainersClient) RegisterPreparer(ctx context.Context, v // RegisterSender sends the Register request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersClient) RegisterSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // RegisterResponder handles the response to the Register request. The method always @@ -443,8 +439,7 @@ func (client ProtectionContainersClient) UnregisterPreparer(ctx context.Context, // UnregisterSender sends the Unregister request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersClient) UnregisterSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // UnregisterResponder handles the response to the Unregister request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainersgroup.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainersgroup.go index 7d6de9dcfcea..1e449347604a 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainersgroup.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectioncontainersgroup.go @@ -107,8 +107,7 @@ func (client ProtectionContainersGroupClient) ListPreparer(ctx context.Context, // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client ProtectionContainersGroupClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectionintent.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectionintent.go index 13ebf02ea8fc..c4a964235727 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectionintent.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectionintent.go @@ -109,8 +109,7 @@ func (client ProtectionIntentClient) CreateOrUpdatePreparer(ctx context.Context, // CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the // http.Response Body if it receives an error. func (client ProtectionIntentClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always @@ -190,8 +189,7 @@ func (client ProtectionIntentClient) DeletePreparer(ctx context.Context, vaultNa // DeleteSender sends the Delete request. The method will close the // http.Response Body if it receives an error. func (client ProtectionIntentClient) DeleteSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // DeleteResponder handles the response to the Delete request. The method always @@ -272,8 +270,7 @@ func (client ProtectionIntentClient) GetPreparer(ctx context.Context, vaultName // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionIntentClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -350,8 +347,7 @@ func (client ProtectionIntentClient) ValidatePreparer(ctx context.Context, azure // ValidateSender sends the Validate request. The method will close the // http.Response Body if it receives an error. func (client ProtectionIntentClient) ValidateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ValidateResponder handles the response to the Validate request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectionintentgroup.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectionintentgroup.go index 8dd9d8768722..ea8d7b73ee69 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectionintentgroup.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectionintentgroup.go @@ -111,8 +111,7 @@ func (client ProtectionIntentGroupClient) ListPreparer(ctx context.Context, vaul // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client ProtectionIntentGroupClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicies.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicies.go index 31c4d9ccb054..8201292a1650 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicies.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicies.go @@ -109,8 +109,7 @@ func (client ProtectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Contex // CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the // http.Response Body if it receives an error. func (client ProtectionPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always @@ -190,8 +189,7 @@ func (client ProtectionPoliciesClient) DeletePreparer(ctx context.Context, vault // DeleteSender sends the Delete request. The method will close the // http.Response Body if it receives an error. func (client ProtectionPoliciesClient) DeleteSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // DeleteResponder handles the response to the Delete request. The method always @@ -269,8 +267,7 @@ func (client ProtectionPoliciesClient) GetPreparer(ctx context.Context, vaultNam // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationresults.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationresults.go index 19d4ab579281..c39e37eeafe8 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationresults.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationresults.go @@ -106,8 +106,7 @@ func (client ProtectionPolicyOperationResultsClient) GetPreparer(ctx context.Con // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionPolicyOperationResultsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationstatuses.go b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationstatuses.go index e22d4d8ed8be..e1662486e8b2 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationstatuses.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/protectionpolicyoperationstatuses.go @@ -110,8 +110,7 @@ func (client ProtectionPolicyOperationStatusesClient) GetPreparer(ctx context.Co // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ProtectionPolicyOperationStatusesClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/recoverypoints.go b/services/recoveryservices/mgmt/2019-06-15/backup/recoverypoints.go index 19d27076d75a..8698bb22381f 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/recoverypoints.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/recoverypoints.go @@ -111,8 +111,7 @@ func (client RecoveryPointsClient) GetPreparer(ctx context.Context, vaultName st // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client RecoveryPointsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -199,8 +198,7 @@ func (client RecoveryPointsClient) ListPreparer(ctx context.Context, vaultName s // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client RecoveryPointsClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/resourcestorageconfigs.go b/services/recoveryservices/mgmt/2019-06-15/backup/resourcestorageconfigs.go index cdbfd329774b..04f7519e2f8e 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/resourcestorageconfigs.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/resourcestorageconfigs.go @@ -102,8 +102,7 @@ func (client ResourceStorageConfigsClient) GetPreparer(ctx context.Context, vaul // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ResourceStorageConfigsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -182,8 +181,7 @@ func (client ResourceStorageConfigsClient) PatchPreparer(ctx context.Context, va // PatchSender sends the Patch request. The method will close the // http.Response Body if it receives an error. func (client ResourceStorageConfigsClient) PatchSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // PatchResponder handles the response to the Patch request. The method always @@ -261,8 +259,7 @@ func (client ResourceStorageConfigsClient) UpdatePreparer(ctx context.Context, v // UpdateSender sends the Update request. The method will close the // http.Response Body if it receives an error. func (client ResourceStorageConfigsClient) UpdateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // UpdateResponder handles the response to the Update request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/resourcevaultconfigs.go b/services/recoveryservices/mgmt/2019-06-15/backup/resourcevaultconfigs.go index 836314b063bd..bd15ce7eb7db 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/resourcevaultconfigs.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/resourcevaultconfigs.go @@ -102,8 +102,7 @@ func (client ResourceVaultConfigsClient) GetPreparer(ctx context.Context, vaultN // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client ResourceVaultConfigsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always @@ -119,6 +118,85 @@ func (client ResourceVaultConfigsClient) GetResponder(resp *http.Response) (resu return } +// Put updates vault security config. +// Parameters: +// vaultName - the name of the recovery services vault. +// resourceGroupName - the name of the resource group where the recovery services vault is present. +// parameters - resource config request +func (client ResourceVaultConfigsClient) Put(ctx context.Context, vaultName string, resourceGroupName string, parameters ResourceVaultConfigResource) (result ResourceVaultConfigResource, err error) { + if tracing.IsEnabled() { + ctx = tracing.StartSpan(ctx, fqdn+"/ResourceVaultConfigsClient.Put") + defer func() { + sc := -1 + if result.Response.Response != nil { + sc = result.Response.Response.StatusCode + } + tracing.EndSpan(ctx, sc, err) + }() + } + req, err := client.PutPreparer(ctx, vaultName, resourceGroupName, parameters) + if err != nil { + err = autorest.NewErrorWithError(err, "backup.ResourceVaultConfigsClient", "Put", nil, "Failure preparing request") + return + } + + resp, err := client.PutSender(req) + if err != nil { + result.Response = autorest.Response{Response: resp} + err = autorest.NewErrorWithError(err, "backup.ResourceVaultConfigsClient", "Put", resp, "Failure sending request") + return + } + + result, err = client.PutResponder(resp) + if err != nil { + err = autorest.NewErrorWithError(err, "backup.ResourceVaultConfigsClient", "Put", resp, "Failure responding to request") + } + + return +} + +// PutPreparer prepares the Put request. +func (client ResourceVaultConfigsClient) PutPreparer(ctx context.Context, vaultName string, resourceGroupName string, parameters ResourceVaultConfigResource) (*http.Request, error) { + pathParameters := map[string]interface{}{ + "resourceGroupName": autorest.Encode("path", resourceGroupName), + "subscriptionId": autorest.Encode("path", client.SubscriptionID), + "vaultName": autorest.Encode("path", vaultName), + } + + const APIVersion = "2019-06-15" + queryParameters := map[string]interface{}{ + "api-version": APIVersion, + } + + preparer := autorest.CreatePreparer( + autorest.AsContentType("application/json; charset=utf-8"), + autorest.AsPut(), + autorest.WithBaseURL(client.BaseURI), + autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupconfig/vaultconfig", pathParameters), + autorest.WithJSON(parameters), + autorest.WithQueryParameters(queryParameters)) + return preparer.Prepare((&http.Request{}).WithContext(ctx)) +} + +// PutSender sends the Put request. The method will close the +// http.Response Body if it receives an error. +func (client ResourceVaultConfigsClient) PutSender(req *http.Request) (*http.Response, error) { + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) +} + +// PutResponder handles the response to the Put request. The method always +// closes the http.Response Body. +func (client ResourceVaultConfigsClient) PutResponder(resp *http.Response) (result ResourceVaultConfigResource, err error) { + err = autorest.Respond( + resp, + client.ByInspecting(), + azure.WithErrorUnlessStatusCode(http.StatusOK), + autorest.ByUnmarshallingJSON(&result), + autorest.ByClosing()) + result.Response = autorest.Response{Response: resp} + return +} + // Update updates vault security config. // Parameters: // vaultName - the name of the recovery services vault. @@ -182,8 +260,7 @@ func (client ResourceVaultConfigsClient) UpdatePreparer(ctx context.Context, vau // UpdateSender sends the Update request. The method will close the // http.Response Body if it receives an error. func (client ResourceVaultConfigsClient) UpdateSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // UpdateResponder handles the response to the Update request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/restores.go b/services/recoveryservices/mgmt/2019-06-15/backup/restores.go index d0288a3a2239..4e6b2ee42e50 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/restores.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/restores.go @@ -114,8 +114,7 @@ func (client RestoresClient) TriggerPreparer(ctx context.Context, vaultName stri // TriggerSender sends the Trigger request. The method will close the // http.Response Body if it receives an error. func (client RestoresClient) TriggerSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // TriggerResponder handles the response to the Trigger request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/securitypins.go b/services/recoveryservices/mgmt/2019-06-15/backup/securitypins.go index c34b255d99fd..8decfb977983 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/securitypins.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/securitypins.go @@ -101,8 +101,7 @@ func (client SecurityPINsClient) GetPreparer(ctx context.Context, vaultName stri // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client SecurityPINsClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/status.go b/services/recoveryservices/mgmt/2019-06-15/backup/status.go index c0cf0a6839a1..125a23ce64f4 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/status.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/status.go @@ -102,8 +102,7 @@ func (client StatusClient) GetPreparer(ctx context.Context, azureRegion string, // GetSender sends the Get request. The method will close the // http.Response Body if it receives an error. func (client StatusClient) GetSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // GetResponder handles the response to the Get request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/usagesummaries.go b/services/recoveryservices/mgmt/2019-06-15/backup/usagesummaries.go index 6f8638ddb749..3f1aec99a76c 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/usagesummaries.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/usagesummaries.go @@ -109,8 +109,7 @@ func (client UsageSummariesClient) ListPreparer(ctx context.Context, vaultName s // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client UsageSummariesClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always diff --git a/services/recoveryservices/mgmt/2019-06-15/backup/workloaditems.go b/services/recoveryservices/mgmt/2019-06-15/backup/workloaditems.go index b5585cf4ea5f..4572ca04e540 100644 --- a/services/recoveryservices/mgmt/2019-06-15/backup/workloaditems.go +++ b/services/recoveryservices/mgmt/2019-06-15/backup/workloaditems.go @@ -116,8 +116,7 @@ func (client WorkloadItemsClient) ListPreparer(ctx context.Context, vaultName st // ListSender sends the List request. The method will close the // http.Response Body if it receives an error. func (client WorkloadItemsClient) ListSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) + return client.Send(req, azure.DoRetryWithRegistration(client.Client)) } // ListResponder handles the response to the List request. The method always