diff --git a/profiles/latest/operationalinsights/mgmt/operationalinsights/models.go b/profiles/latest/operationalinsights/mgmt/operationalinsights/models.go index d0a4679c911f..38e9078107cf 100644 --- a/profiles/latest/operationalinsights/mgmt/operationalinsights/models.go +++ b/profiles/latest/operationalinsights/mgmt/operationalinsights/models.go @@ -64,13 +64,9 @@ type SavedSearch = original.SavedSearch type SavedSearchProperties = original.SavedSearchProperties type SavedSearchesClient = original.SavedSearchesClient type SavedSearchesListResult = original.SavedSearchesListResult -type SearchError = original.SearchError type SearchGetSchemaResponse = original.SearchGetSchemaResponse -type SearchHighlight = original.SearchHighlight type SearchMetadata = original.SearchMetadata type SearchMetadataSchema = original.SearchMetadataSchema -type SearchParameters = original.SearchParameters -type SearchResultsResponse = original.SearchResultsResponse type SearchSchemaValue = original.SearchSchemaValue type SearchSort = original.SearchSort type SharedKeys = original.SharedKeys @@ -88,7 +84,6 @@ type WorkspacePurgeBodyFilters = original.WorkspacePurgeBodyFilters type WorkspacePurgeResponse = original.WorkspacePurgeResponse type WorkspacePurgeStatusResponse = original.WorkspacePurgeStatusResponse type WorkspacesClient = original.WorkspacesClient -type WorkspacesGetSearchResultsFuture = original.WorkspacesGetSearchResultsFuture func New(subscriptionID string, purgeID string) BaseClient { return original.New(subscriptionID, purgeID) diff --git a/profiles/preview/operationalinsights/mgmt/operationalinsights/models.go b/profiles/preview/operationalinsights/mgmt/operationalinsights/models.go index d77d183fbf2c..072914563365 100644 --- a/profiles/preview/operationalinsights/mgmt/operationalinsights/models.go +++ b/profiles/preview/operationalinsights/mgmt/operationalinsights/models.go @@ -64,13 +64,9 @@ type SavedSearch = original.SavedSearch type SavedSearchProperties = original.SavedSearchProperties type SavedSearchesClient = original.SavedSearchesClient type SavedSearchesListResult = original.SavedSearchesListResult -type SearchError = original.SearchError type SearchGetSchemaResponse = original.SearchGetSchemaResponse -type SearchHighlight = original.SearchHighlight type SearchMetadata = original.SearchMetadata type SearchMetadataSchema = original.SearchMetadataSchema -type SearchParameters = original.SearchParameters -type SearchResultsResponse = original.SearchResultsResponse type SearchSchemaValue = original.SearchSchemaValue type SearchSort = original.SearchSort type SharedKeys = original.SharedKeys @@ -88,7 +84,6 @@ type WorkspacePurgeBodyFilters = original.WorkspacePurgeBodyFilters type WorkspacePurgeResponse = original.WorkspacePurgeResponse type WorkspacePurgeStatusResponse = original.WorkspacePurgeStatusResponse type WorkspacesClient = original.WorkspacesClient -type WorkspacesGetSearchResultsFuture = original.WorkspacesGetSearchResultsFuture func New(subscriptionID string, purgeID string) BaseClient { return original.New(subscriptionID, purgeID) diff --git a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/models.go b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/models.go index 53135ebcbfaa..1e5b422a5761 100644 --- a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/models.go +++ b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/models.go @@ -21,7 +21,6 @@ import ( "context" "encoding/json" "github.com/Azure/go-autorest/autorest" - "github.com/Azure/go-autorest/autorest/azure" "github.com/Azure/go-autorest/autorest/date" "github.com/Azure/go-autorest/autorest/to" "github.com/Azure/go-autorest/tracing" @@ -264,7 +263,7 @@ func (ss *SavedSearch) UnmarshalJSON(body []byte) error { // SavedSearchesListResult the saved search list operation response. type SavedSearchesListResult struct { autorest.Response `json:"-"` - // Metadata - The metadata from search results. + // Metadata - Unused legacy property, kept here for backward compatibility. Metadata *SearchMetadata `json:"__metadata,omitempty"` // Value - The array of result values. Value *[]SavedSearch `json:"value,omitempty"` @@ -284,14 +283,6 @@ type SavedSearchProperties struct { Tags *[]Tag `json:"tags,omitempty"` } -// SearchError details for a search error. -type SearchError struct { - // Type - The error type. - Type *string `json:"type,omitempty"` - // Message - The error message. - Message *string `json:"message,omitempty"` -} - // SearchGetSchemaResponse the get schema operation response. type SearchGetSchemaResponse struct { autorest.Response `json:"-"` @@ -301,14 +292,6 @@ type SearchGetSchemaResponse struct { Value *[]SearchSchemaValue `json:"value,omitempty"` } -// SearchHighlight highlight details. -type SearchHighlight struct { - // Pre - The string that is put before a matched result. - Pre *string `json:"pre,omitempty"` - // Post - The string that is put after a matched result. - Post *string `json:"post,omitempty"` -} - // SearchMetadata metadata for search results. type SearchMetadata struct { // SearchID - The request id of the search. @@ -355,33 +338,6 @@ type SearchMetadataSchema struct { Version *int32 `json:"version,omitempty"` } -// SearchParameters parameters specifying the search query and range. -type SearchParameters struct { - // Top - The number to get from the top. - Top *int64 `json:"top,omitempty"` - // Highlight - The highlight that looks for all occurrences of a string. - Highlight *SearchHighlight `json:"highlight,omitempty"` - // Query - The query to search. - Query *string `json:"query,omitempty"` - // Start - The start date filter, so the only query results returned are after this date. - Start *date.Time `json:"start,omitempty"` - // End - The end date filter, so the only query results returned are before this date. - End *date.Time `json:"end,omitempty"` -} - -// SearchResultsResponse the get search result operation response. -type SearchResultsResponse struct { - autorest.Response `json:"-"` - // ID - READ-ONLY; The id of the search, which includes the full url. - ID *string `json:"id,omitempty"` - // Metadata - The metadata from search results. - Metadata *SearchMetadata `json:"metaData,omitempty"` - // Value - The array of result values. - Value *[]interface{} `json:"value,omitempty"` - // Error - The error. - Error *SearchError `json:"error,omitempty"` -} - // SearchSchemaValue value object for schema results. type SearchSchemaValue struct { // Name - The name of the schema. @@ -733,32 +689,3 @@ type WorkspacePurgeStatusResponse struct { // Status - Status of the operation represented by the requested Id. Possible values include: 'Pending', 'Completed' Status PurgeState `json:"status,omitempty"` } - -// WorkspacesGetSearchResultsFuture an abstraction for monitoring and retrieving the results of a -// long-running operation. -type WorkspacesGetSearchResultsFuture struct { - azure.Future -} - -// Result returns the result of the asynchronous operation. -// If the operation has not completed it will return an error. -func (future *WorkspacesGetSearchResultsFuture) Result(client WorkspacesClient) (srr SearchResultsResponse, err error) { - var done bool - done, err = future.DoneWithContext(context.Background(), client) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesGetSearchResultsFuture", "Result", future.Response(), "Polling failure") - return - } - if !done { - err = azure.NewAsyncOpIncompleteError("operationalinsights.WorkspacesGetSearchResultsFuture") - return - } - sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...)) - if srr.Response.Response, err = future.GetResult(sender); err == nil && srr.Response.Response.StatusCode != http.StatusNoContent { - srr, err = client.GetSearchResultsResponder(srr.Response.Response) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesGetSearchResultsFuture", "Result", srr.Response.Response, "Failure responding to request") - } - } - return -} diff --git a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/operationalinsightsapi/interfaces.go b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/operationalinsightsapi/interfaces.go index 659bb6cffd24..7db515a6cbbd 100644 --- a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/operationalinsightsapi/interfaces.go +++ b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/operationalinsightsapi/interfaces.go @@ -38,12 +38,10 @@ type WorkspacesClientAPI interface { DeleteGateways(ctx context.Context, resourceGroupName string, workspaceName string, gatewayID string) (result autorest.Response, err error) GetPurgeStatus(ctx context.Context, resourceGroupName string, workspaceName string) (result operationalinsights.WorkspacePurgeStatusResponse, err error) GetSchema(ctx context.Context, resourceGroupName string, workspaceName string) (result operationalinsights.SearchGetSchemaResponse, err error) - GetSearchResults(ctx context.Context, resourceGroupName string, workspaceName string, parameters operationalinsights.SearchParameters) (result operationalinsights.WorkspacesGetSearchResultsFuture, err error) ListKeys(ctx context.Context, resourceGroupName string, workspaceName string) (result operationalinsights.SharedKeys, err error) ListLinkTargets(ctx context.Context) (result operationalinsights.ListLinkTarget, err error) Purge(ctx context.Context, resourceGroupName string, workspaceName string, body operationalinsights.WorkspacePurgeBody) (result operationalinsights.WorkspacePurgeResponse, err error) RegenerateSharedKeys(ctx context.Context, resourceGroupName string, workspaceName string) (result operationalinsights.SharedKeys, err error) - UpdateSearchResults(ctx context.Context, resourceGroupName string, workspaceName string, ID string) (result operationalinsights.SearchResultsResponse, err error) } var _ WorkspacesClientAPI = (*operationalinsights.WorkspacesClient)(nil) @@ -53,7 +51,6 @@ type SavedSearchesClientAPI interface { CreateOrUpdate(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string, parameters operationalinsights.SavedSearch) (result operationalinsights.SavedSearch, err error) Delete(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string) (result autorest.Response, err error) Get(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string) (result operationalinsights.SavedSearch, err error) - GetResults(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string) (result operationalinsights.SearchResultsResponse, err error) ListByWorkspace(ctx context.Context, resourceGroupName string, workspaceName string) (result operationalinsights.SavedSearchesListResult, err error) } diff --git a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/savedsearches.go b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/savedsearches.go index 62b89f840ccc..c14989217454 100644 --- a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/savedsearches.go +++ b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/savedsearches.go @@ -317,93 +317,6 @@ func (client SavedSearchesClient) GetResponder(resp *http.Response) (result Save return } -// GetResults gets the results from a saved search for a given workspace. -// Parameters: -// resourceGroupName - the Resource Group name. -// workspaceName - the Log Analytics Workspace name. -// savedSearchID - the id of the saved search. -func (client SavedSearchesClient) GetResults(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string) (result SearchResultsResponse, err error) { - if tracing.IsEnabled() { - ctx = tracing.StartSpan(ctx, fqdn+"/SavedSearchesClient.GetResults") - defer func() { - sc := -1 - if result.Response.Response != nil { - sc = result.Response.Response.StatusCode - } - tracing.EndSpan(ctx, sc, err) - }() - } - if err := validation.Validate([]validation.Validation{ - {TargetValue: resourceGroupName, - Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil}, - {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}, - {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+$`, Chain: nil}}}}); err != nil { - return result, validation.NewError("operationalinsights.SavedSearchesClient", "GetResults", err.Error()) - } - - req, err := client.GetResultsPreparer(ctx, resourceGroupName, workspaceName, savedSearchID) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.SavedSearchesClient", "GetResults", nil, "Failure preparing request") - return - } - - resp, err := client.GetResultsSender(req) - if err != nil { - result.Response = autorest.Response{Response: resp} - err = autorest.NewErrorWithError(err, "operationalinsights.SavedSearchesClient", "GetResults", resp, "Failure sending request") - return - } - - result, err = client.GetResultsResponder(resp) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.SavedSearchesClient", "GetResults", resp, "Failure responding to request") - } - - return -} - -// GetResultsPreparer prepares the GetResults request. -func (client SavedSearchesClient) GetResultsPreparer(ctx context.Context, resourceGroupName string, workspaceName string, savedSearchID string) (*http.Request, error) { - pathParameters := map[string]interface{}{ - "resourceGroupName": autorest.Encode("path", resourceGroupName), - "savedSearchId": autorest.Encode("path", savedSearchID), - "subscriptionId": autorest.Encode("path", client.SubscriptionID), - "workspaceName": autorest.Encode("path", workspaceName), - } - - const APIVersion = "2015-03-20" - queryParameters := map[string]interface{}{ - "api-version": APIVersion, - } - - preparer := autorest.CreatePreparer( - autorest.AsGet(), - autorest.WithBaseURL(client.BaseURI), - autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/savedSearches/{savedSearchId}/results", pathParameters), - autorest.WithQueryParameters(queryParameters)) - return preparer.Prepare((&http.Request{}).WithContext(ctx)) -} - -// GetResultsSender sends the GetResults request. The method will close the -// http.Response Body if it receives an error. -func (client SavedSearchesClient) GetResultsSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) -} - -// GetResultsResponder handles the response to the GetResults request. The method always -// closes the http.Response Body. -func (client SavedSearchesClient) GetResultsResponder(resp *http.Response) (result SearchResultsResponse, err error) { - err = autorest.Respond( - resp, - client.ByInspecting(), - azure.WithErrorUnlessStatusCode(http.StatusOK), - autorest.ByUnmarshallingJSON(&result), - autorest.ByClosing()) - result.Response = autorest.Response{Response: resp} - return -} - // ListByWorkspace gets the saved searches for a given Log Analytics Workspace // Parameters: // resourceGroupName - the Resource Group name. diff --git a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/workspaces.go b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/workspaces.go index 151d5fdd4ca0..26f9a8aa6db7 100644 --- a/services/operationalinsights/mgmt/2015-03-20/operationalinsights/workspaces.go +++ b/services/operationalinsights/mgmt/2015-03-20/operationalinsights/workspaces.go @@ -298,98 +298,6 @@ func (client WorkspacesClient) GetSchemaResponder(resp *http.Response) (result S return } -// GetSearchResults submit a search for a given workspace. The response will contain an id to track the search. User -// can use the id to poll the search status and get the full search result later if the search takes long time to -// finish. -// Parameters: -// resourceGroupName - the Resource Group name. -// workspaceName - the Log Analytics Workspace name. -// parameters - the parameters required to execute a search query. -func (client WorkspacesClient) GetSearchResults(ctx context.Context, resourceGroupName string, workspaceName string, parameters SearchParameters) (result WorkspacesGetSearchResultsFuture, err error) { - if tracing.IsEnabled() { - ctx = tracing.StartSpan(ctx, fqdn+"/WorkspacesClient.GetSearchResults") - defer func() { - sc := -1 - if result.Response() != nil { - sc = result.Response().StatusCode - } - tracing.EndSpan(ctx, sc, err) - }() - } - if err := validation.Validate([]validation.Validation{ - {TargetValue: resourceGroupName, - Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil}, - {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}, - {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+$`, Chain: nil}}}, - {TargetValue: parameters, - Constraints: []validation.Constraint{{Target: "parameters.Query", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil { - return result, validation.NewError("operationalinsights.WorkspacesClient", "GetSearchResults", err.Error()) - } - - req, err := client.GetSearchResultsPreparer(ctx, resourceGroupName, workspaceName, parameters) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesClient", "GetSearchResults", nil, "Failure preparing request") - return - } - - result, err = client.GetSearchResultsSender(req) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesClient", "GetSearchResults", result.Response(), "Failure sending request") - return - } - - return -} - -// GetSearchResultsPreparer prepares the GetSearchResults request. -func (client WorkspacesClient) GetSearchResultsPreparer(ctx context.Context, resourceGroupName string, workspaceName string, parameters SearchParameters) (*http.Request, error) { - pathParameters := map[string]interface{}{ - "resourceGroupName": autorest.Encode("path", resourceGroupName), - "subscriptionId": autorest.Encode("path", client.SubscriptionID), - "workspaceName": autorest.Encode("path", workspaceName), - } - - const APIVersion = "2015-03-20" - queryParameters := map[string]interface{}{ - "api-version": APIVersion, - } - - preparer := autorest.CreatePreparer( - autorest.AsContentType("application/json; charset=utf-8"), - autorest.AsPost(), - autorest.WithBaseURL(client.BaseURI), - autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/search", pathParameters), - autorest.WithJSON(parameters), - autorest.WithQueryParameters(queryParameters)) - return preparer.Prepare((&http.Request{}).WithContext(ctx)) -} - -// GetSearchResultsSender sends the GetSearchResults request. The method will close the -// http.Response Body if it receives an error. -func (client WorkspacesClient) GetSearchResultsSender(req *http.Request) (future WorkspacesGetSearchResultsFuture, err error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - var resp *http.Response - resp, err = autorest.SendWithSender(client, req, sd...) - if err != nil { - return - } - future.Future, err = azure.NewFutureFromResponse(resp) - return -} - -// GetSearchResultsResponder handles the response to the GetSearchResults request. The method always -// closes the http.Response Body. -func (client WorkspacesClient) GetSearchResultsResponder(resp *http.Response) (result SearchResultsResponse, err error) { - err = autorest.Respond( - resp, - client.ByInspecting(), - azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted), - autorest.ByUnmarshallingJSON(&result), - autorest.ByClosing()) - result.Response = autorest.Response{Response: resp} - return -} - // ListKeys gets the shared keys for a Log Analytics Workspace. These keys are used to connect Microsoft Operational // Insights agents to the workspace. // Parameters: @@ -550,6 +458,11 @@ func (client WorkspacesClient) ListLinkTargetsResponder(resp *http.Response) (re } // Purge purges data in an Log Analytics workspace by a set of user-defined filters. +// +// In order to manage system resources, purge requests are throttled at 50 requests per hour. You should batch the +// execution of purge requests by sending a single command whose predicate includes all user identities that require +// purging. Use the in operator to specify multiple identities. You should run the query prior to using for a purge +// request to verify that the results are expected. // Parameters: // resourceGroupName - the Resource Group name. // workspaceName - the Log Analytics Workspace name. @@ -725,91 +638,3 @@ func (client WorkspacesClient) RegenerateSharedKeysResponder(resp *http.Response result.Response = autorest.Response{Response: resp} return } - -// UpdateSearchResults gets updated search results for a given search query. -// Parameters: -// resourceGroupName - the Resource Group name. -// workspaceName - the Log Analytics Workspace name. -// ID - the id of the search that will have results updated. You can get the id from the response of the -// GetResults call. -func (client WorkspacesClient) UpdateSearchResults(ctx context.Context, resourceGroupName string, workspaceName string, ID string) (result SearchResultsResponse, err error) { - if tracing.IsEnabled() { - ctx = tracing.StartSpan(ctx, fqdn+"/WorkspacesClient.UpdateSearchResults") - defer func() { - sc := -1 - if result.Response.Response != nil { - sc = result.Response.Response.StatusCode - } - tracing.EndSpan(ctx, sc, err) - }() - } - if err := validation.Validate([]validation.Validation{ - {TargetValue: resourceGroupName, - Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil}, - {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil}, - {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+$`, Chain: nil}}}}); err != nil { - return result, validation.NewError("operationalinsights.WorkspacesClient", "UpdateSearchResults", err.Error()) - } - - req, err := client.UpdateSearchResultsPreparer(ctx, resourceGroupName, workspaceName, ID) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesClient", "UpdateSearchResults", nil, "Failure preparing request") - return - } - - resp, err := client.UpdateSearchResultsSender(req) - if err != nil { - result.Response = autorest.Response{Response: resp} - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesClient", "UpdateSearchResults", resp, "Failure sending request") - return - } - - result, err = client.UpdateSearchResultsResponder(resp) - if err != nil { - err = autorest.NewErrorWithError(err, "operationalinsights.WorkspacesClient", "UpdateSearchResults", resp, "Failure responding to request") - } - - return -} - -// UpdateSearchResultsPreparer prepares the UpdateSearchResults request. -func (client WorkspacesClient) UpdateSearchResultsPreparer(ctx context.Context, resourceGroupName string, workspaceName string, ID string) (*http.Request, error) { - pathParameters := map[string]interface{}{ - "id": autorest.Encode("path", ID), - "resourceGroupName": autorest.Encode("path", resourceGroupName), - "subscriptionId": autorest.Encode("path", client.SubscriptionID), - "workspaceName": autorest.Encode("path", workspaceName), - } - - const APIVersion = "2015-03-20" - queryParameters := map[string]interface{}{ - "api-version": APIVersion, - } - - preparer := autorest.CreatePreparer( - autorest.AsPost(), - autorest.WithBaseURL(client.BaseURI), - autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/search/{id}", pathParameters), - autorest.WithQueryParameters(queryParameters)) - return preparer.Prepare((&http.Request{}).WithContext(ctx)) -} - -// UpdateSearchResultsSender sends the UpdateSearchResults request. The method will close the -// http.Response Body if it receives an error. -func (client WorkspacesClient) UpdateSearchResultsSender(req *http.Request) (*http.Response, error) { - sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client)) - return autorest.SendWithSender(client, req, sd...) -} - -// UpdateSearchResultsResponder handles the response to the UpdateSearchResults request. The method always -// closes the http.Response Body. -func (client WorkspacesClient) UpdateSearchResultsResponder(resp *http.Response) (result SearchResultsResponse, err error) { - err = autorest.Respond( - resp, - client.ByInspecting(), - azure.WithErrorUnlessStatusCode(http.StatusOK), - autorest.ByUnmarshallingJSON(&result), - autorest.ByClosing()) - result.Response = autorest.Response{Response: resp} - return -} diff --git a/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go b/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go index b71302b59126..a47383465675 100644 --- a/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go +++ b/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go @@ -872,11 +872,11 @@ type WorkspaceListUsagesResult struct { type WorkspaceProperties struct { // ProvisioningState - The provisioning state of the workspace. Possible values include: 'Creating', 'Succeeded', 'Failed', 'Canceled', 'Deleting', 'ProvisioningAccount' ProvisioningState EntityStatus `json:"provisioningState,omitempty"` - // Source - The source of the workspace. Source defines where the workspace was created. 'Azure' implies it was created in Azure. 'External' implies it was created via the Operational Insights Portal. This value is set on the service side and read-only on the client side. + // Source - READ-ONLY; This is a read-only legacy property. It is always set to 'Azure' by the service. Kept here for backward compatibility. Source *string `json:"source,omitempty"` - // CustomerID - The ID associated with the workspace. Setting this value at creation time allows the workspace being created to be linked to an existing workspace. + // CustomerID - READ-ONLY; This is a read-only property. Represents the ID associated with the workspace. CustomerID *string `json:"customerId,omitempty"` - // PortalURL - The URL of the Operational Insights portal for this workspace. This value is set on the service side and read-only on the client side. + // PortalURL - READ-ONLY; This is a legacy property and is not used anymore. Kept here for backward compatibility. PortalURL *string `json:"portalUrl,omitempty"` // Sku - The SKU of the workspace. Sku *Sku `json:"sku,omitempty"`