vendor: update all dependencies to latest versions
This commit is contained in:
Generated
Vendored
+3
-5
@@ -1,5 +1,4 @@
|
||||
// Package account implements the Azure ARM Account service API version
|
||||
// 2016-11-01.
|
||||
// Package account implements the Azure ARM Account service API version 2016-11-01.
|
||||
//
|
||||
// Creates an Azure Data Lake Analytics account management client.
|
||||
package account
|
||||
@@ -18,9 +17,8 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
|
||||
Generated
Vendored
+468
@@ -0,0 +1,468 @@
|
||||
package account
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/autorest/validation"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// ComputePoliciesClient is the creates an Azure Data Lake Analytics account management client.
|
||||
type ComputePoliciesClient struct {
|
||||
ManagementClient
|
||||
}
|
||||
|
||||
// NewComputePoliciesClient creates an instance of the ComputePoliciesClient client.
|
||||
func NewComputePoliciesClient(subscriptionID string) ComputePoliciesClient {
|
||||
return NewComputePoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewComputePoliciesClientWithBaseURI creates an instance of the ComputePoliciesClient client.
|
||||
func NewComputePoliciesClientWithBaseURI(baseURI string, subscriptionID string) ComputePoliciesClient {
|
||||
return ComputePoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates the specified compute policy. During update, the compute policy with the specified
|
||||
// name will be replaced with this new compute policy. An account supports, at most, 50 policies
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to add or replace the compute policy. computePolicyName is the name
|
||||
// of the compute policy to create or update. parameters is parameters supplied to create or update the compute policy.
|
||||
// The max degree of parallelism per job property, min priority per job property, or both must be present.
|
||||
func (client ComputePoliciesClient) CreateOrUpdate(resourceGroupName string, accountName string, computePolicyName string, parameters ComputePolicyCreateOrUpdateParameters) (result ComputePolicy, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: parameters,
|
||||
Constraints: []validation.Constraint{{Target: "parameters.ComputePolicyPropertiesCreateParameters", Name: validation.Null, Rule: true,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ComputePolicyPropertiesCreateParameters.ObjectID", Name: validation.Null, Rule: true, Chain: nil},
|
||||
{Target: "parameters.ComputePolicyPropertiesCreateParameters.MaxDegreeOfParallelismPerJob", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ComputePolicyPropertiesCreateParameters.MaxDegreeOfParallelismPerJob", Name: validation.InclusiveMinimum, Rule: 1, Chain: nil}}},
|
||||
{Target: "parameters.ComputePolicyPropertiesCreateParameters.MinPriorityPerJob", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.ComputePolicyPropertiesCreateParameters.MinPriorityPerJob", Name: validation.InclusiveMinimum, Rule: 1, Chain: nil}}},
|
||||
}}}}}); err != nil {
|
||||
return result, validation.NewErrorWithValidationError(err, "account.ComputePoliciesClient", "CreateOrUpdate")
|
||||
}
|
||||
|
||||
req, err := client.CreateOrUpdatePreparer(resourceGroupName, accountName, computePolicyName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.CreateOrUpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
|
||||
func (client ComputePoliciesClient) CreateOrUpdatePreparer(resourceGroupName string, accountName string, computePolicyName string, parameters ComputePolicyCreateOrUpdateParameters) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"accountName": autorest.Encode("path", accountName),
|
||||
"computePolicyName": autorest.Encode("path", computePolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2016-11-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsJSON(),
|
||||
autorest.AsPut(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/computePolicies/{computePolicyName}", pathParameters),
|
||||
autorest.WithJSON(parameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare(&http.Request{})
|
||||
}
|
||||
|
||||
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ComputePoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
|
||||
return autorest.SendWithSender(client, req)
|
||||
}
|
||||
|
||||
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ComputePoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ComputePolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified compute policy from the specified Data Lake Analytics account
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to delete the compute policy. computePolicyName is the
|
||||
// name of the compute policy to delete.
|
||||
func (client ComputePoliciesClient) Delete(resourceGroupName string, accountName string, computePolicyName string) (result autorest.Response, err error) {
|
||||
req, err := client.DeletePreparer(resourceGroupName, accountName, computePolicyName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Delete", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.DeleteSender(req)
|
||||
if err != nil {
|
||||
result.Response = resp
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Delete", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Delete", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// DeletePreparer prepares the Delete request.
|
||||
func (client ComputePoliciesClient) DeletePreparer(resourceGroupName string, accountName string, computePolicyName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"accountName": autorest.Encode("path", accountName),
|
||||
"computePolicyName": autorest.Encode("path", computePolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2016-11-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsDelete(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/computePolicies/{computePolicyName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare(&http.Request{})
|
||||
}
|
||||
|
||||
// DeleteSender sends the Delete request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ComputePoliciesClient) DeleteSender(req *http.Request) (*http.Response, error) {
|
||||
return autorest.SendWithSender(client, req)
|
||||
}
|
||||
|
||||
// DeleteResponder handles the response to the Delete request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ComputePoliciesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
|
||||
autorest.ByClosing())
|
||||
result.Response = resp
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified Data Lake Analytics compute policy.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to get the compute policy. computePolicyName is the name
|
||||
// of the compute policy to retrieve.
|
||||
func (client ComputePoliciesClient) Get(resourceGroupName string, accountName string, computePolicyName string) (result ComputePolicy, err error) {
|
||||
req, err := client.GetPreparer(resourceGroupName, accountName, computePolicyName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Get", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.GetSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Get", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Get", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// GetPreparer prepares the Get request.
|
||||
func (client ComputePoliciesClient) GetPreparer(resourceGroupName string, accountName string, computePolicyName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"accountName": autorest.Encode("path", accountName),
|
||||
"computePolicyName": autorest.Encode("path", computePolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2016-11-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/computePolicies/{computePolicyName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare(&http.Request{})
|
||||
}
|
||||
|
||||
// GetSender sends the Get request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ComputePoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
|
||||
return autorest.SendWithSender(client, req)
|
||||
}
|
||||
|
||||
// GetResponder handles the response to the Get request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ComputePoliciesClient) GetResponder(resp *http.Response) (result ComputePolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccount lists the Data Lake Analytics compute policies within the specified Data Lake Analytics account. An
|
||||
// account supports, at most, 50 policies
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to get the compute policies.
|
||||
func (client ComputePoliciesClient) ListByAccount(resourceGroupName string, accountName string) (result ComputePolicyListResult, err error) {
|
||||
req, err := client.ListByAccountPreparer(resourceGroupName, accountName)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByAccountSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.ListByAccountResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccountPreparer prepares the ListByAccount request.
|
||||
func (client ComputePoliciesClient) ListByAccountPreparer(resourceGroupName string, accountName string) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"accountName": autorest.Encode("path", accountName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2016-11-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/computePolicies", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
return preparer.Prepare(&http.Request{})
|
||||
}
|
||||
|
||||
// ListByAccountSender sends the ListByAccount request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ComputePoliciesClient) ListByAccountSender(req *http.Request) (*http.Response, error) {
|
||||
return autorest.SendWithSender(client, req)
|
||||
}
|
||||
|
||||
// ListByAccountResponder handles the response to the ListByAccount request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ComputePoliciesClient) ListByAccountResponder(resp *http.Response) (result ComputePolicyListResult, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccountNextResults retrieves the next set of results, if any.
|
||||
func (client ComputePoliciesClient) ListByAccountNextResults(lastResults ComputePolicyListResult) (result ComputePolicyListResult, err error) {
|
||||
req, err := lastResults.ComputePolicyListResultPreparer()
|
||||
if err != nil {
|
||||
return result, autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", nil, "Failure preparing next results request")
|
||||
}
|
||||
if req == nil {
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.ListByAccountSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return result, autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", resp, "Failure sending next results request")
|
||||
}
|
||||
|
||||
result, err = client.ListByAccountResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "ListByAccount", resp, "Failure responding to next results request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccountComplete gets all elements from the list without paging.
|
||||
func (client ComputePoliciesClient) ListByAccountComplete(resourceGroupName string, accountName string, cancel <-chan struct{}) (<-chan ComputePolicy, <-chan error) {
|
||||
resultChan := make(chan ComputePolicy)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListByAccount(resourceGroupName, accountName)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListByAccountNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// Update updates the specified compute policy.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to which to update the compute policy. computePolicyName is the name
|
||||
// of the compute policy to update. parameters is parameters supplied to update the compute policy.
|
||||
func (client ComputePoliciesClient) Update(resourceGroupName string, accountName string, computePolicyName string, parameters *ComputePolicy) (result ComputePolicy, err error) {
|
||||
req, err := client.UpdatePreparer(resourceGroupName, accountName, computePolicyName, parameters)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Update", nil, "Failure preparing request")
|
||||
return
|
||||
}
|
||||
|
||||
resp, err := client.UpdateSender(req)
|
||||
if err != nil {
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Update", resp, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "account.ComputePoliciesClient", "Update", resp, "Failure responding to request")
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// UpdatePreparer prepares the Update request.
|
||||
func (client ComputePoliciesClient) UpdatePreparer(resourceGroupName string, accountName string, computePolicyName string, parameters *ComputePolicy) (*http.Request, error) {
|
||||
pathParameters := map[string]interface{}{
|
||||
"accountName": autorest.Encode("path", accountName),
|
||||
"computePolicyName": autorest.Encode("path", computePolicyName),
|
||||
"resourceGroupName": autorest.Encode("path", resourceGroupName),
|
||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||
}
|
||||
|
||||
const APIVersion = "2016-11-01"
|
||||
queryParameters := map[string]interface{}{
|
||||
"api-version": APIVersion,
|
||||
}
|
||||
|
||||
preparer := autorest.CreatePreparer(
|
||||
autorest.AsJSON(),
|
||||
autorest.AsPatch(),
|
||||
autorest.WithBaseURL(client.BaseURI),
|
||||
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeAnalytics/accounts/{accountName}/computePolicies/{computePolicyName}", pathParameters),
|
||||
autorest.WithQueryParameters(queryParameters))
|
||||
if parameters != nil {
|
||||
preparer = autorest.DecoratePreparer(preparer,
|
||||
autorest.WithJSON(parameters))
|
||||
}
|
||||
return preparer.Prepare(&http.Request{})
|
||||
}
|
||||
|
||||
// UpdateSender sends the Update request. The method will close the
|
||||
// http.Response Body if it receives an error.
|
||||
func (client ComputePoliciesClient) UpdateSender(req *http.Request) (*http.Response, error) {
|
||||
return autorest.SendWithSender(client, req)
|
||||
}
|
||||
|
||||
// UpdateResponder handles the response to the Update request. The method always
|
||||
// closes the http.Response Body.
|
||||
func (client ComputePoliciesClient) UpdateResponder(resp *http.Response) (result ComputePolicy, err error) {
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
Generated
Vendored
+73
-46
@@ -14,9 +14,8 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
@@ -25,32 +24,26 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// DataLakeStoreAccountsClient is the creates an Azure Data Lake Analytics
|
||||
// account management client.
|
||||
// DataLakeStoreAccountsClient is the creates an Azure Data Lake Analytics account management client.
|
||||
type DataLakeStoreAccountsClient struct {
|
||||
ManagementClient
|
||||
}
|
||||
|
||||
// NewDataLakeStoreAccountsClient creates an instance of the
|
||||
// DataLakeStoreAccountsClient client.
|
||||
// NewDataLakeStoreAccountsClient creates an instance of the DataLakeStoreAccountsClient client.
|
||||
func NewDataLakeStoreAccountsClient(subscriptionID string) DataLakeStoreAccountsClient {
|
||||
return NewDataLakeStoreAccountsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewDataLakeStoreAccountsClientWithBaseURI creates an instance of the
|
||||
// DataLakeStoreAccountsClient client.
|
||||
// NewDataLakeStoreAccountsClientWithBaseURI creates an instance of the DataLakeStoreAccountsClient client.
|
||||
func NewDataLakeStoreAccountsClientWithBaseURI(baseURI string, subscriptionID string) DataLakeStoreAccountsClient {
|
||||
return DataLakeStoreAccountsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// Add updates the specified Data Lake Analytics account to include the
|
||||
// additional Data Lake Store account.
|
||||
// Add updates the specified Data Lake Analytics account to include the additional Data Lake Store account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to which to add the Data Lake Store account.
|
||||
// dataLakeStoreAccountName is the name of the Data Lake Store account to add.
|
||||
// parameters is the details of the Data Lake Store account.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to which to add the Data Lake Store account. dataLakeStoreAccountName
|
||||
// is the name of the Data Lake Store account to add. parameters is the details of the Data Lake Store account.
|
||||
func (client DataLakeStoreAccountsClient) Add(resourceGroupName string, accountName string, dataLakeStoreAccountName string, parameters *AddDataLakeStoreParameters) (result autorest.Response, err error) {
|
||||
req, err := client.AddPreparer(resourceGroupName, accountName, dataLakeStoreAccountName, parameters)
|
||||
if err != nil {
|
||||
@@ -118,14 +111,11 @@ func (client DataLakeStoreAccountsClient) AddResponder(resp *http.Response) (res
|
||||
return
|
||||
}
|
||||
|
||||
// Delete updates the Data Lake Analytics account specified to remove the
|
||||
// specified Data Lake Store account.
|
||||
// Delete updates the Data Lake Analytics account specified to remove the specified Data Lake Store account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to remove the Data Lake Store account.
|
||||
// dataLakeStoreAccountName is the name of the Data Lake Store account to
|
||||
// remove
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to remove the Data Lake Store account.
|
||||
// dataLakeStoreAccountName is the name of the Data Lake Store account to remove
|
||||
func (client DataLakeStoreAccountsClient) Delete(resourceGroupName string, accountName string, dataLakeStoreAccountName string) (result autorest.Response, err error) {
|
||||
req, err := client.DeletePreparer(resourceGroupName, accountName, dataLakeStoreAccountName)
|
||||
if err != nil {
|
||||
@@ -188,14 +178,11 @@ func (client DataLakeStoreAccountsClient) DeleteResponder(resp *http.Response) (
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified Data Lake Store account details in the specified Data
|
||||
// Lake Analytics account.
|
||||
// Get gets the specified Data Lake Store account details in the specified Data Lake Analytics account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to retrieve the Data Lake Store account
|
||||
// details. dataLakeStoreAccountName is the name of the Data Lake Store account
|
||||
// to retrieve
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to retrieve the Data Lake Store account details.
|
||||
// dataLakeStoreAccountName is the name of the Data Lake Store account to retrieve
|
||||
func (client DataLakeStoreAccountsClient) Get(resourceGroupName string, accountName string, dataLakeStoreAccountName string) (result DataLakeStoreAccountInfo, err error) {
|
||||
req, err := client.GetPreparer(resourceGroupName, accountName, dataLakeStoreAccountName)
|
||||
if err != nil {
|
||||
@@ -259,23 +246,18 @@ func (client DataLakeStoreAccountsClient) GetResponder(resp *http.Response) (res
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccount gets the first page of Data Lake Store accounts linked to the
|
||||
// specified Data Lake Analytics account. The response includes a link to the
|
||||
// next page, if any.
|
||||
// ListByAccount gets the first page of Data Lake Store accounts linked to the specified Data Lake Analytics account.
|
||||
// The response includes a link to the next page, if any.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account for which to list Data Lake Store accounts. filter is
|
||||
// oData filter. Optional. top is the number of items to return. Optional. skip
|
||||
// is the number of items to skip over before returning elements. Optional.
|
||||
// selectParameter is oData Select statement. Limits the properties on each
|
||||
// entry to just those requested, e.g.
|
||||
// Categories?$select=CategoryName,Description. Optional. orderby is orderBy
|
||||
// clause. One or more comma-separated expressions with an optional "asc" (the
|
||||
// default) or "desc" depending on the order you'd like the values sorted, e.g.
|
||||
// Categories?$orderby=CategoryName desc. Optional. count is the Boolean value
|
||||
// of true or false to request a count of the matching resources included with
|
||||
// the resources in the response, e.g. Categories?$count=true. Optional.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account for which to list Data Lake Store accounts. filter is oData filter.
|
||||
// Optional. top is the number of items to return. Optional. skip is the number of items to skip over before returning
|
||||
// elements. Optional. selectParameter is oData Select statement. Limits the properties on each entry to just those
|
||||
// requested, e.g. Categories?$select=CategoryName,Description. Optional. orderby is orderBy clause. One or more
|
||||
// comma-separated expressions with an optional "asc" (the default) or "desc" depending on the order you'd like the
|
||||
// values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. count is the Boolean value of true or false to
|
||||
// request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.
|
||||
// Optional.
|
||||
func (client DataLakeStoreAccountsClient) ListByAccount(resourceGroupName string, accountName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool) (result DataLakeAnalyticsAccountListDataLakeStoreResult, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: top,
|
||||
@@ -389,3 +371,48 @@ func (client DataLakeStoreAccountsClient) ListByAccountNextResults(lastResults D
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccountComplete gets all elements from the list without paging.
|
||||
func (client DataLakeStoreAccountsClient) ListByAccountComplete(resourceGroupName string, accountName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool, cancel <-chan struct{}) (<-chan DataLakeStoreAccountInfo, <-chan error) {
|
||||
resultChan := make(chan DataLakeStoreAccountInfo)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListByAccount(resourceGroupName, accountName, filter, top, skip, selectParameter, orderby, count)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListByAccountNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
Generated
Vendored
+68
-37
@@ -14,9 +14,8 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
@@ -25,33 +24,27 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// FirewallRulesClient is the creates an Azure Data Lake Analytics account
|
||||
// management client.
|
||||
// FirewallRulesClient is the creates an Azure Data Lake Analytics account management client.
|
||||
type FirewallRulesClient struct {
|
||||
ManagementClient
|
||||
}
|
||||
|
||||
// NewFirewallRulesClient creates an instance of the FirewallRulesClient
|
||||
// client.
|
||||
// NewFirewallRulesClient creates an instance of the FirewallRulesClient client.
|
||||
func NewFirewallRulesClient(subscriptionID string) FirewallRulesClient {
|
||||
return NewFirewallRulesClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewFirewallRulesClientWithBaseURI creates an instance of the
|
||||
// FirewallRulesClient client.
|
||||
// NewFirewallRulesClientWithBaseURI creates an instance of the FirewallRulesClient client.
|
||||
func NewFirewallRulesClientWithBaseURI(baseURI string, subscriptionID string) FirewallRulesClient {
|
||||
return FirewallRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// CreateOrUpdate creates or updates the specified firewall rule. During
|
||||
// update, the firewall rule with the specified name will be replaced with this
|
||||
// new firewall rule.
|
||||
// CreateOrUpdate creates or updates the specified firewall rule. During update, the firewall rule with the specified
|
||||
// name will be replaced with this new firewall rule.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to add or replace the firewall rule. firewallRuleName is
|
||||
// the name of the firewall rule to create or update. parameters is parameters
|
||||
// supplied to create or update the firewall rule.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to add or replace the firewall rule. firewallRuleName is the name of
|
||||
// the firewall rule to create or update. parameters is parameters supplied to create or update the firewall rule.
|
||||
func (client FirewallRulesClient) CreateOrUpdate(resourceGroupName string, accountName string, firewallRuleName string, parameters FirewallRule) (result FirewallRule, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: parameters,
|
||||
@@ -126,13 +119,11 @@ func (client FirewallRulesClient) CreateOrUpdateResponder(resp *http.Response) (
|
||||
return
|
||||
}
|
||||
|
||||
// Delete deletes the specified firewall rule from the specified Data Lake
|
||||
// Analytics account
|
||||
// Delete deletes the specified firewall rule from the specified Data Lake Analytics account
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to delete the firewall rule. firewallRuleName
|
||||
// is the name of the firewall rule to delete.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to delete the firewall rule. firewallRuleName is the name
|
||||
// of the firewall rule to delete.
|
||||
func (client FirewallRulesClient) Delete(resourceGroupName string, accountName string, firewallRuleName string) (result autorest.Response, err error) {
|
||||
req, err := client.DeletePreparer(resourceGroupName, accountName, firewallRuleName)
|
||||
if err != nil {
|
||||
@@ -197,10 +188,9 @@ func (client FirewallRulesClient) DeleteResponder(resp *http.Response) (result a
|
||||
|
||||
// Get gets the specified Data Lake Analytics firewall rule.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to get the firewall rule. firewallRuleName is
|
||||
// the name of the firewall rule to retrieve.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to get the firewall rule. firewallRuleName is the name of
|
||||
// the firewall rule to retrieve.
|
||||
func (client FirewallRulesClient) Get(resourceGroupName string, accountName string, firewallRuleName string) (result FirewallRule, err error) {
|
||||
req, err := client.GetPreparer(resourceGroupName, accountName, firewallRuleName)
|
||||
if err != nil {
|
||||
@@ -264,12 +254,10 @@ func (client FirewallRulesClient) GetResponder(resp *http.Response) (result Fire
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccount lists the Data Lake Analytics firewall rules within the
|
||||
// specified Data Lake Analytics account.
|
||||
// ListByAccount lists the Data Lake Analytics firewall rules within the specified Data Lake Analytics account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to get the firewall rules.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to get the firewall rules.
|
||||
func (client FirewallRulesClient) ListByAccount(resourceGroupName string, accountName string) (result DataLakeAnalyticsFirewallRuleListResult, err error) {
|
||||
req, err := client.ListByAccountPreparer(resourceGroupName, accountName)
|
||||
if err != nil {
|
||||
@@ -356,13 +344,56 @@ func (client FirewallRulesClient) ListByAccountNextResults(lastResults DataLakeA
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccountComplete gets all elements from the list without paging.
|
||||
func (client FirewallRulesClient) ListByAccountComplete(resourceGroupName string, accountName string, cancel <-chan struct{}) (<-chan FirewallRule, <-chan error) {
|
||||
resultChan := make(chan FirewallRule)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListByAccount(resourceGroupName, accountName)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListByAccountNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// Update updates the specified firewall rule.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to which to update the firewall rule. firewallRuleName is
|
||||
// the name of the firewall rule to update. parameters is parameters supplied
|
||||
// to update the firewall rule.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to which to update the firewall rule. firewallRuleName is the name of
|
||||
// the firewall rule to update. parameters is parameters supplied to update the firewall rule.
|
||||
func (client FirewallRulesClient) Update(resourceGroupName string, accountName string, firewallRuleName string, parameters *UpdateFirewallRuleParameters) (result FirewallRule, err error) {
|
||||
req, err := client.UpdatePreparer(resourceGroupName, accountName, firewallRuleName, parameters)
|
||||
if err != nil {
|
||||
|
||||
Generated
Vendored
Executable → Regular
+144
-62
@@ -14,9 +14,8 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
@@ -25,8 +24,7 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// GroupClient is the creates an Azure Data Lake Analytics account management
|
||||
// client.
|
||||
// GroupClient is the creates an Azure Data Lake Analytics account management client.
|
||||
type GroupClient struct {
|
||||
ManagementClient
|
||||
}
|
||||
@@ -41,15 +39,12 @@ func NewGroupClientWithBaseURI(baseURI string, subscriptionID string) GroupClien
|
||||
return GroupClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// Create creates the specified Data Lake Analytics account. This supplies the
|
||||
// user with computation services for Data Lake Analytics workloads This method
|
||||
// may poll for completion. Polling can be canceled by passing the cancel
|
||||
// channel argument. The channel will be used to cancel polling and any
|
||||
// outstanding HTTP requests.
|
||||
// Create creates the specified Data Lake Analytics account. This supplies the user with computation services for Data
|
||||
// Lake Analytics workloads This method may poll for completion. Polling can be canceled by passing the cancel channel
|
||||
// argument. The channel will be used to cancel polling and any outstanding HTTP requests.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account.the account will be associated with. accountName
|
||||
// is the name of the Data Lake Analytics account to create. parameters is
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account.the account
|
||||
// will be associated with. accountName is the name of the Data Lake Analytics account to create. parameters is
|
||||
// parameters supplied to the create Data Lake Analytics account operation.
|
||||
func (client GroupClient) Create(resourceGroupName string, accountName string, parameters DataLakeAnalyticsAccount, cancel <-chan struct{}) (<-chan DataLakeAnalyticsAccount, <-chan error) {
|
||||
resultChan := make(chan DataLakeAnalyticsAccount, 1)
|
||||
@@ -67,6 +62,10 @@ func (client GroupClient) Create(resourceGroupName string, accountName string, p
|
||||
{Target: "parameters.DataLakeAnalyticsAccountProperties.MaxJobCount", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.DataLakeAnalyticsAccountProperties.MaxJobCount", Name: validation.InclusiveMinimum, Rule: 1, Chain: nil}}},
|
||||
{Target: "parameters.DataLakeAnalyticsAccountProperties.DataLakeStoreAccounts", Name: validation.Null, Rule: true, Chain: nil},
|
||||
{Target: "parameters.DataLakeAnalyticsAccountProperties.MaxDegreeOfParallelismPerJob", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.DataLakeAnalyticsAccountProperties.MaxDegreeOfParallelismPerJob", Name: validation.InclusiveMinimum, Rule: 1, Chain: nil}}},
|
||||
{Target: "parameters.DataLakeAnalyticsAccountProperties.MinPriorityPerJob", Name: validation.Null, Rule: false,
|
||||
Chain: []validation.Constraint{{Target: "parameters.DataLakeAnalyticsAccountProperties.MinPriorityPerJob", Name: validation.InclusiveMinimum, Rule: 1, Chain: nil}}},
|
||||
}}}}}); err != nil {
|
||||
errChan <- validation.NewErrorWithValidationError(err, "account.GroupClient", "Create")
|
||||
close(errChan)
|
||||
@@ -78,8 +77,10 @@ func (client GroupClient) Create(resourceGroupName string, accountName string, p
|
||||
var err error
|
||||
var result DataLakeAnalyticsAccount
|
||||
defer func() {
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
}
|
||||
resultChan <- result
|
||||
errChan <- err
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
@@ -141,21 +142,19 @@ func (client GroupClient) CreateResponder(resp *http.Response) (result DataLakeA
|
||||
err = autorest.Respond(
|
||||
resp,
|
||||
client.ByInspecting(),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusCreated, http.StatusOK),
|
||||
azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
|
||||
autorest.ByUnmarshallingJSON(&result),
|
||||
autorest.ByClosing())
|
||||
result.Response = autorest.Response{Response: resp}
|
||||
return
|
||||
}
|
||||
|
||||
// Delete begins the delete delete process for the Data Lake Analytics account
|
||||
// object specified by the account name. This method may poll for completion.
|
||||
// Polling can be canceled by passing the cancel channel argument. The channel
|
||||
// will be used to cancel polling and any outstanding HTTP requests.
|
||||
// Delete begins the delete process for the Data Lake Analytics account object specified by the account name. This
|
||||
// method may poll for completion. Polling can be canceled by passing the cancel channel argument. The channel will be
|
||||
// used to cancel polling and any outstanding HTTP requests.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to delete
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to delete
|
||||
func (client GroupClient) Delete(resourceGroupName string, accountName string, cancel <-chan struct{}) (<-chan autorest.Response, <-chan error) {
|
||||
resultChan := make(chan autorest.Response, 1)
|
||||
errChan := make(chan error, 1)
|
||||
@@ -163,8 +162,10 @@ func (client GroupClient) Delete(resourceGroupName string, accountName string, c
|
||||
var err error
|
||||
var result autorest.Response
|
||||
defer func() {
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
}
|
||||
resultChan <- result
|
||||
errChan <- err
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
@@ -232,9 +233,8 @@ func (client GroupClient) DeleteResponder(resp *http.Response) (result autorest.
|
||||
|
||||
// Get gets details of the specified Data Lake Analytics account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to retrieve.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to retrieve.
|
||||
func (client GroupClient) Get(resourceGroupName string, accountName string) (result DataLakeAnalyticsAccount, err error) {
|
||||
req, err := client.GetPreparer(resourceGroupName, accountName)
|
||||
if err != nil {
|
||||
@@ -297,19 +297,16 @@ func (client GroupClient) GetResponder(resp *http.Response) (result DataLakeAnal
|
||||
return
|
||||
}
|
||||
|
||||
// List gets the first page of Data Lake Analytics accounts, if any, within the
|
||||
// current subscription. This includes a link to the next page, if any.
|
||||
// List gets the first page of Data Lake Analytics accounts, if any, within the current subscription. This includes a
|
||||
// link to the next page, if any.
|
||||
//
|
||||
// filter is oData filter. Optional. top is the number of items to return.
|
||||
// Optional. skip is the number of items to skip over before returning
|
||||
// elements. Optional. selectParameter is oData Select statement. Limits the
|
||||
// properties on each entry to just those requested, e.g.
|
||||
// Categories?$select=CategoryName,Description. Optional. orderby is orderBy
|
||||
// clause. One or more comma-separated expressions with an optional "asc" (the
|
||||
// default) or "desc" depending on the order you'd like the values sorted, e.g.
|
||||
// Categories?$orderby=CategoryName desc. Optional. count is the Boolean value
|
||||
// of true or false to request a count of the matching resources included with
|
||||
// the resources in the response, e.g. Categories?$count=true. Optional.
|
||||
// filter is oData filter. Optional. top is the number of items to return. Optional. skip is the number of items to
|
||||
// skip over before returning elements. Optional. selectParameter is oData Select statement. Limits the properties on
|
||||
// each entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. orderby is orderBy
|
||||
// clause. One or more comma-separated expressions with an optional "asc" (the default) or "desc" depending on the
|
||||
// order you'd like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. count is the Boolean value
|
||||
// of true or false to request a count of the matching resources included with the resources in the response, e.g.
|
||||
// Categories?$count=true. Optional.
|
||||
func (client GroupClient) List(filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool) (result DataLakeAnalyticsAccountListResult, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: top,
|
||||
@@ -422,21 +419,62 @@ func (client GroupClient) ListNextResults(lastResults DataLakeAnalyticsAccountLi
|
||||
return
|
||||
}
|
||||
|
||||
// ListByResourceGroup gets the first page of Data Lake Analytics accounts, if
|
||||
// any, within a specific resource group. This includes a link to the next
|
||||
// page, if any.
|
||||
// ListComplete gets all elements from the list without paging.
|
||||
func (client GroupClient) ListComplete(filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool, cancel <-chan struct{}) (<-chan DataLakeAnalyticsAccountBasic, <-chan error) {
|
||||
resultChan := make(chan DataLakeAnalyticsAccountBasic)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.List(filter, top, skip, selectParameter, orderby, count)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// ListByResourceGroup gets the first page of Data Lake Analytics accounts, if any, within a specific resource group.
|
||||
// This includes a link to the next page, if any.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. filter is oData filter. Optional. top is the
|
||||
// number of items to return. Optional. skip is the number of items to skip
|
||||
// over before returning elements. Optional. selectParameter is oData Select
|
||||
// statement. Limits the properties on each entry to just those requested, e.g.
|
||||
// Categories?$select=CategoryName,Description. Optional. orderby is orderBy
|
||||
// clause. One or more comma-separated expressions with an optional "asc" (the
|
||||
// default) or "desc" depending on the order you'd like the values sorted, e.g.
|
||||
// Categories?$orderby=CategoryName desc. Optional. count is the Boolean value
|
||||
// of true or false to request a count of the matching resources included with
|
||||
// the resources in the response, e.g. Categories?$count=true. Optional.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. filter is
|
||||
// oData filter. Optional. top is the number of items to return. Optional. skip is the number of items to skip over
|
||||
// before returning elements. Optional. selectParameter is oData Select statement. Limits the properties on each entry
|
||||
// to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. orderby is orderBy clause. One
|
||||
// or more comma-separated expressions with an optional "asc" (the default) or "desc" depending on the order you'd like
|
||||
// the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. count is the Boolean value of true or false
|
||||
// to request a count of the matching resources included with the resources in the response, e.g.
|
||||
// Categories?$count=true. Optional.
|
||||
func (client GroupClient) ListByResourceGroup(resourceGroupName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool) (result DataLakeAnalyticsAccountListResult, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: top,
|
||||
@@ -550,16 +588,58 @@ func (client GroupClient) ListByResourceGroupNextResults(lastResults DataLakeAna
|
||||
return
|
||||
}
|
||||
|
||||
// Update updates the Data Lake Analytics account object specified by the
|
||||
// accountName with the contents of the account object. This method may poll
|
||||
// for completion. Polling can be canceled by passing the cancel channel
|
||||
// argument. The channel will be used to cancel polling and any outstanding
|
||||
// HTTP requests.
|
||||
// ListByResourceGroupComplete gets all elements from the list without paging.
|
||||
func (client GroupClient) ListByResourceGroupComplete(resourceGroupName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool, cancel <-chan struct{}) (<-chan DataLakeAnalyticsAccountBasic, <-chan error) {
|
||||
resultChan := make(chan DataLakeAnalyticsAccountBasic)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListByResourceGroup(resourceGroupName, filter, top, skip, selectParameter, orderby, count)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListByResourceGroupNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// Update updates the Data Lake Analytics account object specified by the accountName with the contents of the account
|
||||
// object. This method may poll for completion. Polling can be canceled by passing the cancel channel argument. The
|
||||
// channel will be used to cancel polling and any outstanding HTTP requests.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to update. parameters is parameters supplied to the update
|
||||
// Data Lake Analytics account operation.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to update. parameters is parameters supplied to the update Data Lake
|
||||
// Analytics account operation.
|
||||
func (client GroupClient) Update(resourceGroupName string, accountName string, parameters *DataLakeAnalyticsAccountUpdateParameters, cancel <-chan struct{}) (<-chan DataLakeAnalyticsAccount, <-chan error) {
|
||||
resultChan := make(chan DataLakeAnalyticsAccount, 1)
|
||||
errChan := make(chan error, 1)
|
||||
@@ -567,8 +647,10 @@ func (client GroupClient) Update(resourceGroupName string, accountName string, p
|
||||
var err error
|
||||
var result DataLakeAnalyticsAccount
|
||||
defer func() {
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
}
|
||||
resultChan <- result
|
||||
errChan <- err
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
Generated
Vendored
+177
-118
@@ -14,70 +14,68 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
"github.com/Azure/go-autorest/autorest/date"
|
||||
"github.com/Azure/go-autorest/autorest/to"
|
||||
uuid "github.com/satori/go.uuid"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// DataLakeAnalyticsAccountState enumerates the values for data lake analytics
|
||||
// account state.
|
||||
// AADObjectType enumerates the values for aad object type.
|
||||
type AADObjectType string
|
||||
|
||||
const (
|
||||
// Group specifies the group state for aad object type.
|
||||
Group AADObjectType = "Group"
|
||||
// ServicePrincipal specifies the service principal state for aad object type.
|
||||
ServicePrincipal AADObjectType = "ServicePrincipal"
|
||||
// User specifies the user state for aad object type.
|
||||
User AADObjectType = "User"
|
||||
)
|
||||
|
||||
// DataLakeAnalyticsAccountState enumerates the values for data lake analytics account state.
|
||||
type DataLakeAnalyticsAccountState string
|
||||
|
||||
const (
|
||||
// Active specifies the active state for data lake analytics account state.
|
||||
Active DataLakeAnalyticsAccountState = "Active"
|
||||
// Suspended specifies the suspended state for data lake analytics account
|
||||
// state.
|
||||
// Suspended specifies the suspended state for data lake analytics account state.
|
||||
Suspended DataLakeAnalyticsAccountState = "Suspended"
|
||||
)
|
||||
|
||||
// DataLakeAnalyticsAccountStatus enumerates the values for data lake analytics
|
||||
// account status.
|
||||
// DataLakeAnalyticsAccountStatus enumerates the values for data lake analytics account status.
|
||||
type DataLakeAnalyticsAccountStatus string
|
||||
|
||||
const (
|
||||
// Creating specifies the creating state for data lake analytics account
|
||||
// status.
|
||||
// Creating specifies the creating state for data lake analytics account status.
|
||||
Creating DataLakeAnalyticsAccountStatus = "Creating"
|
||||
// Deleted specifies the deleted state for data lake analytics account
|
||||
// status.
|
||||
// Deleted specifies the deleted state for data lake analytics account status.
|
||||
Deleted DataLakeAnalyticsAccountStatus = "Deleted"
|
||||
// Deleting specifies the deleting state for data lake analytics account
|
||||
// status.
|
||||
// Deleting specifies the deleting state for data lake analytics account status.
|
||||
Deleting DataLakeAnalyticsAccountStatus = "Deleting"
|
||||
// Failed specifies the failed state for data lake analytics account
|
||||
// status.
|
||||
// Failed specifies the failed state for data lake analytics account status.
|
||||
Failed DataLakeAnalyticsAccountStatus = "Failed"
|
||||
// Patching specifies the patching state for data lake analytics account
|
||||
// status.
|
||||
// Patching specifies the patching state for data lake analytics account status.
|
||||
Patching DataLakeAnalyticsAccountStatus = "Patching"
|
||||
// Resuming specifies the resuming state for data lake analytics account
|
||||
// status.
|
||||
// Resuming specifies the resuming state for data lake analytics account status.
|
||||
Resuming DataLakeAnalyticsAccountStatus = "Resuming"
|
||||
// Running specifies the running state for data lake analytics account
|
||||
// status.
|
||||
// Running specifies the running state for data lake analytics account status.
|
||||
Running DataLakeAnalyticsAccountStatus = "Running"
|
||||
// Succeeded specifies the succeeded state for data lake analytics account
|
||||
// status.
|
||||
// Succeeded specifies the succeeded state for data lake analytics account status.
|
||||
Succeeded DataLakeAnalyticsAccountStatus = "Succeeded"
|
||||
// Suspending specifies the suspending state for data lake analytics
|
||||
// account status.
|
||||
// Suspending specifies the suspending state for data lake analytics account status.
|
||||
Suspending DataLakeAnalyticsAccountStatus = "Suspending"
|
||||
)
|
||||
|
||||
// FirewallAllowAzureIpsState enumerates the values for firewall allow azure
|
||||
// ips state.
|
||||
// FirewallAllowAzureIpsState enumerates the values for firewall allow azure ips state.
|
||||
type FirewallAllowAzureIpsState string
|
||||
|
||||
const (
|
||||
// Disabled specifies the disabled state for firewall allow azure ips
|
||||
// state.
|
||||
// Disabled specifies the disabled state for firewall allow azure ips state.
|
||||
Disabled FirewallAllowAzureIpsState = "Disabled"
|
||||
// Enabled specifies the enabled state for firewall allow azure ips state.
|
||||
Enabled FirewallAllowAzureIpsState = "Enabled"
|
||||
@@ -87,11 +85,9 @@ const (
|
||||
type FirewallState string
|
||||
|
||||
const (
|
||||
// FirewallStateDisabled specifies the firewall state disabled state for
|
||||
// firewall state.
|
||||
// FirewallStateDisabled specifies the firewall state disabled state for firewall state.
|
||||
FirewallStateDisabled FirewallState = "Disabled"
|
||||
// FirewallStateEnabled specifies the firewall state enabled state for
|
||||
// firewall state.
|
||||
// FirewallStateEnabled specifies the firewall state enabled state for firewall state.
|
||||
FirewallStateEnabled FirewallState = "Enabled"
|
||||
)
|
||||
|
||||
@@ -99,29 +95,21 @@ const (
|
||||
type TierType string
|
||||
|
||||
const (
|
||||
// Commitment100000AUHours specifies the commitment 100000au hours state
|
||||
// for tier type.
|
||||
// Commitment100000AUHours specifies the commitment 100000au hours state for tier type.
|
||||
Commitment100000AUHours TierType = "Commitment_100000AUHours"
|
||||
// Commitment10000AUHours specifies the commitment 10000au hours state for
|
||||
// tier type.
|
||||
// Commitment10000AUHours specifies the commitment 10000au hours state for tier type.
|
||||
Commitment10000AUHours TierType = "Commitment_10000AUHours"
|
||||
// Commitment1000AUHours specifies the commitment 1000au hours state for
|
||||
// tier type.
|
||||
// Commitment1000AUHours specifies the commitment 1000au hours state for tier type.
|
||||
Commitment1000AUHours TierType = "Commitment_1000AUHours"
|
||||
// Commitment100AUHours specifies the commitment 100au hours state for tier
|
||||
// type.
|
||||
// Commitment100AUHours specifies the commitment 100au hours state for tier type.
|
||||
Commitment100AUHours TierType = "Commitment_100AUHours"
|
||||
// Commitment500000AUHours specifies the commitment 500000au hours state
|
||||
// for tier type.
|
||||
// Commitment500000AUHours specifies the commitment 500000au hours state for tier type.
|
||||
Commitment500000AUHours TierType = "Commitment_500000AUHours"
|
||||
// Commitment50000AUHours specifies the commitment 50000au hours state for
|
||||
// tier type.
|
||||
// Commitment50000AUHours specifies the commitment 50000au hours state for tier type.
|
||||
Commitment50000AUHours TierType = "Commitment_50000AUHours"
|
||||
// Commitment5000AUHours specifies the commitment 5000au hours state for
|
||||
// tier type.
|
||||
// Commitment5000AUHours specifies the commitment 5000au hours state for tier type.
|
||||
Commitment5000AUHours TierType = "Commitment_5000AUHours"
|
||||
// Commitment500AUHours specifies the commitment 500au hours state for tier
|
||||
// type.
|
||||
// Commitment500AUHours specifies the commitment 500au hours state for tier type.
|
||||
Commitment500AUHours TierType = "Commitment_500AUHours"
|
||||
// Consumption specifies the consumption state for tier type.
|
||||
Consumption TierType = "Consumption"
|
||||
@@ -132,14 +120,67 @@ type AddDataLakeStoreParameters struct {
|
||||
*DataLakeStoreAccountInfoProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// AddStorageAccountParameters is storage account parameters for a storage
|
||||
// account being added to a Data Lake Analytics account.
|
||||
// AddStorageAccountParameters is storage account parameters for a storage account being added to a Data Lake Analytics
|
||||
// account.
|
||||
type AddStorageAccountParameters struct {
|
||||
*StorageAccountProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccount is a Data Lake Analytics account object, containing
|
||||
// all information associated with the named Data Lake Analytics account.
|
||||
// ComputePolicy is the parameters used to create a new compute policy.
|
||||
type ComputePolicy struct {
|
||||
autorest.Response `json:"-"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
*ComputePolicyProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// ComputePolicyAccountCreateParameters is the parameters used to create a new compute policy.
|
||||
type ComputePolicyAccountCreateParameters struct {
|
||||
Name *string `json:"name,omitempty"`
|
||||
*ComputePolicyPropertiesCreateParameters `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// ComputePolicyCreateOrUpdateParameters is the parameters used to create a new compute policy.
|
||||
type ComputePolicyCreateOrUpdateParameters struct {
|
||||
*ComputePolicyPropertiesCreateParameters `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// ComputePolicyListResult is the list of compute policies in the account.
|
||||
type ComputePolicyListResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]ComputePolicy `json:"value,omitempty"`
|
||||
NextLink *string `json:"nextLink,omitempty"`
|
||||
}
|
||||
|
||||
// ComputePolicyListResultPreparer prepares a request to retrieve the next set of results. It returns
|
||||
// nil if no more results exist.
|
||||
func (client ComputePolicyListResult) ComputePolicyListResultPreparer() (*http.Request, error) {
|
||||
if client.NextLink == nil || len(to.String(client.NextLink)) <= 0 {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare(&http.Request{},
|
||||
autorest.AsJSON(),
|
||||
autorest.AsGet(),
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// ComputePolicyProperties is the compute policy properties to use when creating a new compute policy
|
||||
type ComputePolicyProperties struct {
|
||||
ObjectID *uuid.UUID `json:"objectId,omitempty"`
|
||||
ObjectType AADObjectType `json:"objectType,omitempty"`
|
||||
MaxDegreeOfParallelismPerJob *int32 `json:"maxDegreeOfParallelismPerJob,omitempty"`
|
||||
MinPriorityPerJob *int32 `json:"minPriorityPerJob,omitempty"`
|
||||
}
|
||||
|
||||
// ComputePolicyPropertiesCreateParameters is the compute policy properties to use when creating a new compute policy
|
||||
type ComputePolicyPropertiesCreateParameters struct {
|
||||
ObjectID *uuid.UUID `json:"objectId,omitempty"`
|
||||
ObjectType AADObjectType `json:"objectType,omitempty"`
|
||||
MaxDegreeOfParallelismPerJob *int32 `json:"maxDegreeOfParallelismPerJob,omitempty"`
|
||||
MinPriorityPerJob *int32 `json:"minPriorityPerJob,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccount is a Data Lake Analytics account object, containing all information associated with the
|
||||
// named Data Lake Analytics account.
|
||||
type DataLakeAnalyticsAccount struct {
|
||||
autorest.Response `json:"-"`
|
||||
ID *string `json:"id,omitempty"`
|
||||
@@ -150,8 +191,18 @@ type DataLakeAnalyticsAccount struct {
|
||||
*DataLakeAnalyticsAccountProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountListDataLakeStoreResult is data Lake Account list
|
||||
// information.
|
||||
// DataLakeAnalyticsAccountBasic is a Data Lake Analytics account object, containing all information associated with
|
||||
// the named Data Lake Analytics account.
|
||||
type DataLakeAnalyticsAccountBasic struct {
|
||||
ID *string `json:"id,omitempty"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
Type *string `json:"type,omitempty"`
|
||||
Location *string `json:"location,omitempty"`
|
||||
Tags *map[string]*string `json:"tags,omitempty"`
|
||||
*DataLakeAnalyticsAccountPropertiesBasic `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountListDataLakeStoreResult is data Lake Account list information.
|
||||
type DataLakeAnalyticsAccountListDataLakeStoreResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]DataLakeStoreAccountInfo `json:"value,omitempty"`
|
||||
@@ -170,12 +221,11 @@ func (client DataLakeAnalyticsAccountListDataLakeStoreResult) DataLakeAnalyticsA
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountListResult is dataLakeAnalytics Account list
|
||||
// information.
|
||||
// DataLakeAnalyticsAccountListResult is dataLakeAnalytics Account list information.
|
||||
type DataLakeAnalyticsAccountListResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]DataLakeAnalyticsAccount `json:"value,omitempty"`
|
||||
NextLink *string `json:"nextLink,omitempty"`
|
||||
Value *[]DataLakeAnalyticsAccountBasic `json:"value,omitempty"`
|
||||
NextLink *string `json:"nextLink,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountListResultPreparer prepares a request to retrieve the next set of results. It returns
|
||||
@@ -190,8 +240,7 @@ func (client DataLakeAnalyticsAccountListResult) DataLakeAnalyticsAccountListRes
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountListStorageAccountsResult is azure Storage Account
|
||||
// list information.
|
||||
// DataLakeAnalyticsAccountListStorageAccountsResult is azure Storage Account list information.
|
||||
type DataLakeAnalyticsAccountListStorageAccountsResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]StorageAccountInfo `json:"value,omitempty"`
|
||||
@@ -210,38 +259,52 @@ func (client DataLakeAnalyticsAccountListStorageAccountsResult) DataLakeAnalytic
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountProperties is the account specific properties that
|
||||
// are associated with an underlying Data Lake Analytics account.
|
||||
// DataLakeAnalyticsAccountProperties is the account specific properties that are associated with an underlying Data
|
||||
// Lake Analytics account. Returned only when retrieving a specific account.
|
||||
type DataLakeAnalyticsAccountProperties struct {
|
||||
ProvisioningState DataLakeAnalyticsAccountStatus `json:"provisioningState,omitempty"`
|
||||
State DataLakeAnalyticsAccountState `json:"state,omitempty"`
|
||||
DefaultDataLakeStoreAccount *string `json:"defaultDataLakeStoreAccount,omitempty"`
|
||||
MaxDegreeOfParallelism *int32 `json:"maxDegreeOfParallelism,omitempty"`
|
||||
QueryStoreRetention *int32 `json:"queryStoreRetention,omitempty"`
|
||||
MaxJobCount *int32 `json:"maxJobCount,omitempty"`
|
||||
SystemMaxDegreeOfParallelism *int32 `json:"systemMaxDegreeOfParallelism,omitempty"`
|
||||
SystemMaxJobCount *int32 `json:"systemMaxJobCount,omitempty"`
|
||||
DataLakeStoreAccounts *[]DataLakeStoreAccountInfo `json:"dataLakeStoreAccounts,omitempty"`
|
||||
StorageAccounts *[]StorageAccountInfo `json:"storageAccounts,omitempty"`
|
||||
CreationTime *date.Time `json:"creationTime,omitempty"`
|
||||
LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"`
|
||||
Endpoint *string `json:"endpoint,omitempty"`
|
||||
NewTier TierType `json:"newTier,omitempty"`
|
||||
CurrentTier TierType `json:"currentTier,omitempty"`
|
||||
FirewallState FirewallState `json:"firewallState,omitempty"`
|
||||
FirewallAllowAzureIps FirewallAllowAzureIpsState `json:"firewallAllowAzureIps,omitempty"`
|
||||
FirewallRules *[]FirewallRule `json:"firewallRules,omitempty"`
|
||||
ProvisioningState DataLakeAnalyticsAccountStatus `json:"provisioningState,omitempty"`
|
||||
State DataLakeAnalyticsAccountState `json:"state,omitempty"`
|
||||
CreationTime *date.Time `json:"creationTime,omitempty"`
|
||||
LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"`
|
||||
Endpoint *string `json:"endpoint,omitempty"`
|
||||
AccountID *uuid.UUID `json:"accountId,omitempty"`
|
||||
DefaultDataLakeStoreAccount *string `json:"defaultDataLakeStoreAccount,omitempty"`
|
||||
MaxDegreeOfParallelism *int32 `json:"maxDegreeOfParallelism,omitempty"`
|
||||
QueryStoreRetention *int32 `json:"queryStoreRetention,omitempty"`
|
||||
MaxJobCount *int32 `json:"maxJobCount,omitempty"`
|
||||
SystemMaxDegreeOfParallelism *int32 `json:"systemMaxDegreeOfParallelism,omitempty"`
|
||||
SystemMaxJobCount *int32 `json:"systemMaxJobCount,omitempty"`
|
||||
DataLakeStoreAccounts *[]DataLakeStoreAccountInfo `json:"dataLakeStoreAccounts,omitempty"`
|
||||
StorageAccounts *[]StorageAccountInfo `json:"storageAccounts,omitempty"`
|
||||
NewTier TierType `json:"newTier,omitempty"`
|
||||
CurrentTier TierType `json:"currentTier,omitempty"`
|
||||
FirewallState FirewallState `json:"firewallState,omitempty"`
|
||||
FirewallAllowAzureIps FirewallAllowAzureIpsState `json:"firewallAllowAzureIps,omitempty"`
|
||||
FirewallRules *[]FirewallRule `json:"firewallRules,omitempty"`
|
||||
MaxDegreeOfParallelismPerJob *int32 `json:"maxDegreeOfParallelismPerJob,omitempty"`
|
||||
MinPriorityPerJob *int32 `json:"minPriorityPerJob,omitempty"`
|
||||
ComputePolicies *[]ComputePolicyAccountCreateParameters `json:"computePolicies,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountUpdateParameters is the parameters that can be used
|
||||
// to update an existing Data Lake Analytics account.
|
||||
// DataLakeAnalyticsAccountPropertiesBasic is the basic account specific properties that are associated with an
|
||||
// underlying Data Lake Analytics account.
|
||||
type DataLakeAnalyticsAccountPropertiesBasic struct {
|
||||
ProvisioningState DataLakeAnalyticsAccountStatus `json:"provisioningState,omitempty"`
|
||||
State DataLakeAnalyticsAccountState `json:"state,omitempty"`
|
||||
CreationTime *date.Time `json:"creationTime,omitempty"`
|
||||
LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"`
|
||||
Endpoint *string `json:"endpoint,omitempty"`
|
||||
AccountID *uuid.UUID `json:"accountId,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsAccountUpdateParameters is the parameters that can be used to update an existing Data Lake
|
||||
// Analytics account.
|
||||
type DataLakeAnalyticsAccountUpdateParameters struct {
|
||||
Tags *map[string]*string `json:"tags,omitempty"`
|
||||
*UpdateDataLakeAnalyticsAccountProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeAnalyticsFirewallRuleListResult is data Lake Analytics firewall rule
|
||||
// list information.
|
||||
// DataLakeAnalyticsFirewallRuleListResult is data Lake Analytics firewall rule list information.
|
||||
type DataLakeAnalyticsFirewallRuleListResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]FirewallRule `json:"value,omitempty"`
|
||||
@@ -269,8 +332,7 @@ type DataLakeStoreAccountInfo struct {
|
||||
*DataLakeStoreAccountInfoProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// DataLakeStoreAccountInfoProperties is data Lake Store account properties
|
||||
// information.
|
||||
// DataLakeStoreAccountInfoProperties is data Lake Store account properties information.
|
||||
type DataLakeStoreAccountInfoProperties struct {
|
||||
Suffix *string `json:"suffix,omitempty"`
|
||||
}
|
||||
@@ -284,15 +346,14 @@ type FirewallRule struct {
|
||||
*FirewallRuleProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// FirewallRuleProperties is data Lake Analytics firewall rule properties
|
||||
// information
|
||||
// FirewallRuleProperties is data Lake Analytics firewall rule properties information
|
||||
type FirewallRuleProperties struct {
|
||||
StartIPAddress *string `json:"startIpAddress,omitempty"`
|
||||
EndIPAddress *string `json:"endIpAddress,omitempty"`
|
||||
}
|
||||
|
||||
// ListSasTokensResult is the SAS response that contains the storage account,
|
||||
// container and associated SAS token for connection use.
|
||||
// ListSasTokensResult is the SAS response that contains the storage account, container and associated SAS token for
|
||||
// connection use.
|
||||
type ListSasTokensResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]SasTokenInfo `json:"value,omitempty"`
|
||||
@@ -311,8 +372,8 @@ func (client ListSasTokensResult) ListSasTokensResultPreparer() (*http.Request,
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// ListStorageContainersResult is the list of blob containers associated with
|
||||
// the storage account attached to the Data Lake Analytics account.
|
||||
// ListStorageContainersResult is the list of blob containers associated with the storage account attached to the Data
|
||||
// Lake Analytics account.
|
||||
type ListStorageContainersResult struct {
|
||||
autorest.Response `json:"-"`
|
||||
Value *[]StorageContainer `json:"value,omitempty"`
|
||||
@@ -331,8 +392,7 @@ func (client ListStorageContainersResult) ListStorageContainersResultPreparer()
|
||||
autorest.WithBaseURL(to.String(client.NextLink)))
|
||||
}
|
||||
|
||||
// OptionalSubResource is the Resource model definition for a nested resource
|
||||
// with no required properties.
|
||||
// OptionalSubResource is the Resource model definition for a nested resource with no required properties.
|
||||
type OptionalSubResource struct {
|
||||
ID *string `json:"id,omitempty"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
@@ -348,7 +408,7 @@ type Resource struct {
|
||||
Tags *map[string]*string `json:"tags,omitempty"`
|
||||
}
|
||||
|
||||
// SasTokenInfo is sAS token information.
|
||||
// SasTokenInfo is SAS token information.
|
||||
type SasTokenInfo struct {
|
||||
AccessToken *string `json:"accessToken,omitempty"`
|
||||
}
|
||||
@@ -371,14 +431,13 @@ type StorageAccountProperties struct {
|
||||
// StorageContainer is azure Storage blob container information.
|
||||
type StorageContainer struct {
|
||||
autorest.Response `json:"-"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
ID *string `json:"id,omitempty"`
|
||||
Name *string `json:"name,omitempty"`
|
||||
Type *string `json:"type,omitempty"`
|
||||
*StorageContainerProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// StorageContainerProperties is azure Storage blob container properties
|
||||
// information.
|
||||
// StorageContainerProperties is azure Storage blob container properties information.
|
||||
type StorageContainerProperties struct {
|
||||
LastModifiedTime *date.Time `json:"lastModifiedTime,omitempty"`
|
||||
}
|
||||
@@ -390,39 +449,39 @@ type SubResource struct {
|
||||
Type *string `json:"type,omitempty"`
|
||||
}
|
||||
|
||||
// UpdateDataLakeAnalyticsAccountProperties is the properties to update that
|
||||
// are associated with an underlying Data Lake Analytics account to.
|
||||
// UpdateDataLakeAnalyticsAccountProperties is the properties to update that are associated with an underlying Data
|
||||
// Lake Analytics account to.
|
||||
type UpdateDataLakeAnalyticsAccountProperties struct {
|
||||
MaxDegreeOfParallelism *int32 `json:"maxDegreeOfParallelism,omitempty"`
|
||||
QueryStoreRetention *int32 `json:"queryStoreRetention,omitempty"`
|
||||
MaxJobCount *int32 `json:"maxJobCount,omitempty"`
|
||||
NewTier TierType `json:"newTier,omitempty"`
|
||||
FirewallState FirewallState `json:"firewallState,omitempty"`
|
||||
FirewallAllowAzureIps FirewallAllowAzureIpsState `json:"firewallAllowAzureIps,omitempty"`
|
||||
FirewallRules *[]FirewallRule `json:"firewallRules,omitempty"`
|
||||
MaxDegreeOfParallelism *int32 `json:"maxDegreeOfParallelism,omitempty"`
|
||||
QueryStoreRetention *int32 `json:"queryStoreRetention,omitempty"`
|
||||
MaxJobCount *int32 `json:"maxJobCount,omitempty"`
|
||||
NewTier TierType `json:"newTier,omitempty"`
|
||||
FirewallState FirewallState `json:"firewallState,omitempty"`
|
||||
FirewallAllowAzureIps FirewallAllowAzureIpsState `json:"firewallAllowAzureIps,omitempty"`
|
||||
FirewallRules *[]FirewallRule `json:"firewallRules,omitempty"`
|
||||
MaxDegreeOfParallelismPerJob *int32 `json:"maxDegreeOfParallelismPerJob,omitempty"`
|
||||
MinPriorityPerJob *int32 `json:"minPriorityPerJob,omitempty"`
|
||||
ComputePolicies *[]ComputePolicy `json:"computePolicies,omitempty"`
|
||||
}
|
||||
|
||||
// UpdateFirewallRuleParameters is data Lake Analytics firewall rule update
|
||||
// parameters
|
||||
// UpdateFirewallRuleParameters is data Lake Analytics firewall rule update parameters
|
||||
type UpdateFirewallRuleParameters struct {
|
||||
*UpdateFirewallRuleProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// UpdateFirewallRuleProperties is data Lake Analytics firewall rule properties
|
||||
// information
|
||||
// UpdateFirewallRuleProperties is data Lake Analytics firewall rule properties information
|
||||
type UpdateFirewallRuleProperties struct {
|
||||
StartIPAddress *string `json:"startIpAddress,omitempty"`
|
||||
EndIPAddress *string `json:"endIpAddress,omitempty"`
|
||||
}
|
||||
|
||||
// UpdateStorageAccountParameters is storage account parameters for a storage
|
||||
// account being updated in a Data Lake Analytics account.
|
||||
// UpdateStorageAccountParameters is storage account parameters for a storage account being updated in a Data Lake
|
||||
// Analytics account.
|
||||
type UpdateStorageAccountParameters struct {
|
||||
*UpdateStorageAccountProperties `json:"properties,omitempty"`
|
||||
}
|
||||
|
||||
// UpdateStorageAccountProperties is azure Storage account properties
|
||||
// information to update.
|
||||
// UpdateStorageAccountProperties is azure Storage account properties information to update.
|
||||
type UpdateStorageAccountProperties struct {
|
||||
AccessKey *string `json:"accessKey,omitempty"`
|
||||
Suffix *string `json:"suffix,omitempty"`
|
||||
|
||||
Generated
Vendored
+186
-78
@@ -14,9 +14,8 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
import (
|
||||
"github.com/Azure/go-autorest/autorest"
|
||||
@@ -25,32 +24,26 @@ import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// StorageAccountsClient is the creates an Azure Data Lake Analytics account
|
||||
// management client.
|
||||
// StorageAccountsClient is the creates an Azure Data Lake Analytics account management client.
|
||||
type StorageAccountsClient struct {
|
||||
ManagementClient
|
||||
}
|
||||
|
||||
// NewStorageAccountsClient creates an instance of the StorageAccountsClient
|
||||
// client.
|
||||
// NewStorageAccountsClient creates an instance of the StorageAccountsClient client.
|
||||
func NewStorageAccountsClient(subscriptionID string) StorageAccountsClient {
|
||||
return NewStorageAccountsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||
}
|
||||
|
||||
// NewStorageAccountsClientWithBaseURI creates an instance of the
|
||||
// StorageAccountsClient client.
|
||||
// NewStorageAccountsClientWithBaseURI creates an instance of the StorageAccountsClient client.
|
||||
func NewStorageAccountsClientWithBaseURI(baseURI string, subscriptionID string) StorageAccountsClient {
|
||||
return StorageAccountsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// Add updates the specified Data Lake Analytics account to add an Azure
|
||||
// Storage account.
|
||||
// Add updates the specified Data Lake Analytics account to add an Azure Storage account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to which to add the Azure Storage account.
|
||||
// storageAccountName is the name of the Azure Storage account to add
|
||||
// parameters is the parameters containing the access key and optional suffix
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to which to add the Azure Storage account. storageAccountName is the
|
||||
// name of the Azure Storage account to add parameters is the parameters containing the access key and optional suffix
|
||||
// for the Azure Storage Account.
|
||||
func (client StorageAccountsClient) Add(resourceGroupName string, accountName string, storageAccountName string, parameters AddStorageAccountParameters) (result autorest.Response, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
@@ -123,13 +116,11 @@ func (client StorageAccountsClient) AddResponder(resp *http.Response) (result au
|
||||
return
|
||||
}
|
||||
|
||||
// Delete updates the specified Data Lake Analytics account to remove an Azure
|
||||
// Storage account.
|
||||
// Delete updates the specified Data Lake Analytics account to remove an Azure Storage account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to remove the Azure Storage account.
|
||||
// storageAccountName is the name of the Azure Storage account to remove
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to remove the Azure Storage account. storageAccountName is
|
||||
// the name of the Azure Storage account to remove
|
||||
func (client StorageAccountsClient) Delete(resourceGroupName string, accountName string, storageAccountName string) (result autorest.Response, err error) {
|
||||
req, err := client.DeletePreparer(resourceGroupName, accountName, storageAccountName)
|
||||
if err != nil {
|
||||
@@ -192,14 +183,11 @@ func (client StorageAccountsClient) DeleteResponder(resp *http.Response) (result
|
||||
return
|
||||
}
|
||||
|
||||
// Get gets the specified Azure Storage account linked to the given Data Lake
|
||||
// Analytics account.
|
||||
// Get gets the specified Azure Storage account linked to the given Data Lake Analytics account.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which to retrieve Azure storage account details.
|
||||
// storageAccountName is the name of the Azure Storage account for which to
|
||||
// retrieve the details.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which to retrieve Azure storage account details.
|
||||
// storageAccountName is the name of the Azure Storage account for which to retrieve the details.
|
||||
func (client StorageAccountsClient) Get(resourceGroupName string, accountName string, storageAccountName string) (result StorageAccountInfo, err error) {
|
||||
req, err := client.GetPreparer(resourceGroupName, accountName, storageAccountName)
|
||||
if err != nil {
|
||||
@@ -263,15 +251,13 @@ func (client StorageAccountsClient) GetResponder(resp *http.Response) (result St
|
||||
return
|
||||
}
|
||||
|
||||
// GetStorageContainer gets the specified Azure Storage container associated
|
||||
// with the given Data Lake Analytics and Azure Storage accounts.
|
||||
// GetStorageContainer gets the specified Azure Storage container associated with the given Data Lake Analytics and
|
||||
// Azure Storage accounts.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account for which to retrieve blob container. storageAccountName
|
||||
// is the name of the Azure storage account from which to retrieve the blob
|
||||
// container. containerName is the name of the Azure storage container to
|
||||
// retrieve
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account for which to retrieve blob container. storageAccountName is the name
|
||||
// of the Azure storage account from which to retrieve the blob container. containerName is the name of the Azure
|
||||
// storage container to retrieve
|
||||
func (client StorageAccountsClient) GetStorageContainer(resourceGroupName string, accountName string, storageAccountName string, containerName string) (result StorageContainer, err error) {
|
||||
req, err := client.GetStorageContainerPreparer(resourceGroupName, accountName, storageAccountName, containerName)
|
||||
if err != nil {
|
||||
@@ -336,23 +322,18 @@ func (client StorageAccountsClient) GetStorageContainerResponder(resp *http.Resp
|
||||
return
|
||||
}
|
||||
|
||||
// ListByAccount gets the first page of Azure Storage accounts, if any, linked
|
||||
// to the specified Data Lake Analytics account. The response includes a link
|
||||
// to the next page, if any.
|
||||
// ListByAccount gets the first page of Azure Storage accounts, if any, linked to the specified Data Lake Analytics
|
||||
// account. The response includes a link to the next page, if any.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account for which to list Azure Storage accounts. filter is the
|
||||
// OData filter. Optional. top is the number of items to return. Optional. skip
|
||||
// is the number of items to skip over before returning elements. Optional.
|
||||
// selectParameter is oData Select statement. Limits the properties on each
|
||||
// entry to just those requested, e.g.
|
||||
// Categories?$select=CategoryName,Description. Optional. orderby is orderBy
|
||||
// clause. One or more comma-separated expressions with an optional "asc" (the
|
||||
// default) or "desc" depending on the order you'd like the values sorted, e.g.
|
||||
// Categories?$orderby=CategoryName desc. Optional. count is the Boolean value
|
||||
// of true or false to request a count of the matching resources included with
|
||||
// the resources in the response, e.g. Categories?$count=true. Optional.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account for which to list Azure Storage accounts. filter is the OData filter.
|
||||
// Optional. top is the number of items to return. Optional. skip is the number of items to skip over before returning
|
||||
// elements. Optional. selectParameter is oData Select statement. Limits the properties on each entry to just those
|
||||
// requested, e.g. Categories?$select=CategoryName,Description. Optional. orderby is orderBy clause. One or more
|
||||
// comma-separated expressions with an optional "asc" (the default) or "desc" depending on the order you'd like the
|
||||
// values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. count is the Boolean value of true or false to
|
||||
// request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.
|
||||
// Optional.
|
||||
func (client StorageAccountsClient) ListByAccount(resourceGroupName string, accountName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool) (result DataLakeAnalyticsAccountListStorageAccountsResult, err error) {
|
||||
if err := validation.Validate([]validation.Validation{
|
||||
{TargetValue: top,
|
||||
@@ -467,15 +448,58 @@ func (client StorageAccountsClient) ListByAccountNextResults(lastResults DataLak
|
||||
return
|
||||
}
|
||||
|
||||
// ListSasTokens gets the SAS token associated with the specified Data Lake
|
||||
// Analytics and Azure Storage account and container combination.
|
||||
// ListByAccountComplete gets all elements from the list without paging.
|
||||
func (client StorageAccountsClient) ListByAccountComplete(resourceGroupName string, accountName string, filter string, top *int32, skip *int32, selectParameter string, orderby string, count *bool, cancel <-chan struct{}) (<-chan StorageAccountInfo, <-chan error) {
|
||||
resultChan := make(chan StorageAccountInfo)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListByAccount(resourceGroupName, accountName, filter, top, skip, selectParameter, orderby, count)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListByAccountNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// ListSasTokens gets the SAS token associated with the specified Data Lake Analytics and Azure Storage account and
|
||||
// container combination.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account from which an Azure Storage account's SAS token is being
|
||||
// requested. storageAccountName is the name of the Azure storage account for
|
||||
// which the SAS token is being requested. containerName is the name of the
|
||||
// Azure storage container for which the SAS token is being requested.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account from which an Azure Storage account's SAS token is being requested.
|
||||
// storageAccountName is the name of the Azure storage account for which the SAS token is being requested.
|
||||
// containerName is the name of the Azure storage container for which the SAS token is being requested.
|
||||
func (client StorageAccountsClient) ListSasTokens(resourceGroupName string, accountName string, storageAccountName string, containerName string) (result ListSasTokensResult, err error) {
|
||||
req, err := client.ListSasTokensPreparer(resourceGroupName, accountName, storageAccountName, containerName)
|
||||
if err != nil {
|
||||
@@ -564,16 +588,57 @@ func (client StorageAccountsClient) ListSasTokensNextResults(lastResults ListSas
|
||||
return
|
||||
}
|
||||
|
||||
// ListStorageContainers lists the Azure Storage containers, if any, associated
|
||||
// with the specified Data Lake Analytics and Azure Storage account
|
||||
// combination. The response includes a link to the next page of results, if
|
||||
// any.
|
||||
// ListSasTokensComplete gets all elements from the list without paging.
|
||||
func (client StorageAccountsClient) ListSasTokensComplete(resourceGroupName string, accountName string, storageAccountName string, containerName string, cancel <-chan struct{}) (<-chan SasTokenInfo, <-chan error) {
|
||||
resultChan := make(chan SasTokenInfo)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListSasTokens(resourceGroupName, accountName, storageAccountName, containerName)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListSasTokensNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// ListStorageContainers lists the Azure Storage containers, if any, associated with the specified Data Lake Analytics
|
||||
// and Azure Storage account combination. The response includes a link to the next page of results, if any.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account for which to list Azure Storage blob containers.
|
||||
// storageAccountName is the name of the Azure storage account from which to
|
||||
// list blob containers.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account for which to list Azure Storage blob containers. storageAccountName
|
||||
// is the name of the Azure storage account from which to list blob containers.
|
||||
func (client StorageAccountsClient) ListStorageContainers(resourceGroupName string, accountName string, storageAccountName string) (result ListStorageContainersResult, err error) {
|
||||
req, err := client.ListStorageContainersPreparer(resourceGroupName, accountName, storageAccountName)
|
||||
if err != nil {
|
||||
@@ -661,15 +726,58 @@ func (client StorageAccountsClient) ListStorageContainersNextResults(lastResults
|
||||
return
|
||||
}
|
||||
|
||||
// Update updates the Data Lake Analytics account to replace Azure Storage blob
|
||||
// account details, such as the access key and/or suffix.
|
||||
// ListStorageContainersComplete gets all elements from the list without paging.
|
||||
func (client StorageAccountsClient) ListStorageContainersComplete(resourceGroupName string, accountName string, storageAccountName string, cancel <-chan struct{}) (<-chan StorageContainer, <-chan error) {
|
||||
resultChan := make(chan StorageContainer)
|
||||
errChan := make(chan error, 1)
|
||||
go func() {
|
||||
defer func() {
|
||||
close(resultChan)
|
||||
close(errChan)
|
||||
}()
|
||||
list, err := client.ListStorageContainers(resourceGroupName, accountName, storageAccountName)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
for list.NextLink != nil {
|
||||
list, err = client.ListStorageContainersNextResults(list)
|
||||
if err != nil {
|
||||
errChan <- err
|
||||
return
|
||||
}
|
||||
if list.Value != nil {
|
||||
for _, item := range *list.Value {
|
||||
select {
|
||||
case <-cancel:
|
||||
return
|
||||
case resultChan <- item:
|
||||
// Intentionally left blank
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}()
|
||||
return resultChan, errChan
|
||||
}
|
||||
|
||||
// Update updates the Data Lake Analytics account to replace Azure Storage blob account details, such as the access key
|
||||
// and/or suffix.
|
||||
//
|
||||
// resourceGroupName is the name of the Azure resource group that contains the
|
||||
// Data Lake Analytics account. accountName is the name of the Data Lake
|
||||
// Analytics account to modify storage accounts in storageAccountName is the
|
||||
// Azure Storage account to modify parameters is the parameters containing the
|
||||
// access key and suffix to update the storage account with, if any. Passing
|
||||
// nothing results in no change.
|
||||
// resourceGroupName is the name of the Azure resource group that contains the Data Lake Analytics account. accountName
|
||||
// is the name of the Data Lake Analytics account to modify storage accounts in storageAccountName is the Azure Storage
|
||||
// account to modify parameters is the parameters containing the access key and suffix to update the storage account
|
||||
// with, if any. Passing nothing results in no change.
|
||||
func (client StorageAccountsClient) Update(resourceGroupName string, accountName string, storageAccountName string, parameters *UpdateStorageAccountParameters) (result autorest.Response, err error) {
|
||||
req, err := client.UpdatePreparer(resourceGroupName, accountName, storageAccountName, parameters)
|
||||
if err != nil {
|
||||
|
||||
Generated
Vendored
+4
-5
@@ -14,16 +14,15 @@ package account
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator 1.0.1.0
|
||||
// Changes may cause incorrect behavior and will be lost if the code is
|
||||
// regenerated.
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
// UserAgent returns the UserAgent string to use when sending http.Requests.
|
||||
func UserAgent() string {
|
||||
return "Azure-SDK-For-Go/v10.1.0-beta arm-account/2016-11-01"
|
||||
return "Azure-SDK-For-Go/v11.0.0-beta arm-account/2016-11-01"
|
||||
}
|
||||
|
||||
// Version returns the semantic version (see http://semver.org) of the client.
|
||||
func Version() string {
|
||||
return "v10.1.0-beta"
|
||||
return "v11.0.0-beta"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user