From d3bdb4ed68c623c31497b6121e85a89a01a6621b Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 17 Jul 2018 15:59:29 -0700 Subject: [PATCH] Generated from cd62a73e3ee9ec6ab5fcac545fb206d29e6311bf (#2238) Fixed operation ID for configuration operation --- .../hdinsight/mgmt/hdinsight/models.go | 2 +- .../hdinsight/configurations.go | 26 +++++++++---------- .../2018-06-01-preview/hdinsight/models.go | 11 ++++---- 3 files changed, 19 insertions(+), 20 deletions(-) diff --git a/profiles/preview/preview/hdinsight/mgmt/hdinsight/models.go b/profiles/preview/preview/hdinsight/mgmt/hdinsight/models.go index 541895a71026..572852f03627 100644 --- a/profiles/preview/preview/hdinsight/mgmt/hdinsight/models.go +++ b/profiles/preview/preview/hdinsight/mgmt/hdinsight/models.go @@ -98,7 +98,7 @@ type ClustersDeleteFuture = original.ClustersDeleteFuture type ClustersExecuteScriptActionsFuture = original.ClustersExecuteScriptActionsFuture type ClustersResizeFuture = original.ClustersResizeFuture type ComputeProfile = original.ComputeProfile -type ConfigurationsUpdateHTTPSettingsFuture = original.ConfigurationsUpdateHTTPSettingsFuture +type ConfigurationsUpdateFuture = original.ConfigurationsUpdateFuture type ConnectivityEndpoint = original.ConnectivityEndpoint type DataDisksGroups = original.DataDisksGroups type ErrorResponse = original.ErrorResponse diff --git a/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/configurations.go b/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/configurations.go index 6abb70cb09c1..1d60ee1327d7 100644 --- a/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/configurations.go +++ b/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/configurations.go @@ -109,36 +109,36 @@ func (client ConfigurationsClient) GetResponder(resp *http.Response) (result Set return } -// UpdateHTTPSettings configures the HTTP settings on the specified cluster. +// Update configures the configuration on the specified cluster. // Parameters: // resourceGroupName - the name of the resource group. // clusterName - the name of the cluster. // configurationName - the name of the cluster configuration. // parameters - the cluster configurations. -func (client ConfigurationsClient) UpdateHTTPSettings(ctx context.Context, resourceGroupName string, clusterName string, configurationName string, parameters map[string]*string) (result ConfigurationsUpdateHTTPSettingsFuture, err error) { +func (client ConfigurationsClient) Update(ctx context.Context, resourceGroupName string, clusterName string, configurationName string, parameters map[string]*string) (result ConfigurationsUpdateFuture, err error) { if err := validation.Validate([]validation.Validation{ {TargetValue: parameters, Constraints: []validation.Constraint{{Target: "parameters", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil { - return result, validation.NewError("hdinsight.ConfigurationsClient", "UpdateHTTPSettings", err.Error()) + return result, validation.NewError("hdinsight.ConfigurationsClient", "Update", err.Error()) } - req, err := client.UpdateHTTPSettingsPreparer(ctx, resourceGroupName, clusterName, configurationName, parameters) + req, err := client.UpdatePreparer(ctx, resourceGroupName, clusterName, configurationName, parameters) if err != nil { - err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsClient", "UpdateHTTPSettings", nil, "Failure preparing request") + err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsClient", "Update", nil, "Failure preparing request") return } - result, err = client.UpdateHTTPSettingsSender(req) + result, err = client.UpdateSender(req) if err != nil { - err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsClient", "UpdateHTTPSettings", result.Response(), "Failure sending request") + err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsClient", "Update", result.Response(), "Failure sending request") return } return } -// UpdateHTTPSettingsPreparer prepares the UpdateHTTPSettings request. -func (client ConfigurationsClient) UpdateHTTPSettingsPreparer(ctx context.Context, resourceGroupName string, clusterName string, configurationName string, parameters map[string]*string) (*http.Request, error) { +// UpdatePreparer prepares the Update request. +func (client ConfigurationsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, clusterName string, configurationName string, parameters map[string]*string) (*http.Request, error) { pathParameters := map[string]interface{}{ "clusterName": autorest.Encode("path", clusterName), "configurationName": autorest.Encode("path", configurationName), @@ -161,9 +161,9 @@ func (client ConfigurationsClient) UpdateHTTPSettingsPreparer(ctx context.Contex return preparer.Prepare((&http.Request{}).WithContext(ctx)) } -// UpdateHTTPSettingsSender sends the UpdateHTTPSettings request. The method will close the +// UpdateSender sends the Update request. The method will close the // http.Response Body if it receives an error. -func (client ConfigurationsClient) UpdateHTTPSettingsSender(req *http.Request) (future ConfigurationsUpdateHTTPSettingsFuture, err error) { +func (client ConfigurationsClient) UpdateSender(req *http.Request) (future ConfigurationsUpdateFuture, err error) { var resp *http.Response resp, err = autorest.SendWithSender(client, req, azure.DoRetryWithRegistration(client.Client)) @@ -178,9 +178,9 @@ func (client ConfigurationsClient) UpdateHTTPSettingsSender(req *http.Request) ( return } -// UpdateHTTPSettingsResponder handles the response to the UpdateHTTPSettings request. The method always +// UpdateResponder handles the response to the Update request. The method always // closes the http.Response Body. -func (client ConfigurationsClient) UpdateHTTPSettingsResponder(resp *http.Response) (result autorest.Response, err error) { +func (client ConfigurationsClient) UpdateResponder(resp *http.Response) (result autorest.Response, err error) { err = autorest.Respond( resp, client.ByInspecting(), diff --git a/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go b/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go index 7600979e8b14..30889b3932f5 100644 --- a/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go +++ b/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go @@ -775,23 +775,22 @@ type ComputeProfile struct { Roles *[]Role `json:"roles,omitempty"` } -// ConfigurationsUpdateHTTPSettingsFuture an abstraction for monitoring and retrieving the results of a -// long-running operation. -type ConfigurationsUpdateHTTPSettingsFuture struct { +// ConfigurationsUpdateFuture an abstraction for monitoring and retrieving the results of a long-running operation. +type ConfigurationsUpdateFuture struct { azure.Future } // Result returns the result of the asynchronous operation. // If the operation has not completed it will return an error. -func (future *ConfigurationsUpdateHTTPSettingsFuture) Result(client ConfigurationsClient) (ar autorest.Response, err error) { +func (future *ConfigurationsUpdateFuture) Result(client ConfigurationsClient) (ar autorest.Response, err error) { var done bool done, err = future.Done(client) if err != nil { - err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsUpdateHTTPSettingsFuture", "Result", future.Response(), "Polling failure") + err = autorest.NewErrorWithError(err, "hdinsight.ConfigurationsUpdateFuture", "Result", future.Response(), "Polling failure") return } if !done { - err = azure.NewAsyncOpIncompleteError("hdinsight.ConfigurationsUpdateHTTPSettingsFuture") + err = azure.NewAsyncOpIncompleteError("hdinsight.ConfigurationsUpdateFuture") return } ar.Response = future.Response()