diff --git a/azurerm/data_source_storage_account.go b/azurerm/data_source_storage_account.go
index 80011d590ba8..29843d29252f 100644
--- a/azurerm/data_source_storage_account.go
+++ b/azurerm/data_source_storage_account.go
@@ -6,6 +6,7 @@ import (
"strings"
"time"
+ "github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage"
azautorest "github.com/Azure/go-autorest/autorest"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/terraform-providers/terraform-provider-azurerm/azurerm/helpers/azure"
@@ -289,7 +290,7 @@ func dataSourceArmStorageAccountRead(d *schema.ResourceData, meta interface{}) e
d.Set("primary_access_key", "")
d.Set("secondary_access_key", "")
- keys, err := client.ListKeys(ctx, resourceGroup, name)
+ keys, err := client.ListKeys(ctx, resourceGroup, name, storage.Kerb)
if err != nil {
// the API returns a 200 with an inner error of a 409..
var hasWriteLock bool
diff --git a/azurerm/internal/services/recoveryservices/client.go b/azurerm/internal/services/recoveryservices/client.go
index 7d3abc4f550d..29dd936573d7 100644
--- a/azurerm/internal/services/recoveryservices/client.go
+++ b/azurerm/internal/services/recoveryservices/client.go
@@ -8,7 +8,7 @@ import (
)
type Client struct {
- ProtectedItemsClient *backup.ProtectedItemsGroupClient
+ ProtectedItemsClient *backup.ProtectedItemsClient
ProtectionPoliciesClient *backup.ProtectionPoliciesClient
VaultsClient *recoveryservices.VaultsClient
FabricClient func(resourceGroupName string, vaultName string) siterecovery.ReplicationFabricsClient
@@ -23,7 +23,7 @@ func BuildClient(o *common.ClientOptions) *Client {
VaultsClient := recoveryservices.NewVaultsClientWithBaseURI(o.ResourceManagerEndpoint, o.SubscriptionId)
o.ConfigureClient(&VaultsClient.Client, o.ResourceManagerAuthorizer)
- ProtectedItemsClient := backup.NewProtectedItemsGroupClientWithBaseURI(o.ResourceManagerEndpoint, o.SubscriptionId)
+ ProtectedItemsClient := backup.NewProtectedItemsClientWithBaseURI(o.ResourceManagerEndpoint, o.SubscriptionId)
o.ConfigureClient(&ProtectedItemsClient.Client, o.ResourceManagerAuthorizer)
ProtectionPoliciesClient := backup.NewProtectionPoliciesClientWithBaseURI(o.ResourceManagerEndpoint, o.SubscriptionId)
diff --git a/azurerm/internal/services/storage/helpers.go b/azurerm/internal/services/storage/helpers.go
index f1a85ffdbfd2..f21e1218296f 100644
--- a/azurerm/internal/services/storage/helpers.go
+++ b/azurerm/internal/services/storage/helpers.go
@@ -34,7 +34,7 @@ func (ad *accountDetails) AccountKey(ctx context.Context, client Client) (*strin
}
log.Printf("[DEBUG] Cache Miss - looking up the account key for storage account %q..", ad.name)
- props, err := client.AccountsClient.ListKeys(ctx, ad.ResourceGroup, ad.name)
+ props, err := client.AccountsClient.ListKeys(ctx, ad.ResourceGroup, ad.name, storage.Kerb)
if err != nil {
return nil, fmt.Errorf("Error Listing Keys for Storage Account %q (Resource Group %q): %+v", ad.name, ad.ResourceGroup, err)
}
diff --git a/azurerm/resource_arm_cognitive_account.go b/azurerm/resource_arm_cognitive_account.go
index 4bededc57c42..901dd0c477a1 100644
--- a/azurerm/resource_arm_cognitive_account.go
+++ b/azurerm/resource_arm_cognitive_account.go
@@ -18,8 +18,6 @@ import (
"github.com/terraform-providers/terraform-provider-azurerm/azurerm/utils"
)
-type cognitiveServicesPropertiesStruct struct{}
-
func resourceArmCognitiveAccount() *schema.Resource {
return &schema.Resource{
Create: resourceArmCognitiveAccountCreate,
@@ -159,11 +157,11 @@ func resourceArmCognitiveAccountCreate(d *schema.ResourceData, meta interface{})
t := d.Get("tags").(map[string]interface{})
sku := expandCognitiveAccountSku(d)
- properties := cognitiveservices.AccountCreateParameters{
+ properties := cognitiveservices.Account{
Kind: utils.String(kind),
Location: utils.String(location),
Sku: sku,
- Properties: &cognitiveServicesPropertiesStruct{},
+ Properties: &cognitiveservices.AccountProperties{},
Tags: tags.Expand(t),
}
@@ -197,7 +195,7 @@ func resourceArmCognitiveAccountUpdate(d *schema.ResourceData, meta interface{})
t := d.Get("tags").(map[string]interface{})
sku := expandCognitiveAccountSku(d)
- properties := cognitiveservices.AccountUpdateParameters{
+ properties := cognitiveservices.Account{
Sku: sku,
Tags: tags.Expand(t),
}
@@ -246,7 +244,7 @@ func resourceArmCognitiveAccountRead(d *schema.ResourceData, meta interface{}) e
return fmt.Errorf("Error setting `sku`: %+v", err)
}
- if props := resp.AccountProperties; props != nil {
+ if props := resp.Properties; props != nil {
d.Set("endpoint", props.Endpoint)
}
diff --git a/azurerm/resource_arm_recovery_services_protected_vm.go b/azurerm/resource_arm_recovery_services_protected_vm.go
index 421462109018..1d6a9279d629 100644
--- a/azurerm/resource_arm_recovery_services_protected_vm.go
+++ b/azurerm/resource_arm_recovery_services_protected_vm.go
@@ -206,7 +206,7 @@ func resourceArmRecoveryServicesProtectedVmDelete(d *schema.ResourceData, meta i
return nil
}
-func resourceArmRecoveryServicesProtectedVmWaitForState(client *backup.ProtectedItemsGroupClient, ctx context.Context, found bool, vaultName, resourceGroup, containerName, protectedItemName string, policyId string, newResource bool) (backup.ProtectedItemResource, error) {
+func resourceArmRecoveryServicesProtectedVmWaitForState(client *backup.ProtectedItemsClient, ctx context.Context, found bool, vaultName, resourceGroup, containerName, protectedItemName string, policyId string, newResource bool) (backup.ProtectedItemResource, error) {
state := &resource.StateChangeConf{
Timeout: 30 * time.Minute,
MinTimeout: 30 * time.Second,
diff --git a/azurerm/resource_arm_storage_account.go b/azurerm/resource_arm_storage_account.go
index 3b7deb42cc92..b06ca8d356cf 100644
--- a/azurerm/resource_arm_storage_account.go
+++ b/azurerm/resource_arm_storage_account.go
@@ -1016,7 +1016,7 @@ func resourceArmStorageAccountRead(d *schema.ResourceData, meta interface{}) err
d.Set("primary_access_key", "")
d.Set("secondary_access_key", "")
- keys, err := client.ListKeys(ctx, resGroup, name)
+ keys, err := client.ListKeys(ctx, resGroup, name, storage.Kerb)
if err != nil {
// the API returns a 200 with an inner error of a 409..
var hasWriteLock bool
diff --git a/go.mod b/go.mod
index 05c0f84a5eb6..e6d3af57ef5f 100644
--- a/go.mod
+++ b/go.mod
@@ -1,13 +1,13 @@
module github.com/terraform-providers/terraform-provider-azurerm
require (
- github.com/Azure/azure-sdk-for-go v34.1.0+incompatible
- github.com/Azure/go-autorest/autorest v0.9.0
+ github.com/Azure/azure-sdk-for-go v35.0.0+incompatible
+ github.com/Azure/go-autorest/autorest v0.9.2
github.com/Azure/go-autorest/autorest/date v0.2.0
github.com/btubbs/datetime v0.1.0
github.com/davecgh/go-spew v1.1.1
github.com/google/uuid v1.1.1
- github.com/hashicorp/go-azure-helpers v0.9.0
+ github.com/hashicorp/go-azure-helpers v0.10.0
github.com/hashicorp/go-getter v1.4.0
github.com/hashicorp/go-multierror v1.0.0
github.com/hashicorp/go-uuid v1.0.1
diff --git a/go.sum b/go.sum
index 5a9de3c28e6b..e811df33ca58 100644
--- a/go.sum
+++ b/go.sum
@@ -15,15 +15,21 @@ github.com/Azure/azure-sdk-for-go v32.5.0+incompatible h1:Hn/DsObfmw0M7dMGS/c0Ml
github.com/Azure/azure-sdk-for-go v32.5.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/azure-sdk-for-go v34.1.0+incompatible h1:uW/dgSzmRQEPXwaRUN8WzBHJy5J2cp8cw1ea908uFj0=
github.com/Azure/azure-sdk-for-go v34.1.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-sdk-for-go v35.0.0+incompatible h1:PkmdmQUmeSdQQ5258f4SyCf2Zcz0w67qztEg37cOR7U=
+github.com/Azure/azure-sdk-for-go v35.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/go-autorest v10.15.4+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest v13.0.0+incompatible h1:56c11ykhsFSPNNQuS73Ri8h/ezqVhr2h6t9LJIEKVO0=
github.com/Azure/go-autorest v13.0.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest/autorest v0.9.0 h1:MRvx8gncNaXJqOoLmhNjUAKh33JJF8LyxPhomEtOsjs=
github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
+github.com/Azure/go-autorest/autorest v0.9.2 h1:6AWuh3uWrsZJcNoCHrCF/+g4aKPCU39kaMO6/qrnK/4=
+github.com/Azure/go-autorest/autorest v0.9.2/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
github.com/Azure/go-autorest/autorest/adal v0.5.0 h1:q2gDruN08/guU9vAjuPWff0+QIrpH6ediguzdAzXAUU=
github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
github.com/Azure/go-autorest/autorest/adal v0.6.0 h1:UCTq22yE3RPgbU/8u4scfnnzuCW6pwQ9n+uBtV78ouo=
github.com/Azure/go-autorest/autorest/adal v0.6.0/go.mod h1:Z6vX6WXXuyieHAXwMj0S6HY6e6wcHn37qQMBQlvY3lc=
+github.com/Azure/go-autorest/autorest/adal v0.8.1-0.20191028180845-3492b2aff503 h1:Hxqlh1uAA8aGpa1dFhDNhll7U/rkWtG8ZItFvRMr7l0=
+github.com/Azure/go-autorest/autorest/adal v0.8.1-0.20191028180845-3492b2aff503/go.mod h1:Z6vX6WXXuyieHAXwMj0S6HY6e6wcHn37qQMBQlvY3lc=
github.com/Azure/go-autorest/autorest/azure/auth v0.3.0/go.mod h1:CI4BQYBct8NS7BXNBBX+RchsFsUu5+oz+OSyR/ZIi7U=
github.com/Azure/go-autorest/autorest/azure/cli v0.2.0 h1:pSwNMF0qotgehbQNllUWwJ4V3vnrLKOzHrwDLEZK904=
github.com/Azure/go-autorest/autorest/azure/cli v0.2.0/go.mod h1:WWTbGPvkAg3I4ms2j2s+Zr5xCGwGqTQh+6M2ZqOczkE=
@@ -197,6 +203,8 @@ github.com/hashicorp/go-azure-helpers v0.7.0 h1:wxGpOyWYp15bjBMeL3pXKP5X3oFLZbTh
github.com/hashicorp/go-azure-helpers v0.7.0/go.mod h1:3xdjhbL7qs69rnwxA0UENOzkPJjtTFIRb5aRyrEpbCU=
github.com/hashicorp/go-azure-helpers v0.9.0 h1:KERW4n9AukvQ6kXGJdqXLaR0S2yxH3Xwj+rio/3/uLI=
github.com/hashicorp/go-azure-helpers v0.9.0/go.mod h1:3xdjhbL7qs69rnwxA0UENOzkPJjtTFIRb5aRyrEpbCU=
+github.com/hashicorp/go-azure-helpers v0.10.0 h1:KhjDnQhCqEMKlt4yH00MCevJQPJ6LkHFdSveXINO6vE=
+github.com/hashicorp/go-azure-helpers v0.10.0/go.mod h1:YuAtHxm2v74s+IjQwUG88dHBJPd5jL+cXr5BGVzSKhE=
github.com/hashicorp/go-checkpoint v0.5.0/go.mod h1:7nfLNL10NsxqO4iWuW6tWW0HjZuDrwkBuEQsVcpCOgg=
github.com/hashicorp/go-cleanhttp v0.5.0 h1:wvCrVc9TjDls6+YGAF2hAifE1E5U1+b4tH6KdvN3Gig=
github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/automation/mgmt/2015-10-31/automation/jobschedule.go b/vendor/github.com/Azure/azure-sdk-for-go/services/automation/mgmt/2015-10-31/automation/jobschedule.go
index 02866fdea827..78fd95ae7562 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/automation/mgmt/2015-10-31/automation/jobschedule.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/automation/mgmt/2015-10-31/automation/jobschedule.go
@@ -19,13 +19,12 @@ package automation
import (
"context"
- "net/http"
-
"github.com/Azure/go-autorest/autorest"
"github.com/Azure/go-autorest/autorest/azure"
"github.com/Azure/go-autorest/autorest/validation"
"github.com/Azure/go-autorest/tracing"
"github.com/satori/go.uuid"
+ "net/http"
)
// JobScheduleClient is the automation Client
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/accounts.go b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/accounts.go
index 3e3eea0f5422..96aa03010e9f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/accounts.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/accounts.go
@@ -46,8 +46,8 @@ func NewAccountsClientWithBaseURI(baseURI string, subscriptionID string) Account
// Parameters:
// resourceGroupName - the name of the resource group within the user's subscription.
// accountName - the name of Cognitive Services account.
-// parameters - the parameters to provide for the created account.
-func (client AccountsClient) Create(ctx context.Context, resourceGroupName string, accountName string, parameters AccountCreateParameters) (result Account, err error) {
+// account - the parameters to provide for the created account.
+func (client AccountsClient) Create(ctx context.Context, resourceGroupName string, accountName string, account Account) (result Account, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AccountsClient.Create")
defer func() {
@@ -63,16 +63,25 @@ func (client AccountsClient) Create(ctx context.Context, resourceGroupName strin
Constraints: []validation.Constraint{{Target: "accountName", Name: validation.MaxLength, Rule: 64, Chain: nil},
{Target: "accountName", Name: validation.MinLength, Rule: 2, Chain: nil},
{Target: "accountName", Name: validation.Pattern, Rule: `^[a-zA-Z0-9][a-zA-Z0-9_.-]*$`, Chain: nil}}},
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Sku", Name: validation.Null, Rule: true,
- Chain: []validation.Constraint{{Target: "parameters.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}},
- {Target: "parameters.Kind", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.Location", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.Properties", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ {TargetValue: account,
+ Constraints: []validation.Constraint{{Target: "account.Properties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "account.Properties.APIProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "account.Properties.APIProperties.EventHubConnectionString", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "account.Properties.APIProperties.EventHubConnectionString", Name: validation.MaxLength, Rule: 1000, Chain: nil},
+ {Target: "account.Properties.APIProperties.EventHubConnectionString", Name: validation.Pattern, Rule: `^( *)Endpoint=sb://(.*);( *)SharedAccessKeyName=(.*);( *)SharedAccessKey=(.*)$`, Chain: nil},
+ }},
+ {Target: "account.Properties.APIProperties.StorageAccountConnectionString", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "account.Properties.APIProperties.StorageAccountConnectionString", Name: validation.MaxLength, Rule: 1000, Chain: nil},
+ {Target: "account.Properties.APIProperties.StorageAccountConnectionString", Name: validation.Pattern, Rule: `^(( *)DefaultEndpointsProtocol=(http|https)( *);( *))?AccountName=(.*)AccountKey=(.*)EndpointSuffix=(.*)$`, Chain: nil},
+ }},
+ }},
+ }},
+ {Target: "account.Sku", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "account.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
return result, validation.NewError("cognitiveservices.AccountsClient", "Create", err.Error())
}
- req, err := client.CreatePreparer(ctx, resourceGroupName, accountName, parameters)
+ req, err := client.CreatePreparer(ctx, resourceGroupName, accountName, account)
if err != nil {
err = autorest.NewErrorWithError(err, "cognitiveservices.AccountsClient", "Create", nil, "Failure preparing request")
return
@@ -94,7 +103,7 @@ func (client AccountsClient) Create(ctx context.Context, resourceGroupName strin
}
// CreatePreparer prepares the Create request.
-func (client AccountsClient) CreatePreparer(ctx context.Context, resourceGroupName string, accountName string, parameters AccountCreateParameters) (*http.Request, error) {
+func (client AccountsClient) CreatePreparer(ctx context.Context, resourceGroupName string, accountName string, account Account) (*http.Request, error) {
pathParameters := map[string]interface{}{
"accountName": autorest.Encode("path", accountName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -106,12 +115,16 @@ func (client AccountsClient) CreatePreparer(ctx context.Context, resourceGroupNa
"api-version": APIVersion,
}
+ account.Etag = nil
+ account.ID = nil
+ account.Name = nil
+ account.Type = nil
preparer := autorest.CreatePreparer(
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CognitiveServices/accounts/{accountName}", pathParameters),
- autorest.WithJSON(parameters),
+ autorest.WithJSON(account),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
@@ -880,8 +893,8 @@ func (client AccountsClient) RegenerateKeyResponder(resp *http.Response) (result
// Parameters:
// resourceGroupName - the name of the resource group within the user's subscription.
// accountName - the name of Cognitive Services account.
-// parameters - the parameters to provide for the created account.
-func (client AccountsClient) Update(ctx context.Context, resourceGroupName string, accountName string, parameters AccountUpdateParameters) (result Account, err error) {
+// account - the parameters to provide for the created account.
+func (client AccountsClient) Update(ctx context.Context, resourceGroupName string, accountName string, account Account) (result Account, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AccountsClient.Update")
defer func() {
@@ -900,7 +913,7 @@ func (client AccountsClient) Update(ctx context.Context, resourceGroupName strin
return result, validation.NewError("cognitiveservices.AccountsClient", "Update", err.Error())
}
- req, err := client.UpdatePreparer(ctx, resourceGroupName, accountName, parameters)
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, accountName, account)
if err != nil {
err = autorest.NewErrorWithError(err, "cognitiveservices.AccountsClient", "Update", nil, "Failure preparing request")
return
@@ -922,7 +935,7 @@ func (client AccountsClient) Update(ctx context.Context, resourceGroupName strin
}
// UpdatePreparer prepares the Update request.
-func (client AccountsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, accountName string, parameters AccountUpdateParameters) (*http.Request, error) {
+func (client AccountsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, accountName string, account Account) (*http.Request, error) {
pathParameters := map[string]interface{}{
"accountName": autorest.Encode("path", accountName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -934,12 +947,16 @@ func (client AccountsClient) UpdatePreparer(ctx context.Context, resourceGroupNa
"api-version": APIVersion,
}
+ account.Etag = nil
+ account.ID = nil
+ account.Name = nil
+ account.Type = nil
preparer := autorest.CreatePreparer(
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPatch(),
autorest.WithBaseURL(client.BaseURI),
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CognitiveServices/accounts/{accountName}", pathParameters),
- autorest.WithJSON(parameters),
+ autorest.WithJSON(account),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/checkskuavailability.go b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/checkskuavailability.go
deleted file mode 100644
index 4339b18a4838..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/checkskuavailability.go
+++ /dev/null
@@ -1,128 +0,0 @@
-package cognitiveservices
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// CheckSkuAvailabilityClient is the cognitive Services Management Client
-type CheckSkuAvailabilityClient struct {
- BaseClient
-}
-
-// NewCheckSkuAvailabilityClient creates an instance of the CheckSkuAvailabilityClient client.
-func NewCheckSkuAvailabilityClient(subscriptionID string) CheckSkuAvailabilityClient {
- return NewCheckSkuAvailabilityClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewCheckSkuAvailabilityClientWithBaseURI creates an instance of the CheckSkuAvailabilityClient client.
-func NewCheckSkuAvailabilityClientWithBaseURI(baseURI string, subscriptionID string) CheckSkuAvailabilityClient {
- return CheckSkuAvailabilityClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// List check available SKUs.
-// Parameters:
-// location - resource location.
-// parameters - check SKU Availability POST body.
-func (client CheckSkuAvailabilityClient) List(ctx context.Context, location string, parameters CheckSkuAvailabilityParameter) (result CheckSkuAvailabilityResultList, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/CheckSkuAvailabilityClient.List")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Skus", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.Kind", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.Type", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("cognitiveservices.CheckSkuAvailabilityClient", "List", err.Error())
- }
-
- req, err := client.ListPreparer(ctx, location, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "cognitiveservices.CheckSkuAvailabilityClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "cognitiveservices.CheckSkuAvailabilityClient", "List", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "cognitiveservices.CheckSkuAvailabilityClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client CheckSkuAvailabilityClient) ListPreparer(ctx context.Context, location string, parameters CheckSkuAvailabilityParameter) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "location": autorest.Encode("path", location),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-04-18"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.CognitiveServices/locations/{location}/checkSkuAvailability", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client CheckSkuAvailabilityClient) ListSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client CheckSkuAvailabilityClient) ListResponder(resp *http.Response) (result CheckSkuAvailabilityResultList, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/client.go b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/client.go
index ba2be90e1e99..49599b4fa9a3 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/client.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/client.go
@@ -137,3 +137,89 @@ func (client BaseClient) CheckDomainAvailabilityResponder(resp *http.Response) (
result.Response = autorest.Response{Response: resp}
return
}
+
+// CheckSkuAvailability check available SKUs.
+// Parameters:
+// location - resource location.
+// parameters - check SKU Availability POST body.
+func (client BaseClient) CheckSkuAvailability(ctx context.Context, location string, parameters CheckSkuAvailabilityParameter) (result CheckSkuAvailabilityResultList, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BaseClient.CheckSkuAvailability")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.Skus", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.Kind", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.Type", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("cognitiveservices.BaseClient", "CheckSkuAvailability", err.Error())
+ }
+
+ req, err := client.CheckSkuAvailabilityPreparer(ctx, location, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "cognitiveservices.BaseClient", "CheckSkuAvailability", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CheckSkuAvailabilitySender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "cognitiveservices.BaseClient", "CheckSkuAvailability", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CheckSkuAvailabilityResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "cognitiveservices.BaseClient", "CheckSkuAvailability", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CheckSkuAvailabilityPreparer prepares the CheckSkuAvailability request.
+func (client BaseClient) CheckSkuAvailabilityPreparer(ctx context.Context, location string, parameters CheckSkuAvailabilityParameter) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "location": autorest.Encode("path", location),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-04-18"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.CognitiveServices/locations/{location}/checkSkuAvailability", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CheckSkuAvailabilitySender sends the CheckSkuAvailability request. The method will close the
+// http.Response Body if it receives an error.
+func (client BaseClient) CheckSkuAvailabilitySender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CheckSkuAvailabilityResponder handles the response to the CheckSkuAvailability request. The method always
+// closes the http.Response Body.
+func (client BaseClient) CheckSkuAvailabilityResponder(resp *http.Response) (result CheckSkuAvailabilityResultList, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/models.go
index 4478c4e38058..732c8f44c7b1 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/mgmt/2017-04-18/cognitiveservices/models.go
@@ -59,21 +59,6 @@ func PossibleNetworkRuleActionValues() []NetworkRuleAction {
return []NetworkRuleAction{Allow, Deny}
}
-// NetworkRuleBypassOptions enumerates the values for network rule bypass options.
-type NetworkRuleBypassOptions string
-
-const (
- // AzureServices ...
- AzureServices NetworkRuleBypassOptions = "AzureServices"
- // None ...
- None NetworkRuleBypassOptions = "None"
-)
-
-// PossibleNetworkRuleBypassOptionsValues returns an array of possible values for the NetworkRuleBypassOptions const type.
-func PossibleNetworkRuleBypassOptionsValues() []NetworkRuleBypassOptions {
- return []NetworkRuleBypassOptions{AzureServices, None}
-}
-
// ProvisioningState enumerates the values for provisioning state.
type ProvisioningState string
@@ -192,18 +177,18 @@ func PossibleUnitTypeValues() []UnitType {
// location and SKU.
type Account struct {
autorest.Response `json:"-"`
- // Etag - Entity Tag
+ // Etag - READ-ONLY; Entity Tag
Etag *string `json:"etag,omitempty"`
// ID - READ-ONLY; The id of the created account
ID *string `json:"id,omitempty"`
- // Kind - Type of cognitive service account.
+ // Kind - The Kind of the resource.
Kind *string `json:"kind,omitempty"`
// Location - The location of the resource
Location *string `json:"location,omitempty"`
// Name - READ-ONLY; The name of the created account
Name *string `json:"name,omitempty"`
- // AccountProperties - Properties of Cognitive Services account.
- *AccountProperties `json:"properties,omitempty"`
+ // Properties - Properties of Cognitive Services account.
+ Properties *AccountProperties `json:"properties,omitempty"`
// Sku - The SKU of Cognitive Services account.
Sku *Sku `json:"sku,omitempty"`
// Tags - Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
@@ -215,17 +200,14 @@ type Account struct {
// MarshalJSON is the custom marshaler for Account.
func (a Account) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
- if a.Etag != nil {
- objectMap["etag"] = a.Etag
- }
if a.Kind != nil {
objectMap["kind"] = a.Kind
}
if a.Location != nil {
objectMap["location"] = a.Location
}
- if a.AccountProperties != nil {
- objectMap["properties"] = a.AccountProperties
+ if a.Properties != nil {
+ objectMap["properties"] = a.Properties
}
if a.Sku != nil {
objectMap["sku"] = a.Sku
@@ -236,135 +218,16 @@ func (a Account) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// UnmarshalJSON is the custom unmarshaler for Account struct.
-func (a *Account) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "etag":
- if v != nil {
- var etag string
- err = json.Unmarshal(*v, &etag)
- if err != nil {
- return err
- }
- a.Etag = &etag
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- a.ID = &ID
- }
- case "kind":
- if v != nil {
- var kind string
- err = json.Unmarshal(*v, &kind)
- if err != nil {
- return err
- }
- a.Kind = &kind
- }
- case "location":
- if v != nil {
- var location string
- err = json.Unmarshal(*v, &location)
- if err != nil {
- return err
- }
- a.Location = &location
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- a.Name = &name
- }
- case "properties":
- if v != nil {
- var accountProperties AccountProperties
- err = json.Unmarshal(*v, &accountProperties)
- if err != nil {
- return err
- }
- a.AccountProperties = &accountProperties
- }
- case "sku":
- if v != nil {
- var sku Sku
- err = json.Unmarshal(*v, &sku)
- if err != nil {
- return err
- }
- a.Sku = &sku
- }
- case "tags":
- if v != nil {
- var tags map[string]*string
- err = json.Unmarshal(*v, &tags)
- if err != nil {
- return err
- }
- a.Tags = tags
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- a.Type = &typeVar
- }
- }
- }
-
- return nil
-}
-
-// AccountCreateParameters the parameters to provide for the account.
-type AccountCreateParameters struct {
- // Sku - Required. Gets or sets the SKU of the resource.
- Sku *Sku `json:"sku,omitempty"`
- // Kind - Required. Gets or sets the Kind of the resource.
- Kind *string `json:"kind,omitempty"`
- // Location - Required. Gets or sets the location of the resource. This will be one of the supported and registered Azure Geo Regions (e.g. West US, East US, Southeast Asia, etc.). The geo region of a resource cannot be changed once it is created, but if an identical geo region is specified on update the request will succeed.
- Location *string `json:"location,omitempty"`
- // Tags - Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
- Tags map[string]*string `json:"tags"`
- // Properties - Must exist in the request. Must be an empty object. Must not be null.
- Properties interface{} `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for AccountCreateParameters.
-func (acp AccountCreateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if acp.Sku != nil {
- objectMap["sku"] = acp.Sku
- }
- if acp.Kind != nil {
- objectMap["kind"] = acp.Kind
- }
- if acp.Location != nil {
- objectMap["location"] = acp.Location
- }
- if acp.Tags != nil {
- objectMap["tags"] = acp.Tags
- }
- if acp.Properties != nil {
- objectMap["properties"] = acp.Properties
- }
- return json.Marshal(objectMap)
+// AccountAPIProperties the api properties for special APIs.
+type AccountAPIProperties struct {
+ // QnaRuntimeEndpoint - (QnAMaker Only) The runtime endpoint of QnAMaker.
+ QnaRuntimeEndpoint *string `json:"qnaRuntimeEndpoint,omitempty"`
+ // StatisticsEnabled - (Bing Search Only) The flag to enable statistics of Bing Search.
+ StatisticsEnabled *bool `json:"statisticsEnabled,omitempty"`
+ // EventHubConnectionString - (Personalization Only) The flag to enable statistics of Bing Search.
+ EventHubConnectionString *string `json:"eventHubConnectionString,omitempty"`
+ // StorageAccountConnectionString - (Personalization Only) The storage account connection string.
+ StorageAccountConnectionString *string `json:"storageAccountConnectionString,omitempty"`
}
// AccountEnumerateSkusResult the list of cognitive services accounts operation response.
@@ -533,39 +396,16 @@ func NewAccountListResultPage(getNextPage func(context.Context, AccountListResul
type AccountProperties struct {
// ProvisioningState - READ-ONLY; Gets the status of the cognitive services account at the time the operation was called. Possible values include: 'Creating', 'ResolvingDNS', 'Moving', 'Deleting', 'Succeeded', 'Failed'
ProvisioningState ProvisioningState `json:"provisioningState,omitempty"`
- // Endpoint - Endpoint of the created account.
+ // Endpoint - READ-ONLY; Endpoint of the created account.
Endpoint *string `json:"endpoint,omitempty"`
- // InternalID - The internal identifier.
+ // InternalID - READ-ONLY; The internal identifier.
InternalID *string `json:"internalId,omitempty"`
// CustomSubDomainName - Optional subdomain name used for token-based authentication.
CustomSubDomainName *string `json:"customSubDomainName,omitempty"`
// NetworkAcls - A collection of rules governing the accessibility from specific network locations.
NetworkAcls *NetworkRuleSet `json:"networkAcls,omitempty"`
-}
-
-// AccountUpdateParameters the parameters to provide for the account.
-type AccountUpdateParameters struct {
- // Sku - Gets or sets the SKU of the resource.
- Sku *Sku `json:"sku,omitempty"`
- // Tags - Gets or sets a list of key value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters.
- Tags map[string]*string `json:"tags"`
- // Properties - Additional properties for Account. Only provided fields will be updated.
- Properties interface{} `json:"properties,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for AccountUpdateParameters.
-func (aup AccountUpdateParameters) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if aup.Sku != nil {
- objectMap["sku"] = aup.Sku
- }
- if aup.Tags != nil {
- objectMap["tags"] = aup.Tags
- }
- if aup.Properties != nil {
- objectMap["properties"] = aup.Properties
- }
- return json.Marshal(objectMap)
+ // APIProperties - The api properties for special APIs.
+ APIProperties *AccountAPIProperties `json:"apiProperties,omitempty"`
}
// CheckDomainAvailabilityParameter check Domain availability parameter.
@@ -652,8 +492,6 @@ type MetricName struct {
// NetworkRuleSet a set of rules governing the network accessibility.
type NetworkRuleSet struct {
- // Bypass - Tells what traffic can bypass network rules. This can be 'AzureServices' or 'None'. If not specified the default is 'AzureServices'. Possible values include: 'AzureServices', 'None'
- Bypass NetworkRuleBypassOptions `json:"bypass,omitempty"`
// DefaultAction - The default action when no rule from ipRules and from virtualNetworkRules match. This is only used after the bypass property has been evaluated. Possible values include: 'Allow', 'Deny'
DefaultAction NetworkRuleAction `json:"defaultAction,omitempty"`
// IPRules - The list of IP address rules.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/availabilitysets.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/availabilitysets.go
index 853abfc1c95c..92945517338f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/availabilitysets.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/availabilitysets.go
@@ -85,7 +85,7 @@ func (client AvailabilitySetsClient) CreateOrUpdatePreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -164,7 +164,7 @@ func (client AvailabilitySetsClient) DeletePreparer(ctx context.Context, resourc
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -240,7 +240,7 @@ func (client AvailabilitySetsClient) GetPreparer(ctx context.Context, resourceGr
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -316,7 +316,7 @@ func (client AvailabilitySetsClient) ListPreparer(ctx context.Context, resourceG
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -431,7 +431,7 @@ func (client AvailabilitySetsClient) ListAvailableSizesPreparer(ctx context.Cont
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -506,7 +506,7 @@ func (client AvailabilitySetsClient) ListBySubscriptionPreparer(ctx context.Cont
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -624,7 +624,7 @@ func (client AvailabilitySetsClient) UpdatePreparer(ctx context.Context, resourc
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhostgroups.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhostgroups.go
index 77ec9da3137b..c786ffefc3f3 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhostgroups.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhostgroups.go
@@ -98,7 +98,7 @@ func (client DedicatedHostGroupsClient) CreateOrUpdatePreparer(ctx context.Conte
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -177,7 +177,7 @@ func (client DedicatedHostGroupsClient) DeletePreparer(ctx context.Context, reso
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -253,7 +253,7 @@ func (client DedicatedHostGroupsClient) GetPreparer(ctx context.Context, resourc
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -330,7 +330,7 @@ func (client DedicatedHostGroupsClient) ListByResourceGroupPreparer(ctx context.
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -441,7 +441,7 @@ func (client DedicatedHostGroupsClient) ListBySubscriptionPreparer(ctx context.C
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -556,7 +556,7 @@ func (client DedicatedHostGroupsClient) UpdatePreparer(ctx context.Context, reso
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhosts.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhosts.go
index 31f8795d6fdd..fb6ff59522b3 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhosts.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/dedicatedhosts.go
@@ -94,7 +94,7 @@ func (client DedicatedHostsClient) CreateOrUpdatePreparer(ctx context.Context, r
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -175,7 +175,7 @@ func (client DedicatedHostsClient) DeletePreparer(ctx context.Context, resourceG
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -260,7 +260,7 @@ func (client DedicatedHostsClient) GetPreparer(ctx context.Context, resourceGrou
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -342,7 +342,7 @@ func (client DedicatedHostsClient) ListByHostGroupPreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -453,7 +453,7 @@ func (client DedicatedHostsClient) UpdatePreparer(ctx context.Context, resourceG
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/diskencryptionsets.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/diskencryptionsets.go
new file mode 100644
index 000000000000..cb93acdde874
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/diskencryptionsets.go
@@ -0,0 +1,599 @@
+package compute
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DiskEncryptionSetsClient is the compute Client
+type DiskEncryptionSetsClient struct {
+ BaseClient
+}
+
+// NewDiskEncryptionSetsClient creates an instance of the DiskEncryptionSetsClient client.
+func NewDiskEncryptionSetsClient(subscriptionID string) DiskEncryptionSetsClient {
+ return NewDiskEncryptionSetsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDiskEncryptionSetsClientWithBaseURI creates an instance of the DiskEncryptionSetsClient client.
+func NewDiskEncryptionSetsClientWithBaseURI(baseURI string, subscriptionID string) DiskEncryptionSetsClient {
+ return DiskEncryptionSetsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a disk encryption set
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// diskEncryptionSetName - the name of the disk encryption set that is being created. The name can't be changed
+// after the disk encryption set is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The
+// maximum name length is 80 characters.
+// diskEncryptionSet - disk encryption set object supplied in the body of the Put disk encryption set
+// operation.
+func (client DiskEncryptionSetsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, diskEncryptionSetName string, diskEncryptionSet DiskEncryptionSet) (result DiskEncryptionSetsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: diskEncryptionSet,
+ Constraints: []validation.Constraint{{Target: "diskEncryptionSet.EncryptionSetProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "diskEncryptionSet.EncryptionSetProperties.ActiveKey", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "diskEncryptionSet.EncryptionSetProperties.ActiveKey.SourceVault", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "diskEncryptionSet.EncryptionSetProperties.ActiveKey.KeyURL", Name: validation.Null, Rule: true, Chain: nil},
+ }},
+ }}}}}); err != nil {
+ return result, validation.NewError("compute.DiskEncryptionSetsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, diskEncryptionSetName, diskEncryptionSet)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DiskEncryptionSetsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, diskEncryptionSetName string, diskEncryptionSet DiskEncryptionSet) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "diskEncryptionSetName": autorest.Encode("path", diskEncryptionSetName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/diskEncryptionSets/{diskEncryptionSetName}", pathParameters),
+ autorest.WithJSON(diskEncryptionSet),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) CreateOrUpdateSender(req *http.Request) (future DiskEncryptionSetsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) CreateOrUpdateResponder(resp *http.Response) (result DiskEncryptionSet, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a disk encryption set.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// diskEncryptionSetName - the name of the disk encryption set that is being created. The name can't be changed
+// after the disk encryption set is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The
+// maximum name length is 80 characters.
+func (client DiskEncryptionSetsClient) Delete(ctx context.Context, resourceGroupName string, diskEncryptionSetName string) (result DiskEncryptionSetsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, diskEncryptionSetName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client DiskEncryptionSetsClient) DeletePreparer(ctx context.Context, resourceGroupName string, diskEncryptionSetName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "diskEncryptionSetName": autorest.Encode("path", diskEncryptionSetName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-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.Compute/diskEncryptionSets/{diskEncryptionSetName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) DeleteSender(req *http.Request) (future DiskEncryptionSetsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets information about a disk encryption set.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// diskEncryptionSetName - the name of the disk encryption set that is being created. The name can't be changed
+// after the disk encryption set is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The
+// maximum name length is 80 characters.
+func (client DiskEncryptionSetsClient) Get(ctx context.Context, resourceGroupName string, diskEncryptionSetName string) (result DiskEncryptionSet, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, diskEncryptionSetName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DiskEncryptionSetsClient) GetPreparer(ctx context.Context, resourceGroupName string, diskEncryptionSetName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "diskEncryptionSetName": autorest.Encode("path", diskEncryptionSetName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-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.Compute/diskEncryptionSets/{diskEncryptionSetName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) GetResponder(resp *http.Response) (result DiskEncryptionSet, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List lists all the disk encryption sets under a subscription.
+func (client DiskEncryptionSetsClient) List(ctx context.Context) (result DiskEncryptionSetListPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.List")
+ defer func() {
+ sc := -1
+ if result.desl.Response.Response != nil {
+ sc = result.desl.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.desl.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.desl, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client DiskEncryptionSetsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Compute/diskEncryptionSets", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) ListResponder(resp *http.Response) (result DiskEncryptionSetList, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client DiskEncryptionSetsClient) listNextResults(ctx context.Context, lastResults DiskEncryptionSetList) (result DiskEncryptionSetList, err error) {
+ req, err := lastResults.diskEncryptionSetListPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client DiskEncryptionSetsClient) ListComplete(ctx context.Context) (result DiskEncryptionSetListIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
+
+// ListByResourceGroup lists all the disk encryption sets under a resource group.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+func (client DiskEncryptionSetsClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result DiskEncryptionSetListPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.desl.Response.Response != nil {
+ sc = result.desl.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByResourceGroupNextResults
+ req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "ListByResourceGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.desl.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "ListByResourceGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.desl, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "ListByResourceGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
+func (client DiskEncryptionSetsClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-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.Compute/diskEncryptionSets", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) ListByResourceGroupResponder(resp *http.Response) (result DiskEncryptionSetList, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByResourceGroupNextResults retrieves the next set of results, if any.
+func (client DiskEncryptionSetsClient) listByResourceGroupNextResults(ctx context.Context, lastResults DiskEncryptionSetList) (result DiskEncryptionSetList, err error) {
+ req, err := lastResults.diskEncryptionSetListPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client DiskEncryptionSetsClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result DiskEncryptionSetListIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
+ return
+}
+
+// Update updates (patches) a disk encryption set.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// diskEncryptionSetName - the name of the disk encryption set that is being created. The name can't be changed
+// after the disk encryption set is created. Supported characters for the name are a-z, A-Z, 0-9 and _. The
+// maximum name length is 80 characters.
+// diskEncryptionSet - disk encryption set object supplied in the body of the Patch disk encryption set
+// operation.
+func (client DiskEncryptionSetsClient) Update(ctx context.Context, resourceGroupName string, diskEncryptionSetName string, diskEncryptionSet DiskEncryptionSetUpdate) (result DiskEncryptionSetsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, diskEncryptionSetName, diskEncryptionSet)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client DiskEncryptionSetsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, diskEncryptionSetName string, diskEncryptionSet DiskEncryptionSetUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "diskEncryptionSetName": autorest.Encode("path", diskEncryptionSetName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/diskEncryptionSets/{diskEncryptionSetName}", pathParameters),
+ autorest.WithJSON(diskEncryptionSet),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client DiskEncryptionSetsClient) UpdateSender(req *http.Request) (future DiskEncryptionSetsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client DiskEncryptionSetsClient) UpdateResponder(resp *http.Response) (result DiskEncryptionSet, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go
index 31ee32f12f42..4bf336689169 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go
@@ -95,7 +95,7 @@ func (client DisksClient) CreateOrUpdatePreparer(ctx context.Context, resourceGr
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -177,7 +177,7 @@ func (client DisksClient) DeletePreparer(ctx context.Context, resourceGroupName
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -261,7 +261,7 @@ func (client DisksClient) GetPreparer(ctx context.Context, resourceGroupName str
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -341,7 +341,7 @@ func (client DisksClient) GrantAccessPreparer(ctx context.Context, resourceGroup
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -422,7 +422,7 @@ func (client DisksClient) ListPreparer(ctx context.Context) (*http.Request, erro
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -535,7 +535,7 @@ func (client DisksClient) ListByResourceGroupPreparer(ctx context.Context, resou
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -645,7 +645,7 @@ func (client DisksClient) RevokeAccessPreparer(ctx context.Context, resourceGrou
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -724,7 +724,7 @@ func (client DisksClient) UpdatePreparer(ctx context.Context, resourceGroupName
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/images.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/images.go
index e15083ca448d..dfb92b46b0f7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/images.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/images.go
@@ -79,7 +79,7 @@ func (client ImagesClient) CreateOrUpdatePreparer(ctx context.Context, resourceG
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -158,7 +158,7 @@ func (client ImagesClient) DeletePreparer(ctx context.Context, resourceGroupName
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -241,7 +241,7 @@ func (client ImagesClient) GetPreparer(ctx context.Context, resourceGroupName st
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -318,7 +318,7 @@ func (client ImagesClient) ListPreparer(ctx context.Context) (*http.Request, err
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -431,7 +431,7 @@ func (client ImagesClient) ListByResourceGroupPreparer(ctx context.Context, reso
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -540,7 +540,7 @@ func (client ImagesClient) UpdatePreparer(ctx context.Context, resourceGroupName
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/loganalytics.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/loganalytics.go
index 8fa8c1b05416..145d834d59b8 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/loganalytics.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/loganalytics.go
@@ -85,7 +85,7 @@ func (client LogAnalyticsClient) ExportRequestRateByIntervalPreparer(ctx context
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -170,7 +170,7 @@ func (client LogAnalyticsClient) ExportThrottledRequestsPreparer(ctx context.Con
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go
index 8cf3b0571819..11e0c0a1bd2c 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go
@@ -311,6 +311,19 @@ func PossibleDiskCreateOptionTypesValues() []DiskCreateOptionTypes {
return []DiskCreateOptionTypes{DiskCreateOptionTypesAttach, DiskCreateOptionTypesEmpty, DiskCreateOptionTypesFromImage}
}
+// DiskEncryptionSetIdentityType enumerates the values for disk encryption set identity type.
+type DiskEncryptionSetIdentityType string
+
+const (
+ // SystemAssigned ...
+ SystemAssigned DiskEncryptionSetIdentityType = "SystemAssigned"
+)
+
+// PossibleDiskEncryptionSetIdentityTypeValues returns an array of possible values for the DiskEncryptionSetIdentityType const type.
+func PossibleDiskEncryptionSetIdentityTypeValues() []DiskEncryptionSetIdentityType {
+ return []DiskEncryptionSetIdentityType{SystemAssigned}
+}
+
// DiskState enumerates the values for disk state.
type DiskState string
@@ -357,6 +370,22 @@ func PossibleDiskStorageAccountTypesValues() []DiskStorageAccountTypes {
return []DiskStorageAccountTypes{PremiumLRS, StandardLRS, StandardSSDLRS, UltraSSDLRS}
}
+// EncryptionType enumerates the values for encryption type.
+type EncryptionType string
+
+const (
+ // EncryptionAtRestWithCustomerKey Disk is encrypted with Customer managed key at rest.
+ EncryptionAtRestWithCustomerKey EncryptionType = "EncryptionAtRestWithCustomerKey"
+ // EncryptionAtRestWithPlatformKey Disk is encrypted with XStore managed key at rest. It is the default
+ // encryption type.
+ EncryptionAtRestWithPlatformKey EncryptionType = "EncryptionAtRestWithPlatformKey"
+)
+
+// PossibleEncryptionTypeValues returns an array of possible values for the EncryptionType const type.
+func PossibleEncryptionTypeValues() []EncryptionType {
+ return []EncryptionType{EncryptionAtRestWithCustomerKey, EncryptionAtRestWithPlatformKey}
+}
+
// HostCaching enumerates the values for host caching.
type HostCaching string
@@ -1395,6 +1424,17 @@ type AutomaticOSUpgradeProperties struct {
AutomaticOSUpgradeSupported *bool `json:"automaticOSUpgradeSupported,omitempty"`
}
+// AutomaticRepairsPolicy specifies the configuration parameters for automatic repairs on the virtual
+// machine scale set.
+type AutomaticRepairsPolicy struct {
+ // Enabled - Specifies whether automatic repairs should be enabled on the virtual machine scale set. The default value is false.
+ Enabled *bool `json:"enabled,omitempty"`
+ // GracePeriod - The amount of time for which automatic repairs are suspended due to a state change on VM. The grace time starts after the state change has completed. This helps avoid premature or accidental repairs. The time duration should be specified in ISO 8601 format. The default value is 5 minutes (PT5M).
+ GracePeriod *string `json:"gracePeriod,omitempty"`
+ // MaxInstanceRepairsPercent - The percentage (capacity of scaleset) of virtual machines that will be simultaneously repaired. The default value is 20%.
+ MaxInstanceRepairsPercent *int32 `json:"maxInstanceRepairsPercent,omitempty"`
+}
+
// AvailabilitySet specifies information about the availability set that the virtual machine should be
// assigned to. Virtual machines specified in the same availability set are allocated to different nodes to
// maximize availability. For more information about availability sets, see [Manage the availability of
@@ -1772,7 +1812,7 @@ type BootDiagnosticsInstanceView struct {
Status *InstanceViewStatus `json:"status,omitempty"`
}
-// CloudError an error response from the Gallery service.
+// CloudError an error response from the Compute service.
type CloudError struct {
Error *APIError `json:"error,omitempty"`
}
@@ -2224,6 +2264,10 @@ type DataDisk struct {
ManagedDisk *ManagedDiskParameters `json:"managedDisk,omitempty"`
// ToBeDetached - Specifies whether the data disk is in process of detachment from the VirtualMachine/VirtualMachineScaleset
ToBeDetached *bool `json:"toBeDetached,omitempty"`
+ // DiskIOPSReadWrite - READ-ONLY; Specifies the Read-Write IOPS for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set.
+ DiskIOPSReadWrite *int64 `json:"diskIOPSReadWrite,omitempty"`
+ // DiskMBpsReadWrite - READ-ONLY; Specifies the bandwidth in MB per second for the managed disk when StorageAccountType is UltraSSD_LRS. Returned only for VirtualMachine ScaleSet VM disks. Can be updated only via updates to the VirtualMachine Scale Set.
+ DiskMBpsReadWrite *int64 `json:"diskMBpsReadWrite,omitempty"`
}
// DataDiskImage contains the data disk images information.
@@ -3166,6 +3210,354 @@ func (d *Disk) UnmarshalJSON(body []byte) error {
return nil
}
+// DiskEncryptionSet disk encryption set resource.
+type DiskEncryptionSet struct {
+ autorest.Response `json:"-"`
+ Identity *EncryptionSetIdentity `json:"identity,omitempty"`
+ *EncryptionSetProperties `json:"properties,omitempty"`
+ // ID - READ-ONLY; Resource Id
+ ID *string `json:"id,omitempty"`
+ // Name - READ-ONLY; Resource name
+ Name *string `json:"name,omitempty"`
+ // Type - READ-ONLY; Resource type
+ Type *string `json:"type,omitempty"`
+ // Location - Resource location
+ Location *string `json:"location,omitempty"`
+ // Tags - Resource tags
+ Tags map[string]*string `json:"tags"`
+}
+
+// MarshalJSON is the custom marshaler for DiskEncryptionSet.
+func (desVar DiskEncryptionSet) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if desVar.Identity != nil {
+ objectMap["identity"] = desVar.Identity
+ }
+ if desVar.EncryptionSetProperties != nil {
+ objectMap["properties"] = desVar.EncryptionSetProperties
+ }
+ if desVar.Location != nil {
+ objectMap["location"] = desVar.Location
+ }
+ if desVar.Tags != nil {
+ objectMap["tags"] = desVar.Tags
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for DiskEncryptionSet struct.
+func (desVar *DiskEncryptionSet) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "identity":
+ if v != nil {
+ var identity EncryptionSetIdentity
+ err = json.Unmarshal(*v, &identity)
+ if err != nil {
+ return err
+ }
+ desVar.Identity = &identity
+ }
+ case "properties":
+ if v != nil {
+ var encryptionSetProperties EncryptionSetProperties
+ err = json.Unmarshal(*v, &encryptionSetProperties)
+ if err != nil {
+ return err
+ }
+ desVar.EncryptionSetProperties = &encryptionSetProperties
+ }
+ case "id":
+ if v != nil {
+ var ID string
+ err = json.Unmarshal(*v, &ID)
+ if err != nil {
+ return err
+ }
+ desVar.ID = &ID
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ desVar.Name = &name
+ }
+ case "type":
+ if v != nil {
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ desVar.Type = &typeVar
+ }
+ case "location":
+ if v != nil {
+ var location string
+ err = json.Unmarshal(*v, &location)
+ if err != nil {
+ return err
+ }
+ desVar.Location = &location
+ }
+ case "tags":
+ if v != nil {
+ var tags map[string]*string
+ err = json.Unmarshal(*v, &tags)
+ if err != nil {
+ return err
+ }
+ desVar.Tags = tags
+ }
+ }
+ }
+
+ return nil
+}
+
+// DiskEncryptionSetList the List disk encryption set operation response.
+type DiskEncryptionSetList struct {
+ autorest.Response `json:"-"`
+ // Value - A list of disk encryption sets.
+ Value *[]DiskEncryptionSet `json:"value,omitempty"`
+ // NextLink - The uri to fetch the next page of disk encryption sets. Call ListNext() with this to fetch the next page of disk encryption sets.
+ NextLink *string `json:"nextLink,omitempty"`
+}
+
+// DiskEncryptionSetListIterator provides access to a complete listing of DiskEncryptionSet values.
+type DiskEncryptionSetListIterator struct {
+ i int
+ page DiskEncryptionSetListPage
+}
+
+// NextWithContext advances to the next value. If there was an error making
+// the request the iterator does not advance and the error is returned.
+func (iter *DiskEncryptionSetListIterator) NextWithContext(ctx context.Context) (err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetListIterator.NextWithContext")
+ defer func() {
+ sc := -1
+ if iter.Response().Response.Response != nil {
+ sc = iter.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ iter.i++
+ if iter.i < len(iter.page.Values()) {
+ return nil
+ }
+ err = iter.page.NextWithContext(ctx)
+ if err != nil {
+ iter.i--
+ return err
+ }
+ iter.i = 0
+ return nil
+}
+
+// Next advances to the next value. If there was an error making
+// the request the iterator does not advance and the error is returned.
+// Deprecated: Use NextWithContext() instead.
+func (iter *DiskEncryptionSetListIterator) Next() error {
+ return iter.NextWithContext(context.Background())
+}
+
+// NotDone returns true if the enumeration should be started or is not yet complete.
+func (iter DiskEncryptionSetListIterator) NotDone() bool {
+ return iter.page.NotDone() && iter.i < len(iter.page.Values())
+}
+
+// Response returns the raw server response from the last page request.
+func (iter DiskEncryptionSetListIterator) Response() DiskEncryptionSetList {
+ return iter.page.Response()
+}
+
+// Value returns the current value or a zero-initialized value if the
+// iterator has advanced beyond the end of the collection.
+func (iter DiskEncryptionSetListIterator) Value() DiskEncryptionSet {
+ if !iter.page.NotDone() {
+ return DiskEncryptionSet{}
+ }
+ return iter.page.Values()[iter.i]
+}
+
+// Creates a new instance of the DiskEncryptionSetListIterator type.
+func NewDiskEncryptionSetListIterator(page DiskEncryptionSetListPage) DiskEncryptionSetListIterator {
+ return DiskEncryptionSetListIterator{page: page}
+}
+
+// IsEmpty returns true if the ListResult contains no values.
+func (desl DiskEncryptionSetList) IsEmpty() bool {
+ return desl.Value == nil || len(*desl.Value) == 0
+}
+
+// diskEncryptionSetListPreparer prepares a request to retrieve the next set of results.
+// It returns nil if no more results exist.
+func (desl DiskEncryptionSetList) diskEncryptionSetListPreparer(ctx context.Context) (*http.Request, error) {
+ if desl.NextLink == nil || len(to.String(desl.NextLink)) < 1 {
+ return nil, nil
+ }
+ return autorest.Prepare((&http.Request{}).WithContext(ctx),
+ autorest.AsJSON(),
+ autorest.AsGet(),
+ autorest.WithBaseURL(to.String(desl.NextLink)))
+}
+
+// DiskEncryptionSetListPage contains a page of DiskEncryptionSet values.
+type DiskEncryptionSetListPage struct {
+ fn func(context.Context, DiskEncryptionSetList) (DiskEncryptionSetList, error)
+ desl DiskEncryptionSetList
+}
+
+// NextWithContext advances to the next page of values. If there was an error making
+// the request the page does not advance and the error is returned.
+func (page *DiskEncryptionSetListPage) NextWithContext(ctx context.Context) (err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DiskEncryptionSetListPage.NextWithContext")
+ defer func() {
+ sc := -1
+ if page.Response().Response.Response != nil {
+ sc = page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ next, err := page.fn(ctx, page.desl)
+ if err != nil {
+ return err
+ }
+ page.desl = next
+ return nil
+}
+
+// Next advances to the next page of values. If there was an error making
+// the request the page does not advance and the error is returned.
+// Deprecated: Use NextWithContext() instead.
+func (page *DiskEncryptionSetListPage) Next() error {
+ return page.NextWithContext(context.Background())
+}
+
+// NotDone returns true if the page enumeration should be started or is not yet complete.
+func (page DiskEncryptionSetListPage) NotDone() bool {
+ return !page.desl.IsEmpty()
+}
+
+// Response returns the raw server response from the last page request.
+func (page DiskEncryptionSetListPage) Response() DiskEncryptionSetList {
+ return page.desl
+}
+
+// Values returns the slice of values for the current page or nil if there are no values.
+func (page DiskEncryptionSetListPage) Values() []DiskEncryptionSet {
+ if page.desl.IsEmpty() {
+ return nil
+ }
+ return *page.desl.Value
+}
+
+// Creates a new instance of the DiskEncryptionSetListPage type.
+func NewDiskEncryptionSetListPage(getNextPage func(context.Context, DiskEncryptionSetList) (DiskEncryptionSetList, error)) DiskEncryptionSetListPage {
+ return DiskEncryptionSetListPage{fn: getNextPage}
+}
+
+// DiskEncryptionSetParameters describes the parameter of customer managed disk encryption set resource id
+// that can be specified for disk.
NOTE: The disk encryption set resource id can only be specified
+// for managed disk. Please refer https://aka.ms/mdssewithcmkoverview for more details.
+type DiskEncryptionSetParameters struct {
+ // ID - Resource Id
+ ID *string `json:"id,omitempty"`
+}
+
+// DiskEncryptionSetsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
+// long-running operation.
+type DiskEncryptionSetsCreateOrUpdateFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *DiskEncryptionSetsCreateOrUpdateFuture) Result(client DiskEncryptionSetsClient) (desVar DiskEncryptionSet, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsCreateOrUpdateFuture")
+ return
+ }
+ sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+ if desVar.Response.Response, err = future.GetResult(sender); err == nil && desVar.Response.Response.StatusCode != http.StatusNoContent {
+ desVar, err = client.CreateOrUpdateResponder(desVar.Response.Response)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsCreateOrUpdateFuture", "Result", desVar.Response.Response, "Failure responding to request")
+ }
+ }
+ return
+}
+
+// DiskEncryptionSetsDeleteFuture an abstraction for monitoring and retrieving the results of a
+// long-running operation.
+type DiskEncryptionSetsDeleteFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *DiskEncryptionSetsDeleteFuture) Result(client DiskEncryptionSetsClient) (ar autorest.Response, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsDeleteFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsDeleteFuture")
+ return
+ }
+ ar.Response = future.Response()
+ return
+}
+
+// DiskEncryptionSetsUpdateFuture an abstraction for monitoring and retrieving the results of a
+// long-running operation.
+type DiskEncryptionSetsUpdateFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *DiskEncryptionSetsUpdateFuture) Result(client DiskEncryptionSetsClient) (desVar DiskEncryptionSet, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsUpdateFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsUpdateFuture")
+ return
+ }
+ sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+ if desVar.Response.Response, err = future.GetResult(sender); err == nil && desVar.Response.Response.StatusCode != http.StatusNoContent {
+ desVar, err = client.UpdateResponder(desVar.Response.Response)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsUpdateFuture", "Result", desVar.Response.Response, "Failure responding to request")
+ }
+ }
+ return
+}
+
// DiskEncryptionSettings describes a Encryption Settings for a Disk
type DiskEncryptionSettings struct {
// DiskEncryptionKey - Specifies the location of the disk encryption key, which is a Key Vault Secret.
@@ -3176,6 +3568,63 @@ type DiskEncryptionSettings struct {
Enabled *bool `json:"enabled,omitempty"`
}
+// DiskEncryptionSetUpdate disk encryption set update resource.
+type DiskEncryptionSetUpdate struct {
+ *DiskEncryptionSetUpdateProperties `json:"properties,omitempty"`
+ // Tags - Resource tags
+ Tags map[string]*string `json:"tags"`
+}
+
+// MarshalJSON is the custom marshaler for DiskEncryptionSetUpdate.
+func (desu DiskEncryptionSetUpdate) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if desu.DiskEncryptionSetUpdateProperties != nil {
+ objectMap["properties"] = desu.DiskEncryptionSetUpdateProperties
+ }
+ if desu.Tags != nil {
+ objectMap["tags"] = desu.Tags
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for DiskEncryptionSetUpdate struct.
+func (desu *DiskEncryptionSetUpdate) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "properties":
+ if v != nil {
+ var diskEncryptionSetUpdateProperties DiskEncryptionSetUpdateProperties
+ err = json.Unmarshal(*v, &diskEncryptionSetUpdateProperties)
+ if err != nil {
+ return err
+ }
+ desu.DiskEncryptionSetUpdateProperties = &diskEncryptionSetUpdateProperties
+ }
+ case "tags":
+ if v != nil {
+ var tags map[string]*string
+ err = json.Unmarshal(*v, &tags)
+ if err != nil {
+ return err
+ }
+ desu.Tags = tags
+ }
+ }
+ }
+
+ return nil
+}
+
+// DiskEncryptionSetUpdateProperties disk encryption set resource update properties.
+type DiskEncryptionSetUpdateProperties struct {
+ ActiveKey *KeyVaultAndKeyReference `json:"activeKey,omitempty"`
+}
+
// DiskInstanceView the instance view of the disk.
type DiskInstanceView struct {
// Name - The disk name.
@@ -3358,6 +3807,8 @@ type DiskProperties struct {
DiskMBpsReadWrite *int32 `json:"diskMBpsReadWrite,omitempty"`
// DiskState - READ-ONLY; The state of the disk. Possible values include: 'Unattached', 'Attached', 'Reserved', 'ActiveSAS', 'ReadyToUpload', 'ActiveUpload'
DiskState DiskState `json:"diskState,omitempty"`
+ // Encryption - Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
+ Encryption *Encryption `json:"encryption,omitempty"`
}
// DisksCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
@@ -3578,6 +4029,35 @@ type DiskUpdateProperties struct {
DiskMBpsReadWrite *int32 `json:"diskMBpsReadWrite,omitempty"`
}
+// Encryption encryption at rest settings for disk or snapshot
+type Encryption struct {
+ // DiskEncryptionSetID - ResourceId of the disk encryption set to use for enabling encryption at rest.
+ DiskEncryptionSetID *string `json:"diskEncryptionSetId,omitempty"`
+ // Type - The type of key used to encrypt the data of the disk. Possible values include: 'EncryptionAtRestWithPlatformKey', 'EncryptionAtRestWithCustomerKey'
+ Type EncryptionType `json:"type,omitempty"`
+}
+
+// EncryptionSetIdentity the managed identity for the disk encryption set. It should be given permission on
+// the key vault before it can be used to encrypt disks.
+type EncryptionSetIdentity struct {
+ // Type - The type of Managed Identity used by the DiskEncryptionSet. Only SystemAssigned is supported. Possible values include: 'SystemAssigned'
+ Type DiskEncryptionSetIdentityType `json:"type,omitempty"`
+ // PrincipalID - READ-ONLY; The object id of the Managed Identity Resource. This will be sent to the RP from ARM via the x-ms-identity-principal-id header in the PUT request if the resource has a systemAssigned(implicit) identity
+ PrincipalID *string `json:"principalId,omitempty"`
+ // TenantID - READ-ONLY; The tenant id of the Managed Identity Resource. This will be sent to the RP from ARM via the x-ms-client-tenant-id header in the PUT request if the resource has a systemAssigned(implicit) identity
+ TenantID *string `json:"tenantId,omitempty"`
+}
+
+// EncryptionSetProperties ...
+type EncryptionSetProperties struct {
+ // ActiveKey - The key vault key which is currently used by this disk encryption set.
+ ActiveKey *KeyVaultAndKeyReference `json:"activeKey,omitempty"`
+ // PreviousKeys - READ-ONLY; A readonly collection of key vault keys previously used by this disk encryption set while a key rotation is in progress. It will be empty if there is no ongoing key rotation.
+ PreviousKeys *[]KeyVaultAndKeyReference `json:"previousKeys,omitempty"`
+ // ProvisioningState - READ-ONLY; The disk encryption set provisioning state.
+ ProvisioningState *string `json:"provisioningState,omitempty"`
+}
+
// EncryptionSettingsCollection encryption settings for disk or snapshot
type EncryptionSettingsCollection struct {
// Enabled - Set this flag to true and provide DiskEncryptionKey and optional KeyEncryptionKey to enable encryption. Set this flag to false and remove DiskEncryptionKey and KeyEncryptionKey to disable encryption. If EncryptionSettings is null in the request object, the existing settings remain unchanged.
@@ -5409,6 +5889,26 @@ type ImageDataDisk struct {
DiskSizeGB *int32 `json:"diskSizeGB,omitempty"`
// StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
StorageAccountType StorageAccountTypes `json:"storageAccountType,omitempty"`
+ // DiskEncryptionSet - Specifies the customer managed disk encryption set resource id for the managed image disk.
+ DiskEncryptionSet *DiskEncryptionSetParameters `json:"diskEncryptionSet,omitempty"`
+}
+
+// ImageDisk describes a image disk.
+type ImageDisk struct {
+ // Snapshot - The snapshot.
+ Snapshot *SubResource `json:"snapshot,omitempty"`
+ // ManagedDisk - The managedDisk.
+ ManagedDisk *SubResource `json:"managedDisk,omitempty"`
+ // BlobURI - The Virtual Hard Disk.
+ BlobURI *string `json:"blobUri,omitempty"`
+ // Caching - Specifies the caching requirements.
Possible values are:
**None**
**ReadOnly**
**ReadWrite**
Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: 'CachingTypesNone', 'CachingTypesReadOnly', 'CachingTypesReadWrite'
+ Caching CachingTypes `json:"caching,omitempty"`
+ // DiskSizeGB - Specifies the size of empty data disks in gigabytes. This element can be used to overwrite the name of the disk in a virtual machine image.
This value cannot be larger than 1023 GB
+ DiskSizeGB *int32 `json:"diskSizeGB,omitempty"`
+ // StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
+ StorageAccountType StorageAccountTypes `json:"storageAccountType,omitempty"`
+ // DiskEncryptionSet - Specifies the customer managed disk encryption set resource id for the managed image disk.
+ DiskEncryptionSet *DiskEncryptionSetParameters `json:"diskEncryptionSet,omitempty"`
}
// ImageDiskReference the source image used for creating the disk.
@@ -5581,8 +6081,10 @@ type ImageOSDisk struct {
Caching CachingTypes `json:"caching,omitempty"`
// DiskSizeGB - Specifies the size of empty data disks in gigabytes. This element can be used to overwrite the name of the disk in a virtual machine image.
This value cannot be larger than 1023 GB
DiskSizeGB *int32 `json:"diskSizeGB,omitempty"`
- // StorageAccountType - Specifies the storage account type for the managed disk. UltraSSD_LRS cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
+ // StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
StorageAccountType StorageAccountTypes `json:"storageAccountType,omitempty"`
+ // DiskEncryptionSet - Specifies the customer managed disk encryption set resource id for the managed image disk.
+ DiskEncryptionSet *DiskEncryptionSetParameters `json:"diskEncryptionSet,omitempty"`
}
// ImageProperties describes the properties of an Image.
@@ -6108,6 +6610,8 @@ type ManagedArtifact struct {
type ManagedDiskParameters struct {
// StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
StorageAccountType StorageAccountTypes `json:"storageAccountType,omitempty"`
+ // DiskEncryptionSet - Specifies the customer managed disk encryption set resource id for the managed disk.
+ DiskEncryptionSet *DiskEncryptionSetParameters `json:"diskEncryptionSet,omitempty"`
// ID - Resource Id
ID *string `json:"id,omitempty"`
}
@@ -6307,6 +6811,8 @@ type OSProfile struct {
Secrets *[]VaultSecretGroup `json:"secrets,omitempty"`
// AllowExtensionOperations - Specifies whether extension operations should be allowed on the virtual machine.
This may only be set to False when no extensions are present on the virtual machine.
AllowExtensionOperations *bool `json:"allowExtensionOperations,omitempty"`
+ // RequireGuestProvisionSignal - Specifies whether the guest provision signal is required from the virtual machine.
+ RequireGuestProvisionSignal *bool `json:"requireGuestProvisionSignal,omitempty"`
}
// Plan specifies information about the marketplace image used to create the virtual machine. This element
@@ -7631,6 +8137,8 @@ type SnapshotProperties struct {
ProvisioningState *string `json:"provisioningState,omitempty"`
// Incremental - Whether a snapshot is incremental. Incremental snapshots on the same disk occupy less space than full snapshots and can be diffed.
Incremental *bool `json:"incremental,omitempty"`
+ // Encryption - Encryption property can be used to encrypt data at rest with customer managed keys or platform managed keys.
+ Encryption *Encryption `json:"encryption,omitempty"`
}
// SnapshotsCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a long-running
@@ -9213,6 +9721,10 @@ type VirtualMachineScaleSetDataDisk struct {
DiskSizeGB *int32 `json:"diskSizeGB,omitempty"`
// ManagedDisk - The managed disk parameters.
ManagedDisk *VirtualMachineScaleSetManagedDiskParameters `json:"managedDisk,omitempty"`
+ // DiskIOPSReadWrite - Specifies the Read-Write IOPS for the managed disk. Should be used only when StorageAccountType is UltraSSD_LRS. If not specified, a default value would be assigned based on diskSizeGB.
+ DiskIOPSReadWrite *int64 `json:"diskIOPSReadWrite,omitempty"`
+ // DiskMBpsReadWrite - Specifies the bandwidth in MB per second for the managed disk. Should be used only when StorageAccountType is UltraSSD_LRS. If not specified, a default value would be assigned based on diskSizeGB.
+ DiskMBpsReadWrite *int64 `json:"diskMBpsReadWrite,omitempty"`
}
// VirtualMachineScaleSetExtension describes a Virtual Machine Scale Set Extension.
@@ -10247,6 +10759,8 @@ func NewVirtualMachineScaleSetListWithLinkResultPage(getNextPage func(context.Co
type VirtualMachineScaleSetManagedDiskParameters struct {
// StorageAccountType - Specifies the storage account type for the managed disk. NOTE: UltraSSD_LRS can only be used with data disks, it cannot be used with OS Disk. Possible values include: 'StorageAccountTypesStandardLRS', 'StorageAccountTypesPremiumLRS', 'StorageAccountTypesStandardSSDLRS', 'StorageAccountTypesUltraSSDLRS'
StorageAccountType StorageAccountTypes `json:"storageAccountType,omitempty"`
+ // DiskEncryptionSet - Specifies the customer managed disk encryption set resource id for the managed disk.
+ DiskEncryptionSet *DiskEncryptionSetParameters `json:"diskEncryptionSet,omitempty"`
}
// VirtualMachineScaleSetNetworkConfiguration describes a virtual machine scale set network profile's
@@ -10394,6 +10908,8 @@ type VirtualMachineScaleSetOSProfile struct {
type VirtualMachineScaleSetProperties struct {
// UpgradePolicy - The upgrade policy.
UpgradePolicy *UpgradePolicy `json:"upgradePolicy,omitempty"`
+ // AutomaticRepairsPolicy - Policy for automatic repairs.
+ AutomaticRepairsPolicy *AutomaticRepairsPolicy `json:"automaticRepairsPolicy,omitempty"`
// VirtualMachineProfile - The virtual machine profile.
VirtualMachineProfile *VirtualMachineScaleSetVMProfile `json:"virtualMachineProfile,omitempty"`
// ProvisioningState - READ-ONLY; The provisioning state, which only appears in the response.
@@ -10489,6 +11005,8 @@ type VirtualMachineScaleSetPublicIPAddressConfigurationProperties struct {
IPTags *[]VirtualMachineScaleSetIPTag `json:"ipTags,omitempty"`
// PublicIPPrefix - The PublicIPPrefix from which to allocate publicIP addresses.
PublicIPPrefix *SubResource `json:"publicIPPrefix,omitempty"`
+ // PublicIPAddressVersion - Available from Api-Version 2019-07-01 onwards, it represents whether the specific ipconfiguration is IPv4 or IPv6. Default is taken as IPv4. Possible values are: 'IPv4' and 'IPv6'. Possible values include: 'IPv4', 'IPv6'
+ PublicIPAddressVersion IPVersion `json:"publicIPAddressVersion,omitempty"`
}
// VirtualMachineScaleSetReimageParameters describes a Virtual Machine Scale Set VM Reimage Parameters.
@@ -11219,10 +11737,14 @@ type VirtualMachineScaleSetUpdateOSProfile struct {
type VirtualMachineScaleSetUpdateProperties struct {
// UpgradePolicy - The upgrade policy.
UpgradePolicy *UpgradePolicy `json:"upgradePolicy,omitempty"`
+ // AutomaticRepairsPolicy - Policy for automatic repairs.
+ AutomaticRepairsPolicy *AutomaticRepairsPolicy `json:"automaticRepairsPolicy,omitempty"`
// VirtualMachineProfile - The virtual machine profile.
VirtualMachineProfile *VirtualMachineScaleSetUpdateVMProfile `json:"virtualMachineProfile,omitempty"`
// Overprovision - Specifies whether the Virtual Machine Scale Set should be overprovisioned.
Overprovision *bool `json:"overprovision,omitempty"`
+ // DoNotRunExtensionsOnOverprovisionedVMs - When Overprovision is enabled, extensions are launched only on the requested number of VMs which are finally kept. This property will hence ensure that the extensions do not run on the extra overprovisioned VMs.
+ DoNotRunExtensionsOnOverprovisionedVMs *bool `json:"doNotRunExtensionsOnOverprovisionedVMs,omitempty"`
// SinglePlacementGroup - When true this limits the scale set to a single placement group, of max size 100 virtual machines.
SinglePlacementGroup *bool `json:"singlePlacementGroup,omitempty"`
// AdditionalCapabilities - Specifies additional capabilities enabled or disabled on the Virtual Machines in the Virtual Machine Scale Set. For instance: whether the Virtual Machines have the capability to support attaching managed data disks with UltraSSD_LRS storage account type.
@@ -11481,6 +12003,58 @@ func (vmssv *VirtualMachineScaleSetVM) UnmarshalJSON(body []byte) error {
return nil
}
+// VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture an abstraction for monitoring and retrieving the
+// results of a long-running operation.
+type VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture) Result(client VirtualMachineScaleSetVMExtensionsClient) (vme VirtualMachineExtension, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture")
+ return
+ }
+ sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+ if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
+ vme, err = client.CreateOrUpdateResponder(vme.Response.Response)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
+ }
+ }
+ return
+}
+
+// VirtualMachineScaleSetVMExtensionsDeleteFuture an abstraction for monitoring and retrieving the results
+// of a long-running operation.
+type VirtualMachineScaleSetVMExtensionsDeleteFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *VirtualMachineScaleSetVMExtensionsDeleteFuture) Result(client VirtualMachineScaleSetVMExtensionsClient) (ar autorest.Response, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsDeleteFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsDeleteFuture")
+ return
+ }
+ ar.Response = future.Response()
+ return
+}
+
// VirtualMachineScaleSetVMExtensionsSummary extensions summary for virtual machines of a virtual machine
// scale set.
type VirtualMachineScaleSetVMExtensionsSummary struct {
@@ -11490,6 +12064,35 @@ type VirtualMachineScaleSetVMExtensionsSummary struct {
StatusesSummary *[]VirtualMachineStatusCodeCount `json:"statusesSummary,omitempty"`
}
+// VirtualMachineScaleSetVMExtensionsUpdateFuture an abstraction for monitoring and retrieving the results
+// of a long-running operation.
+type VirtualMachineScaleSetVMExtensionsUpdateFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *VirtualMachineScaleSetVMExtensionsUpdateFuture) Result(client VirtualMachineScaleSetVMExtensionsClient) (vme VirtualMachineExtension, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsUpdateFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsUpdateFuture")
+ return
+ }
+ sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+ if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
+ vme, err = client.UpdateResponder(vme.Response.Response)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
+ }
+ }
+ return
+}
+
// VirtualMachineScaleSetVMInstanceIDs specifies a list of virtual machine instance IDs from the VM scale
// set.
type VirtualMachineScaleSetVMInstanceIDs struct {
@@ -12219,6 +12822,29 @@ func (future *VirtualMachinesPowerOffFuture) Result(client VirtualMachinesClient
return
}
+// VirtualMachinesReapplyFuture an abstraction for monitoring and retrieving the results of a long-running
+// operation.
+type VirtualMachinesReapplyFuture struct {
+ azure.Future
+}
+
+// Result returns the result of the asynchronous operation.
+// If the operation has not completed it will return an error.
+func (future *VirtualMachinesReapplyFuture) Result(client VirtualMachinesClient) (ar autorest.Response, err error) {
+ var done bool
+ done, err = future.DoneWithContext(context.Background(), client)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachinesReapplyFuture", "Result", future.Response(), "Polling failure")
+ return
+ }
+ if !done {
+ err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesReapplyFuture")
+ return
+ }
+ ar.Response = future.Response()
+ return
+}
+
// VirtualMachinesRedeployFuture an abstraction for monitoring and retrieving the results of a long-running
// operation.
type VirtualMachinesRedeployFuture struct {
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/operations.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/operations.go
index c19b7567d7dd..021b16328e7d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/operations.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/operations.go
@@ -75,7 +75,7 @@ func (client OperationsClient) List(ctx context.Context) (result OperationListRe
// ListPreparer prepares the List request.
func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/proximityplacementgroups.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/proximityplacementgroups.go
index a85c1640cd43..a42d52685560 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/proximityplacementgroups.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/proximityplacementgroups.go
@@ -85,7 +85,7 @@ func (client ProximityPlacementGroupsClient) CreateOrUpdatePreparer(ctx context.
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -164,7 +164,7 @@ func (client ProximityPlacementGroupsClient) DeletePreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -240,7 +240,7 @@ func (client ProximityPlacementGroupsClient) GetPreparer(ctx context.Context, re
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -316,7 +316,7 @@ func (client ProximityPlacementGroupsClient) ListByResourceGroupPreparer(ctx con
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -426,7 +426,7 @@ func (client ProximityPlacementGroupsClient) ListBySubscriptionPreparer(ctx cont
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -541,7 +541,7 @@ func (client ProximityPlacementGroupsClient) UpdatePreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/resourceskus.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/resourceskus.go
index dade057a45fe..adb402788c87 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/resourceskus.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/resourceskus.go
@@ -41,7 +41,9 @@ func NewResourceSkusClientWithBaseURI(baseURI string, subscriptionID string) Res
}
// List gets the list of Microsoft.Compute SKUs available for your Subscription.
-func (client ResourceSkusClient) List(ctx context.Context) (result ResourceSkusResultPage, err error) {
+// Parameters:
+// filter - the filter to apply on the operation.
+func (client ResourceSkusClient) List(ctx context.Context, filter string) (result ResourceSkusResultPage, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/ResourceSkusClient.List")
defer func() {
@@ -53,7 +55,7 @@ func (client ResourceSkusClient) List(ctx context.Context) (result ResourceSkusR
}()
}
result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
+ req, err := client.ListPreparer(ctx, filter)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.ResourceSkusClient", "List", nil, "Failure preparing request")
return
@@ -75,7 +77,7 @@ func (client ResourceSkusClient) List(ctx context.Context) (result ResourceSkusR
}
// ListPreparer prepares the List request.
-func (client ResourceSkusClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+func (client ResourceSkusClient) ListPreparer(ctx context.Context, filter string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -84,6 +86,9 @@ func (client ResourceSkusClient) ListPreparer(ctx context.Context) (*http.Reques
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
preparer := autorest.CreatePreparer(
autorest.AsGet(),
@@ -135,7 +140,7 @@ func (client ResourceSkusClient) listNextResults(ctx context.Context, lastResult
}
// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ResourceSkusClient) ListComplete(ctx context.Context) (result ResourceSkusResultIterator, err error) {
+func (client ResourceSkusClient) ListComplete(ctx context.Context, filter string) (result ResourceSkusResultIterator, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/ResourceSkusClient.List")
defer func() {
@@ -146,6 +151,6 @@ func (client ResourceSkusClient) ListComplete(ctx context.Context) (result Resou
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.List(ctx)
+ result.page, err = client.List(ctx, filter)
return
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/snapshots.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/snapshots.go
index 5fca4e7acd7f..3a52fe87388b 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/snapshots.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/snapshots.go
@@ -94,7 +94,7 @@ func (client SnapshotsClient) CreateOrUpdatePreparer(ctx context.Context, resour
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -175,7 +175,7 @@ func (client SnapshotsClient) DeletePreparer(ctx context.Context, resourceGroupN
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -258,7 +258,7 @@ func (client SnapshotsClient) GetPreparer(ctx context.Context, resourceGroupName
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -337,7 +337,7 @@ func (client SnapshotsClient) GrantAccessPreparer(ctx context.Context, resourceG
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -418,7 +418,7 @@ func (client SnapshotsClient) ListPreparer(ctx context.Context) (*http.Request,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -531,7 +531,7 @@ func (client SnapshotsClient) ListByResourceGroupPreparer(ctx context.Context, r
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -640,7 +640,7 @@ func (client SnapshotsClient) RevokeAccessPreparer(ctx context.Context, resource
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -718,7 +718,7 @@ func (client SnapshotsClient) UpdatePreparer(ctx context.Context, resourceGroupN
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/usage.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/usage.go
index 36565c1a55c7..690136c06d54 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/usage.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/usage.go
@@ -91,7 +91,7 @@ func (client UsageClient) ListPreparer(ctx context.Context, location string) (*h
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensionimages.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensionimages.go
index 94adf706bf31..7a670a607c82 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensionimages.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensionimages.go
@@ -86,7 +86,7 @@ func (client VirtualMachineExtensionImagesClient) GetPreparer(ctx context.Contex
"version": autorest.Encode("path", version),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -162,7 +162,7 @@ func (client VirtualMachineExtensionImagesClient) ListTypesPreparer(ctx context.
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -240,7 +240,7 @@ func (client VirtualMachineExtensionImagesClient) ListVersionsPreparer(ctx conte
"type": autorest.Encode("path", typeParameter),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensions.go
index bb80694c6340..a77180ddc688 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineextensions.go
@@ -81,7 +81,7 @@ func (client VirtualMachineExtensionsClient) CreateOrUpdatePreparer(ctx context.
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -162,7 +162,7 @@ func (client VirtualMachineExtensionsClient) DeletePreparer(ctx context.Context,
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -247,7 +247,7 @@ func (client VirtualMachineExtensionsClient) GetPreparer(ctx context.Context, re
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -328,7 +328,7 @@ func (client VirtualMachineExtensionsClient) ListPreparer(ctx context.Context, r
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -405,7 +405,7 @@ func (client VirtualMachineExtensionsClient) UpdatePreparer(ctx context.Context,
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineimages.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineimages.go
index 2843539d6a81..e1e830c2f432 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineimages.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineimages.go
@@ -90,7 +90,7 @@ func (client VirtualMachineImagesClient) GetPreparer(ctx context.Context, locati
"version": autorest.Encode("path", version),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -172,7 +172,7 @@ func (client VirtualMachineImagesClient) ListPreparer(ctx context.Context, locat
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -258,7 +258,7 @@ func (client VirtualMachineImagesClient) ListOffersPreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -333,7 +333,7 @@ func (client VirtualMachineImagesClient) ListPublishersPreparer(ctx context.Cont
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -412,7 +412,7 @@ func (client VirtualMachineImagesClient) ListSkusPreparer(ctx context.Context, l
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineruncommands.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineruncommands.go
index e2b53b704796..82be43acfd4c 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineruncommands.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachineruncommands.go
@@ -91,7 +91,7 @@ func (client VirtualMachineRunCommandsClient) GetPreparer(ctx context.Context, l
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -173,7 +173,7 @@ func (client VirtualMachineRunCommandsClient) ListPreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachines.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachines.go
index 206e7f4d7257..b329db181d98 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachines.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachines.go
@@ -89,7 +89,7 @@ func (client VirtualMachinesClient) CapturePreparer(ctx context.Context, resourc
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -169,7 +169,7 @@ func (client VirtualMachinesClient) ConvertToManagedDisksPreparer(ctx context.Co
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -267,7 +267,7 @@ func (client VirtualMachinesClient) CreateOrUpdatePreparer(ctx context.Context,
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -348,7 +348,7 @@ func (client VirtualMachinesClient) DeallocatePreparer(ctx context.Context, reso
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -424,7 +424,7 @@ func (client VirtualMachinesClient) DeletePreparer(ctx context.Context, resource
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -506,7 +506,7 @@ func (client VirtualMachinesClient) GeneralizePreparer(ctx context.Context, reso
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -583,7 +583,7 @@ func (client VirtualMachinesClient) GetPreparer(ctx context.Context, resourceGro
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -663,7 +663,7 @@ func (client VirtualMachinesClient) InstanceViewPreparer(ctx context.Context, re
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -740,7 +740,7 @@ func (client VirtualMachinesClient) ListPreparer(ctx context.Context, resourceGr
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -812,7 +812,9 @@ func (client VirtualMachinesClient) ListComplete(ctx context.Context, resourceGr
// ListAll lists all of the virtual machines in the specified subscription. Use the nextLink property in the response
// to get the next page of virtual machines.
-func (client VirtualMachinesClient) ListAll(ctx context.Context) (result VirtualMachineListResultPage, err error) {
+// Parameters:
+// statusOnly - statusOnly=true enables fetching run time status of all Virtual Machines in the subscription.
+func (client VirtualMachinesClient) ListAll(ctx context.Context, statusOnly string) (result VirtualMachineListResultPage, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachinesClient.ListAll")
defer func() {
@@ -824,7 +826,7 @@ func (client VirtualMachinesClient) ListAll(ctx context.Context) (result Virtual
}()
}
result.fn = client.listAllNextResults
- req, err := client.ListAllPreparer(ctx)
+ req, err := client.ListAllPreparer(ctx, statusOnly)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ListAll", nil, "Failure preparing request")
return
@@ -846,15 +848,18 @@ func (client VirtualMachinesClient) ListAll(ctx context.Context) (result Virtual
}
// ListAllPreparer prepares the ListAll request.
-func (client VirtualMachinesClient) ListAllPreparer(ctx context.Context) (*http.Request, error) {
+func (client VirtualMachinesClient) ListAllPreparer(ctx context.Context, statusOnly string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if len(statusOnly) > 0 {
+ queryParameters["statusOnly"] = autorest.Encode("query", statusOnly)
+ }
preparer := autorest.CreatePreparer(
autorest.AsGet(),
@@ -906,7 +911,7 @@ func (client VirtualMachinesClient) listAllNextResults(ctx context.Context, last
}
// ListAllComplete enumerates all values, automatically crossing page boundaries as required.
-func (client VirtualMachinesClient) ListAllComplete(ctx context.Context) (result VirtualMachineListResultIterator, err error) {
+func (client VirtualMachinesClient) ListAllComplete(ctx context.Context, statusOnly string) (result VirtualMachineListResultIterator, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachinesClient.ListAll")
defer func() {
@@ -917,7 +922,7 @@ func (client VirtualMachinesClient) ListAllComplete(ctx context.Context) (result
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListAll(ctx)
+ result.page, err = client.ListAll(ctx, statusOnly)
return
}
@@ -965,7 +970,7 @@ func (client VirtualMachinesClient) ListAvailableSizesPreparer(ctx context.Conte
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1047,7 +1052,7 @@ func (client VirtualMachinesClient) ListByLocationPreparer(ctx context.Context,
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1155,7 +1160,7 @@ func (client VirtualMachinesClient) PerformMaintenancePreparer(ctx context.Conte
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1235,7 +1240,7 @@ func (client VirtualMachinesClient) PowerOffPreparer(ctx context.Context, resour
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1278,6 +1283,82 @@ func (client VirtualMachinesClient) PowerOffResponder(resp *http.Response) (resu
return
}
+// Reapply the operation to reapply a virtual machine's state.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMName - the name of the virtual machine.
+func (client VirtualMachinesClient) Reapply(ctx context.Context, resourceGroupName string, VMName string) (result VirtualMachinesReapplyFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachinesClient.Reapply")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ReapplyPreparer(ctx, resourceGroupName, VMName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reapply", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.ReapplySender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reapply", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// ReapplyPreparer prepares the Reapply request.
+func (client VirtualMachinesClient) ReapplyPreparer(ctx context.Context, resourceGroupName string, VMName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmName": autorest.Encode("path", VMName),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachines/{vmName}/reapply", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ReapplySender sends the Reapply request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachinesClient) ReapplySender(req *http.Request) (future VirtualMachinesReapplyFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// ReapplyResponder handles the response to the Reapply request. The method always
+// closes the http.Response Body.
+func (client VirtualMachinesClient) ReapplyResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
// Redeploy shuts down the virtual machine, moves it to a new node, and powers it back on.
// Parameters:
// resourceGroupName - the name of the resource group.
@@ -1316,7 +1397,7 @@ func (client VirtualMachinesClient) RedeployPreparer(ctx context.Context, resour
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1393,7 +1474,7 @@ func (client VirtualMachinesClient) ReimagePreparer(ctx context.Context, resourc
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1474,7 +1555,7 @@ func (client VirtualMachinesClient) RestartPreparer(ctx context.Context, resourc
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1557,7 +1638,7 @@ func (client VirtualMachinesClient) RunCommandPreparer(ctx context.Context, reso
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1636,7 +1717,7 @@ func (client VirtualMachinesClient) StartPreparer(ctx context.Context, resourceG
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1713,7 +1794,7 @@ func (client VirtualMachinesClient) UpdatePreparer(ctx context.Context, resource
"vmName": autorest.Encode("path", VMName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetextensions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetextensions.go
index 041df6980553..7e4d6d0a6b70 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetextensions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetextensions.go
@@ -82,7 +82,7 @@ func (client VirtualMachineScaleSetExtensionsClient) CreateOrUpdatePreparer(ctx
"vmssExtensionName": autorest.Encode("path", vmssExtensionName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -163,7 +163,7 @@ func (client VirtualMachineScaleSetExtensionsClient) DeletePreparer(ctx context.
"vmssExtensionName": autorest.Encode("path", vmssExtensionName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -248,7 +248,7 @@ func (client VirtualMachineScaleSetExtensionsClient) GetPreparer(ctx context.Con
"vmssExtensionName": autorest.Encode("path", vmssExtensionName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -329,7 +329,7 @@ func (client VirtualMachineScaleSetExtensionsClient) ListPreparer(ctx context.Co
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetrollingupgrades.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetrollingupgrades.go
index 6bdc9f2b3224..c20c01d515cf 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetrollingupgrades.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetrollingupgrades.go
@@ -80,7 +80,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) CancelPreparer(ctx con
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -162,7 +162,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) GetLatestPreparer(ctx
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -235,7 +235,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartExtensionUpgradeP
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -312,7 +312,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartOSUpgradePreparer
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesets.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesets.go
index 660464e05780..54b1393fe57d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesets.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesets.go
@@ -177,7 +177,7 @@ func (client VirtualMachineScaleSetsClient) CreateOrUpdatePreparer(ctx context.C
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -258,7 +258,7 @@ func (client VirtualMachineScaleSetsClient) DeallocatePreparer(ctx context.Conte
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -339,7 +339,7 @@ func (client VirtualMachineScaleSetsClient) DeletePreparer(ctx context.Context,
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -422,7 +422,7 @@ func (client VirtualMachineScaleSetsClient) DeleteInstancesPreparer(ctx context.
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -508,7 +508,7 @@ func (client VirtualMachineScaleSetsClient) ForceRecoveryServiceFabricPlatformUp
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
"platformUpdateDomain": autorest.Encode("query", platformUpdateDomain),
@@ -586,7 +586,7 @@ func (client VirtualMachineScaleSetsClient) GetPreparer(ctx context.Context, res
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -663,7 +663,7 @@ func (client VirtualMachineScaleSetsClient) GetInstanceViewPreparer(ctx context.
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -741,7 +741,7 @@ func (client VirtualMachineScaleSetsClient) GetOSUpgradeHistoryPreparer(ctx cont
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -854,7 +854,7 @@ func (client VirtualMachineScaleSetsClient) ListPreparer(ctx context.Context, re
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -966,7 +966,7 @@ func (client VirtualMachineScaleSetsClient) ListAllPreparer(ctx context.Context)
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1082,7 +1082,7 @@ func (client VirtualMachineScaleSetsClient) ListSkusPreparer(ctx context.Context
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1193,7 +1193,7 @@ func (client VirtualMachineScaleSetsClient) PerformMaintenancePreparer(ctx conte
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1279,7 +1279,7 @@ func (client VirtualMachineScaleSetsClient) PowerOffPreparer(ctx context.Context
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1367,7 +1367,7 @@ func (client VirtualMachineScaleSetsClient) RedeployPreparer(ctx context.Context
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1450,7 +1450,7 @@ func (client VirtualMachineScaleSetsClient) ReimagePreparer(ctx context.Context,
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1533,7 +1533,7 @@ func (client VirtualMachineScaleSetsClient) ReimageAllPreparer(ctx context.Conte
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1615,7 +1615,7 @@ func (client VirtualMachineScaleSetsClient) RestartPreparer(ctx context.Context,
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1697,7 +1697,7 @@ func (client VirtualMachineScaleSetsClient) StartPreparer(ctx context.Context, r
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1779,7 +1779,7 @@ func (client VirtualMachineScaleSetsClient) UpdatePreparer(ctx context.Context,
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1865,7 +1865,7 @@ func (client VirtualMachineScaleSetsClient) UpdateInstancesPreparer(ctx context.
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvmextensions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvmextensions.go
new file mode 100644
index 000000000000..3fe6bf51dd22
--- /dev/null
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvmextensions.go
@@ -0,0 +1,459 @@
+package compute
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// VirtualMachineScaleSetVMExtensionsClient is the compute Client
+type VirtualMachineScaleSetVMExtensionsClient struct {
+ BaseClient
+}
+
+// NewVirtualMachineScaleSetVMExtensionsClient creates an instance of the VirtualMachineScaleSetVMExtensionsClient
+// client.
+func NewVirtualMachineScaleSetVMExtensionsClient(subscriptionID string) VirtualMachineScaleSetVMExtensionsClient {
+ return NewVirtualMachineScaleSetVMExtensionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewVirtualMachineScaleSetVMExtensionsClientWithBaseURI creates an instance of the
+// VirtualMachineScaleSetVMExtensionsClient client.
+func NewVirtualMachineScaleSetVMExtensionsClientWithBaseURI(baseURI string, subscriptionID string) VirtualMachineScaleSetVMExtensionsClient {
+ return VirtualMachineScaleSetVMExtensionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate the operation to create or update the VMSS VM extension.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMScaleSetName - the name of the VM scale set.
+// instanceID - the instance ID of the virtual machine.
+// VMExtensionName - the name of the virtual machine extension.
+// extensionParameters - parameters supplied to the Create Virtual Machine Extension operation.
+func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, extensionParameters VirtualMachineExtension) (result VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachineScaleSetVMExtensionsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, VMScaleSetName, instanceID, VMExtensionName, extensionParameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, extensionParameters VirtualMachineExtension) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmExtensionName": autorest.Encode("path", VMExtensionName),
+ "vmScaleSetName": autorest.Encode("path", VMScaleSetName),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/extensions/{vmExtensionName}", pathParameters),
+ autorest.WithJSON(extensionParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdateSender(req *http.Request) (future VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdateResponder(resp *http.Response) (result VirtualMachineExtension, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete the operation to delete the VMSS VM extension.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMScaleSetName - the name of the VM scale set.
+// instanceID - the instance ID of the virtual machine.
+// VMExtensionName - the name of the virtual machine extension.
+func (client VirtualMachineScaleSetVMExtensionsClient) Delete(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string) (result VirtualMachineScaleSetVMExtensionsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachineScaleSetVMExtensionsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, VMScaleSetName, instanceID, VMExtensionName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client VirtualMachineScaleSetVMExtensionsClient) DeletePreparer(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmExtensionName": autorest.Encode("path", VMExtensionName),
+ "vmScaleSetName": autorest.Encode("path", VMScaleSetName),
+ }
+
+ const APIVersion = "2019-07-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.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/extensions/{vmExtensionName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachineScaleSetVMExtensionsClient) DeleteSender(req *http.Request) (future VirtualMachineScaleSetVMExtensionsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client VirtualMachineScaleSetVMExtensionsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get the operation to get the VMSS VM extension.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMScaleSetName - the name of the VM scale set.
+// instanceID - the instance ID of the virtual machine.
+// VMExtensionName - the name of the virtual machine extension.
+// expand - the expand expression to apply on the operation.
+func (client VirtualMachineScaleSetVMExtensionsClient) Get(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, expand string) (result VirtualMachineExtension, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachineScaleSetVMExtensionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, VMScaleSetName, instanceID, VMExtensionName, expand)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client VirtualMachineScaleSetVMExtensionsClient) GetPreparer(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, expand string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmExtensionName": autorest.Encode("path", VMExtensionName),
+ "vmScaleSetName": autorest.Encode("path", VMScaleSetName),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(expand) > 0 {
+ queryParameters["$expand"] = autorest.Encode("query", expand)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/extensions/{vmExtensionName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachineScaleSetVMExtensionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client VirtualMachineScaleSetVMExtensionsClient) GetResponder(resp *http.Response) (result VirtualMachineExtension, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List the operation to get all extensions of an instance in Virtual Machine Scaleset.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMScaleSetName - the name of the VM scale set.
+// instanceID - the instance ID of the virtual machine.
+// expand - the expand expression to apply on the operation.
+func (client VirtualMachineScaleSetVMExtensionsClient) List(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, expand string) (result VirtualMachineExtensionsListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachineScaleSetVMExtensionsClient.List")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListPreparer(ctx, resourceGroupName, VMScaleSetName, instanceID, expand)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client VirtualMachineScaleSetVMExtensionsClient) ListPreparer(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, expand string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmScaleSetName": autorest.Encode("path", VMScaleSetName),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(expand) > 0 {
+ queryParameters["$expand"] = autorest.Encode("query", expand)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/extensions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachineScaleSetVMExtensionsClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client VirtualMachineScaleSetVMExtensionsClient) ListResponder(resp *http.Response) (result VirtualMachineExtensionsListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Update the operation to update the VMSS VM extension.
+// Parameters:
+// resourceGroupName - the name of the resource group.
+// VMScaleSetName - the name of the VM scale set.
+// instanceID - the instance ID of the virtual machine.
+// VMExtensionName - the name of the virtual machine extension.
+// extensionParameters - parameters supplied to the Update Virtual Machine Extension operation.
+func (client VirtualMachineScaleSetVMExtensionsClient) Update(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, extensionParameters VirtualMachineExtensionUpdate) (result VirtualMachineScaleSetVMExtensionsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualMachineScaleSetVMExtensionsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, VMScaleSetName, instanceID, VMExtensionName, extensionParameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client VirtualMachineScaleSetVMExtensionsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, VMScaleSetName string, instanceID string, VMExtensionName string, extensionParameters VirtualMachineExtensionUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vmExtensionName": autorest.Encode("path", VMExtensionName),
+ "vmScaleSetName": autorest.Encode("path", VMScaleSetName),
+ }
+
+ const APIVersion = "2019-07-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/virtualMachineScaleSets/{vmScaleSetName}/virtualMachines/{instanceId}/extensions/{vmExtensionName}", pathParameters),
+ autorest.WithJSON(extensionParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualMachineScaleSetVMExtensionsClient) UpdateSender(req *http.Request) (future VirtualMachineScaleSetVMExtensionsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client VirtualMachineScaleSetVMExtensionsClient) UpdateResponder(resp *http.Response) (result VirtualMachineExtension, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvms.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvms.go
index 6015078f439d..155e6eee83df 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvms.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinescalesetvms.go
@@ -83,7 +83,7 @@ func (client VirtualMachineScaleSetVMsClient) DeallocatePreparer(ctx context.Con
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -161,7 +161,7 @@ func (client VirtualMachineScaleSetVMsClient) DeletePreparer(ctx context.Context
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -246,7 +246,7 @@ func (client VirtualMachineScaleSetVMsClient) GetPreparer(ctx context.Context, r
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -328,7 +328,7 @@ func (client VirtualMachineScaleSetVMsClient) GetInstanceViewPreparer(ctx contex
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -409,7 +409,7 @@ func (client VirtualMachineScaleSetVMsClient) ListPreparer(ctx context.Context,
"virtualMachineScaleSetName": autorest.Encode("path", virtualMachineScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -528,7 +528,7 @@ func (client VirtualMachineScaleSetVMsClient) PerformMaintenancePreparer(ctx con
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -610,7 +610,7 @@ func (client VirtualMachineScaleSetVMsClient) PowerOffPreparer(ctx context.Conte
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -694,7 +694,7 @@ func (client VirtualMachineScaleSetVMsClient) RedeployPreparer(ctx context.Conte
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -773,7 +773,7 @@ func (client VirtualMachineScaleSetVMsClient) ReimagePreparer(ctx context.Contex
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -857,7 +857,7 @@ func (client VirtualMachineScaleSetVMsClient) ReimageAllPreparer(ctx context.Con
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -935,7 +935,7 @@ func (client VirtualMachineScaleSetVMsClient) RestartPreparer(ctx context.Contex
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1020,7 +1020,7 @@ func (client VirtualMachineScaleSetVMsClient) RunCommandPreparer(ctx context.Con
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1101,7 +1101,7 @@ func (client VirtualMachineScaleSetVMsClient) StartPreparer(ctx context.Context,
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -1201,7 +1201,7 @@ func (client VirtualMachineScaleSetVMsClient) UpdatePreparer(ctx context.Context
"vmScaleSetName": autorest.Encode("path", VMScaleSetName),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinesizes.go b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinesizes.go
index 04bcbb0490d4..55335fe9a518 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinesizes.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/virtualmachinesizes.go
@@ -90,7 +90,7 @@ func (client VirtualMachineSizesClient) ListPreparer(ctx context.Context, locati
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- const APIVersion = "2019-03-01"
+ const APIVersion = "2019-07-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry/models.go
index a957075be5d0..94796bea2233 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/containerregistry/mgmt/2018-09-01/containerregistry/models.go
@@ -2180,8 +2180,6 @@ type Registry struct {
autorest.Response `json:"-"`
// Sku - The SKU of the container registry.
Sku *Sku `json:"sku,omitempty"`
- // Identity - The identity of the container registry.
- Identity *RegistryIdentity `json:"identity,omitempty"`
// RegistryProperties - The properties of the container registry.
*RegistryProperties `json:"properties,omitempty"`
// ID - READ-ONLY; The resource ID.
@@ -2202,9 +2200,6 @@ func (r Registry) MarshalJSON() ([]byte, error) {
if r.Sku != nil {
objectMap["sku"] = r.Sku
}
- if r.Identity != nil {
- objectMap["identity"] = r.Identity
- }
if r.RegistryProperties != nil {
objectMap["properties"] = r.RegistryProperties
}
@@ -2235,15 +2230,6 @@ func (r *Registry) UnmarshalJSON(body []byte) error {
}
r.Sku = &sku
}
- case "identity":
- if v != nil {
- var identity RegistryIdentity
- err = json.Unmarshal(*v, &identity)
- if err != nil {
- return err
- }
- r.Identity = &identity
- }
case "properties":
if v != nil {
var registryProperties RegistryProperties
@@ -2304,16 +2290,6 @@ func (r *Registry) UnmarshalJSON(body []byte) error {
return nil
}
-// RegistryIdentity the identity of the container registry.
-type RegistryIdentity struct {
- // Type - The type of identity used for the registry.
- Type *string `json:"type,omitempty"`
- // PrincipalID - The principal ID of registry identity.
- PrincipalID *string `json:"principalId,omitempty"`
- // TenantID - The tenant ID associated with the registry.
- TenantID *string `json:"tenantId,omitempty"`
-}
-
// RegistryListCredentialsResult the response from the ListCredentials operation.
type RegistryListCredentialsResult struct {
autorest.Response `json:"-"`
@@ -2539,8 +2515,6 @@ type RegistryUpdateParameters struct {
Tags map[string]*string `json:"tags"`
// Sku - The SKU of the container registry.
Sku *Sku `json:"sku,omitempty"`
- // Identity - The identity of the container registry.
- Identity *RegistryIdentity `json:"identity,omitempty"`
// RegistryPropertiesUpdateParameters - The properties that the container registry will be updated with.
*RegistryPropertiesUpdateParameters `json:"properties,omitempty"`
}
@@ -2554,9 +2528,6 @@ func (rup RegistryUpdateParameters) MarshalJSON() ([]byte, error) {
if rup.Sku != nil {
objectMap["sku"] = rup.Sku
}
- if rup.Identity != nil {
- objectMap["identity"] = rup.Identity
- }
if rup.RegistryPropertiesUpdateParameters != nil {
objectMap["properties"] = rup.RegistryPropertiesUpdateParameters
}
@@ -2590,15 +2561,6 @@ func (rup *RegistryUpdateParameters) UnmarshalJSON(body []byte) error {
}
rup.Sku = &sku
}
- case "identity":
- if v != nil {
- var identity RegistryIdentity
- err = json.Unmarshal(*v, &identity)
- if err != nil {
- return err
- }
- rup.Identity = &identity
- }
case "properties":
if v != nil {
var registryPropertiesUpdateParameters RegistryPropertiesUpdateParameters
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/datafactory/mgmt/2018-06-01/datafactory/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/datafactory/mgmt/2018-06-01/datafactory/models.go
index a7f764d671c7..210e26dfdf33 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/datafactory/mgmt/2018-06-01/datafactory/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/datafactory/mgmt/2018-06-01/datafactory/models.go
@@ -295,6 +295,8 @@ func PossibleDependencyConditionValues() []DependencyCondition {
type DynamicsAuthenticationType string
const (
+ // AADServicePrincipal ...
+ AADServicePrincipal DynamicsAuthenticationType = "AADServicePrincipal"
// Ifd ...
Ifd DynamicsAuthenticationType = "Ifd"
// Office365 ...
@@ -303,7 +305,7 @@ const (
// PossibleDynamicsAuthenticationTypeValues returns an array of possible values for the DynamicsAuthenticationType const type.
func PossibleDynamicsAuthenticationTypeValues() []DynamicsAuthenticationType {
- return []DynamicsAuthenticationType{Ifd, Office365}
+ return []DynamicsAuthenticationType{AADServicePrincipal, Ifd, Office365}
}
// DynamicsDeploymentType enumerates the values for dynamics deployment type.
@@ -806,6 +808,23 @@ func PossibleOraclePartitionOptionValues() []OraclePartitionOption {
return []OraclePartitionOption{OraclePartitionOptionDynamicRange, OraclePartitionOptionNone, OraclePartitionOptionPhysicalPartitionsOfTable}
}
+// OrcCompressionCodec enumerates the values for orc compression codec.
+type OrcCompressionCodec string
+
+const (
+ // OrcCompressionCodecNone ...
+ OrcCompressionCodecNone OrcCompressionCodec = "none"
+ // OrcCompressionCodecSnappy ...
+ OrcCompressionCodecSnappy OrcCompressionCodec = "snappy"
+ // OrcCompressionCodecZlib ...
+ OrcCompressionCodecZlib OrcCompressionCodec = "zlib"
+)
+
+// PossibleOrcCompressionCodecValues returns an array of possible values for the OrcCompressionCodec const type.
+func PossibleOrcCompressionCodecValues() []OrcCompressionCodec {
+ return []OrcCompressionCodec{OrcCompressionCodecNone, OrcCompressionCodecSnappy, OrcCompressionCodecZlib}
+}
+
// ParameterType enumerates the values for parameter type.
type ParameterType string
@@ -1398,6 +1417,8 @@ const (
TypeAzureFunctionActivity TypeBasicActivity = "AzureFunctionActivity"
// TypeAzureMLBatchExecution ...
TypeAzureMLBatchExecution TypeBasicActivity = "AzureMLBatchExecution"
+ // TypeAzureMLExecutePipeline ...
+ TypeAzureMLExecutePipeline TypeBasicActivity = "AzureMLExecutePipeline"
// TypeAzureMLUpdateResource ...
TypeAzureMLUpdateResource TypeBasicActivity = "AzureMLUpdateResource"
// TypeContainer ...
@@ -1448,6 +1469,8 @@ const (
TypeSetVariable TypeBasicActivity = "SetVariable"
// TypeSQLServerStoredProcedure ...
TypeSQLServerStoredProcedure TypeBasicActivity = "SqlServerStoredProcedure"
+ // TypeSwitch ...
+ TypeSwitch TypeBasicActivity = "Switch"
// TypeUntil ...
TypeUntil TypeBasicActivity = "Until"
// TypeValidation ...
@@ -1462,7 +1485,7 @@ const (
// PossibleTypeBasicActivityValues returns an array of possible values for the TypeBasicActivity const type.
func PossibleTypeBasicActivityValues() []TypeBasicActivity {
- return []TypeBasicActivity{TypeActivity, TypeAppendVariable, TypeAzureDataExplorerCommand, TypeAzureFunctionActivity, TypeAzureMLBatchExecution, TypeAzureMLUpdateResource, TypeContainer, TypeCopy, TypeCustom, TypeDatabricksNotebook, TypeDatabricksSparkJar, TypeDatabricksSparkPython, TypeDataLakeAnalyticsUSQL, TypeDelete, TypeExecuteDataFlow, TypeExecutePipeline, TypeExecuteSSISPackage, TypeExecution, TypeFilter, TypeForEach, TypeGetMetadata, TypeHDInsightHive, TypeHDInsightMapReduce, TypeHDInsightPig, TypeHDInsightSpark, TypeHDInsightStreaming, TypeIfCondition, TypeLookup, TypeSetVariable, TypeSQLServerStoredProcedure, TypeUntil, TypeValidation, TypeWait, TypeWebActivity, TypeWebHook}
+ return []TypeBasicActivity{TypeActivity, TypeAppendVariable, TypeAzureDataExplorerCommand, TypeAzureFunctionActivity, TypeAzureMLBatchExecution, TypeAzureMLExecutePipeline, TypeAzureMLUpdateResource, TypeContainer, TypeCopy, TypeCustom, TypeDatabricksNotebook, TypeDatabricksSparkJar, TypeDatabricksSparkPython, TypeDataLakeAnalyticsUSQL, TypeDelete, TypeExecuteDataFlow, TypeExecutePipeline, TypeExecuteSSISPackage, TypeExecution, TypeFilter, TypeForEach, TypeGetMetadata, TypeHDInsightHive, TypeHDInsightMapReduce, TypeHDInsightPig, TypeHDInsightSpark, TypeHDInsightStreaming, TypeIfCondition, TypeLookup, TypeSetVariable, TypeSQLServerStoredProcedure, TypeSwitch, TypeUntil, TypeValidation, TypeWait, TypeWebActivity, TypeWebHook}
}
// TypeBasicCopySink enumerates the values for type basic copy sink.
@@ -2092,6 +2115,8 @@ const (
TypeAzureDataLakeAnalytics TypeBasicLinkedService = "AzureDataLakeAnalytics"
// TypeAzureDataLakeStore ...
TypeAzureDataLakeStore TypeBasicLinkedService = "AzureDataLakeStore"
+ // TypeAzureFileStorage ...
+ TypeAzureFileStorage TypeBasicLinkedService = "AzureFileStorage"
// TypeAzureFunction ...
TypeAzureFunction TypeBasicLinkedService = "AzureFunction"
// TypeAzureKeyVault ...
@@ -2100,6 +2125,8 @@ const (
TypeAzureMariaDB TypeBasicLinkedService = "AzureMariaDB"
// TypeAzureML ...
TypeAzureML TypeBasicLinkedService = "AzureML"
+ // TypeAzureMLService ...
+ TypeAzureMLService TypeBasicLinkedService = "AzureMLService"
// TypeAzureMySQL ...
TypeAzureMySQL TypeBasicLinkedService = "AzureMySql"
// TypeAzurePostgreSQL ...
@@ -2150,6 +2177,8 @@ const (
TypeGoogleAdWords TypeBasicLinkedService = "GoogleAdWords"
// TypeGoogleBigQuery ...
TypeGoogleBigQuery TypeBasicLinkedService = "GoogleBigQuery"
+ // TypeGoogleCloudStorage ...
+ TypeGoogleCloudStorage TypeBasicLinkedService = "GoogleCloudStorage"
// TypeGreenplum ...
TypeGreenplum TypeBasicLinkedService = "Greenplum"
// TypeHBase ...
@@ -2260,7 +2289,7 @@ const (
// PossibleTypeBasicLinkedServiceValues returns an array of possible values for the TypeBasicLinkedService const type.
func PossibleTypeBasicLinkedServiceValues() []TypeBasicLinkedService {
- return []TypeBasicLinkedService{TypeAmazonMWS, TypeAmazonRedshift, TypeAmazonS3, TypeAzureBatch, TypeAzureBlobFS, TypeAzureBlobStorage, TypeAzureDatabricks, TypeAzureDataExplorer, TypeAzureDataLakeAnalytics, TypeAzureDataLakeStore, TypeAzureFunction, TypeAzureKeyVault, TypeAzureMariaDB, TypeAzureML, TypeAzureMySQL, TypeAzurePostgreSQL, TypeAzureSearch, TypeAzureSQLDatabase, TypeAzureSQLDW, TypeAzureSQLMI, TypeAzureStorage, TypeAzureTableStorage, TypeCassandra, TypeCommonDataServiceForApps, TypeConcur, TypeCosmosDb, TypeCosmosDbMongoDbAPI, TypeCouchbase, TypeCustomDataSource, TypeDb2, TypeDrill, TypeDynamics, TypeDynamicsAX, TypeDynamicsCrm, TypeEloqua, TypeFileServer, TypeFtpServer, TypeGoogleAdWords, TypeGoogleBigQuery, TypeGreenplum, TypeHBase, TypeHdfs, TypeHDInsight, TypeHDInsightOnDemand, TypeHive, TypeHTTPServer, TypeHubspot, TypeImpala, TypeInformix, TypeJira, TypeLinkedService, TypeMagento, TypeMariaDB, TypeMarketo, TypeMicrosoftAccess, TypeMongoDb, TypeMongoDbV2, TypeMySQL, TypeNetezza, TypeOData, TypeOdbc, TypeOffice365, TypeOracle, TypeOracleServiceCloud, TypePaypal, TypePhoenix, TypePostgreSQL, TypePresto, TypeQuickBooks, TypeResponsys, TypeRestService, TypeSalesforce, TypeSalesforceMarketingCloud, TypeSalesforceServiceCloud, TypeSapBW, TypeSapCloudForCustomer, TypeSapEcc, TypeSapHana, TypeSapOpenHub, TypeSapTable, TypeServiceNow, TypeSftp, TypeShopify, TypeSpark, TypeSQLServer, TypeSquare, TypeSybase, TypeTeradata, TypeVertica, TypeWeb, TypeXero, TypeZoho}
+ return []TypeBasicLinkedService{TypeAmazonMWS, TypeAmazonRedshift, TypeAmazonS3, TypeAzureBatch, TypeAzureBlobFS, TypeAzureBlobStorage, TypeAzureDatabricks, TypeAzureDataExplorer, TypeAzureDataLakeAnalytics, TypeAzureDataLakeStore, TypeAzureFileStorage, TypeAzureFunction, TypeAzureKeyVault, TypeAzureMariaDB, TypeAzureML, TypeAzureMLService, TypeAzureMySQL, TypeAzurePostgreSQL, TypeAzureSearch, TypeAzureSQLDatabase, TypeAzureSQLDW, TypeAzureSQLMI, TypeAzureStorage, TypeAzureTableStorage, TypeCassandra, TypeCommonDataServiceForApps, TypeConcur, TypeCosmosDb, TypeCosmosDbMongoDbAPI, TypeCouchbase, TypeCustomDataSource, TypeDb2, TypeDrill, TypeDynamics, TypeDynamicsAX, TypeDynamicsCrm, TypeEloqua, TypeFileServer, TypeFtpServer, TypeGoogleAdWords, TypeGoogleBigQuery, TypeGoogleCloudStorage, TypeGreenplum, TypeHBase, TypeHdfs, TypeHDInsight, TypeHDInsightOnDemand, TypeHive, TypeHTTPServer, TypeHubspot, TypeImpala, TypeInformix, TypeJira, TypeLinkedService, TypeMagento, TypeMariaDB, TypeMarketo, TypeMicrosoftAccess, TypeMongoDb, TypeMongoDbV2, TypeMySQL, TypeNetezza, TypeOData, TypeOdbc, TypeOffice365, TypeOracle, TypeOracleServiceCloud, TypePaypal, TypePhoenix, TypePostgreSQL, TypePresto, TypeQuickBooks, TypeResponsys, TypeRestService, TypeSalesforce, TypeSalesforceMarketingCloud, TypeSalesforceServiceCloud, TypeSapBW, TypeSapCloudForCustomer, TypeSapEcc, TypeSapHana, TypeSapOpenHub, TypeSapTable, TypeServiceNow, TypeSftp, TypeShopify, TypeSpark, TypeSQLServer, TypeSquare, TypeSybase, TypeTeradata, TypeVertica, TypeWeb, TypeXero, TypeZoho}
}
// TypeBasicSsisObjectMetadata enumerates the values for type basic ssis object metadata.
@@ -2400,6 +2429,7 @@ type BasicActivity interface {
AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool)
AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool)
AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool)
+ AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool)
AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool)
AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool)
AsGetMetadataActivity() (*GetMetadataActivity, bool)
@@ -2426,6 +2456,7 @@ type BasicActivity interface {
AsUntilActivity() (*UntilActivity, bool)
AsWaitActivity() (*WaitActivity, bool)
AsForEachActivity() (*ForEachActivity, bool)
+ AsSwitchActivity() (*SwitchActivity, bool)
AsIfConditionActivity() (*IfConditionActivity, bool)
AsExecutePipelineActivity() (*ExecutePipelineActivity, bool)
AsControlActivity() (*ControlActivity, bool)
@@ -2445,7 +2476,7 @@ type Activity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -2481,6 +2512,10 @@ func unmarshalBasicActivity(body []byte) (BasicActivity, error) {
var dlaua DataLakeAnalyticsUSQLActivity
err := json.Unmarshal(body, &dlaua)
return dlaua, err
+ case string(TypeAzureMLExecutePipeline):
+ var amepa AzureMLExecutePipelineActivity
+ err := json.Unmarshal(body, &amepa)
+ return amepa, err
case string(TypeAzureMLUpdateResource):
var amura AzureMLUpdateResourceActivity
err := json.Unmarshal(body, &amura)
@@ -2581,6 +2616,10 @@ func unmarshalBasicActivity(body []byte) (BasicActivity, error) {
var fea ForEachActivity
err := json.Unmarshal(body, &fea)
return fea, err
+ case string(TypeSwitch):
+ var sa SwitchActivity
+ err := json.Unmarshal(body, &sa)
+ return sa, err
case string(TypeIfCondition):
var ica IfConditionActivity
err := json.Unmarshal(body, &ica)
@@ -2673,6 +2712,11 @@ func (a Activity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActiv
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for Activity.
+func (a Activity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for Activity.
func (a Activity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -2803,6 +2847,11 @@ func (a Activity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for Activity.
+func (a Activity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for Activity.
func (a Activity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -3302,7 +3351,7 @@ type AmazonMWSLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -3674,6 +3723,11 @@ func (amls AmazonMWSLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AmazonMWSLinkedService.
+func (amls AmazonMWSLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AmazonMWSLinkedService.
func (amls AmazonMWSLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -3714,6 +3768,16 @@ func (amls AmazonMWSLinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AmazonMWSLinkedService.
+func (amls AmazonMWSLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AmazonMWSLinkedService.
+func (amls AmazonMWSLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AmazonMWSLinkedService.
func (amls AmazonMWSLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -5212,7 +5276,7 @@ type AmazonRedshiftLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -5584,6 +5648,11 @@ func (arls AmazonRedshiftLinkedService) AsOdbcLinkedService() (*OdbcLinkedServic
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AmazonRedshiftLinkedService.
+func (arls AmazonRedshiftLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AmazonRedshiftLinkedService.
func (arls AmazonRedshiftLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -5624,6 +5693,16 @@ func (arls AmazonRedshiftLinkedService) AsOracleLinkedService() (*OracleLinkedSe
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AmazonRedshiftLinkedService.
+func (arls AmazonRedshiftLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AmazonRedshiftLinkedService.
+func (arls AmazonRedshiftLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AmazonRedshiftLinkedService.
func (arls AmazonRedshiftLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -7822,7 +7901,7 @@ type AmazonS3LinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -8194,6 +8273,11 @@ func (asls AmazonS3LinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AmazonS3LinkedService.
+func (asls AmazonS3LinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AmazonS3LinkedService.
func (asls AmazonS3LinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -8234,6 +8318,16 @@ func (asls AmazonS3LinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AmazonS3LinkedService.
+func (asls AmazonS3LinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AmazonS3LinkedService.
+func (asls AmazonS3LinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AmazonS3LinkedService.
func (asls AmazonS3LinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -8756,7 +8850,7 @@ type AppendVariableActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -8818,6 +8912,11 @@ func (ava AppendVariableActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAn
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AppendVariableActivity.
+func (ava AppendVariableActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AppendVariableActivity.
func (ava AppendVariableActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -8948,6 +9047,11 @@ func (ava AppendVariableActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for AppendVariableActivity.
+func (ava AppendVariableActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for AppendVariableActivity.
func (ava AppendVariableActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -10803,7 +10907,7 @@ type AzureBatchLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -11175,6 +11279,11 @@ func (abls AzureBatchLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureBatchLinkedService.
+func (abls AzureBatchLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureBatchLinkedService.
func (abls AzureBatchLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -11215,6 +11324,16 @@ func (abls AzureBatchLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureBatchLinkedService.
+func (abls AzureBatchLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureBatchLinkedService.
+func (abls AzureBatchLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureBatchLinkedService.
func (abls AzureBatchLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -12862,7 +12981,7 @@ type AzureBlobFSLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -13234,6 +13353,11 @@ func (abfls AzureBlobFSLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureBlobFSLinkedService.
+func (abfls AzureBlobFSLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureBlobFSLinkedService.
func (abfls AzureBlobFSLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -13274,6 +13398,16 @@ func (abfls AzureBlobFSLinkedService) AsOracleLinkedService() (*OracleLinkedServ
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureBlobFSLinkedService.
+func (abfls AzureBlobFSLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureBlobFSLinkedService.
+func (abfls AzureBlobFSLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureBlobFSLinkedService.
func (abfls AzureBlobFSLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -14831,7 +14965,7 @@ type AzureBlobStorageLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -15203,6 +15337,11 @@ func (absls AzureBlobStorageLinkedService) AsOdbcLinkedService() (*OdbcLinkedSer
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureBlobStorageLinkedService.
+func (absls AzureBlobStorageLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureBlobStorageLinkedService.
func (absls AzureBlobStorageLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -15243,6 +15382,16 @@ func (absls AzureBlobStorageLinkedService) AsOracleLinkedService() (*OracleLinke
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureBlobStorageLinkedService.
+func (absls AzureBlobStorageLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureBlobStorageLinkedService.
+func (absls AzureBlobStorageLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureBlobStorageLinkedService.
func (absls AzureBlobStorageLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -15921,7 +16070,7 @@ type AzureDatabricksLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -16293,6 +16442,11 @@ func (adls AzureDatabricksLinkedService) AsOdbcLinkedService() (*OdbcLinkedServi
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureDatabricksLinkedService.
+func (adls AzureDatabricksLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureDatabricksLinkedService.
func (adls AzureDatabricksLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -16333,6 +16487,16 @@ func (adls AzureDatabricksLinkedService) AsOracleLinkedService() (*OracleLinkedS
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureDatabricksLinkedService.
+func (adls AzureDatabricksLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureDatabricksLinkedService.
+func (adls AzureDatabricksLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureDatabricksLinkedService.
func (adls AzureDatabricksLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -16735,7 +16899,7 @@ type AzureDataExplorerCommandActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -16803,6 +16967,11 @@ func (adeca AzureDataExplorerCommandActivity) AsDataLakeAnalyticsUSQLActivity()
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AzureDataExplorerCommandActivity.
+func (adeca AzureDataExplorerCommandActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AzureDataExplorerCommandActivity.
func (adeca AzureDataExplorerCommandActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -16933,6 +17102,11 @@ func (adeca AzureDataExplorerCommandActivity) AsForEachActivity() (*ForEachActiv
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for AzureDataExplorerCommandActivity.
+func (adeca AzureDataExplorerCommandActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for AzureDataExplorerCommandActivity.
func (adeca AzureDataExplorerCommandActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -17090,7 +17264,7 @@ type AzureDataExplorerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -17462,6 +17636,11 @@ func (adels AzureDataExplorerLinkedService) AsOdbcLinkedService() (*OdbcLinkedSe
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureDataExplorerLinkedService.
+func (adels AzureDataExplorerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureDataExplorerLinkedService.
func (adels AzureDataExplorerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -17502,6 +17681,16 @@ func (adels AzureDataExplorerLinkedService) AsOracleLinkedService() (*OracleLink
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureDataExplorerLinkedService.
+func (adels AzureDataExplorerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureDataExplorerLinkedService.
+func (adels AzureDataExplorerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureDataExplorerLinkedService.
func (adels AzureDataExplorerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -19309,7 +19498,7 @@ type AzureDataLakeAnalyticsLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -19681,6 +19870,11 @@ func (adlals AzureDataLakeAnalyticsLinkedService) AsOdbcLinkedService() (*OdbcLi
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureDataLakeAnalyticsLinkedService.
+func (adlals AzureDataLakeAnalyticsLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureDataLakeAnalyticsLinkedService.
func (adlals AzureDataLakeAnalyticsLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -19721,6 +19915,16 @@ func (adlals AzureDataLakeAnalyticsLinkedService) AsOracleLinkedService() (*Orac
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureDataLakeAnalyticsLinkedService.
+func (adlals AzureDataLakeAnalyticsLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureDataLakeAnalyticsLinkedService.
+func (adlals AzureDataLakeAnalyticsLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureDataLakeAnalyticsLinkedService.
func (adlals AzureDataLakeAnalyticsLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -20682,7 +20886,7 @@ type AzureDataLakeStoreLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -21054,6 +21258,11 @@ func (adlsls AzureDataLakeStoreLinkedService) AsOdbcLinkedService() (*OdbcLinked
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureDataLakeStoreLinkedService.
+func (adlsls AzureDataLakeStoreLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureDataLakeStoreLinkedService.
func (adlsls AzureDataLakeStoreLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -21094,6 +21303,16 @@ func (adlsls AzureDataLakeStoreLinkedService) AsOracleLinkedService() (*OracleLi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureDataLakeStoreLinkedService.
+func (adlsls AzureDataLakeStoreLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureDataLakeStoreLinkedService.
+func (adlsls AzureDataLakeStoreLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureDataLakeStoreLinkedService.
func (adlsls AzureDataLakeStoreLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -22617,6 +22836,913 @@ func (adlsws *AzureDataLakeStoreWriteSettings) UnmarshalJSON(body []byte) error
return nil
}
+// AzureFileStorageLinkedService azure File Storage linked service.
+type AzureFileStorageLinkedService struct {
+ // AzureFileStorageLinkedServiceTypeProperties - Azure File Storage linked service properties.
+ *AzureFileStorageLinkedServiceTypeProperties `json:"typeProperties,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // ConnectVia - The integration runtime reference.
+ ConnectVia *IntegrationRuntimeReference `json:"connectVia,omitempty"`
+ // Description - Linked service description.
+ Description *string `json:"description,omitempty"`
+ // Parameters - Parameters for linked service.
+ Parameters map[string]*ParameterSpecification `json:"parameters"`
+ // Annotations - List of tags that can be used for describing the linked service.
+ Annotations *[]interface{} `json:"annotations,omitempty"`
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ Type TypeBasicLinkedService `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) MarshalJSON() ([]byte, error) {
+ afsls.Type = TypeAzureFileStorage
+ objectMap := make(map[string]interface{})
+ if afsls.AzureFileStorageLinkedServiceTypeProperties != nil {
+ objectMap["typeProperties"] = afsls.AzureFileStorageLinkedServiceTypeProperties
+ }
+ if afsls.ConnectVia != nil {
+ objectMap["connectVia"] = afsls.ConnectVia
+ }
+ if afsls.Description != nil {
+ objectMap["description"] = afsls.Description
+ }
+ if afsls.Parameters != nil {
+ objectMap["parameters"] = afsls.Parameters
+ }
+ if afsls.Annotations != nil {
+ objectMap["annotations"] = afsls.Annotations
+ }
+ if afsls.Type != "" {
+ objectMap["type"] = afsls.Type
+ }
+ for k, v := range afsls.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsAzureFunctionLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureFunctionLinkedService() (*AzureFunctionLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureDataExplorerLinkedService() (*AzureDataExplorerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapTableLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapTableLinkedService() (*SapTableLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleAdWordsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsGoogleAdWordsLinkedService() (*GoogleAdWordsLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleServiceCloudLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsOracleServiceCloudLinkedService() (*OracleServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsAXLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsDynamicsAXLinkedService() (*DynamicsAXLinkedService, bool) {
+ return nil, false
+}
+
+// AsResponsysLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsResponsysLinkedService() (*ResponsysLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDatabricksLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureDatabricksLinkedService() (*AzureDatabricksLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeAnalyticsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureDataLakeAnalyticsLinkedService() (*AzureDataLakeAnalyticsLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightOnDemandLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHDInsightOnDemandLinkedService() (*HDInsightOnDemandLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceMarketingCloudLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSalesforceMarketingCloudLinkedService() (*SalesforceMarketingCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsNetezzaLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsNetezzaLinkedService() (*NetezzaLinkedService, bool) {
+ return nil, false
+}
+
+// AsVerticaLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsVerticaLinkedService() (*VerticaLinkedService, bool) {
+ return nil, false
+}
+
+// AsZohoLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsZohoLinkedService() (*ZohoLinkedService, bool) {
+ return nil, false
+}
+
+// AsXeroLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsXeroLinkedService() (*XeroLinkedService, bool) {
+ return nil, false
+}
+
+// AsSquareLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSquareLinkedService() (*SquareLinkedService, bool) {
+ return nil, false
+}
+
+// AsSparkLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSparkLinkedService() (*SparkLinkedService, bool) {
+ return nil, false
+}
+
+// AsShopifyLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsShopifyLinkedService() (*ShopifyLinkedService, bool) {
+ return nil, false
+}
+
+// AsServiceNowLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsServiceNowLinkedService() (*ServiceNowLinkedService, bool) {
+ return nil, false
+}
+
+// AsQuickBooksLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsQuickBooksLinkedService() (*QuickBooksLinkedService, bool) {
+ return nil, false
+}
+
+// AsPrestoLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsPrestoLinkedService() (*PrestoLinkedService, bool) {
+ return nil, false
+}
+
+// AsPhoenixLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsPhoenixLinkedService() (*PhoenixLinkedService, bool) {
+ return nil, false
+}
+
+// AsPaypalLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsPaypalLinkedService() (*PaypalLinkedService, bool) {
+ return nil, false
+}
+
+// AsMarketoLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMarketoLinkedService() (*MarketoLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMariaDBLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureMariaDBLinkedService() (*AzureMariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMariaDBLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMariaDBLinkedService() (*MariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMagentoLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMagentoLinkedService() (*MagentoLinkedService, bool) {
+ return nil, false
+}
+
+// AsJiraLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsJiraLinkedService() (*JiraLinkedService, bool) {
+ return nil, false
+}
+
+// AsImpalaLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsImpalaLinkedService() (*ImpalaLinkedService, bool) {
+ return nil, false
+}
+
+// AsHubspotLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHubspotLinkedService() (*HubspotLinkedService, bool) {
+ return nil, false
+}
+
+// AsHiveLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHiveLinkedService() (*HiveLinkedService, bool) {
+ return nil, false
+}
+
+// AsHBaseLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHBaseLinkedService() (*HBaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsGreenplumLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsGreenplumLinkedService() (*GreenplumLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleBigQueryLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsGoogleBigQueryLinkedService() (*GoogleBigQueryLinkedService, bool) {
+ return nil, false
+}
+
+// AsEloquaLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsEloquaLinkedService() (*EloquaLinkedService, bool) {
+ return nil, false
+}
+
+// AsDrillLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsDrillLinkedService() (*DrillLinkedService, bool) {
+ return nil, false
+}
+
+// AsCouchbaseLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCouchbaseLinkedService() (*CouchbaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsConcurLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsConcurLinkedService() (*ConcurLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzurePostgreSQLLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzurePostgreSQLLinkedService() (*AzurePostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonMWSLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAmazonMWSLinkedService() (*AmazonMWSLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapHanaLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapHanaLinkedService() (*SapHanaLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapBWLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapBWLinkedService() (*SapBWLinkedService, bool) {
+ return nil, false
+}
+
+// AsSftpServerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSftpServerLinkedService() (*SftpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsFtpServerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsFtpServerLinkedService() (*FtpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHTTPLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHTTPLinkedService() (*HTTPLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSearchLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureSearchLinkedService() (*AzureSearchLinkedService, bool) {
+ return nil, false
+}
+
+// AsCustomDataSourceLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCustomDataSourceLinkedService() (*CustomDataSourceLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonRedshiftLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAmazonRedshiftLinkedService() (*AmazonRedshiftLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonS3LinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAmazonS3LinkedService() (*AmazonS3LinkedService, bool) {
+ return nil, false
+}
+
+// AsRestServiceLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsRestServiceLinkedService() (*RestServiceLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapOpenHubLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapOpenHubLinkedService() (*SapOpenHubLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapEccLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapEccLinkedService() (*SapEccLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapCloudForCustomerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSapCloudForCustomerLinkedService() (*SapCloudForCustomerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceServiceCloudLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSalesforceServiceCloudLinkedService() (*SalesforceServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSalesforceLinkedService() (*SalesforceLinkedService, bool) {
+ return nil, false
+}
+
+// AsOffice365LinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsOffice365LinkedService() (*Office365LinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobFSLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureBlobFSLinkedService() (*AzureBlobFSLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeStoreLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureDataLakeStoreLinkedService() (*AzureDataLakeStoreLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbMongoDbAPILinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCosmosDbMongoDbAPILinkedService() (*CosmosDbMongoDbAPILinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbV2LinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMongoDbV2LinkedService() (*MongoDbV2LinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMongoDbLinkedService() (*MongoDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsCassandraLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCassandraLinkedService() (*CassandraLinkedService, bool) {
+ return nil, false
+}
+
+// AsWebLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsWebLinkedService() (*WebLinkedService, bool) {
+ return nil, false
+}
+
+// AsODataLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsODataLinkedService() (*ODataLinkedService, bool) {
+ return nil, false
+}
+
+// AsHdfsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHdfsLinkedService() (*HdfsLinkedService, bool) {
+ return nil, false
+}
+
+// AsMicrosoftAccessLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMicrosoftAccessLinkedService() (*MicrosoftAccessLinkedService, bool) {
+ return nil, false
+}
+
+// AsInformixLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsInformixLinkedService() (*InformixLinkedService, bool) {
+ return nil, false
+}
+
+// AsOdbcLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
+ return nil, false
+}
+
+// AsTeradataLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsTeradataLinkedService() (*TeradataLinkedService, bool) {
+ return nil, false
+}
+
+// AsDb2LinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsDb2LinkedService() (*Db2LinkedService, bool) {
+ return nil, false
+}
+
+// AsSybaseLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSybaseLinkedService() (*SybaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsPostgreSQLLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsPostgreSQLLinkedService() (*PostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsMySQLLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsMySQLLinkedService() (*MySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMySQLLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureMySQLLinkedService() (*AzureMySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return &afsls, true
+}
+
+// AsFileServerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsHDInsightLinkedService() (*HDInsightLinkedService, bool) {
+ return nil, false
+}
+
+// AsCommonDataServiceForAppsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCommonDataServiceForAppsLinkedService() (*CommonDataServiceForAppsLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsCrmLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsDynamicsCrmLinkedService() (*DynamicsCrmLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsDynamicsLinkedService() (*DynamicsLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsCosmosDbLinkedService() (*CosmosDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureKeyVaultLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureKeyVaultLinkedService() (*AzureKeyVaultLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBatchLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureBatchLinkedService() (*AzureBatchLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLMILinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureSQLMILinkedService() (*AzureSQLMILinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDatabaseLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureSQLDatabaseLinkedService() (*AzureSQLDatabaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsSQLServerLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsSQLServerLinkedService() (*SQLServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDWLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureSQLDWLinkedService() (*AzureSQLDWLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureTableStorageLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureTableStorageLinkedService() (*AzureTableStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobStorageLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureBlobStorageLinkedService() (*AzureBlobStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureStorageLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsAzureStorageLinkedService() (*AzureStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsLinkedService() (*LinkedService, bool) {
+ return nil, false
+}
+
+// AsBasicLinkedService is the BasicLinkedService implementation for AzureFileStorageLinkedService.
+func (afsls AzureFileStorageLinkedService) AsBasicLinkedService() (BasicLinkedService, bool) {
+ return &afsls, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureFileStorageLinkedService struct.
+func (afsls *AzureFileStorageLinkedService) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var azureFileStorageLinkedServiceTypeProperties AzureFileStorageLinkedServiceTypeProperties
+ err = json.Unmarshal(*v, &azureFileStorageLinkedServiceTypeProperties)
+ if err != nil {
+ return err
+ }
+ afsls.AzureFileStorageLinkedServiceTypeProperties = &azureFileStorageLinkedServiceTypeProperties
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if afsls.AdditionalProperties == nil {
+ afsls.AdditionalProperties = make(map[string]interface{})
+ }
+ afsls.AdditionalProperties[k] = additionalProperties
+ }
+ case "connectVia":
+ if v != nil {
+ var connectVia IntegrationRuntimeReference
+ err = json.Unmarshal(*v, &connectVia)
+ if err != nil {
+ return err
+ }
+ afsls.ConnectVia = &connectVia
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ afsls.Description = &description
+ }
+ case "parameters":
+ if v != nil {
+ var parameters map[string]*ParameterSpecification
+ err = json.Unmarshal(*v, ¶meters)
+ if err != nil {
+ return err
+ }
+ afsls.Parameters = parameters
+ }
+ case "annotations":
+ if v != nil {
+ var annotations []interface{}
+ err = json.Unmarshal(*v, &annotations)
+ if err != nil {
+ return err
+ }
+ afsls.Annotations = &annotations
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicLinkedService
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ afsls.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// AzureFileStorageLinkedServiceTypeProperties azure File Storage linked service properties.
+type AzureFileStorageLinkedServiceTypeProperties struct {
+ // Host - Host name of the server. Type: string (or Expression with resultType string).
+ Host interface{} `json:"host,omitempty"`
+ // UserID - User ID to logon the server. Type: string (or Expression with resultType string).
+ UserID interface{} `json:"userId,omitempty"`
+ // Password - Password to logon the server.
+ Password BasicSecretBase `json:"password,omitempty"`
+ // EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
+ EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureFileStorageLinkedServiceTypeProperties struct.
+func (afslstp *AzureFileStorageLinkedServiceTypeProperties) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "host":
+ if v != nil {
+ var host interface{}
+ err = json.Unmarshal(*v, &host)
+ if err != nil {
+ return err
+ }
+ afslstp.Host = host
+ }
+ case "userId":
+ if v != nil {
+ var userID interface{}
+ err = json.Unmarshal(*v, &userID)
+ if err != nil {
+ return err
+ }
+ afslstp.UserID = userID
+ }
+ case "password":
+ if v != nil {
+ password, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ afslstp.Password = password
+ }
+ case "encryptedCredential":
+ if v != nil {
+ var encryptedCredential interface{}
+ err = json.Unmarshal(*v, &encryptedCredential)
+ if err != nil {
+ return err
+ }
+ afslstp.EncryptedCredential = encryptedCredential
+ }
+ }
+ }
+
+ return nil
+}
+
+// AzureFileStorageLocation the location of file server dataset.
+type AzureFileStorageLocation struct {
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Type - Type of dataset storage location.
+ Type *string `json:"type,omitempty"`
+ // FolderPath - Specify the folder path of dataset. Type: string (or Expression with resultType string)
+ FolderPath interface{} `json:"folderPath,omitempty"`
+ // FileName - Specify the file name of dataset. Type: string (or Expression with resultType string).
+ FileName interface{} `json:"fileName,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureFileStorageLocation.
+func (afsl AzureFileStorageLocation) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if afsl.Type != nil {
+ objectMap["type"] = afsl.Type
+ }
+ if afsl.FolderPath != nil {
+ objectMap["folderPath"] = afsl.FolderPath
+ }
+ if afsl.FileName != nil {
+ objectMap["fileName"] = afsl.FileName
+ }
+ for k, v := range afsl.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureFileStorageLocation struct.
+func (afsl *AzureFileStorageLocation) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if afsl.AdditionalProperties == nil {
+ afsl.AdditionalProperties = make(map[string]interface{})
+ }
+ afsl.AdditionalProperties[k] = additionalProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ afsl.Type = &typeVar
+ }
+ case "folderPath":
+ if v != nil {
+ var folderPath interface{}
+ err = json.Unmarshal(*v, &folderPath)
+ if err != nil {
+ return err
+ }
+ afsl.FolderPath = folderPath
+ }
+ case "fileName":
+ if v != nil {
+ var fileName interface{}
+ err = json.Unmarshal(*v, &fileName)
+ if err != nil {
+ return err
+ }
+ afsl.FileName = fileName
+ }
+ }
+ }
+
+ return nil
+}
+
+// AzureFileStorageReadSettings azure File Storage read settings.
+type AzureFileStorageReadSettings struct {
+ // Recursive - If true, files under the folder path will be read recursively. Default is true. Type: boolean (or Expression with resultType boolean).
+ Recursive interface{} `json:"recursive,omitempty"`
+ // WildcardFolderPath - Azure File Storage wildcardFolderPath. Type: string (or Expression with resultType string).
+ WildcardFolderPath interface{} `json:"wildcardFolderPath,omitempty"`
+ // WildcardFileName - Azure File Storage wildcardFileName. Type: string (or Expression with resultType string).
+ WildcardFileName interface{} `json:"wildcardFileName,omitempty"`
+ // EnablePartitionDiscovery - Indicates whether to enable partition discovery.
+ EnablePartitionDiscovery *bool `json:"enablePartitionDiscovery,omitempty"`
+ // ModifiedDatetimeStart - The start of file's modified datetime. Type: string (or Expression with resultType string).
+ ModifiedDatetimeStart interface{} `json:"modifiedDatetimeStart,omitempty"`
+ // ModifiedDatetimeEnd - The end of file's modified datetime. Type: string (or Expression with resultType string).
+ ModifiedDatetimeEnd interface{} `json:"modifiedDatetimeEnd,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Type - The read setting type.
+ Type *string `json:"type,omitempty"`
+ // MaxConcurrentConnections - The maximum concurrent connection count for the source data store. Type: integer (or Expression with resultType integer).
+ MaxConcurrentConnections interface{} `json:"maxConcurrentConnections,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureFileStorageReadSettings.
+func (afsrs AzureFileStorageReadSettings) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if afsrs.Recursive != nil {
+ objectMap["recursive"] = afsrs.Recursive
+ }
+ if afsrs.WildcardFolderPath != nil {
+ objectMap["wildcardFolderPath"] = afsrs.WildcardFolderPath
+ }
+ if afsrs.WildcardFileName != nil {
+ objectMap["wildcardFileName"] = afsrs.WildcardFileName
+ }
+ if afsrs.EnablePartitionDiscovery != nil {
+ objectMap["enablePartitionDiscovery"] = afsrs.EnablePartitionDiscovery
+ }
+ if afsrs.ModifiedDatetimeStart != nil {
+ objectMap["modifiedDatetimeStart"] = afsrs.ModifiedDatetimeStart
+ }
+ if afsrs.ModifiedDatetimeEnd != nil {
+ objectMap["modifiedDatetimeEnd"] = afsrs.ModifiedDatetimeEnd
+ }
+ if afsrs.Type != nil {
+ objectMap["type"] = afsrs.Type
+ }
+ if afsrs.MaxConcurrentConnections != nil {
+ objectMap["maxConcurrentConnections"] = afsrs.MaxConcurrentConnections
+ }
+ for k, v := range afsrs.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureFileStorageReadSettings struct.
+func (afsrs *AzureFileStorageReadSettings) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "recursive":
+ if v != nil {
+ var recursive interface{}
+ err = json.Unmarshal(*v, &recursive)
+ if err != nil {
+ return err
+ }
+ afsrs.Recursive = recursive
+ }
+ case "wildcardFolderPath":
+ if v != nil {
+ var wildcardFolderPath interface{}
+ err = json.Unmarshal(*v, &wildcardFolderPath)
+ if err != nil {
+ return err
+ }
+ afsrs.WildcardFolderPath = wildcardFolderPath
+ }
+ case "wildcardFileName":
+ if v != nil {
+ var wildcardFileName interface{}
+ err = json.Unmarshal(*v, &wildcardFileName)
+ if err != nil {
+ return err
+ }
+ afsrs.WildcardFileName = wildcardFileName
+ }
+ case "enablePartitionDiscovery":
+ if v != nil {
+ var enablePartitionDiscovery bool
+ err = json.Unmarshal(*v, &enablePartitionDiscovery)
+ if err != nil {
+ return err
+ }
+ afsrs.EnablePartitionDiscovery = &enablePartitionDiscovery
+ }
+ case "modifiedDatetimeStart":
+ if v != nil {
+ var modifiedDatetimeStart interface{}
+ err = json.Unmarshal(*v, &modifiedDatetimeStart)
+ if err != nil {
+ return err
+ }
+ afsrs.ModifiedDatetimeStart = modifiedDatetimeStart
+ }
+ case "modifiedDatetimeEnd":
+ if v != nil {
+ var modifiedDatetimeEnd interface{}
+ err = json.Unmarshal(*v, &modifiedDatetimeEnd)
+ if err != nil {
+ return err
+ }
+ afsrs.ModifiedDatetimeEnd = modifiedDatetimeEnd
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if afsrs.AdditionalProperties == nil {
+ afsrs.AdditionalProperties = make(map[string]interface{})
+ }
+ afsrs.AdditionalProperties[k] = additionalProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ afsrs.Type = &typeVar
+ }
+ case "maxConcurrentConnections":
+ if v != nil {
+ var maxConcurrentConnections interface{}
+ err = json.Unmarshal(*v, &maxConcurrentConnections)
+ if err != nil {
+ return err
+ }
+ afsrs.MaxConcurrentConnections = maxConcurrentConnections
+ }
+ }
+ }
+
+ return nil
+}
+
// AzureFunctionActivity azure Function activity.
type AzureFunctionActivity struct {
// AzureFunctionActivityTypeProperties - Azure Function activity properties.
@@ -22635,7 +23761,7 @@ type AzureFunctionActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -22703,6 +23829,11 @@ func (afa AzureFunctionActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAna
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AzureFunctionActivity.
+func (afa AzureFunctionActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AzureFunctionActivity.
func (afa AzureFunctionActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -22833,6 +23964,11 @@ func (afa AzureFunctionActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for AzureFunctionActivity.
+func (afa AzureFunctionActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for AzureFunctionActivity.
func (afa AzureFunctionActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -22988,7 +24124,7 @@ type AzureFunctionLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -23360,6 +24496,11 @@ func (afls AzureFunctionLinkedService) AsOdbcLinkedService() (*OdbcLinkedService
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureFunctionLinkedService.
+func (afls AzureFunctionLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureFunctionLinkedService.
func (afls AzureFunctionLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -23400,6 +24541,16 @@ func (afls AzureFunctionLinkedService) AsOracleLinkedService() (*OracleLinkedSer
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureFunctionLinkedService.
+func (afls AzureFunctionLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureFunctionLinkedService.
+func (afls AzureFunctionLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureFunctionLinkedService.
func (afls AzureFunctionLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -23631,7 +24782,7 @@ type AzureKeyVaultLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -24003,6 +25154,11 @@ func (akvls AzureKeyVaultLinkedService) AsOdbcLinkedService() (*OdbcLinkedServic
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureKeyVaultLinkedService.
+func (akvls AzureKeyVaultLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureKeyVaultLinkedService.
func (akvls AzureKeyVaultLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -24043,6 +25199,16 @@ func (akvls AzureKeyVaultLinkedService) AsOracleLinkedService() (*OracleLinkedSe
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureKeyVaultLinkedService.
+func (akvls AzureKeyVaultLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureKeyVaultLinkedService.
+func (akvls AzureKeyVaultLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureKeyVaultLinkedService.
func (akvls AzureKeyVaultLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -24280,7 +25446,7 @@ type AzureMariaDBLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -24652,6 +25818,11 @@ func (amdls AzureMariaDBLinkedService) AsOdbcLinkedService() (*OdbcLinkedService
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureMariaDBLinkedService.
+func (amdls AzureMariaDBLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureMariaDBLinkedService.
func (amdls AzureMariaDBLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -24692,6 +25863,16 @@ func (amdls AzureMariaDBLinkedService) AsOracleLinkedService() (*OracleLinkedSer
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureMariaDBLinkedService.
+func (amdls AzureMariaDBLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureMariaDBLinkedService.
+func (amdls AzureMariaDBLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureMariaDBLinkedService.
func (amdls AzureMariaDBLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -26077,7 +27258,7 @@ type AzureMLBatchExecutionActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -26145,6 +27326,11 @@ func (ambea AzureMLBatchExecutionActivity) AsDataLakeAnalyticsUSQLActivity() (*D
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AzureMLBatchExecutionActivity.
+func (ambea AzureMLBatchExecutionActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AzureMLBatchExecutionActivity.
func (ambea AzureMLBatchExecutionActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -26275,6 +27461,11 @@ func (ambea AzureMLBatchExecutionActivity) AsForEachActivity() (*ForEachActivity
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for AzureMLBatchExecutionActivity.
+func (ambea AzureMLBatchExecutionActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for AzureMLBatchExecutionActivity.
func (ambea AzureMLBatchExecutionActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -26429,9 +27620,378 @@ func (ambeatp AzureMLBatchExecutionActivityTypeProperties) MarshalJSON() ([]byte
return json.Marshal(objectMap)
}
-// AzureMLLinkedService azure ML Web Service linked service.
+// AzureMLExecutePipelineActivity azure ML Execute Pipeline activity.
+type AzureMLExecutePipelineActivity struct {
+ // AzureMLExecutePipelineActivityTypeProperties - Azure ML Execute Pipeline activity properties.
+ *AzureMLExecutePipelineActivityTypeProperties `json:"typeProperties,omitempty"`
+ // LinkedServiceName - Linked service reference.
+ LinkedServiceName *LinkedServiceReference `json:"linkedServiceName,omitempty"`
+ // Policy - Activity policy.
+ Policy *ActivityPolicy `json:"policy,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Name - Activity name.
+ Name *string `json:"name,omitempty"`
+ // Description - Activity description.
+ Description *string `json:"description,omitempty"`
+ // DependsOn - Activity depends on condition.
+ DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
+ // UserProperties - Activity user properties.
+ UserProperties *[]UserProperty `json:"userProperties,omitempty"`
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ Type TypeBasicActivity `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) MarshalJSON() ([]byte, error) {
+ amepa.Type = TypeAzureMLExecutePipeline
+ objectMap := make(map[string]interface{})
+ if amepa.AzureMLExecutePipelineActivityTypeProperties != nil {
+ objectMap["typeProperties"] = amepa.AzureMLExecutePipelineActivityTypeProperties
+ }
+ if amepa.LinkedServiceName != nil {
+ objectMap["linkedServiceName"] = amepa.LinkedServiceName
+ }
+ if amepa.Policy != nil {
+ objectMap["policy"] = amepa.Policy
+ }
+ if amepa.Name != nil {
+ objectMap["name"] = amepa.Name
+ }
+ if amepa.Description != nil {
+ objectMap["description"] = amepa.Description
+ }
+ if amepa.DependsOn != nil {
+ objectMap["dependsOn"] = amepa.DependsOn
+ }
+ if amepa.UserProperties != nil {
+ objectMap["userProperties"] = amepa.UserProperties
+ }
+ if amepa.Type != "" {
+ objectMap["type"] = amepa.Type
+ }
+ for k, v := range amepa.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsExecuteDataFlowActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsExecuteDataFlowActivity() (*ExecuteDataFlowActivity, bool) {
+ return nil, false
+}
+
+// AsAzureFunctionActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAzureFunctionActivity() (*AzureFunctionActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkPythonActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsDatabricksSparkPythonActivity() (*DatabricksSparkPythonActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkJarActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksNotebookActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool) {
+ return nil, false
+}
+
+// AsDataLakeAnalyticsUSQLActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return &amepa, true
+}
+
+// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLBatchExecutionActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsGetMetadataActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsGetMetadataActivity() (*GetMetadataActivity, bool) {
+ return nil, false
+}
+
+// AsWebActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsWebActivity() (*WebActivity, bool) {
+ return nil, false
+}
+
+// AsLookupActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsLookupActivity() (*LookupActivity, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerCommandActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAzureDataExplorerCommandActivity() (*AzureDataExplorerCommandActivity, bool) {
+ return nil, false
+}
+
+// AsDeleteActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsDeleteActivity() (*DeleteActivity, bool) {
+ return nil, false
+}
+
+// AsSQLServerStoredProcedureActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsSQLServerStoredProcedureActivity() (*SQLServerStoredProcedureActivity, bool) {
+ return nil, false
+}
+
+// AsCustomActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsCustomActivity() (*CustomActivity, bool) {
+ return nil, false
+}
+
+// AsExecuteSSISPackageActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsExecuteSSISPackageActivity() (*ExecuteSSISPackageActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightSparkActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsHDInsightSparkActivity() (*HDInsightSparkActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightStreamingActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsHDInsightStreamingActivity() (*HDInsightStreamingActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightMapReduceActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsHDInsightMapReduceActivity() (*HDInsightMapReduceActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightPigActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsHDInsightPigActivity() (*HDInsightPigActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightHiveActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsHDInsightHiveActivity() (*HDInsightHiveActivity, bool) {
+ return nil, false
+}
+
+// AsCopyActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsCopyActivity() (*CopyActivity, bool) {
+ return nil, false
+}
+
+// AsExecutionActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsExecutionActivity() (*ExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsBasicExecutionActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsBasicExecutionActivity() (BasicExecutionActivity, bool) {
+ return &amepa, true
+}
+
+// AsWebHookActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsWebHookActivity() (*WebHookActivity, bool) {
+ return nil, false
+}
+
+// AsAppendVariableActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsAppendVariableActivity() (*AppendVariableActivity, bool) {
+ return nil, false
+}
+
+// AsSetVariableActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsSetVariableActivity() (*SetVariableActivity, bool) {
+ return nil, false
+}
+
+// AsFilterActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsFilterActivity() (*FilterActivity, bool) {
+ return nil, false
+}
+
+// AsValidationActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsValidationActivity() (*ValidationActivity, bool) {
+ return nil, false
+}
+
+// AsUntilActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsUntilActivity() (*UntilActivity, bool) {
+ return nil, false
+}
+
+// AsWaitActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsWaitActivity() (*WaitActivity, bool) {
+ return nil, false
+}
+
+// AsForEachActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsForEachActivity() (*ForEachActivity, bool) {
+ return nil, false
+}
+
+// AsSwitchActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
+// AsIfConditionActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
+ return nil, false
+}
+
+// AsExecutePipelineActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsExecutePipelineActivity() (*ExecutePipelineActivity, bool) {
+ return nil, false
+}
+
+// AsControlActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsControlActivity() (*ControlActivity, bool) {
+ return nil, false
+}
+
+// AsBasicControlActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsBasicControlActivity() (BasicControlActivity, bool) {
+ return nil, false
+}
+
+// AsActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsActivity() (*Activity, bool) {
+ return nil, false
+}
+
+// AsBasicActivity is the BasicActivity implementation for AzureMLExecutePipelineActivity.
+func (amepa AzureMLExecutePipelineActivity) AsBasicActivity() (BasicActivity, bool) {
+ return &amepa, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureMLExecutePipelineActivity struct.
+func (amepa *AzureMLExecutePipelineActivity) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var azureMLExecutePipelineActivityTypeProperties AzureMLExecutePipelineActivityTypeProperties
+ err = json.Unmarshal(*v, &azureMLExecutePipelineActivityTypeProperties)
+ if err != nil {
+ return err
+ }
+ amepa.AzureMLExecutePipelineActivityTypeProperties = &azureMLExecutePipelineActivityTypeProperties
+ }
+ case "linkedServiceName":
+ if v != nil {
+ var linkedServiceName LinkedServiceReference
+ err = json.Unmarshal(*v, &linkedServiceName)
+ if err != nil {
+ return err
+ }
+ amepa.LinkedServiceName = &linkedServiceName
+ }
+ case "policy":
+ if v != nil {
+ var policy ActivityPolicy
+ err = json.Unmarshal(*v, &policy)
+ if err != nil {
+ return err
+ }
+ amepa.Policy = &policy
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if amepa.AdditionalProperties == nil {
+ amepa.AdditionalProperties = make(map[string]interface{})
+ }
+ amepa.AdditionalProperties[k] = additionalProperties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ amepa.Name = &name
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ amepa.Description = &description
+ }
+ case "dependsOn":
+ if v != nil {
+ var dependsOn []ActivityDependency
+ err = json.Unmarshal(*v, &dependsOn)
+ if err != nil {
+ return err
+ }
+ amepa.DependsOn = &dependsOn
+ }
+ case "userProperties":
+ if v != nil {
+ var userProperties []UserProperty
+ err = json.Unmarshal(*v, &userProperties)
+ if err != nil {
+ return err
+ }
+ amepa.UserProperties = &userProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicActivity
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ amepa.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// AzureMLExecutePipelineActivityTypeProperties azure ML Execute Pipeline activity properties.
+type AzureMLExecutePipelineActivityTypeProperties struct {
+ // MlPipelineID - ID of the published Azure ML pipeline. Type: string (or Expression with resultType string).
+ MlPipelineID interface{} `json:"mlPipelineId,omitempty"`
+ // ExperimentName - Run history experiment name of the pipeline run. This information will be passed in the ExperimentName property of the published pipeline execution request. Type: string (or Expression with resultType string).
+ ExperimentName interface{} `json:"experimentName,omitempty"`
+ // MlPipelineParameters - Key,Value pairs to be passed to the published Azure ML pipeline endpoint. Keys must match the names of pipeline parameters defined in the published pipeline. Values will be passed in the ParameterAssignments property of the published pipeline execution request. Type: object with key value pairs (or Expression with resultType object).
+ MlPipelineParameters interface{} `json:"mlPipelineParameters,omitempty"`
+ // MlParentRunID - The parent Azure ML Service pipeline run id. This information will be passed in the ParentRunId property of the published pipeline execution request. Type: string (or Expression with resultType string).
+ MlParentRunID interface{} `json:"mlParentRunId,omitempty"`
+ // ContinueOnStepFailure - Whether to continue execution of other steps in the PipelineRun if a step fails. This information will be passed in the continueOnStepFailure property of the published pipeline execution request. Type: boolean (or Expression with resultType boolean).
+ ContinueOnStepFailure interface{} `json:"continueOnStepFailure,omitempty"`
+}
+
+// AzureMLLinkedService azure ML Studio Web Service linked service.
type AzureMLLinkedService struct {
- // AzureMLLinkedServiceTypeProperties - Azure ML Web Service linked service properties.
+ // AzureMLLinkedServiceTypeProperties - Azure ML Studio Web Service linked service properties.
*AzureMLLinkedServiceTypeProperties `json:"typeProperties,omitempty"`
// AdditionalProperties - Unmatched properties from the message are deserialized this collection
AdditionalProperties map[string]interface{} `json:""`
@@ -26443,7 +28003,7 @@ type AzureMLLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -26815,6 +28375,11 @@ func (amls AzureMLLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureMLLinkedService.
+func (amls AzureMLLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureMLLinkedService.
func (amls AzureMLLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return &amls, true
@@ -26855,6 +28420,16 @@ func (amls AzureMLLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureMLLinkedService.
+func (amls AzureMLLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureMLLinkedService.
+func (amls AzureMLLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureMLLinkedService.
func (amls AzureMLLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -27021,17 +28596,17 @@ func (amls *AzureMLLinkedService) UnmarshalJSON(body []byte) error {
return nil
}
-// AzureMLLinkedServiceTypeProperties azure ML Web Service linked service properties.
+// AzureMLLinkedServiceTypeProperties azure ML Studio Web Service linked service properties.
type AzureMLLinkedServiceTypeProperties struct {
- // MlEndpoint - The Batch Execution REST URL for an Azure ML Web Service endpoint. Type: string (or Expression with resultType string).
+ // MlEndpoint - The Batch Execution REST URL for an Azure ML Studio Web Service endpoint. Type: string (or Expression with resultType string).
MlEndpoint interface{} `json:"mlEndpoint,omitempty"`
// APIKey - The API key for accessing the Azure ML model endpoint.
APIKey BasicSecretBase `json:"apiKey,omitempty"`
- // UpdateResourceEndpoint - The Update Resource REST URL for an Azure ML Web Service endpoint. Type: string (or Expression with resultType string).
+ // UpdateResourceEndpoint - The Update Resource REST URL for an Azure ML Studio Web Service endpoint. Type: string (or Expression with resultType string).
UpdateResourceEndpoint interface{} `json:"updateResourceEndpoint,omitempty"`
- // ServicePrincipalID - The ID of the service principal used to authenticate against the ARM-based updateResourceEndpoint of an Azure ML web service. Type: string (or Expression with resultType string).
+ // ServicePrincipalID - The ID of the service principal used to authenticate against the ARM-based updateResourceEndpoint of an Azure ML Studio web service. Type: string (or Expression with resultType string).
ServicePrincipalID interface{} `json:"servicePrincipalId,omitempty"`
- // ServicePrincipalKey - The key of the service principal used to authenticate against the ARM-based updateResourceEndpoint of an Azure ML web service.
+ // ServicePrincipalKey - The key of the service principal used to authenticate against the ARM-based updateResourceEndpoint of an Azure ML Studio web service.
ServicePrincipalKey BasicSecretBase `json:"servicePrincipalKey,omitempty"`
// Tenant - The name or ID of the tenant to which the service principal belongs. Type: string (or Expression with resultType string).
Tenant interface{} `json:"tenant,omitempty"`
@@ -27115,6 +28690,708 @@ func (amlstp *AzureMLLinkedServiceTypeProperties) UnmarshalJSON(body []byte) err
return nil
}
+// AzureMLServiceLinkedService azure ML Service linked service.
+type AzureMLServiceLinkedService struct {
+ // AzureMLServiceLinkedServiceTypeProperties - Azure ML Service linked service properties.
+ *AzureMLServiceLinkedServiceTypeProperties `json:"typeProperties,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // ConnectVia - The integration runtime reference.
+ ConnectVia *IntegrationRuntimeReference `json:"connectVia,omitempty"`
+ // Description - Linked service description.
+ Description *string `json:"description,omitempty"`
+ // Parameters - Parameters for linked service.
+ Parameters map[string]*ParameterSpecification `json:"parameters"`
+ // Annotations - List of tags that can be used for describing the linked service.
+ Annotations *[]interface{} `json:"annotations,omitempty"`
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ Type TypeBasicLinkedService `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) MarshalJSON() ([]byte, error) {
+ amsls.Type = TypeAzureMLService
+ objectMap := make(map[string]interface{})
+ if amsls.AzureMLServiceLinkedServiceTypeProperties != nil {
+ objectMap["typeProperties"] = amsls.AzureMLServiceLinkedServiceTypeProperties
+ }
+ if amsls.ConnectVia != nil {
+ objectMap["connectVia"] = amsls.ConnectVia
+ }
+ if amsls.Description != nil {
+ objectMap["description"] = amsls.Description
+ }
+ if amsls.Parameters != nil {
+ objectMap["parameters"] = amsls.Parameters
+ }
+ if amsls.Annotations != nil {
+ objectMap["annotations"] = amsls.Annotations
+ }
+ if amsls.Type != "" {
+ objectMap["type"] = amsls.Type
+ }
+ for k, v := range amsls.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsAzureFunctionLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureFunctionLinkedService() (*AzureFunctionLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureDataExplorerLinkedService() (*AzureDataExplorerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapTableLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapTableLinkedService() (*SapTableLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleAdWordsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsGoogleAdWordsLinkedService() (*GoogleAdWordsLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleServiceCloudLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsOracleServiceCloudLinkedService() (*OracleServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsAXLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsDynamicsAXLinkedService() (*DynamicsAXLinkedService, bool) {
+ return nil, false
+}
+
+// AsResponsysLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsResponsysLinkedService() (*ResponsysLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDatabricksLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureDatabricksLinkedService() (*AzureDatabricksLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeAnalyticsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureDataLakeAnalyticsLinkedService() (*AzureDataLakeAnalyticsLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightOnDemandLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHDInsightOnDemandLinkedService() (*HDInsightOnDemandLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceMarketingCloudLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSalesforceMarketingCloudLinkedService() (*SalesforceMarketingCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsNetezzaLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsNetezzaLinkedService() (*NetezzaLinkedService, bool) {
+ return nil, false
+}
+
+// AsVerticaLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsVerticaLinkedService() (*VerticaLinkedService, bool) {
+ return nil, false
+}
+
+// AsZohoLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsZohoLinkedService() (*ZohoLinkedService, bool) {
+ return nil, false
+}
+
+// AsXeroLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsXeroLinkedService() (*XeroLinkedService, bool) {
+ return nil, false
+}
+
+// AsSquareLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSquareLinkedService() (*SquareLinkedService, bool) {
+ return nil, false
+}
+
+// AsSparkLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSparkLinkedService() (*SparkLinkedService, bool) {
+ return nil, false
+}
+
+// AsShopifyLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsShopifyLinkedService() (*ShopifyLinkedService, bool) {
+ return nil, false
+}
+
+// AsServiceNowLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsServiceNowLinkedService() (*ServiceNowLinkedService, bool) {
+ return nil, false
+}
+
+// AsQuickBooksLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsQuickBooksLinkedService() (*QuickBooksLinkedService, bool) {
+ return nil, false
+}
+
+// AsPrestoLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsPrestoLinkedService() (*PrestoLinkedService, bool) {
+ return nil, false
+}
+
+// AsPhoenixLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsPhoenixLinkedService() (*PhoenixLinkedService, bool) {
+ return nil, false
+}
+
+// AsPaypalLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsPaypalLinkedService() (*PaypalLinkedService, bool) {
+ return nil, false
+}
+
+// AsMarketoLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMarketoLinkedService() (*MarketoLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMariaDBLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureMariaDBLinkedService() (*AzureMariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMariaDBLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMariaDBLinkedService() (*MariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMagentoLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMagentoLinkedService() (*MagentoLinkedService, bool) {
+ return nil, false
+}
+
+// AsJiraLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsJiraLinkedService() (*JiraLinkedService, bool) {
+ return nil, false
+}
+
+// AsImpalaLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsImpalaLinkedService() (*ImpalaLinkedService, bool) {
+ return nil, false
+}
+
+// AsHubspotLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHubspotLinkedService() (*HubspotLinkedService, bool) {
+ return nil, false
+}
+
+// AsHiveLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHiveLinkedService() (*HiveLinkedService, bool) {
+ return nil, false
+}
+
+// AsHBaseLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHBaseLinkedService() (*HBaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsGreenplumLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsGreenplumLinkedService() (*GreenplumLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleBigQueryLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsGoogleBigQueryLinkedService() (*GoogleBigQueryLinkedService, bool) {
+ return nil, false
+}
+
+// AsEloquaLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsEloquaLinkedService() (*EloquaLinkedService, bool) {
+ return nil, false
+}
+
+// AsDrillLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsDrillLinkedService() (*DrillLinkedService, bool) {
+ return nil, false
+}
+
+// AsCouchbaseLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCouchbaseLinkedService() (*CouchbaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsConcurLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsConcurLinkedService() (*ConcurLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzurePostgreSQLLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzurePostgreSQLLinkedService() (*AzurePostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonMWSLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAmazonMWSLinkedService() (*AmazonMWSLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapHanaLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapHanaLinkedService() (*SapHanaLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapBWLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapBWLinkedService() (*SapBWLinkedService, bool) {
+ return nil, false
+}
+
+// AsSftpServerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSftpServerLinkedService() (*SftpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsFtpServerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsFtpServerLinkedService() (*FtpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHTTPLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHTTPLinkedService() (*HTTPLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSearchLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureSearchLinkedService() (*AzureSearchLinkedService, bool) {
+ return nil, false
+}
+
+// AsCustomDataSourceLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCustomDataSourceLinkedService() (*CustomDataSourceLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonRedshiftLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAmazonRedshiftLinkedService() (*AmazonRedshiftLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonS3LinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAmazonS3LinkedService() (*AmazonS3LinkedService, bool) {
+ return nil, false
+}
+
+// AsRestServiceLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsRestServiceLinkedService() (*RestServiceLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapOpenHubLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapOpenHubLinkedService() (*SapOpenHubLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapEccLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapEccLinkedService() (*SapEccLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapCloudForCustomerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSapCloudForCustomerLinkedService() (*SapCloudForCustomerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceServiceCloudLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSalesforceServiceCloudLinkedService() (*SalesforceServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSalesforceLinkedService() (*SalesforceLinkedService, bool) {
+ return nil, false
+}
+
+// AsOffice365LinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsOffice365LinkedService() (*Office365LinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobFSLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureBlobFSLinkedService() (*AzureBlobFSLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeStoreLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureDataLakeStoreLinkedService() (*AzureDataLakeStoreLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbMongoDbAPILinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCosmosDbMongoDbAPILinkedService() (*CosmosDbMongoDbAPILinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbV2LinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMongoDbV2LinkedService() (*MongoDbV2LinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMongoDbLinkedService() (*MongoDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsCassandraLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCassandraLinkedService() (*CassandraLinkedService, bool) {
+ return nil, false
+}
+
+// AsWebLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsWebLinkedService() (*WebLinkedService, bool) {
+ return nil, false
+}
+
+// AsODataLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsODataLinkedService() (*ODataLinkedService, bool) {
+ return nil, false
+}
+
+// AsHdfsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHdfsLinkedService() (*HdfsLinkedService, bool) {
+ return nil, false
+}
+
+// AsMicrosoftAccessLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMicrosoftAccessLinkedService() (*MicrosoftAccessLinkedService, bool) {
+ return nil, false
+}
+
+// AsInformixLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsInformixLinkedService() (*InformixLinkedService, bool) {
+ return nil, false
+}
+
+// AsOdbcLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return &amsls, true
+}
+
+// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
+ return nil, false
+}
+
+// AsTeradataLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsTeradataLinkedService() (*TeradataLinkedService, bool) {
+ return nil, false
+}
+
+// AsDb2LinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsDb2LinkedService() (*Db2LinkedService, bool) {
+ return nil, false
+}
+
+// AsSybaseLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSybaseLinkedService() (*SybaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsPostgreSQLLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsPostgreSQLLinkedService() (*PostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsMySQLLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsMySQLLinkedService() (*MySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMySQLLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureMySQLLinkedService() (*AzureMySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsFileServerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsHDInsightLinkedService() (*HDInsightLinkedService, bool) {
+ return nil, false
+}
+
+// AsCommonDataServiceForAppsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCommonDataServiceForAppsLinkedService() (*CommonDataServiceForAppsLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsCrmLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsDynamicsCrmLinkedService() (*DynamicsCrmLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsDynamicsLinkedService() (*DynamicsLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsCosmosDbLinkedService() (*CosmosDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureKeyVaultLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureKeyVaultLinkedService() (*AzureKeyVaultLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBatchLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureBatchLinkedService() (*AzureBatchLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLMILinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureSQLMILinkedService() (*AzureSQLMILinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDatabaseLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureSQLDatabaseLinkedService() (*AzureSQLDatabaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsSQLServerLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsSQLServerLinkedService() (*SQLServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDWLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureSQLDWLinkedService() (*AzureSQLDWLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureTableStorageLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureTableStorageLinkedService() (*AzureTableStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobStorageLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureBlobStorageLinkedService() (*AzureBlobStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureStorageLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsAzureStorageLinkedService() (*AzureStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsLinkedService() (*LinkedService, bool) {
+ return nil, false
+}
+
+// AsBasicLinkedService is the BasicLinkedService implementation for AzureMLServiceLinkedService.
+func (amsls AzureMLServiceLinkedService) AsBasicLinkedService() (BasicLinkedService, bool) {
+ return &amsls, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureMLServiceLinkedService struct.
+func (amsls *AzureMLServiceLinkedService) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var azureMLServiceLinkedServiceTypeProperties AzureMLServiceLinkedServiceTypeProperties
+ err = json.Unmarshal(*v, &azureMLServiceLinkedServiceTypeProperties)
+ if err != nil {
+ return err
+ }
+ amsls.AzureMLServiceLinkedServiceTypeProperties = &azureMLServiceLinkedServiceTypeProperties
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if amsls.AdditionalProperties == nil {
+ amsls.AdditionalProperties = make(map[string]interface{})
+ }
+ amsls.AdditionalProperties[k] = additionalProperties
+ }
+ case "connectVia":
+ if v != nil {
+ var connectVia IntegrationRuntimeReference
+ err = json.Unmarshal(*v, &connectVia)
+ if err != nil {
+ return err
+ }
+ amsls.ConnectVia = &connectVia
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ amsls.Description = &description
+ }
+ case "parameters":
+ if v != nil {
+ var parameters map[string]*ParameterSpecification
+ err = json.Unmarshal(*v, ¶meters)
+ if err != nil {
+ return err
+ }
+ amsls.Parameters = parameters
+ }
+ case "annotations":
+ if v != nil {
+ var annotations []interface{}
+ err = json.Unmarshal(*v, &annotations)
+ if err != nil {
+ return err
+ }
+ amsls.Annotations = &annotations
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicLinkedService
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ amsls.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// AzureMLServiceLinkedServiceTypeProperties azure ML Service linked service properties.
+type AzureMLServiceLinkedServiceTypeProperties struct {
+ // SubscriptionID - Azure ML Service workspace subscription ID. Type: string (or Expression with resultType string).
+ SubscriptionID interface{} `json:"subscriptionId,omitempty"`
+ // ResourceGroupName - Azure ML Service workspace resource group name. Type: string (or Expression with resultType string).
+ ResourceGroupName interface{} `json:"resourceGroupName,omitempty"`
+ // MlWorkspaceName - Azure ML Service workspace name. Type: string (or Expression with resultType string).
+ MlWorkspaceName interface{} `json:"mlWorkspaceName,omitempty"`
+ // ServicePrincipalID - The ID of the service principal used to authenticate against the endpoint of a published Azure ML Service pipeline. Type: string (or Expression with resultType string).
+ ServicePrincipalID interface{} `json:"servicePrincipalId,omitempty"`
+ // ServicePrincipalKey - The key of the service principal used to authenticate against the endpoint of a published Azure ML Service pipeline.
+ ServicePrincipalKey BasicSecretBase `json:"servicePrincipalKey,omitempty"`
+ // Tenant - The name or ID of the tenant to which the service principal belongs. Type: string (or Expression with resultType string).
+ Tenant interface{} `json:"tenant,omitempty"`
+ // EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
+ EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for AzureMLServiceLinkedServiceTypeProperties struct.
+func (amslstp *AzureMLServiceLinkedServiceTypeProperties) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "subscriptionId":
+ if v != nil {
+ var subscriptionID interface{}
+ err = json.Unmarshal(*v, &subscriptionID)
+ if err != nil {
+ return err
+ }
+ amslstp.SubscriptionID = subscriptionID
+ }
+ case "resourceGroupName":
+ if v != nil {
+ var resourceGroupName interface{}
+ err = json.Unmarshal(*v, &resourceGroupName)
+ if err != nil {
+ return err
+ }
+ amslstp.ResourceGroupName = resourceGroupName
+ }
+ case "mlWorkspaceName":
+ if v != nil {
+ var mlWorkspaceName interface{}
+ err = json.Unmarshal(*v, &mlWorkspaceName)
+ if err != nil {
+ return err
+ }
+ amslstp.MlWorkspaceName = mlWorkspaceName
+ }
+ case "servicePrincipalId":
+ if v != nil {
+ var servicePrincipalID interface{}
+ err = json.Unmarshal(*v, &servicePrincipalID)
+ if err != nil {
+ return err
+ }
+ amslstp.ServicePrincipalID = servicePrincipalID
+ }
+ case "servicePrincipalKey":
+ if v != nil {
+ servicePrincipalKey, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ amslstp.ServicePrincipalKey = servicePrincipalKey
+ }
+ case "tenant":
+ if v != nil {
+ var tenant interface{}
+ err = json.Unmarshal(*v, &tenant)
+ if err != nil {
+ return err
+ }
+ amslstp.Tenant = tenant
+ }
+ case "encryptedCredential":
+ if v != nil {
+ var encryptedCredential interface{}
+ err = json.Unmarshal(*v, &encryptedCredential)
+ if err != nil {
+ return err
+ }
+ amslstp.EncryptedCredential = encryptedCredential
+ }
+ }
+ }
+
+ return nil
+}
+
// AzureMLUpdateResourceActivity azure ML Update Resource management activity.
type AzureMLUpdateResourceActivity struct {
// AzureMLUpdateResourceActivityTypeProperties - Azure ML Update Resource management activity properties.
@@ -27133,7 +29410,7 @@ type AzureMLUpdateResourceActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -27201,6 +29478,11 @@ func (amura AzureMLUpdateResourceActivity) AsDataLakeAnalyticsUSQLActivity() (*D
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for AzureMLUpdateResourceActivity.
+func (amura AzureMLUpdateResourceActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for AzureMLUpdateResourceActivity.
func (amura AzureMLUpdateResourceActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return &amura, true
@@ -27331,6 +29613,11 @@ func (amura AzureMLUpdateResourceActivity) AsForEachActivity() (*ForEachActivity
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for AzureMLUpdateResourceActivity.
+func (amura AzureMLUpdateResourceActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for AzureMLUpdateResourceActivity.
func (amura AzureMLUpdateResourceActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -27492,7 +29779,7 @@ type AzureMySQLLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -27864,6 +30151,11 @@ func (amsls AzureMySQLLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureMySQLLinkedService.
+func (amsls AzureMySQLLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureMySQLLinkedService.
func (amsls AzureMySQLLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -27904,6 +30196,16 @@ func (amsls AzureMySQLLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureMySQLLinkedService.
+func (amsls AzureMySQLLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureMySQLLinkedService.
+func (amsls AzureMySQLLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureMySQLLinkedService.
func (amsls AzureMySQLLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -29596,6 +31898,8 @@ func (amstd *AzureMySQLTableDataset) UnmarshalJSON(body []byte) error {
type AzureMySQLTableDatasetTypeProperties struct {
// TableName - The Azure MySQL database table name. Type: string (or Expression with resultType string).
TableName interface{} `json:"tableName,omitempty"`
+ // Table - The name of Azure MySQL database table. Type: string (or Expression with resultType string).
+ Table interface{} `json:"table,omitempty"`
}
// AzurePostgreSQLLinkedService azure PostgreSQL linked service.
@@ -29612,7 +31916,7 @@ type AzurePostgreSQLLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -29984,6 +32288,11 @@ func (apsls AzurePostgreSQLLinkedService) AsOdbcLinkedService() (*OdbcLinkedServ
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzurePostgreSQLLinkedService.
+func (apsls AzurePostgreSQLLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzurePostgreSQLLinkedService.
func (apsls AzurePostgreSQLLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -30024,6 +32333,16 @@ func (apsls AzurePostgreSQLLinkedService) AsOracleLinkedService() (*OracleLinked
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzurePostgreSQLLinkedService.
+func (apsls AzurePostgreSQLLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzurePostgreSQLLinkedService.
+func (apsls AzurePostgreSQLLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzurePostgreSQLLinkedService.
func (apsls AzurePostgreSQLLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -32984,7 +35303,7 @@ type AzureSearchLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -33356,6 +35675,11 @@ func (asls AzureSearchLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureSearchLinkedService.
+func (asls AzureSearchLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureSearchLinkedService.
func (asls AzureSearchLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -33396,6 +35720,16 @@ func (asls AzureSearchLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureSearchLinkedService.
+func (asls AzureSearchLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureSearchLinkedService.
+func (asls AzureSearchLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureSearchLinkedService.
func (asls AzureSearchLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -33627,7 +35961,7 @@ type AzureSQLDatabaseLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -33999,6 +36333,11 @@ func (asdls AzureSQLDatabaseLinkedService) AsOdbcLinkedService() (*OdbcLinkedSer
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureSQLDatabaseLinkedService.
+func (asdls AzureSQLDatabaseLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureSQLDatabaseLinkedService.
func (asdls AzureSQLDatabaseLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -34039,6 +36378,16 @@ func (asdls AzureSQLDatabaseLinkedService) AsOracleLinkedService() (*OracleLinke
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureSQLDatabaseLinkedService.
+func (asdls AzureSQLDatabaseLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureSQLDatabaseLinkedService.
+func (asdls AzureSQLDatabaseLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureSQLDatabaseLinkedService.
func (asdls AzureSQLDatabaseLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -34303,7 +36652,7 @@ type AzureSQLDWLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -34675,6 +37024,11 @@ func (asdls AzureSQLDWLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureSQLDWLinkedService.
+func (asdls AzureSQLDWLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureSQLDWLinkedService.
func (asdls AzureSQLDWLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -34715,6 +37069,16 @@ func (asdls AzureSQLDWLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureSQLDWLinkedService.
+func (asdls AzureSQLDWLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureSQLDWLinkedService.
+func (asdls AzureSQLDWLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureSQLDWLinkedService.
func (asdls AzureSQLDWLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -35603,7 +37967,7 @@ type AzureSQLMILinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -35975,6 +38339,11 @@ func (asmls AzureSQLMILinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureSQLMILinkedService.
+func (asmls AzureSQLMILinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureSQLMILinkedService.
func (asmls AzureSQLMILinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -36015,6 +38384,16 @@ func (asmls AzureSQLMILinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureSQLMILinkedService.
+func (asmls AzureSQLMILinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureSQLMILinkedService.
+func (asmls AzureSQLMILinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureSQLMILinkedService.
func (asmls AzureSQLMILinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -38537,7 +40916,7 @@ type AzureStorageLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -38909,6 +41288,11 @@ func (asls AzureStorageLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureStorageLinkedService.
+func (asls AzureStorageLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureStorageLinkedService.
func (asls AzureStorageLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -38949,6 +41333,16 @@ func (asls AzureStorageLinkedService) AsOracleLinkedService() (*OracleLinkedServ
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureStorageLinkedService.
+func (asls AzureStorageLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureStorageLinkedService.
+func (asls AzureStorageLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureStorageLinkedService.
func (asls AzureStorageLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -40717,7 +43111,7 @@ type AzureTableStorageLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -41089,6 +43483,11 @@ func (atsls AzureTableStorageLinkedService) AsOdbcLinkedService() (*OdbcLinkedSe
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for AzureTableStorageLinkedService.
+func (atsls AzureTableStorageLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for AzureTableStorageLinkedService.
func (atsls AzureTableStorageLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -41129,6 +43528,16 @@ func (atsls AzureTableStorageLinkedService) AsOracleLinkedService() (*OracleLink
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for AzureTableStorageLinkedService.
+func (atsls AzureTableStorageLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for AzureTableStorageLinkedService.
+func (atsls AzureTableStorageLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for AzureTableStorageLinkedService.
func (atsls AzureTableStorageLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -43010,6 +45419,8 @@ type BlobEventsTriggerTypeProperties struct {
BlobPathBeginsWith *string `json:"blobPathBeginsWith,omitempty"`
// BlobPathEndsWith - The blob path must end with the pattern provided for trigger to fire. For example, 'december/boxes.csv' will only fire the trigger for blobs named boxes in a december folder. At least one of these must be provided: blobPathBeginsWith, blobPathEndsWith.
BlobPathEndsWith *string `json:"blobPathEndsWith,omitempty"`
+ // IgnoreEmptyBlobs - If set to true, blobs with zero bytes will be ignored.
+ IgnoreEmptyBlobs *bool `json:"ignoreEmptyBlobs,omitempty"`
// Events - The type of events that cause this trigger to fire.
Events *[]BlobEventTypes `json:"events,omitempty"`
// Scope - The ARM resource ID of the Storage Account.
@@ -44168,7 +46579,7 @@ type CassandraLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -44540,6 +46951,11 @@ func (cls CassandraLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CassandraLinkedService.
+func (cls CassandraLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CassandraLinkedService.
func (cls CassandraLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -44580,6 +46996,16 @@ func (cls CassandraLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CassandraLinkedService.
+func (cls CassandraLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CassandraLinkedService.
+func (cls CassandraLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CassandraLinkedService.
func (cls CassandraLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -47044,7 +49470,7 @@ type CommonDataServiceForAppsLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -47416,6 +49842,11 @@ func (cdsfals CommonDataServiceForAppsLinkedService) AsOdbcLinkedService() (*Odb
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CommonDataServiceForAppsLinkedService.
+func (cdsfals CommonDataServiceForAppsLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CommonDataServiceForAppsLinkedService.
func (cdsfals CommonDataServiceForAppsLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -47456,6 +49887,16 @@ func (cdsfals CommonDataServiceForAppsLinkedService) AsOracleLinkedService() (*O
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CommonDataServiceForAppsLinkedService.
+func (cdsfals CommonDataServiceForAppsLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CommonDataServiceForAppsLinkedService.
+func (cdsfals CommonDataServiceForAppsLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CommonDataServiceForAppsLinkedService.
func (cdsfals CommonDataServiceForAppsLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -47635,12 +50076,18 @@ type CommonDataServiceForAppsLinkedServiceTypeProperties struct {
ServiceURI interface{} `json:"serviceUri,omitempty"`
// OrganizationName - The organization name of the Common Data Service for Apps instance. The property is required for on-prem and required for online when there are more than one Common Data Service for Apps instances associated with the user. Type: string (or Expression with resultType string).
OrganizationName interface{} `json:"organizationName,omitempty"`
- // AuthenticationType - The authentication type to connect to Common Data Service for Apps server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario. Type: string (or Expression with resultType string). Possible values include: 'Office365', 'Ifd'
+ // AuthenticationType - The authentication type to connect to Common Data Service for Apps server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario. 'AADServicePrincipal' for Server-To-Server authentication in online scenario. Type: string (or Expression with resultType string). Possible values include: 'Office365', 'Ifd', 'AADServicePrincipal'
AuthenticationType DynamicsAuthenticationType `json:"authenticationType,omitempty"`
// Username - User name to access the Common Data Service for Apps instance. Type: string (or Expression with resultType string).
Username interface{} `json:"username,omitempty"`
// Password - Password to access the Common Data Service for Apps instance.
Password BasicSecretBase `json:"password,omitempty"`
+ // ServicePrincipalID - The client ID of the application in Azure Active Directory used for Server-To-Server authentication. Type: string (or Expression with resultType string).
+ ServicePrincipalID interface{} `json:"servicePrincipalId,omitempty"`
+ // ServicePrincipalCredentialType - The service principal credential type to use in Server-To-Server authentication. 'ServicePrincipalKey' for key/secret, 'ServicePrincipalCert' for certificate. Type: string (or Expression with resultType string).
+ ServicePrincipalCredentialType interface{} `json:"servicePrincipalCredentialType,omitempty"`
+ // ServicePrincipalCredential - The credential of the service principal object in Azure Active Directory. If servicePrincipalCredentialType is 'ServicePrincipalKey', servicePrincipalCredential can be SecureString or AzureKeyVaultSecretReference. If servicePrincipalCredentialType is 'ServicePrincipalCert', servicePrincipalCredential can only be AzureKeyVaultSecretReference.
+ ServicePrincipalCredential BasicSecretBase `json:"servicePrincipalCredential,omitempty"`
// EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
}
@@ -47725,6 +50172,32 @@ func (cdsfalstp *CommonDataServiceForAppsLinkedServiceTypeProperties) UnmarshalJ
}
cdsfalstp.Password = password
}
+ case "servicePrincipalId":
+ if v != nil {
+ var servicePrincipalID interface{}
+ err = json.Unmarshal(*v, &servicePrincipalID)
+ if err != nil {
+ return err
+ }
+ cdsfalstp.ServicePrincipalID = servicePrincipalID
+ }
+ case "servicePrincipalCredentialType":
+ if v != nil {
+ var servicePrincipalCredentialType interface{}
+ err = json.Unmarshal(*v, &servicePrincipalCredentialType)
+ if err != nil {
+ return err
+ }
+ cdsfalstp.ServicePrincipalCredentialType = servicePrincipalCredentialType
+ }
+ case "servicePrincipalCredential":
+ if v != nil {
+ servicePrincipalCredential, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ cdsfalstp.ServicePrincipalCredential = servicePrincipalCredential
+ }
case "encryptedCredential":
if v != nil {
var encryptedCredential interface{}
@@ -48745,7 +51218,7 @@ type ConcurLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -49117,6 +51590,11 @@ func (cls ConcurLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ConcurLinkedService.
+func (cls ConcurLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ConcurLinkedService.
func (cls ConcurLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -49157,6 +51635,16 @@ func (cls ConcurLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ConcurLinkedService.
+func (cls ConcurLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ConcurLinkedService.
+func (cls ConcurLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ConcurLinkedService.
func (cls ConcurLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -50619,6 +53107,7 @@ type BasicControlActivity interface {
AsUntilActivity() (*UntilActivity, bool)
AsWaitActivity() (*WaitActivity, bool)
AsForEachActivity() (*ForEachActivity, bool)
+ AsSwitchActivity() (*SwitchActivity, bool)
AsIfConditionActivity() (*IfConditionActivity, bool)
AsExecutePipelineActivity() (*ExecutePipelineActivity, bool)
AsControlActivity() (*ControlActivity, bool)
@@ -50636,7 +53125,7 @@ type ControlActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -50680,6 +53169,10 @@ func unmarshalBasicControlActivity(body []byte) (BasicControlActivity, error) {
var fea ForEachActivity
err := json.Unmarshal(body, &fea)
return fea, err
+ case string(TypeSwitch):
+ var sa SwitchActivity
+ err := json.Unmarshal(body, &sa)
+ return sa, err
case string(TypeIfCondition):
var ica IfConditionActivity
err := json.Unmarshal(body, &ica)
@@ -50768,6 +53261,11 @@ func (ca ControlActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsU
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ControlActivity.
+func (ca ControlActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ControlActivity.
func (ca ControlActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -50898,6 +53396,11 @@ func (ca ControlActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ControlActivity.
+func (ca ControlActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ControlActivity.
func (ca ControlActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -51022,7 +53525,7 @@ type CopyActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -51096,6 +53599,11 @@ func (ca CopyActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQL
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for CopyActivity.
+func (ca CopyActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for CopyActivity.
func (ca CopyActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -51226,6 +53734,11 @@ func (ca CopyActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for CopyActivity.
+func (ca CopyActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for CopyActivity.
func (ca CopyActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -53063,7 +55576,7 @@ type CosmosDbLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -53435,6 +55948,11 @@ func (cdls CosmosDbLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CosmosDbLinkedService.
+func (cdls CosmosDbLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CosmosDbLinkedService.
func (cdls CosmosDbLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -53475,6 +55993,16 @@ func (cdls CosmosDbLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CosmosDbLinkedService.
+func (cdls CosmosDbLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CosmosDbLinkedService.
+func (cdls CosmosDbLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CosmosDbLinkedService.
func (cdls CosmosDbLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -54348,7 +56876,7 @@ type CosmosDbMongoDbAPILinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -54720,6 +57248,11 @@ func (cdmdals CosmosDbMongoDbAPILinkedService) AsOdbcLinkedService() (*OdbcLinke
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CosmosDbMongoDbAPILinkedService.
+func (cdmdals CosmosDbMongoDbAPILinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CosmosDbMongoDbAPILinkedService.
func (cdmdals CosmosDbMongoDbAPILinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -54760,6 +57293,16 @@ func (cdmdals CosmosDbMongoDbAPILinkedService) AsOracleLinkedService() (*OracleL
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CosmosDbMongoDbAPILinkedService.
+func (cdmdals CosmosDbMongoDbAPILinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CosmosDbMongoDbAPILinkedService.
+func (cdmdals CosmosDbMongoDbAPILinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CosmosDbMongoDbAPILinkedService.
func (cdmdals CosmosDbMongoDbAPILinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -57406,7 +59949,7 @@ type CouchbaseLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -57778,6 +60321,11 @@ func (cls CouchbaseLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CouchbaseLinkedService.
+func (cls CouchbaseLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CouchbaseLinkedService.
func (cls CouchbaseLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -57818,6 +60366,16 @@ func (cls CouchbaseLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CouchbaseLinkedService.
+func (cls CouchbaseLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CouchbaseLinkedService.
+func (cls CouchbaseLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CouchbaseLinkedService.
func (cls CouchbaseLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -59194,7 +61752,7 @@ type CreateDataFlowDebugSessionRequest struct {
// TimeToLive - Time to live setting of the cluster in minutes.
TimeToLive *int32 `json:"timeToLive,omitempty"`
// IntegrationRuntime - Set to use integration runtime setting for data flow debug session.
- IntegrationRuntime *IntegrationRuntimeResource `json:"integrationRuntime,omitempty"`
+ IntegrationRuntime *IntegrationRuntimeDebugResource `json:"integrationRuntime,omitempty"`
}
// CreateDataFlowDebugSessionResponse response body structure for creating data flow debug session.
@@ -59243,7 +61801,7 @@ type CustomActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -59311,6 +61869,11 @@ func (ca CustomActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUS
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for CustomActivity.
+func (ca CustomActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for CustomActivity.
func (ca CustomActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -59441,6 +62004,11 @@ func (ca CustomActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for CustomActivity.
+func (ca CustomActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for CustomActivity.
func (ca CustomActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -60246,7 +62814,7 @@ type CustomDataSourceLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -60618,6 +63186,11 @@ func (cdsls CustomDataSourceLinkedService) AsOdbcLinkedService() (*OdbcLinkedSer
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for CustomDataSourceLinkedService.
+func (cdsls CustomDataSourceLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for CustomDataSourceLinkedService.
func (cdsls CustomDataSourceLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -60658,6 +63231,16 @@ func (cdsls CustomDataSourceLinkedService) AsOracleLinkedService() (*OracleLinke
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for CustomDataSourceLinkedService.
+func (cdsls CustomDataSourceLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for CustomDataSourceLinkedService.
+func (cdsls CustomDataSourceLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for CustomDataSourceLinkedService.
func (cdsls CustomDataSourceLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -60936,7 +63519,7 @@ type DatabricksNotebookActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -61004,6 +63587,11 @@ func (dna DatabricksNotebookActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLa
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for DatabricksNotebookActivity.
+func (dna DatabricksNotebookActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for DatabricksNotebookActivity.
func (dna DatabricksNotebookActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -61134,6 +63722,11 @@ func (dna DatabricksNotebookActivity) AsForEachActivity() (*ForEachActivity, boo
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for DatabricksNotebookActivity.
+func (dna DatabricksNotebookActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for DatabricksNotebookActivity.
func (dna DatabricksNotebookActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -61306,7 +63899,7 @@ type DatabricksSparkJarActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -61374,6 +63967,11 @@ func (dsja DatabricksSparkJarActivity) AsDataLakeAnalyticsUSQLActivity() (*DataL
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for DatabricksSparkJarActivity.
+func (dsja DatabricksSparkJarActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for DatabricksSparkJarActivity.
func (dsja DatabricksSparkJarActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -61504,6 +64102,11 @@ func (dsja DatabricksSparkJarActivity) AsForEachActivity() (*ForEachActivity, bo
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for DatabricksSparkJarActivity.
+func (dsja DatabricksSparkJarActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for DatabricksSparkJarActivity.
func (dsja DatabricksSparkJarActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -61661,7 +64264,7 @@ type DatabricksSparkPythonActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -61729,6 +64332,11 @@ func (dspa DatabricksSparkPythonActivity) AsDataLakeAnalyticsUSQLActivity() (*Da
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for DatabricksSparkPythonActivity.
+func (dspa DatabricksSparkPythonActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for DatabricksSparkPythonActivity.
func (dspa DatabricksSparkPythonActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -61859,6 +64467,11 @@ func (dspa DatabricksSparkPythonActivity) AsForEachActivity() (*ForEachActivity,
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for DatabricksSparkPythonActivity.
+func (dspa DatabricksSparkPythonActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for DatabricksSparkPythonActivity.
func (dspa DatabricksSparkPythonActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -62126,11 +64739,11 @@ type DataFlowDebugPackage struct {
// SessionID - The ID of data flow debug session.
SessionID *string `json:"sessionId,omitempty"`
// DataFlow - Data flow instance.
- DataFlow *DataFlowResource `json:"dataFlow,omitempty"`
+ DataFlow *DataFlowDebugResource `json:"dataFlow,omitempty"`
// Datasets - List of datasets.
- Datasets *[]DatasetResource `json:"datasets,omitempty"`
+ Datasets *[]DatasetDebugResource `json:"datasets,omitempty"`
// LinkedServices - List of linked services.
- LinkedServices *[]LinkedServiceResource `json:"linkedServices,omitempty"`
+ LinkedServices *[]LinkedServiceDebugResource `json:"linkedServices,omitempty"`
// Staging - Staging info for debug session.
Staging *DataFlowStagingInfo `json:"staging,omitempty"`
// DebugSettings - Data flow debug settings.
@@ -62196,7 +64809,7 @@ func (dfdp *DataFlowDebugPackage) UnmarshalJSON(body []byte) error {
}
case "dataFlow":
if v != nil {
- var dataFlow DataFlowResource
+ var dataFlow DataFlowDebugResource
err = json.Unmarshal(*v, &dataFlow)
if err != nil {
return err
@@ -62205,7 +64818,7 @@ func (dfdp *DataFlowDebugPackage) UnmarshalJSON(body []byte) error {
}
case "datasets":
if v != nil {
- var datasets []DatasetResource
+ var datasets []DatasetDebugResource
err = json.Unmarshal(*v, &datasets)
if err != nil {
return err
@@ -62214,7 +64827,7 @@ func (dfdp *DataFlowDebugPackage) UnmarshalJSON(body []byte) error {
}
case "linkedServices":
if v != nil {
- var linkedServices []LinkedServiceResource
+ var linkedServices []LinkedServiceDebugResource
err = json.Unmarshal(*v, &linkedServices)
if err != nil {
return err
@@ -62270,6 +64883,46 @@ func (dfdpS DataFlowDebugPackageDebugSettings) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// DataFlowDebugResource data flow debug resource.
+type DataFlowDebugResource struct {
+ // Properties - Data flow properties.
+ Properties BasicDataFlow `json:"properties,omitempty"`
+ // Name - The resource name.
+ Name *string `json:"name,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for DataFlowDebugResource struct.
+func (dfdr *DataFlowDebugResource) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "properties":
+ if v != nil {
+ properties, err := unmarshalBasicDataFlow(*v)
+ if err != nil {
+ return err
+ }
+ dfdr.Properties = properties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ dfdr.Name = &name
+ }
+ }
+ }
+
+ return nil
+}
+
// DataFlowDebugSessionCreateFuture an abstraction for monitoring and retrieving the results of a
// long-running operation.
type DataFlowDebugSessionCreateFuture struct {
@@ -62849,7 +65502,7 @@ type DataLakeAnalyticsUSQLActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -62917,6 +65570,11 @@ func (dlaua DataLakeAnalyticsUSQLActivity) AsDataLakeAnalyticsUSQLActivity() (*D
return &dlaua, true
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for DataLakeAnalyticsUSQLActivity.
+func (dlaua DataLakeAnalyticsUSQLActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for DataLakeAnalyticsUSQLActivity.
func (dlaua DataLakeAnalyticsUSQLActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -63047,6 +65705,11 @@ func (dlaua DataLakeAnalyticsUSQLActivity) AsForEachActivity() (*ForEachActivity
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for DataLakeAnalyticsUSQLActivity.
+func (dlaua DataLakeAnalyticsUSQLActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for DataLakeAnalyticsUSQLActivity.
func (dlaua DataLakeAnalyticsUSQLActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -64528,6 +67191,46 @@ func (dc *DatasetCompression) UnmarshalJSON(body []byte) error {
return nil
}
+// DatasetDebugResource dataset debug resource.
+type DatasetDebugResource struct {
+ // Properties - Dataset properties.
+ Properties BasicDataset `json:"properties,omitempty"`
+ // Name - The resource name.
+ Name *string `json:"name,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for DatasetDebugResource struct.
+func (ddr *DatasetDebugResource) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "properties":
+ if v != nil {
+ properties, err := unmarshalBasicDataset(*v)
+ if err != nil {
+ return err
+ }
+ ddr.Properties = properties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ ddr.Name = &name
+ }
+ }
+ }
+
+ return nil
+}
+
// DatasetDeflateCompression the Deflate compression method used on a dataset.
type DatasetDeflateCompression struct {
// Level - The Deflate compression level.
@@ -65364,7 +68067,7 @@ type Db2LinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -65736,6 +68439,11 @@ func (d2ls Db2LinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for Db2LinkedService.
+func (d2ls Db2LinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for Db2LinkedService.
func (d2ls Db2LinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -65776,6 +68484,16 @@ func (d2ls Db2LinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for Db2LinkedService.
+func (d2ls Db2LinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for Db2LinkedService.
+func (d2ls Db2LinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for Db2LinkedService.
func (d2ls Db2LinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -65954,6 +68672,10 @@ type Db2LinkedServiceTypeProperties struct {
Username interface{} `json:"username,omitempty"`
// Password - Password for authentication.
Password BasicSecretBase `json:"password,omitempty"`
+ // PackageCollection - Under where packages are created when querying database. Type: string (or Expression with resultType string).
+ PackageCollection interface{} `json:"packageCollection,omitempty"`
+ // CertificateCommonName - Certificate Common Name when TLS is enabled. Type: string (or Expression with resultType string).
+ CertificateCommonName interface{} `json:"certificateCommonName,omitempty"`
// EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
}
@@ -66011,6 +68733,24 @@ func (d2lstp *Db2LinkedServiceTypeProperties) UnmarshalJSON(body []byte) error {
}
d2lstp.Password = password
}
+ case "packageCollection":
+ if v != nil {
+ var packageCollection interface{}
+ err = json.Unmarshal(*v, &packageCollection)
+ if err != nil {
+ return err
+ }
+ d2lstp.PackageCollection = packageCollection
+ }
+ case "certificateCommonName":
+ if v != nil {
+ var certificateCommonName interface{}
+ err = json.Unmarshal(*v, &certificateCommonName)
+ if err != nil {
+ return err
+ }
+ d2lstp.CertificateCommonName = certificateCommonName
+ }
case "encryptedCredential":
if v != nil {
var encryptedCredential interface{}
@@ -67245,7 +69985,7 @@ type DeleteActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -67313,6 +70053,11 @@ func (da DeleteActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUS
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for DeleteActivity.
+func (da DeleteActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for DeleteActivity.
func (da DeleteActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -67443,6 +70188,11 @@ func (da DeleteActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for DeleteActivity.
+func (da DeleteActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for DeleteActivity.
func (da DeleteActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -70972,7 +73722,7 @@ type DrillLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -71344,6 +74094,11 @@ func (dls DrillLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for DrillLinkedService.
+func (dls DrillLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for DrillLinkedService.
func (dls DrillLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -71384,6 +74139,16 @@ func (dls DrillLinkedService) AsOracleLinkedService() (*OracleLinkedService, boo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for DrillLinkedService.
+func (dls DrillLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for DrillLinkedService.
+func (dls DrillLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for DrillLinkedService.
func (dls DrillLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -72765,7 +75530,7 @@ type DynamicsAXLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -73137,6 +75902,11 @@ func (dals DynamicsAXLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for DynamicsAXLinkedService.
+func (dals DynamicsAXLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for DynamicsAXLinkedService.
func (dals DynamicsAXLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -73177,6 +75947,16 @@ func (dals DynamicsAXLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for DynamicsAXLinkedService.
+func (dals DynamicsAXLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for DynamicsAXLinkedService.
+func (dals DynamicsAXLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for DynamicsAXLinkedService.
func (dals DynamicsAXLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -75258,7 +78038,7 @@ type DynamicsCrmLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -75630,6 +78410,11 @@ func (dcls DynamicsCrmLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for DynamicsCrmLinkedService.
+func (dcls DynamicsCrmLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for DynamicsCrmLinkedService.
func (dcls DynamicsCrmLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -75670,6 +78455,16 @@ func (dcls DynamicsCrmLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for DynamicsCrmLinkedService.
+func (dcls DynamicsCrmLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for DynamicsCrmLinkedService.
+func (dcls DynamicsCrmLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for DynamicsCrmLinkedService.
func (dcls DynamicsCrmLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -75848,12 +78643,18 @@ type DynamicsCrmLinkedServiceTypeProperties struct {
ServiceURI interface{} `json:"serviceUri,omitempty"`
// OrganizationName - The organization name of the Dynamics CRM instance. The property is required for on-prem and required for online when there are more than one Dynamics CRM instances associated with the user. Type: string (or Expression with resultType string).
OrganizationName interface{} `json:"organizationName,omitempty"`
- // AuthenticationType - The authentication type to connect to Dynamics CRM server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario. Type: string (or Expression with resultType string). Possible values include: 'Office365', 'Ifd'
+ // AuthenticationType - The authentication type to connect to Dynamics CRM server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario, 'AADServicePrincipal' for Server-To-Server authentication in online scenario. Type: string (or Expression with resultType string). Possible values include: 'Office365', 'Ifd', 'AADServicePrincipal'
AuthenticationType DynamicsAuthenticationType `json:"authenticationType,omitempty"`
// Username - User name to access the Dynamics CRM instance. Type: string (or Expression with resultType string).
Username interface{} `json:"username,omitempty"`
// Password - Password to access the Dynamics CRM instance.
Password BasicSecretBase `json:"password,omitempty"`
+ // ServicePrincipalID - The client ID of the application in Azure Active Directory used for Server-To-Server authentication. Type: string (or Expression with resultType string).
+ ServicePrincipalID interface{} `json:"servicePrincipalId,omitempty"`
+ // ServicePrincipalCredentialType - The service principal credential type to use in Server-To-Server authentication. 'ServicePrincipalKey' for key/secret, 'ServicePrincipalCert' for certificate. Type: string (or Expression with resultType string).
+ ServicePrincipalCredentialType interface{} `json:"servicePrincipalCredentialType,omitempty"`
+ // ServicePrincipalCredential - The credential of the service principal object in Azure Active Directory. If servicePrincipalCredentialType is 'ServicePrincipalKey', servicePrincipalCredential can be SecureString or AzureKeyVaultSecretReference. If servicePrincipalCredentialType is 'ServicePrincipalCert', servicePrincipalCredential can only be AzureKeyVaultSecretReference.
+ ServicePrincipalCredential BasicSecretBase `json:"servicePrincipalCredential,omitempty"`
// EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
}
@@ -75938,6 +78739,32 @@ func (dclstp *DynamicsCrmLinkedServiceTypeProperties) UnmarshalJSON(body []byte)
}
dclstp.Password = password
}
+ case "servicePrincipalId":
+ if v != nil {
+ var servicePrincipalID interface{}
+ err = json.Unmarshal(*v, &servicePrincipalID)
+ if err != nil {
+ return err
+ }
+ dclstp.ServicePrincipalID = servicePrincipalID
+ }
+ case "servicePrincipalCredentialType":
+ if v != nil {
+ var servicePrincipalCredentialType interface{}
+ err = json.Unmarshal(*v, &servicePrincipalCredentialType)
+ if err != nil {
+ return err
+ }
+ dclstp.ServicePrincipalCredentialType = servicePrincipalCredentialType
+ }
+ case "servicePrincipalCredential":
+ if v != nil {
+ servicePrincipalCredential, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ dclstp.ServicePrincipalCredential = servicePrincipalCredential
+ }
case "encryptedCredential":
if v != nil {
var encryptedCredential interface{}
@@ -77499,7 +80326,7 @@ type DynamicsLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -77871,6 +80698,11 @@ func (dls DynamicsLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for DynamicsLinkedService.
+func (dls DynamicsLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for DynamicsLinkedService.
func (dls DynamicsLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -77911,6 +80743,16 @@ func (dls DynamicsLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for DynamicsLinkedService.
+func (dls DynamicsLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for DynamicsLinkedService.
+func (dls DynamicsLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for DynamicsLinkedService.
func (dls DynamicsLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -78089,12 +80931,18 @@ type DynamicsLinkedServiceTypeProperties struct {
ServiceURI interface{} `json:"serviceUri,omitempty"`
// OrganizationName - The organization name of the Dynamics instance. The property is required for on-prem and required for online when there are more than one Dynamics instances associated with the user. Type: string (or Expression with resultType string).
OrganizationName interface{} `json:"organizationName,omitempty"`
- // AuthenticationType - The authentication type to connect to Dynamics server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario. Type: string (or Expression with resultType string).
+ // AuthenticationType - The authentication type to connect to Dynamics server. 'Office365' for online scenario, 'Ifd' for on-premises with Ifd scenario, 'AADServicePrincipal' for Server-To-Server authentication in online scenario. Type: string (or Expression with resultType string).
AuthenticationType interface{} `json:"authenticationType,omitempty"`
// Username - User name to access the Dynamics instance. Type: string (or Expression with resultType string).
Username interface{} `json:"username,omitempty"`
// Password - Password to access the Dynamics instance.
Password BasicSecretBase `json:"password,omitempty"`
+ // ServicePrincipalID - The client ID of the application in Azure Active Directory used for Server-To-Server authentication. Type: string (or Expression with resultType string).
+ ServicePrincipalID interface{} `json:"servicePrincipalId,omitempty"`
+ // ServicePrincipalCredentialType - The service principal credential type to use in Server-To-Server authentication. 'ServicePrincipalKey' for key/secret, 'ServicePrincipalCert' for certificate. Type: string (or Expression with resultType string).
+ ServicePrincipalCredentialType interface{} `json:"servicePrincipalCredentialType,omitempty"`
+ // ServicePrincipalCredential - The credential of the service principal object in Azure Active Directory. If servicePrincipalCredentialType is 'ServicePrincipalKey', servicePrincipalCredential can be SecureString or AzureKeyVaultSecretReference. If servicePrincipalCredentialType is 'ServicePrincipalCert', servicePrincipalCredential can only be AzureKeyVaultSecretReference.
+ ServicePrincipalCredential BasicSecretBase `json:"servicePrincipalCredential,omitempty"`
// EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
}
@@ -78179,6 +81027,32 @@ func (dlstp *DynamicsLinkedServiceTypeProperties) UnmarshalJSON(body []byte) err
}
dlstp.Password = password
}
+ case "servicePrincipalId":
+ if v != nil {
+ var servicePrincipalID interface{}
+ err = json.Unmarshal(*v, &servicePrincipalID)
+ if err != nil {
+ return err
+ }
+ dlstp.ServicePrincipalID = servicePrincipalID
+ }
+ case "servicePrincipalCredentialType":
+ if v != nil {
+ var servicePrincipalCredentialType interface{}
+ err = json.Unmarshal(*v, &servicePrincipalCredentialType)
+ if err != nil {
+ return err
+ }
+ dlstp.ServicePrincipalCredentialType = servicePrincipalCredentialType
+ }
+ case "servicePrincipalCredential":
+ if v != nil {
+ servicePrincipalCredential, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ dlstp.ServicePrincipalCredential = servicePrincipalCredential
+ }
case "encryptedCredential":
if v != nil {
var encryptedCredential interface{}
@@ -79120,7 +81994,7 @@ type EloquaLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -79492,6 +82366,11 @@ func (els EloquaLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for EloquaLinkedService.
+func (els EloquaLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for EloquaLinkedService.
func (els EloquaLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -79532,6 +82411,16 @@ func (els EloquaLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for EloquaLinkedService.
+func (els EloquaLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for EloquaLinkedService.
+func (els EloquaLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for EloquaLinkedService.
func (els EloquaLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -81097,7 +83986,7 @@ type ExecuteDataFlowActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -81165,6 +84054,11 @@ func (edfa ExecuteDataFlowActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLake
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ExecuteDataFlowActivity.
+func (edfa ExecuteDataFlowActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ExecuteDataFlowActivity.
func (edfa ExecuteDataFlowActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -81295,6 +84189,11 @@ func (edfa ExecuteDataFlowActivity) AsForEachActivity() (*ForEachActivity, bool)
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ExecuteDataFlowActivity.
+func (edfa ExecuteDataFlowActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ExecuteDataFlowActivity.
func (edfa ExecuteDataFlowActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -81448,7 +84347,7 @@ type ExecutePipelineActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -81510,6 +84409,11 @@ func (epa ExecutePipelineActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeA
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ExecutePipelineActivity.
+func (epa ExecutePipelineActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ExecutePipelineActivity.
func (epa ExecutePipelineActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -81640,6 +84544,11 @@ func (epa ExecutePipelineActivity) AsForEachActivity() (*ForEachActivity, bool)
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ExecutePipelineActivity.
+func (epa ExecutePipelineActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ExecutePipelineActivity.
func (epa ExecutePipelineActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -81794,7 +84703,7 @@ type ExecuteSSISPackageActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -81862,6 +84771,11 @@ func (espa ExecuteSSISPackageActivity) AsDataLakeAnalyticsUSQLActivity() (*DataL
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ExecuteSSISPackageActivity.
+func (espa ExecuteSSISPackageActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ExecuteSSISPackageActivity.
func (espa ExecuteSSISPackageActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -81992,6 +84906,11 @@ func (espa ExecuteSSISPackageActivity) AsForEachActivity() (*ForEachActivity, bo
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ExecuteSSISPackageActivity.
+func (espa ExecuteSSISPackageActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ExecuteSSISPackageActivity.
func (espa ExecuteSSISPackageActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -82199,6 +85118,7 @@ type BasicExecutionActivity interface {
AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool)
AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool)
AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool)
+ AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool)
AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool)
AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool)
AsGetMetadataActivity() (*GetMetadataActivity, bool)
@@ -82234,7 +85154,7 @@ type ExecutionActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -82270,6 +85190,10 @@ func unmarshalBasicExecutionActivity(body []byte) (BasicExecutionActivity, error
var dlaua DataLakeAnalyticsUSQLActivity
err := json.Unmarshal(body, &dlaua)
return dlaua, err
+ case string(TypeAzureMLExecutePipeline):
+ var amepa AzureMLExecutePipelineActivity
+ err := json.Unmarshal(body, &amepa)
+ return amepa, err
case string(TypeAzureMLUpdateResource):
var amura AzureMLUpdateResourceActivity
err := json.Unmarshal(body, &amura)
@@ -82420,6 +85344,11 @@ func (ea ExecutionActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalytic
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ExecutionActivity.
+func (ea ExecutionActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ExecutionActivity.
func (ea ExecutionActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -82550,6 +85479,11 @@ func (ea ExecutionActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ExecutionActivity.
+func (ea ExecutionActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ExecutionActivity.
func (ea ExecutionActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -83376,7 +86310,7 @@ type FileServerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -83748,6 +86682,11 @@ func (fsls FileServerLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for FileServerLinkedService.
+func (fsls FileServerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for FileServerLinkedService.
func (fsls FileServerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -83788,6 +86727,16 @@ func (fsls FileServerLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for FileServerLinkedService.
+func (fsls FileServerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for FileServerLinkedService.
+func (fsls FileServerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for FileServerLinkedService.
func (fsls FileServerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return &fsls, true
@@ -85975,7 +88924,7 @@ type FilterActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -86037,6 +88986,11 @@ func (fa FilterActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUS
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for FilterActivity.
+func (fa FilterActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for FilterActivity.
func (fa FilterActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -86167,6 +89121,11 @@ func (fa FilterActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for FilterActivity.
+func (fa FilterActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for FilterActivity.
func (fa FilterActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -86300,7 +89259,7 @@ type ForEachActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -86362,6 +89321,11 @@ func (fea ForEachActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalytics
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ForEachActivity.
+func (fea ForEachActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ForEachActivity.
func (fea ForEachActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -86492,6 +89456,11 @@ func (fea ForEachActivity) AsForEachActivity() (*ForEachActivity, bool) {
return &fea, true
}
+// AsSwitchActivity is the BasicActivity implementation for ForEachActivity.
+func (fea ForEachActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ForEachActivity.
func (fea ForEachActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -86917,7 +89886,7 @@ type FtpServerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -87289,6 +90258,11 @@ func (fsls FtpServerLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for FtpServerLinkedService.
+func (fsls FtpServerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for FtpServerLinkedService.
func (fsls FtpServerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -87329,6 +90303,16 @@ func (fsls FtpServerLinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for FtpServerLinkedService.
+func (fsls FtpServerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for FtpServerLinkedService.
+func (fsls FtpServerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for FtpServerLinkedService.
func (fsls FtpServerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -87765,7 +90749,7 @@ type GetMetadataActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -87833,6 +90817,11 @@ func (gma GetMetadataActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnaly
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for GetMetadataActivity.
+func (gma GetMetadataActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for GetMetadataActivity.
func (gma GetMetadataActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -87963,6 +90952,11 @@ func (gma GetMetadataActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for GetMetadataActivity.
+func (gma GetMetadataActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for GetMetadataActivity.
func (gma GetMetadataActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -88137,7 +91131,7 @@ type GoogleAdWordsLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -88509,6 +91503,11 @@ func (gawls GoogleAdWordsLinkedService) AsOdbcLinkedService() (*OdbcLinkedServic
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for GoogleAdWordsLinkedService.
+func (gawls GoogleAdWordsLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for GoogleAdWordsLinkedService.
func (gawls GoogleAdWordsLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -88549,6 +91548,16 @@ func (gawls GoogleAdWordsLinkedService) AsOracleLinkedService() (*OracleLinkedSe
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for GoogleAdWordsLinkedService.
+func (gawls GoogleAdWordsLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for GoogleAdWordsLinkedService.
+func (gawls GoogleAdWordsLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for GoogleAdWordsLinkedService.
func (gawls GoogleAdWordsLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -90066,7 +93075,7 @@ type GoogleBigQueryLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -90438,6 +93447,11 @@ func (gbqls GoogleBigQueryLinkedService) AsOdbcLinkedService() (*OdbcLinkedServi
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for GoogleBigQueryLinkedService.
+func (gbqls GoogleBigQueryLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for GoogleBigQueryLinkedService.
func (gbqls GoogleBigQueryLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -90478,6 +93492,16 @@ func (gbqls GoogleBigQueryLinkedService) AsOracleLinkedService() (*OracleLinkedS
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for GoogleBigQueryLinkedService.
+func (gbqls GoogleBigQueryLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for GoogleBigQueryLinkedService.
+func (gbqls GoogleBigQueryLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for GoogleBigQueryLinkedService.
func (gbqls GoogleBigQueryLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -91983,6 +95007,955 @@ func (gbqs *GoogleBigQuerySource) UnmarshalJSON(body []byte) error {
return nil
}
+// GoogleCloudStorageLinkedService linked service for Google Cloud Storage.
+type GoogleCloudStorageLinkedService struct {
+ // GoogleCloudStorageLinkedServiceTypeProperties - Google Cloud Storage linked service properties.
+ *GoogleCloudStorageLinkedServiceTypeProperties `json:"typeProperties,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // ConnectVia - The integration runtime reference.
+ ConnectVia *IntegrationRuntimeReference `json:"connectVia,omitempty"`
+ // Description - Linked service description.
+ Description *string `json:"description,omitempty"`
+ // Parameters - Parameters for linked service.
+ Parameters map[string]*ParameterSpecification `json:"parameters"`
+ // Annotations - List of tags that can be used for describing the linked service.
+ Annotations *[]interface{} `json:"annotations,omitempty"`
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ Type TypeBasicLinkedService `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) MarshalJSON() ([]byte, error) {
+ gcsls.Type = TypeGoogleCloudStorage
+ objectMap := make(map[string]interface{})
+ if gcsls.GoogleCloudStorageLinkedServiceTypeProperties != nil {
+ objectMap["typeProperties"] = gcsls.GoogleCloudStorageLinkedServiceTypeProperties
+ }
+ if gcsls.ConnectVia != nil {
+ objectMap["connectVia"] = gcsls.ConnectVia
+ }
+ if gcsls.Description != nil {
+ objectMap["description"] = gcsls.Description
+ }
+ if gcsls.Parameters != nil {
+ objectMap["parameters"] = gcsls.Parameters
+ }
+ if gcsls.Annotations != nil {
+ objectMap["annotations"] = gcsls.Annotations
+ }
+ if gcsls.Type != "" {
+ objectMap["type"] = gcsls.Type
+ }
+ for k, v := range gcsls.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsAzureFunctionLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureFunctionLinkedService() (*AzureFunctionLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureDataExplorerLinkedService() (*AzureDataExplorerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapTableLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapTableLinkedService() (*SapTableLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleAdWordsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsGoogleAdWordsLinkedService() (*GoogleAdWordsLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleServiceCloudLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsOracleServiceCloudLinkedService() (*OracleServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsAXLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsDynamicsAXLinkedService() (*DynamicsAXLinkedService, bool) {
+ return nil, false
+}
+
+// AsResponsysLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsResponsysLinkedService() (*ResponsysLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDatabricksLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureDatabricksLinkedService() (*AzureDatabricksLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeAnalyticsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureDataLakeAnalyticsLinkedService() (*AzureDataLakeAnalyticsLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightOnDemandLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHDInsightOnDemandLinkedService() (*HDInsightOnDemandLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceMarketingCloudLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSalesforceMarketingCloudLinkedService() (*SalesforceMarketingCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsNetezzaLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsNetezzaLinkedService() (*NetezzaLinkedService, bool) {
+ return nil, false
+}
+
+// AsVerticaLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsVerticaLinkedService() (*VerticaLinkedService, bool) {
+ return nil, false
+}
+
+// AsZohoLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsZohoLinkedService() (*ZohoLinkedService, bool) {
+ return nil, false
+}
+
+// AsXeroLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsXeroLinkedService() (*XeroLinkedService, bool) {
+ return nil, false
+}
+
+// AsSquareLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSquareLinkedService() (*SquareLinkedService, bool) {
+ return nil, false
+}
+
+// AsSparkLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSparkLinkedService() (*SparkLinkedService, bool) {
+ return nil, false
+}
+
+// AsShopifyLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsShopifyLinkedService() (*ShopifyLinkedService, bool) {
+ return nil, false
+}
+
+// AsServiceNowLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsServiceNowLinkedService() (*ServiceNowLinkedService, bool) {
+ return nil, false
+}
+
+// AsQuickBooksLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsQuickBooksLinkedService() (*QuickBooksLinkedService, bool) {
+ return nil, false
+}
+
+// AsPrestoLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsPrestoLinkedService() (*PrestoLinkedService, bool) {
+ return nil, false
+}
+
+// AsPhoenixLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsPhoenixLinkedService() (*PhoenixLinkedService, bool) {
+ return nil, false
+}
+
+// AsPaypalLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsPaypalLinkedService() (*PaypalLinkedService, bool) {
+ return nil, false
+}
+
+// AsMarketoLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMarketoLinkedService() (*MarketoLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMariaDBLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureMariaDBLinkedService() (*AzureMariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMariaDBLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMariaDBLinkedService() (*MariaDBLinkedService, bool) {
+ return nil, false
+}
+
+// AsMagentoLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMagentoLinkedService() (*MagentoLinkedService, bool) {
+ return nil, false
+}
+
+// AsJiraLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsJiraLinkedService() (*JiraLinkedService, bool) {
+ return nil, false
+}
+
+// AsImpalaLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsImpalaLinkedService() (*ImpalaLinkedService, bool) {
+ return nil, false
+}
+
+// AsHubspotLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHubspotLinkedService() (*HubspotLinkedService, bool) {
+ return nil, false
+}
+
+// AsHiveLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHiveLinkedService() (*HiveLinkedService, bool) {
+ return nil, false
+}
+
+// AsHBaseLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHBaseLinkedService() (*HBaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsGreenplumLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsGreenplumLinkedService() (*GreenplumLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleBigQueryLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsGoogleBigQueryLinkedService() (*GoogleBigQueryLinkedService, bool) {
+ return nil, false
+}
+
+// AsEloquaLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsEloquaLinkedService() (*EloquaLinkedService, bool) {
+ return nil, false
+}
+
+// AsDrillLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsDrillLinkedService() (*DrillLinkedService, bool) {
+ return nil, false
+}
+
+// AsCouchbaseLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCouchbaseLinkedService() (*CouchbaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsConcurLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsConcurLinkedService() (*ConcurLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzurePostgreSQLLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzurePostgreSQLLinkedService() (*AzurePostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonMWSLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAmazonMWSLinkedService() (*AmazonMWSLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapHanaLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapHanaLinkedService() (*SapHanaLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapBWLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapBWLinkedService() (*SapBWLinkedService, bool) {
+ return nil, false
+}
+
+// AsSftpServerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSftpServerLinkedService() (*SftpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsFtpServerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsFtpServerLinkedService() (*FtpServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHTTPLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHTTPLinkedService() (*HTTPLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSearchLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureSearchLinkedService() (*AzureSearchLinkedService, bool) {
+ return nil, false
+}
+
+// AsCustomDataSourceLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCustomDataSourceLinkedService() (*CustomDataSourceLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonRedshiftLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAmazonRedshiftLinkedService() (*AmazonRedshiftLinkedService, bool) {
+ return nil, false
+}
+
+// AsAmazonS3LinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAmazonS3LinkedService() (*AmazonS3LinkedService, bool) {
+ return nil, false
+}
+
+// AsRestServiceLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsRestServiceLinkedService() (*RestServiceLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapOpenHubLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapOpenHubLinkedService() (*SapOpenHubLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapEccLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapEccLinkedService() (*SapEccLinkedService, bool) {
+ return nil, false
+}
+
+// AsSapCloudForCustomerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSapCloudForCustomerLinkedService() (*SapCloudForCustomerLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceServiceCloudLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSalesforceServiceCloudLinkedService() (*SalesforceServiceCloudLinkedService, bool) {
+ return nil, false
+}
+
+// AsSalesforceLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSalesforceLinkedService() (*SalesforceLinkedService, bool) {
+ return nil, false
+}
+
+// AsOffice365LinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsOffice365LinkedService() (*Office365LinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobFSLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureBlobFSLinkedService() (*AzureBlobFSLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureDataLakeStoreLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureDataLakeStoreLinkedService() (*AzureDataLakeStoreLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbMongoDbAPILinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCosmosDbMongoDbAPILinkedService() (*CosmosDbMongoDbAPILinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbV2LinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMongoDbV2LinkedService() (*MongoDbV2LinkedService, bool) {
+ return nil, false
+}
+
+// AsMongoDbLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMongoDbLinkedService() (*MongoDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsCassandraLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCassandraLinkedService() (*CassandraLinkedService, bool) {
+ return nil, false
+}
+
+// AsWebLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsWebLinkedService() (*WebLinkedService, bool) {
+ return nil, false
+}
+
+// AsODataLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsODataLinkedService() (*ODataLinkedService, bool) {
+ return nil, false
+}
+
+// AsHdfsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHdfsLinkedService() (*HdfsLinkedService, bool) {
+ return nil, false
+}
+
+// AsMicrosoftAccessLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMicrosoftAccessLinkedService() (*MicrosoftAccessLinkedService, bool) {
+ return nil, false
+}
+
+// AsInformixLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsInformixLinkedService() (*InformixLinkedService, bool) {
+ return nil, false
+}
+
+// AsOdbcLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMLLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
+ return nil, false
+}
+
+// AsTeradataLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsTeradataLinkedService() (*TeradataLinkedService, bool) {
+ return nil, false
+}
+
+// AsDb2LinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsDb2LinkedService() (*Db2LinkedService, bool) {
+ return nil, false
+}
+
+// AsSybaseLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSybaseLinkedService() (*SybaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsPostgreSQLLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsPostgreSQLLinkedService() (*PostgreSQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsMySQLLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsMySQLLinkedService() (*MySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureMySQLLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureMySQLLinkedService() (*AzureMySQLLinkedService, bool) {
+ return nil, false
+}
+
+// AsOracleLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool) {
+ return nil, false
+}
+
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return &gcsls, true
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsFileServerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsHDInsightLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsHDInsightLinkedService() (*HDInsightLinkedService, bool) {
+ return nil, false
+}
+
+// AsCommonDataServiceForAppsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCommonDataServiceForAppsLinkedService() (*CommonDataServiceForAppsLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsCrmLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsDynamicsCrmLinkedService() (*DynamicsCrmLinkedService, bool) {
+ return nil, false
+}
+
+// AsDynamicsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsDynamicsLinkedService() (*DynamicsLinkedService, bool) {
+ return nil, false
+}
+
+// AsCosmosDbLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsCosmosDbLinkedService() (*CosmosDbLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureKeyVaultLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureKeyVaultLinkedService() (*AzureKeyVaultLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBatchLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureBatchLinkedService() (*AzureBatchLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLMILinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureSQLMILinkedService() (*AzureSQLMILinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDatabaseLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureSQLDatabaseLinkedService() (*AzureSQLDatabaseLinkedService, bool) {
+ return nil, false
+}
+
+// AsSQLServerLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsSQLServerLinkedService() (*SQLServerLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureSQLDWLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureSQLDWLinkedService() (*AzureSQLDWLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureTableStorageLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureTableStorageLinkedService() (*AzureTableStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureBlobStorageLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureBlobStorageLinkedService() (*AzureBlobStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureStorageLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsAzureStorageLinkedService() (*AzureStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsLinkedService() (*LinkedService, bool) {
+ return nil, false
+}
+
+// AsBasicLinkedService is the BasicLinkedService implementation for GoogleCloudStorageLinkedService.
+func (gcsls GoogleCloudStorageLinkedService) AsBasicLinkedService() (BasicLinkedService, bool) {
+ return &gcsls, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for GoogleCloudStorageLinkedService struct.
+func (gcsls *GoogleCloudStorageLinkedService) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var googleCloudStorageLinkedServiceTypeProperties GoogleCloudStorageLinkedServiceTypeProperties
+ err = json.Unmarshal(*v, &googleCloudStorageLinkedServiceTypeProperties)
+ if err != nil {
+ return err
+ }
+ gcsls.GoogleCloudStorageLinkedServiceTypeProperties = &googleCloudStorageLinkedServiceTypeProperties
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if gcsls.AdditionalProperties == nil {
+ gcsls.AdditionalProperties = make(map[string]interface{})
+ }
+ gcsls.AdditionalProperties[k] = additionalProperties
+ }
+ case "connectVia":
+ if v != nil {
+ var connectVia IntegrationRuntimeReference
+ err = json.Unmarshal(*v, &connectVia)
+ if err != nil {
+ return err
+ }
+ gcsls.ConnectVia = &connectVia
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ gcsls.Description = &description
+ }
+ case "parameters":
+ if v != nil {
+ var parameters map[string]*ParameterSpecification
+ err = json.Unmarshal(*v, ¶meters)
+ if err != nil {
+ return err
+ }
+ gcsls.Parameters = parameters
+ }
+ case "annotations":
+ if v != nil {
+ var annotations []interface{}
+ err = json.Unmarshal(*v, &annotations)
+ if err != nil {
+ return err
+ }
+ gcsls.Annotations = &annotations
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicLinkedService
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ gcsls.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// GoogleCloudStorageLinkedServiceTypeProperties google Cloud Storage linked service properties.
+type GoogleCloudStorageLinkedServiceTypeProperties struct {
+ // AccessKeyID - The access key identifier of the Google Cloud Storage Identity and Access Management (IAM) user. Type: string (or Expression with resultType string).
+ AccessKeyID interface{} `json:"accessKeyId,omitempty"`
+ // SecretAccessKey - The secret access key of the Google Cloud Storage Identity and Access Management (IAM) user.
+ SecretAccessKey BasicSecretBase `json:"secretAccessKey,omitempty"`
+ // ServiceURL - This value specifies the endpoint to access with the Google Cloud Storage Connector. This is an optional property; change it only if you want to try a different service endpoint or want to switch between https and http. Type: string (or Expression with resultType string).
+ ServiceURL interface{} `json:"serviceUrl,omitempty"`
+ // EncryptedCredential - The encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
+ EncryptedCredential interface{} `json:"encryptedCredential,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for GoogleCloudStorageLinkedServiceTypeProperties struct.
+func (gcslstp *GoogleCloudStorageLinkedServiceTypeProperties) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "accessKeyId":
+ if v != nil {
+ var accessKeyID interface{}
+ err = json.Unmarshal(*v, &accessKeyID)
+ if err != nil {
+ return err
+ }
+ gcslstp.AccessKeyID = accessKeyID
+ }
+ case "secretAccessKey":
+ if v != nil {
+ secretAccessKey, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ gcslstp.SecretAccessKey = secretAccessKey
+ }
+ case "serviceUrl":
+ if v != nil {
+ var serviceURL interface{}
+ err = json.Unmarshal(*v, &serviceURL)
+ if err != nil {
+ return err
+ }
+ gcslstp.ServiceURL = serviceURL
+ }
+ case "encryptedCredential":
+ if v != nil {
+ var encryptedCredential interface{}
+ err = json.Unmarshal(*v, &encryptedCredential)
+ if err != nil {
+ return err
+ }
+ gcslstp.EncryptedCredential = encryptedCredential
+ }
+ }
+ }
+
+ return nil
+}
+
+// GoogleCloudStorageLocation the location of Google Cloud Storage dataset.
+type GoogleCloudStorageLocation struct {
+ // BucketName - Specify the bucketName of Google Cloud Storage. Type: string (or Expression with resultType string)
+ BucketName interface{} `json:"bucketName,omitempty"`
+ // Version - Specify the version of Google Cloud Storage. Type: string (or Expression with resultType string).
+ Version interface{} `json:"version,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Type - Type of dataset storage location.
+ Type *string `json:"type,omitempty"`
+ // FolderPath - Specify the folder path of dataset. Type: string (or Expression with resultType string)
+ FolderPath interface{} `json:"folderPath,omitempty"`
+ // FileName - Specify the file name of dataset. Type: string (or Expression with resultType string).
+ FileName interface{} `json:"fileName,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for GoogleCloudStorageLocation.
+func (gcsl GoogleCloudStorageLocation) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if gcsl.BucketName != nil {
+ objectMap["bucketName"] = gcsl.BucketName
+ }
+ if gcsl.Version != nil {
+ objectMap["version"] = gcsl.Version
+ }
+ if gcsl.Type != nil {
+ objectMap["type"] = gcsl.Type
+ }
+ if gcsl.FolderPath != nil {
+ objectMap["folderPath"] = gcsl.FolderPath
+ }
+ if gcsl.FileName != nil {
+ objectMap["fileName"] = gcsl.FileName
+ }
+ for k, v := range gcsl.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for GoogleCloudStorageLocation struct.
+func (gcsl *GoogleCloudStorageLocation) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "bucketName":
+ if v != nil {
+ var bucketName interface{}
+ err = json.Unmarshal(*v, &bucketName)
+ if err != nil {
+ return err
+ }
+ gcsl.BucketName = bucketName
+ }
+ case "version":
+ if v != nil {
+ var version interface{}
+ err = json.Unmarshal(*v, &version)
+ if err != nil {
+ return err
+ }
+ gcsl.Version = version
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if gcsl.AdditionalProperties == nil {
+ gcsl.AdditionalProperties = make(map[string]interface{})
+ }
+ gcsl.AdditionalProperties[k] = additionalProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ gcsl.Type = &typeVar
+ }
+ case "folderPath":
+ if v != nil {
+ var folderPath interface{}
+ err = json.Unmarshal(*v, &folderPath)
+ if err != nil {
+ return err
+ }
+ gcsl.FolderPath = folderPath
+ }
+ case "fileName":
+ if v != nil {
+ var fileName interface{}
+ err = json.Unmarshal(*v, &fileName)
+ if err != nil {
+ return err
+ }
+ gcsl.FileName = fileName
+ }
+ }
+ }
+
+ return nil
+}
+
+// GoogleCloudStorageReadSettings google Cloud Storage read settings.
+type GoogleCloudStorageReadSettings struct {
+ // Recursive - If true, files under the folder path will be read recursively. Default is true. Type: boolean (or Expression with resultType boolean).
+ Recursive interface{} `json:"recursive,omitempty"`
+ // WildcardFolderPath - Google Cloud Storage wildcardFolderPath. Type: string (or Expression with resultType string).
+ WildcardFolderPath interface{} `json:"wildcardFolderPath,omitempty"`
+ // WildcardFileName - Google Cloud Storage wildcardFileName. Type: string (or Expression with resultType string).
+ WildcardFileName interface{} `json:"wildcardFileName,omitempty"`
+ // Prefix - The prefix filter for the Google Cloud Storage object name. Type: string (or Expression with resultType string).
+ Prefix interface{} `json:"prefix,omitempty"`
+ // EnablePartitionDiscovery - Indicates whether to enable partition discovery.
+ EnablePartitionDiscovery *bool `json:"enablePartitionDiscovery,omitempty"`
+ // ModifiedDatetimeStart - The start of file's modified datetime. Type: string (or Expression with resultType string).
+ ModifiedDatetimeStart interface{} `json:"modifiedDatetimeStart,omitempty"`
+ // ModifiedDatetimeEnd - The end of file's modified datetime. Type: string (or Expression with resultType string).
+ ModifiedDatetimeEnd interface{} `json:"modifiedDatetimeEnd,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Type - The read setting type.
+ Type *string `json:"type,omitempty"`
+ // MaxConcurrentConnections - The maximum concurrent connection count for the source data store. Type: integer (or Expression with resultType integer).
+ MaxConcurrentConnections interface{} `json:"maxConcurrentConnections,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for GoogleCloudStorageReadSettings.
+func (gcsrs GoogleCloudStorageReadSettings) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if gcsrs.Recursive != nil {
+ objectMap["recursive"] = gcsrs.Recursive
+ }
+ if gcsrs.WildcardFolderPath != nil {
+ objectMap["wildcardFolderPath"] = gcsrs.WildcardFolderPath
+ }
+ if gcsrs.WildcardFileName != nil {
+ objectMap["wildcardFileName"] = gcsrs.WildcardFileName
+ }
+ if gcsrs.Prefix != nil {
+ objectMap["prefix"] = gcsrs.Prefix
+ }
+ if gcsrs.EnablePartitionDiscovery != nil {
+ objectMap["enablePartitionDiscovery"] = gcsrs.EnablePartitionDiscovery
+ }
+ if gcsrs.ModifiedDatetimeStart != nil {
+ objectMap["modifiedDatetimeStart"] = gcsrs.ModifiedDatetimeStart
+ }
+ if gcsrs.ModifiedDatetimeEnd != nil {
+ objectMap["modifiedDatetimeEnd"] = gcsrs.ModifiedDatetimeEnd
+ }
+ if gcsrs.Type != nil {
+ objectMap["type"] = gcsrs.Type
+ }
+ if gcsrs.MaxConcurrentConnections != nil {
+ objectMap["maxConcurrentConnections"] = gcsrs.MaxConcurrentConnections
+ }
+ for k, v := range gcsrs.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// UnmarshalJSON is the custom unmarshaler for GoogleCloudStorageReadSettings struct.
+func (gcsrs *GoogleCloudStorageReadSettings) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "recursive":
+ if v != nil {
+ var recursive interface{}
+ err = json.Unmarshal(*v, &recursive)
+ if err != nil {
+ return err
+ }
+ gcsrs.Recursive = recursive
+ }
+ case "wildcardFolderPath":
+ if v != nil {
+ var wildcardFolderPath interface{}
+ err = json.Unmarshal(*v, &wildcardFolderPath)
+ if err != nil {
+ return err
+ }
+ gcsrs.WildcardFolderPath = wildcardFolderPath
+ }
+ case "wildcardFileName":
+ if v != nil {
+ var wildcardFileName interface{}
+ err = json.Unmarshal(*v, &wildcardFileName)
+ if err != nil {
+ return err
+ }
+ gcsrs.WildcardFileName = wildcardFileName
+ }
+ case "prefix":
+ if v != nil {
+ var prefix interface{}
+ err = json.Unmarshal(*v, &prefix)
+ if err != nil {
+ return err
+ }
+ gcsrs.Prefix = prefix
+ }
+ case "enablePartitionDiscovery":
+ if v != nil {
+ var enablePartitionDiscovery bool
+ err = json.Unmarshal(*v, &enablePartitionDiscovery)
+ if err != nil {
+ return err
+ }
+ gcsrs.EnablePartitionDiscovery = &enablePartitionDiscovery
+ }
+ case "modifiedDatetimeStart":
+ if v != nil {
+ var modifiedDatetimeStart interface{}
+ err = json.Unmarshal(*v, &modifiedDatetimeStart)
+ if err != nil {
+ return err
+ }
+ gcsrs.ModifiedDatetimeStart = modifiedDatetimeStart
+ }
+ case "modifiedDatetimeEnd":
+ if v != nil {
+ var modifiedDatetimeEnd interface{}
+ err = json.Unmarshal(*v, &modifiedDatetimeEnd)
+ if err != nil {
+ return err
+ }
+ gcsrs.ModifiedDatetimeEnd = modifiedDatetimeEnd
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if gcsrs.AdditionalProperties == nil {
+ gcsrs.AdditionalProperties = make(map[string]interface{})
+ }
+ gcsrs.AdditionalProperties[k] = additionalProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ gcsrs.Type = &typeVar
+ }
+ case "maxConcurrentConnections":
+ if v != nil {
+ var maxConcurrentConnections interface{}
+ err = json.Unmarshal(*v, &maxConcurrentConnections)
+ if err != nil {
+ return err
+ }
+ gcsrs.MaxConcurrentConnections = maxConcurrentConnections
+ }
+ }
+ }
+
+ return nil
+}
+
// GreenplumDatasetTypeProperties greenplum Dataset Properties
type GreenplumDatasetTypeProperties struct {
// TableName - This property will be retired. Please consider using schema + table properties instead.
@@ -92007,7 +95980,7 @@ type GreenplumLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -92379,6 +96352,11 @@ func (gls GreenplumLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for GreenplumLinkedService.
+func (gls GreenplumLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for GreenplumLinkedService.
func (gls GreenplumLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -92419,6 +96397,16 @@ func (gls GreenplumLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for GreenplumLinkedService.
+func (gls GreenplumLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for GreenplumLinkedService.
+func (gls GreenplumLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for GreenplumLinkedService.
func (gls GreenplumLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -93800,7 +97788,7 @@ type HBaseLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -94172,6 +98160,11 @@ func (hbls HBaseLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HBaseLinkedService.
+func (hbls HBaseLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HBaseLinkedService.
func (hbls HBaseLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -94212,6 +98205,16 @@ func (hbls HBaseLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HBaseLinkedService.
+func (hbls HBaseLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HBaseLinkedService.
+func (hbls HBaseLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HBaseLinkedService.
func (hbls HBaseLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -95722,7 +99725,7 @@ type HdfsLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -96094,6 +100097,11 @@ func (hls HdfsLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HdfsLinkedService.
+func (hls HdfsLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HdfsLinkedService.
func (hls HdfsLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -96134,6 +100142,16 @@ func (hls HdfsLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HdfsLinkedService.
+func (hls HdfsLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HdfsLinkedService.
+func (hls HdfsLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HdfsLinkedService.
func (hls HdfsLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -97220,7 +101238,7 @@ type HDInsightHiveActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -97288,6 +101306,11 @@ func (hiha HDInsightHiveActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAn
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for HDInsightHiveActivity.
+func (hiha HDInsightHiveActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for HDInsightHiveActivity.
func (hiha HDInsightHiveActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -97418,6 +101441,11 @@ func (hiha HDInsightHiveActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for HDInsightHiveActivity.
+func (hiha HDInsightHiveActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for HDInsightHiveActivity.
func (hiha HDInsightHiveActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -97611,7 +101639,7 @@ type HDInsightLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -97983,6 +102011,11 @@ func (hils HDInsightLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HDInsightLinkedService.
+func (hils HDInsightLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HDInsightLinkedService.
func (hils HDInsightLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -98023,6 +102056,16 @@ func (hils HDInsightLinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HDInsightLinkedService.
+func (hils HDInsightLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HDInsightLinkedService.
+func (hils HDInsightLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HDInsightLinkedService.
func (hils HDInsightLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -98313,7 +102356,7 @@ type HDInsightMapReduceActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -98381,6 +102424,11 @@ func (himra HDInsightMapReduceActivity) AsDataLakeAnalyticsUSQLActivity() (*Data
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for HDInsightMapReduceActivity.
+func (himra HDInsightMapReduceActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for HDInsightMapReduceActivity.
func (himra HDInsightMapReduceActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -98511,6 +102559,11 @@ func (himra HDInsightMapReduceActivity) AsForEachActivity() (*ForEachActivity, b
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for HDInsightMapReduceActivity.
+func (himra HDInsightMapReduceActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for HDInsightMapReduceActivity.
func (himra HDInsightMapReduceActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -98704,7 +102757,7 @@ type HDInsightOnDemandLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -99076,6 +103129,11 @@ func (hiodls HDInsightOnDemandLinkedService) AsOdbcLinkedService() (*OdbcLinkedS
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HDInsightOnDemandLinkedService.
+func (hiodls HDInsightOnDemandLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HDInsightOnDemandLinkedService.
func (hiodls HDInsightOnDemandLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -99116,6 +103174,16 @@ func (hiodls HDInsightOnDemandLinkedService) AsOracleLinkedService() (*OracleLin
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HDInsightOnDemandLinkedService.
+func (hiodls HDInsightOnDemandLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HDInsightOnDemandLinkedService.
+func (hiodls HDInsightOnDemandLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HDInsightOnDemandLinkedService.
func (hiodls HDInsightOnDemandLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -99679,7 +103747,7 @@ type HDInsightPigActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -99747,6 +103815,11 @@ func (hipa HDInsightPigActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAna
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for HDInsightPigActivity.
+func (hipa HDInsightPigActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for HDInsightPigActivity.
func (hipa HDInsightPigActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -99877,6 +103950,11 @@ func (hipa HDInsightPigActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for HDInsightPigActivity.
+func (hipa HDInsightPigActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for HDInsightPigActivity.
func (hipa HDInsightPigActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -100010,8 +104088,8 @@ func (hipa *HDInsightPigActivity) UnmarshalJSON(body []byte) error {
type HDInsightPigActivityTypeProperties struct {
// StorageLinkedServices - Storage linked service references.
StorageLinkedServices *[]LinkedServiceReference `json:"storageLinkedServices,omitempty"`
- // Arguments - User specified arguments to HDInsightActivity.
- Arguments *[]interface{} `json:"arguments,omitempty"`
+ // Arguments - User specified arguments to HDInsightActivity. Type: array (or Expression with resultType array).
+ Arguments interface{} `json:"arguments,omitempty"`
// GetDebugInfo - Debug info option. Possible values include: 'HDInsightActivityDebugInfoOptionNone', 'HDInsightActivityDebugInfoOptionAlways', 'HDInsightActivityDebugInfoOptionFailure'
GetDebugInfo HDInsightActivityDebugInfoOption `json:"getDebugInfo,omitempty"`
// ScriptPath - Script path. Type: string (or Expression with resultType string).
@@ -100064,7 +104142,7 @@ type HDInsightSparkActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -100132,6 +104210,11 @@ func (hisa HDInsightSparkActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeA
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for HDInsightSparkActivity.
+func (hisa HDInsightSparkActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for HDInsightSparkActivity.
func (hisa HDInsightSparkActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -100262,6 +104345,11 @@ func (hisa HDInsightSparkActivity) AsForEachActivity() (*ForEachActivity, bool)
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for HDInsightSparkActivity.
+func (hisa HDInsightSparkActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for HDInsightSparkActivity.
func (hisa HDInsightSparkActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -100459,7 +104547,7 @@ type HDInsightStreamingActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -100527,6 +104615,11 @@ func (hisa HDInsightStreamingActivity) AsDataLakeAnalyticsUSQLActivity() (*DataL
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for HDInsightStreamingActivity.
+func (hisa HDInsightStreamingActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for HDInsightStreamingActivity.
func (hisa HDInsightStreamingActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -100657,6 +104750,11 @@ func (hisa HDInsightStreamingActivity) AsForEachActivity() (*ForEachActivity, bo
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for HDInsightStreamingActivity.
+func (hisa HDInsightStreamingActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for HDInsightStreamingActivity.
func (hisa HDInsightStreamingActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -100880,7 +104978,7 @@ type HiveLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -101252,6 +105350,11 @@ func (hls HiveLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HiveLinkedService.
+func (hls HiveLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HiveLinkedService.
func (hls HiveLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -101292,6 +105395,16 @@ func (hls HiveLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HiveLinkedService.
+func (hls HiveLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HiveLinkedService.
+func (hls HiveLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HiveLinkedService.
func (hls HiveLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -103567,7 +107680,7 @@ type HTTPLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -103939,6 +108052,11 @@ func (hls HTTPLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HTTPLinkedService.
+func (hls HTTPLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HTTPLinkedService.
func (hls HTTPLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -103979,6 +108097,16 @@ func (hls HTTPLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HTTPLinkedService.
+func (hls HTTPLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HTTPLinkedService.
+func (hls HTTPLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HTTPLinkedService.
func (hls HTTPLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -105052,7 +109180,7 @@ type HubspotLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -105424,6 +109552,11 @@ func (hls HubspotLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for HubspotLinkedService.
+func (hls HubspotLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for HubspotLinkedService.
func (hls HubspotLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -105464,6 +109597,16 @@ func (hls HubspotLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for HubspotLinkedService.
+func (hls HubspotLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for HubspotLinkedService.
+func (hls HubspotLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for HubspotLinkedService.
func (hls HubspotLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -106941,7 +111084,7 @@ type IfConditionActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -107003,6 +111146,11 @@ func (ica IfConditionActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnaly
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for IfConditionActivity.
+func (ica IfConditionActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for IfConditionActivity.
func (ica IfConditionActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -107133,6 +111281,11 @@ func (ica IfConditionActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for IfConditionActivity.
+func (ica IfConditionActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for IfConditionActivity.
func (ica IfConditionActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return &ica, true
@@ -107318,7 +111471,7 @@ type ImpalaLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -107690,6 +111843,11 @@ func (ils ImpalaLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ImpalaLinkedService.
+func (ils ImpalaLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ImpalaLinkedService.
func (ils ImpalaLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -107730,6 +111888,16 @@ func (ils ImpalaLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ImpalaLinkedService.
+func (ils ImpalaLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ImpalaLinkedService.
+func (ils ImpalaLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ImpalaLinkedService.
func (ils ImpalaLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -109240,7 +113408,7 @@ type InformixLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -109612,6 +113780,11 @@ func (ils InformixLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for InformixLinkedService.
+func (ils InformixLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for InformixLinkedService.
func (ils InformixLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -109652,6 +113825,16 @@ func (ils InformixLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for InformixLinkedService.
+func (ils InformixLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for InformixLinkedService.
+func (ils InformixLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for InformixLinkedService.
func (ils InformixLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -111906,6 +116089,46 @@ type IntegrationRuntimeDataProxyProperties struct {
Path *string `json:"path,omitempty"`
}
+// IntegrationRuntimeDebugResource integration runtime debug resource.
+type IntegrationRuntimeDebugResource struct {
+ // Properties - Integration runtime properties.
+ Properties BasicIntegrationRuntime `json:"properties,omitempty"`
+ // Name - The resource name.
+ Name *string `json:"name,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for IntegrationRuntimeDebugResource struct.
+func (irdr *IntegrationRuntimeDebugResource) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "properties":
+ if v != nil {
+ properties, err := unmarshalBasicIntegrationRuntime(*v)
+ if err != nil {
+ return err
+ }
+ irdr.Properties = properties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ irdr.Name = &name
+ }
+ }
+ }
+
+ return nil
+}
+
// IntegrationRuntimeListResponse a list of integration runtime resources.
type IntegrationRuntimeListResponse struct {
autorest.Response `json:"-"`
@@ -112888,7 +117111,7 @@ type JiraLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -113260,6 +117483,11 @@ func (jls JiraLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for JiraLinkedService.
+func (jls JiraLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for JiraLinkedService.
func (jls JiraLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -113300,6 +117528,16 @@ func (jls JiraLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for JiraLinkedService.
+func (jls JiraLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for JiraLinkedService.
+func (jls JiraLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for JiraLinkedService.
func (jls JiraLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -116881,6 +121119,7 @@ type BasicLinkedService interface {
AsMicrosoftAccessLinkedService() (*MicrosoftAccessLinkedService, bool)
AsInformixLinkedService() (*InformixLinkedService, bool)
AsOdbcLinkedService() (*OdbcLinkedService, bool)
+ AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool)
AsAzureMLLinkedService() (*AzureMLLinkedService, bool)
AsTeradataLinkedService() (*TeradataLinkedService, bool)
AsDb2LinkedService() (*Db2LinkedService, bool)
@@ -116889,6 +121128,8 @@ type BasicLinkedService interface {
AsMySQLLinkedService() (*MySQLLinkedService, bool)
AsAzureMySQLLinkedService() (*AzureMySQLLinkedService, bool)
AsOracleLinkedService() (*OracleLinkedService, bool)
+ AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool)
+ AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool)
AsFileServerLinkedService() (*FileServerLinkedService, bool)
AsHDInsightLinkedService() (*HDInsightLinkedService, bool)
AsCommonDataServiceForAppsLinkedService() (*CommonDataServiceForAppsLinkedService, bool)
@@ -116920,7 +121161,7 @@ type LinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -117204,6 +121445,10 @@ func unmarshalBasicLinkedService(body []byte) (BasicLinkedService, error) {
var ols OdbcLinkedService
err := json.Unmarshal(body, &ols)
return ols, err
+ case string(TypeAzureMLService):
+ var amsls AzureMLServiceLinkedService
+ err := json.Unmarshal(body, &amsls)
+ return amsls, err
case string(TypeAzureML):
var amls AzureMLLinkedService
err := json.Unmarshal(body, &amls)
@@ -117236,6 +121481,14 @@ func unmarshalBasicLinkedService(body []byte) (BasicLinkedService, error) {
var ols OracleLinkedService
err := json.Unmarshal(body, &ols)
return ols, err
+ case string(TypeGoogleCloudStorage):
+ var gcsls GoogleCloudStorageLinkedService
+ err := json.Unmarshal(body, &gcsls)
+ return gcsls, err
+ case string(TypeAzureFileStorage):
+ var afsls AzureFileStorageLinkedService
+ err := json.Unmarshal(body, &afsls)
+ return afsls, err
case string(TypeFileServer):
var fsls FileServerLinkedService
err := json.Unmarshal(body, &fsls)
@@ -117686,6 +121939,11 @@ func (ls LinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for LinkedService.
+func (ls LinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for LinkedService.
func (ls LinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -117726,6 +121984,16 @@ func (ls LinkedService) AsOracleLinkedService() (*OracleLinkedService, bool) {
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for LinkedService.
+func (ls LinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for LinkedService.
+func (ls LinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for LinkedService.
func (ls LinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -117883,6 +122151,46 @@ func (ls *LinkedService) UnmarshalJSON(body []byte) error {
return nil
}
+// LinkedServiceDebugResource linked service debug resource.
+type LinkedServiceDebugResource struct {
+ // Properties - Properties of linked service.
+ Properties BasicLinkedService `json:"properties,omitempty"`
+ // Name - The resource name.
+ Name *string `json:"name,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for LinkedServiceDebugResource struct.
+func (lsdr *LinkedServiceDebugResource) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "properties":
+ if v != nil {
+ properties, err := unmarshalBasicLinkedService(*v)
+ if err != nil {
+ return err
+ }
+ lsdr.Properties = properties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ lsdr.Name = &name
+ }
+ }
+ }
+
+ return nil
+}
+
// LinkedServiceListResponse a list of linked service resources.
type LinkedServiceListResponse struct {
autorest.Response `json:"-"`
@@ -118216,7 +122524,7 @@ type LookupActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -118284,6 +122592,11 @@ func (la LookupActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUS
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for LookupActivity.
+func (la LookupActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for LookupActivity.
func (la LookupActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -118414,6 +122727,11 @@ func (la LookupActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for LookupActivity.
+func (la LookupActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for LookupActivity.
func (la LookupActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -118608,7 +122926,7 @@ type MagentoLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -118980,6 +123298,11 @@ func (mls MagentoLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MagentoLinkedService.
+func (mls MagentoLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MagentoLinkedService.
func (mls MagentoLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -119020,6 +123343,16 @@ func (mls MagentoLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MagentoLinkedService.
+func (mls MagentoLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MagentoLinkedService.
+func (mls MagentoLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MagentoLinkedService.
func (mls MagentoLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -120886,7 +125219,7 @@ type MariaDBLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -121258,6 +125591,11 @@ func (mdls MariaDBLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MariaDBLinkedService.
+func (mdls MariaDBLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MariaDBLinkedService.
func (mdls MariaDBLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -121298,6 +125636,16 @@ func (mdls MariaDBLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MariaDBLinkedService.
+func (mdls MariaDBLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MariaDBLinkedService.
+func (mdls MariaDBLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MariaDBLinkedService.
func (mdls MariaDBLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -122679,7 +127027,7 @@ type MarketoLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -123051,6 +127399,11 @@ func (mls MarketoLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MarketoLinkedService.
+func (mls MarketoLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MarketoLinkedService.
func (mls MarketoLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -123091,6 +127444,16 @@ func (mls MarketoLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MarketoLinkedService.
+func (mls MarketoLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MarketoLinkedService.
+func (mls MarketoLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MarketoLinkedService.
func (mls MarketoLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -124557,7 +128920,7 @@ type MicrosoftAccessLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -124929,6 +129292,11 @@ func (mals MicrosoftAccessLinkedService) AsOdbcLinkedService() (*OdbcLinkedServi
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MicrosoftAccessLinkedService.
+func (mals MicrosoftAccessLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MicrosoftAccessLinkedService.
func (mals MicrosoftAccessLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -124969,6 +129337,16 @@ func (mals MicrosoftAccessLinkedService) AsOracleLinkedService() (*OracleLinkedS
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MicrosoftAccessLinkedService.
+func (mals MicrosoftAccessLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MicrosoftAccessLinkedService.
+func (mals MicrosoftAccessLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MicrosoftAccessLinkedService.
func (mals MicrosoftAccessLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -127454,7 +131832,7 @@ type MongoDbLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -127826,6 +132204,11 @@ func (mdls MongoDbLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MongoDbLinkedService.
+func (mdls MongoDbLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MongoDbLinkedService.
func (mdls MongoDbLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -127866,6 +132249,16 @@ func (mdls MongoDbLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MongoDbLinkedService.
+func (mdls MongoDbLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MongoDbLinkedService.
+func (mdls MongoDbLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MongoDbLinkedService.
func (mdls MongoDbLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -129357,7 +133750,7 @@ type MongoDbV2LinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -129729,6 +134122,11 @@ func (mdvls MongoDbV2LinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MongoDbV2LinkedService.
+func (mdvls MongoDbV2LinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MongoDbV2LinkedService.
func (mdvls MongoDbV2LinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -129769,6 +134167,16 @@ func (mdvls MongoDbV2LinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MongoDbV2LinkedService.
+func (mdvls MongoDbV2LinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MongoDbV2LinkedService.
+func (mdvls MongoDbV2LinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MongoDbV2LinkedService.
func (mdvls MongoDbV2LinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -130775,7 +135183,7 @@ type MySQLLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -131147,6 +135555,11 @@ func (msls MySQLLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for MySQLLinkedService.
+func (msls MySQLLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for MySQLLinkedService.
func (msls MySQLLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -131187,6 +135600,16 @@ func (msls MySQLLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for MySQLLinkedService.
+func (msls MySQLLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for MySQLLinkedService.
+func (msls MySQLLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for MySQLLinkedService.
func (msls MySQLLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -132615,7 +137038,7 @@ type NetezzaLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -132987,6 +137410,11 @@ func (nls NetezzaLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for NetezzaLinkedService.
+func (nls NetezzaLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for NetezzaLinkedService.
func (nls NetezzaLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -133027,6 +137455,16 @@ func (nls NetezzaLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for NetezzaLinkedService.
+func (nls NetezzaLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for NetezzaLinkedService.
+func (nls NetezzaLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for NetezzaLinkedService.
func (nls NetezzaLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -134456,7 +138894,7 @@ type ODataLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -134828,6 +139266,11 @@ func (odls ODataLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ODataLinkedService.
+func (odls ODataLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ODataLinkedService.
func (odls ODataLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -134868,6 +139311,16 @@ func (odls ODataLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ODataLinkedService.
+func (odls ODataLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ODataLinkedService.
+func (odls ODataLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ODataLinkedService.
func (odls ODataLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -136378,7 +140831,7 @@ type OdbcLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -136750,6 +141203,11 @@ func (ols OdbcLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return &ols, true
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for OdbcLinkedService.
+func (ols OdbcLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for OdbcLinkedService.
func (ols OdbcLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -136790,6 +141248,16 @@ func (ols OdbcLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for OdbcLinkedService.
+func (ols OdbcLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for OdbcLinkedService.
+func (ols OdbcLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for OdbcLinkedService.
func (ols OdbcLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -139193,7 +143661,7 @@ type Office365LinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -139565,6 +144033,11 @@ func (o3ls Office365LinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for Office365LinkedService.
+func (o3ls Office365LinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for Office365LinkedService.
func (o3ls Office365LinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -139605,6 +144078,16 @@ func (o3ls Office365LinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for Office365LinkedService.
+func (o3ls Office365LinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for Office365LinkedService.
+func (o3ls Office365LinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for Office365LinkedService.
func (o3ls Office365LinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -140796,7 +145279,7 @@ type OracleLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -141168,6 +145651,11 @@ func (ols OracleLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for OracleLinkedService.
+func (ols OracleLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for OracleLinkedService.
func (ols OracleLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -141208,6 +145696,16 @@ func (ols OracleLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return &ols, true
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for OracleLinkedService.
+func (ols OracleLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for OracleLinkedService.
+func (ols OracleLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for OracleLinkedService.
func (ols OracleLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -141410,7 +145908,7 @@ type OracleServiceCloudLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -141782,6 +146280,11 @@ func (oscls OracleServiceCloudLinkedService) AsOdbcLinkedService() (*OdbcLinkedS
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for OracleServiceCloudLinkedService.
+func (oscls OracleServiceCloudLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for OracleServiceCloudLinkedService.
func (oscls OracleServiceCloudLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -141822,6 +146325,16 @@ func (oscls OracleServiceCloudLinkedService) AsOracleLinkedService() (*OracleLin
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for OracleServiceCloudLinkedService.
+func (oscls OracleServiceCloudLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for OracleServiceCloudLinkedService.
+func (oscls OracleServiceCloudLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for OracleServiceCloudLinkedService.
func (oscls OracleServiceCloudLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -145442,6 +149955,8 @@ func (od *OrcDataset) UnmarshalJSON(body []byte) error {
type OrcDatasetTypeProperties struct {
// Location - The location of the ORC data storage.
Location *DatasetLocation `json:"location,omitempty"`
+ // OrcCompressionCodec - Possible values include: 'OrcCompressionCodecNone', 'OrcCompressionCodecZlib', 'OrcCompressionCodecSnappy'
+ OrcCompressionCodec OrcCompressionCodec `json:"orcCompressionCodec,omitempty"`
}
// OrcFormat the data stored in Optimized Row Columnar (ORC) format.
@@ -148089,7 +152604,7 @@ type PaypalLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -148461,6 +152976,11 @@ func (pls PaypalLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for PaypalLinkedService.
+func (pls PaypalLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for PaypalLinkedService.
func (pls PaypalLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -148501,6 +153021,16 @@ func (pls PaypalLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for PaypalLinkedService.
+func (pls PaypalLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for PaypalLinkedService.
+func (pls PaypalLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for PaypalLinkedService.
func (pls PaypalLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -149977,7 +154507,7 @@ type PhoenixLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -150349,6 +154879,11 @@ func (pls PhoenixLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for PhoenixLinkedService.
+func (pls PhoenixLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for PhoenixLinkedService.
func (pls PhoenixLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -150389,6 +154924,16 @@ func (pls PhoenixLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for PhoenixLinkedService.
+func (pls PhoenixLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for PhoenixLinkedService.
+func (pls PhoenixLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for PhoenixLinkedService.
func (pls PhoenixLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -152613,7 +157158,7 @@ type PostgreSQLLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -152985,6 +157530,11 @@ func (psls PostgreSQLLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for PostgreSQLLinkedService.
+func (psls PostgreSQLLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for PostgreSQLLinkedService.
func (psls PostgreSQLLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -153025,6 +157575,16 @@ func (psls PostgreSQLLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for PostgreSQLLinkedService.
+func (psls PostgreSQLLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for PostgreSQLLinkedService.
+func (psls PostgreSQLLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for PostgreSQLLinkedService.
func (psls PostgreSQLLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -154467,7 +159027,7 @@ type PrestoLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -154839,6 +159399,11 @@ func (pls PrestoLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for PrestoLinkedService.
+func (pls PrestoLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for PrestoLinkedService.
func (pls PrestoLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -154879,6 +159444,16 @@ func (pls PrestoLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for PrestoLinkedService.
+func (pls PrestoLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for PrestoLinkedService.
+func (pls PrestoLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for PrestoLinkedService.
func (pls PrestoLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -156569,7 +161144,7 @@ type QuickBooksLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -156941,6 +161516,11 @@ func (qbls QuickBooksLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for QuickBooksLinkedService.
+func (qbls QuickBooksLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for QuickBooksLinkedService.
func (qbls QuickBooksLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -156981,6 +161561,16 @@ func (qbls QuickBooksLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for QuickBooksLinkedService.
+func (qbls QuickBooksLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for QuickBooksLinkedService.
+func (qbls QuickBooksLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for QuickBooksLinkedService.
func (qbls QuickBooksLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -160341,7 +164931,7 @@ type ResponsysLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -160713,6 +165303,11 @@ func (rls ResponsysLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ResponsysLinkedService.
+func (rls ResponsysLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ResponsysLinkedService.
func (rls ResponsysLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -160753,6 +165348,16 @@ func (rls ResponsysLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ResponsysLinkedService.
+func (rls ResponsysLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ResponsysLinkedService.
+func (rls ResponsysLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ResponsysLinkedService.
func (rls ResponsysLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -162847,7 +167452,7 @@ type RestServiceLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -163219,6 +167824,11 @@ func (rsls RestServiceLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for RestServiceLinkedService.
+func (rsls RestServiceLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for RestServiceLinkedService.
func (rsls RestServiceLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -163259,6 +167869,16 @@ func (rsls RestServiceLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for RestServiceLinkedService.
+func (rsls RestServiceLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for RestServiceLinkedService.
+func (rsls RestServiceLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for RestServiceLinkedService.
func (rsls RestServiceLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -164239,7 +168859,7 @@ type SalesforceLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -164611,6 +169231,11 @@ func (sls SalesforceLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SalesforceLinkedService.
+func (sls SalesforceLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SalesforceLinkedService.
func (sls SalesforceLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -164651,6 +169276,16 @@ func (sls SalesforceLinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SalesforceLinkedService.
+func (sls SalesforceLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SalesforceLinkedService.
+func (sls SalesforceLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SalesforceLinkedService.
func (sls SalesforceLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -164903,7 +169538,7 @@ type SalesforceMarketingCloudLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -165275,6 +169910,11 @@ func (smcls SalesforceMarketingCloudLinkedService) AsOdbcLinkedService() (*OdbcL
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SalesforceMarketingCloudLinkedService.
+func (smcls SalesforceMarketingCloudLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SalesforceMarketingCloudLinkedService.
func (smcls SalesforceMarketingCloudLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -165315,6 +169955,16 @@ func (smcls SalesforceMarketingCloudLinkedService) AsOracleLinkedService() (*Ora
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SalesforceMarketingCloudLinkedService.
+func (smcls SalesforceMarketingCloudLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SalesforceMarketingCloudLinkedService.
+func (smcls SalesforceMarketingCloudLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SalesforceMarketingCloudLinkedService.
func (smcls SalesforceMarketingCloudLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -167391,7 +172041,7 @@ type SalesforceServiceCloudLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -167763,6 +172413,11 @@ func (sscls SalesforceServiceCloudLinkedService) AsOdbcLinkedService() (*OdbcLin
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SalesforceServiceCloudLinkedService.
+func (sscls SalesforceServiceCloudLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SalesforceServiceCloudLinkedService.
func (sscls SalesforceServiceCloudLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -167803,6 +172458,16 @@ func (sscls SalesforceServiceCloudLinkedService) AsOracleLinkedService() (*Oracl
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SalesforceServiceCloudLinkedService.
+func (sscls SalesforceServiceCloudLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SalesforceServiceCloudLinkedService.
+func (sscls SalesforceServiceCloudLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SalesforceServiceCloudLinkedService.
func (sscls SalesforceServiceCloudLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -171152,7 +175817,7 @@ type SapBWLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -171524,6 +176189,11 @@ func (sbls SapBWLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapBWLinkedService.
+func (sbls SapBWLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapBWLinkedService.
func (sbls SapBWLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -171564,6 +176234,16 @@ func (sbls SapBWLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapBWLinkedService.
+func (sbls SapBWLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapBWLinkedService.
+func (sbls SapBWLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapBWLinkedService.
func (sbls SapBWLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -172405,7 +177085,7 @@ type SapCloudForCustomerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -172777,6 +177457,11 @@ func (scfcls SapCloudForCustomerLinkedService) AsOdbcLinkedService() (*OdbcLinke
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapCloudForCustomerLinkedService.
+func (scfcls SapCloudForCustomerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapCloudForCustomerLinkedService.
func (scfcls SapCloudForCustomerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -172817,6 +177502,16 @@ func (scfcls SapCloudForCustomerLinkedService) AsOracleLinkedService() (*OracleL
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapCloudForCustomerLinkedService.
+func (scfcls SapCloudForCustomerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapCloudForCustomerLinkedService.
+func (scfcls SapCloudForCustomerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapCloudForCustomerLinkedService.
func (scfcls SapCloudForCustomerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -174578,7 +179273,7 @@ type SapEccLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -174950,6 +179645,11 @@ func (sels SapEccLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapEccLinkedService.
+func (sels SapEccLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapEccLinkedService.
func (sels SapEccLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -174990,6 +179690,16 @@ func (sels SapEccLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapEccLinkedService.
+func (sels SapEccLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapEccLinkedService.
+func (sels SapEccLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapEccLinkedService.
func (sels SapEccLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -176429,7 +181139,7 @@ type SapHanaLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -176801,6 +181511,11 @@ func (shls SapHanaLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapHanaLinkedService.
+func (shls SapHanaLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapHanaLinkedService.
func (shls SapHanaLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -176841,6 +181556,16 @@ func (shls SapHanaLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapHanaLinkedService.
+func (shls SapHanaLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapHanaLinkedService.
+func (shls SapHanaLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapHanaLinkedService.
func (shls SapHanaLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -178318,7 +183043,7 @@ type SapOpenHubLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -178690,6 +183415,11 @@ func (sohls SapOpenHubLinkedService) AsOdbcLinkedService() (*OdbcLinkedService,
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapOpenHubLinkedService.
+func (sohls SapOpenHubLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapOpenHubLinkedService.
func (sohls SapOpenHubLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -178730,6 +183460,16 @@ func (sohls SapOpenHubLinkedService) AsOracleLinkedService() (*OracleLinkedServi
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapOpenHubLinkedService.
+func (sohls SapOpenHubLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapOpenHubLinkedService.
+func (sohls SapOpenHubLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapOpenHubLinkedService.
func (sohls SapOpenHubLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -180221,7 +184961,7 @@ type SapTableLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -180593,6 +185333,11 @@ func (stls SapTableLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, boo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SapTableLinkedService.
+func (stls SapTableLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SapTableLinkedService.
func (stls SapTableLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -180633,6 +185378,16 @@ func (stls SapTableLinkedService) AsOracleLinkedService() (*OracleLinkedService,
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SapTableLinkedService.
+func (stls SapTableLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SapTableLinkedService.
+func (stls SapTableLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SapTableLinkedService.
func (stls SapTableLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -183155,7 +187910,7 @@ type ServiceNowLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -183527,6 +188282,11 @@ func (snls ServiceNowLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ServiceNowLinkedService.
+func (snls ServiceNowLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ServiceNowLinkedService.
func (snls ServiceNowLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -183567,6 +188327,16 @@ func (snls ServiceNowLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ServiceNowLinkedService.
+func (snls ServiceNowLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ServiceNowLinkedService.
+func (snls ServiceNowLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ServiceNowLinkedService.
func (snls ServiceNowLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -185065,7 +189835,7 @@ type SetVariableActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -185127,6 +189897,11 @@ func (sva SetVariableActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnaly
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for SetVariableActivity.
+func (sva SetVariableActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for SetVariableActivity.
func (sva SetVariableActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -185257,6 +190032,11 @@ func (sva SetVariableActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for SetVariableActivity.
+func (sva SetVariableActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for SetVariableActivity.
func (sva SetVariableActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -185614,7 +190394,7 @@ type SftpServerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -185986,6 +190766,11 @@ func (ssls SftpServerLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SftpServerLinkedService.
+func (ssls SftpServerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SftpServerLinkedService.
func (ssls SftpServerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -186026,6 +190811,16 @@ func (ssls SftpServerLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SftpServerLinkedService.
+func (ssls SftpServerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SftpServerLinkedService.
+func (ssls SftpServerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SftpServerLinkedService.
func (ssls SftpServerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -186343,7 +191138,7 @@ type ShopifyLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -186715,6 +191510,11 @@ func (sls ShopifyLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ShopifyLinkedService.
+func (sls ShopifyLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ShopifyLinkedService.
func (sls ShopifyLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -186755,6 +191555,16 @@ func (sls ShopifyLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ShopifyLinkedService.
+func (sls ShopifyLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ShopifyLinkedService.
+func (sls ShopifyLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ShopifyLinkedService.
func (sls ShopifyLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -188220,7 +193030,7 @@ type SparkLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -188592,6 +193402,11 @@ func (sls SparkLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SparkLinkedService.
+func (sls SparkLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SparkLinkedService.
func (sls SparkLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -188632,6 +193447,16 @@ func (sls SparkLinkedService) AsOracleLinkedService() (*OracleLinkedService, boo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SparkLinkedService.
+func (sls SparkLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SparkLinkedService.
+func (sls SparkLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SparkLinkedService.
func (sls SparkLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -192153,7 +196978,7 @@ type SQLServerLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -192525,6 +197350,11 @@ func (ssls SQLServerLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bo
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SQLServerLinkedService.
+func (ssls SQLServerLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SQLServerLinkedService.
func (ssls SQLServerLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -192565,6 +197395,16 @@ func (ssls SQLServerLinkedService) AsOracleLinkedService() (*OracleLinkedService
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SQLServerLinkedService.
+func (ssls SQLServerLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SQLServerLinkedService.
+func (ssls SQLServerLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SQLServerLinkedService.
func (ssls SQLServerLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -193821,7 +198661,7 @@ type SQLServerStoredProcedureActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -193889,6 +198729,11 @@ func (ssspa SQLServerStoredProcedureActivity) AsDataLakeAnalyticsUSQLActivity()
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for SQLServerStoredProcedureActivity.
+func (ssspa SQLServerStoredProcedureActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for SQLServerStoredProcedureActivity.
func (ssspa SQLServerStoredProcedureActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -194019,6 +198864,11 @@ func (ssspa SQLServerStoredProcedureActivity) AsForEachActivity() (*ForEachActiv
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for SQLServerStoredProcedureActivity.
+func (ssspa SQLServerStoredProcedureActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for SQLServerStoredProcedureActivity.
func (ssspa SQLServerStoredProcedureActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -195802,7 +200652,7 @@ type SquareLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -196174,6 +201024,11 @@ func (sls SquareLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SquareLinkedService.
+func (sls SquareLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SquareLinkedService.
func (sls SquareLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -196214,6 +201069,16 @@ func (sls SquareLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SquareLinkedService.
+func (sls SquareLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SquareLinkedService.
+func (sls SquareLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SquareLinkedService.
func (sls SquareLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -197684,7 +202549,48 @@ type SSISAccessCredential struct {
// UserName - UseName for windows authentication.
UserName interface{} `json:"userName,omitempty"`
// Password - Password for windows authentication.
- Password *SecureString `json:"password,omitempty"`
+ Password BasicSecretBase `json:"password,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for SSISAccessCredential struct.
+func (sac *SSISAccessCredential) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "domain":
+ if v != nil {
+ var domain interface{}
+ err = json.Unmarshal(*v, &domain)
+ if err != nil {
+ return err
+ }
+ sac.Domain = domain
+ }
+ case "userName":
+ if v != nil {
+ var userName interface{}
+ err = json.Unmarshal(*v, &userName)
+ if err != nil {
+ return err
+ }
+ sac.UserName = userName
+ }
+ case "password":
+ if v != nil {
+ password, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ sac.Password = password
+ }
+ }
+ }
+
+ return nil
}
// SsisEnvironment ssis environment.
@@ -198246,13 +203152,54 @@ func (spl *SSISPackageLocation) UnmarshalJSON(body []byte) error {
// SSISPackageLocationTypeProperties SSIS package location properties.
type SSISPackageLocationTypeProperties struct {
// PackagePassword - Password of the package.
- PackagePassword *SecureString `json:"packagePassword,omitempty"`
+ PackagePassword BasicSecretBase `json:"packagePassword,omitempty"`
// AccessCredential - The package access credential.
AccessCredential *SSISAccessCredential `json:"accessCredential,omitempty"`
// ConfigurationPath - The configuration file of the package execution. Type: string (or Expression with resultType string).
ConfigurationPath interface{} `json:"configurationPath,omitempty"`
}
+// UnmarshalJSON is the custom unmarshaler for SSISPackageLocationTypeProperties struct.
+func (spltp *SSISPackageLocationTypeProperties) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "packagePassword":
+ if v != nil {
+ packagePassword, err := unmarshalBasicSecretBase(*v)
+ if err != nil {
+ return err
+ }
+ spltp.PackagePassword = packagePassword
+ }
+ case "accessCredential":
+ if v != nil {
+ var accessCredential SSISAccessCredential
+ err = json.Unmarshal(*v, &accessCredential)
+ if err != nil {
+ return err
+ }
+ spltp.AccessCredential = &accessCredential
+ }
+ case "configurationPath":
+ if v != nil {
+ var configurationPath interface{}
+ err = json.Unmarshal(*v, &configurationPath)
+ if err != nil {
+ return err
+ }
+ spltp.ConfigurationPath = configurationPath
+ }
+ }
+ }
+
+ return nil
+}
+
// SsisParameter ssis parameter.
type SsisParameter struct {
// ID - Parameter id.
@@ -198735,6 +203682,431 @@ type SubResource struct {
Etag *string `json:"etag,omitempty"`
}
+// SubResourceDebugResource azure Data Factory nested debug resource.
+type SubResourceDebugResource struct {
+ // Name - The resource name.
+ Name *string `json:"name,omitempty"`
+}
+
+// SwitchActivity this activity evaluates an expression and executes activities under the cases property
+// that correspond to the expression evaluation expected in the equals property.
+type SwitchActivity struct {
+ // SwitchActivityTypeProperties - Switch activity properties.
+ *SwitchActivityTypeProperties `json:"typeProperties,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Name - Activity name.
+ Name *string `json:"name,omitempty"`
+ // Description - Activity description.
+ Description *string `json:"description,omitempty"`
+ // DependsOn - Activity depends on condition.
+ DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
+ // UserProperties - Activity user properties.
+ UserProperties *[]UserProperty `json:"userProperties,omitempty"`
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ Type TypeBasicActivity `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for SwitchActivity.
+func (sa SwitchActivity) MarshalJSON() ([]byte, error) {
+ sa.Type = TypeSwitch
+ objectMap := make(map[string]interface{})
+ if sa.SwitchActivityTypeProperties != nil {
+ objectMap["typeProperties"] = sa.SwitchActivityTypeProperties
+ }
+ if sa.Name != nil {
+ objectMap["name"] = sa.Name
+ }
+ if sa.Description != nil {
+ objectMap["description"] = sa.Description
+ }
+ if sa.DependsOn != nil {
+ objectMap["dependsOn"] = sa.DependsOn
+ }
+ if sa.UserProperties != nil {
+ objectMap["userProperties"] = sa.UserProperties
+ }
+ if sa.Type != "" {
+ objectMap["type"] = sa.Type
+ }
+ for k, v := range sa.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsExecuteDataFlowActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsExecuteDataFlowActivity() (*ExecuteDataFlowActivity, bool) {
+ return nil, false
+}
+
+// AsAzureFunctionActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAzureFunctionActivity() (*AzureFunctionActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkPythonActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsDatabricksSparkPythonActivity() (*DatabricksSparkPythonActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkJarActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksNotebookActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool) {
+ return nil, false
+}
+
+// AsDataLakeAnalyticsUSQLActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLBatchExecutionActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsGetMetadataActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsGetMetadataActivity() (*GetMetadataActivity, bool) {
+ return nil, false
+}
+
+// AsWebActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsWebActivity() (*WebActivity, bool) {
+ return nil, false
+}
+
+// AsLookupActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsLookupActivity() (*LookupActivity, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerCommandActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAzureDataExplorerCommandActivity() (*AzureDataExplorerCommandActivity, bool) {
+ return nil, false
+}
+
+// AsDeleteActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsDeleteActivity() (*DeleteActivity, bool) {
+ return nil, false
+}
+
+// AsSQLServerStoredProcedureActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsSQLServerStoredProcedureActivity() (*SQLServerStoredProcedureActivity, bool) {
+ return nil, false
+}
+
+// AsCustomActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsCustomActivity() (*CustomActivity, bool) {
+ return nil, false
+}
+
+// AsExecuteSSISPackageActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsExecuteSSISPackageActivity() (*ExecuteSSISPackageActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightSparkActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsHDInsightSparkActivity() (*HDInsightSparkActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightStreamingActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsHDInsightStreamingActivity() (*HDInsightStreamingActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightMapReduceActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsHDInsightMapReduceActivity() (*HDInsightMapReduceActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightPigActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsHDInsightPigActivity() (*HDInsightPigActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightHiveActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsHDInsightHiveActivity() (*HDInsightHiveActivity, bool) {
+ return nil, false
+}
+
+// AsCopyActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsCopyActivity() (*CopyActivity, bool) {
+ return nil, false
+}
+
+// AsExecutionActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsExecutionActivity() (*ExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsBasicExecutionActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsBasicExecutionActivity() (BasicExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsWebHookActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsWebHookActivity() (*WebHookActivity, bool) {
+ return nil, false
+}
+
+// AsAppendVariableActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsAppendVariableActivity() (*AppendVariableActivity, bool) {
+ return nil, false
+}
+
+// AsSetVariableActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsSetVariableActivity() (*SetVariableActivity, bool) {
+ return nil, false
+}
+
+// AsFilterActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsFilterActivity() (*FilterActivity, bool) {
+ return nil, false
+}
+
+// AsValidationActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsValidationActivity() (*ValidationActivity, bool) {
+ return nil, false
+}
+
+// AsUntilActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsUntilActivity() (*UntilActivity, bool) {
+ return nil, false
+}
+
+// AsWaitActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsWaitActivity() (*WaitActivity, bool) {
+ return nil, false
+}
+
+// AsForEachActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsForEachActivity() (*ForEachActivity, bool) {
+ return nil, false
+}
+
+// AsSwitchActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return &sa, true
+}
+
+// AsIfConditionActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
+ return nil, false
+}
+
+// AsExecutePipelineActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsExecutePipelineActivity() (*ExecutePipelineActivity, bool) {
+ return nil, false
+}
+
+// AsControlActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsControlActivity() (*ControlActivity, bool) {
+ return nil, false
+}
+
+// AsBasicControlActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsBasicControlActivity() (BasicControlActivity, bool) {
+ return &sa, true
+}
+
+// AsActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsActivity() (*Activity, bool) {
+ return nil, false
+}
+
+// AsBasicActivity is the BasicActivity implementation for SwitchActivity.
+func (sa SwitchActivity) AsBasicActivity() (BasicActivity, bool) {
+ return &sa, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for SwitchActivity struct.
+func (sa *SwitchActivity) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var switchActivityTypeProperties SwitchActivityTypeProperties
+ err = json.Unmarshal(*v, &switchActivityTypeProperties)
+ if err != nil {
+ return err
+ }
+ sa.SwitchActivityTypeProperties = &switchActivityTypeProperties
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if sa.AdditionalProperties == nil {
+ sa.AdditionalProperties = make(map[string]interface{})
+ }
+ sa.AdditionalProperties[k] = additionalProperties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ sa.Name = &name
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ sa.Description = &description
+ }
+ case "dependsOn":
+ if v != nil {
+ var dependsOn []ActivityDependency
+ err = json.Unmarshal(*v, &dependsOn)
+ if err != nil {
+ return err
+ }
+ sa.DependsOn = &dependsOn
+ }
+ case "userProperties":
+ if v != nil {
+ var userProperties []UserProperty
+ err = json.Unmarshal(*v, &userProperties)
+ if err != nil {
+ return err
+ }
+ sa.UserProperties = &userProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicActivity
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ sa.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// SwitchActivityTypeProperties switch activity properties.
+type SwitchActivityTypeProperties struct {
+ // On - An expression that would evaluate to a string or integer. This is used to determine the block of activities in cases that will be executed.
+ On *Expression `json:"on,omitempty"`
+ // Cases - List of cases that correspond to expected values of the 'on' property. This is an optional property and if not provided, the activity will execute activities provided in defaultActivities.
+ Cases *[]SwitchCase `json:"cases,omitempty"`
+ // DefaultActivities - List of activities to execute if no case condition is satisfied. This is an optional property and if not provided, the activity will exit without any action.
+ DefaultActivities *[]BasicActivity `json:"defaultActivities,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for SwitchActivityTypeProperties struct.
+func (satp *SwitchActivityTypeProperties) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "on":
+ if v != nil {
+ var on Expression
+ err = json.Unmarshal(*v, &on)
+ if err != nil {
+ return err
+ }
+ satp.On = &on
+ }
+ case "cases":
+ if v != nil {
+ var cases []SwitchCase
+ err = json.Unmarshal(*v, &cases)
+ if err != nil {
+ return err
+ }
+ satp.Cases = &cases
+ }
+ case "defaultActivities":
+ if v != nil {
+ defaultActivities, err := unmarshalBasicActivityArray(*v)
+ if err != nil {
+ return err
+ }
+ satp.DefaultActivities = &defaultActivities
+ }
+ }
+ }
+
+ return nil
+}
+
+// SwitchCase switch cases with have a value and corresponding activities.
+type SwitchCase struct {
+ // Value - Expected value that satisfies the expression result of the 'on' property.
+ Value *string `json:"value,omitempty"`
+ // Activities - List of activities to execute for satisfied case condition.
+ Activities *[]BasicActivity `json:"activities,omitempty"`
+}
+
+// UnmarshalJSON is the custom unmarshaler for SwitchCase struct.
+func (sc *SwitchCase) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "value":
+ if v != nil {
+ var value string
+ err = json.Unmarshal(*v, &value)
+ if err != nil {
+ return err
+ }
+ sc.Value = &value
+ }
+ case "activities":
+ if v != nil {
+ activities, err := unmarshalBasicActivityArray(*v)
+ if err != nil {
+ return err
+ }
+ sc.Activities = &activities
+ }
+ }
+ }
+
+ return nil
+}
+
// SybaseLinkedService linked service for Sybase data source.
type SybaseLinkedService struct {
// SybaseLinkedServiceTypeProperties - Sybase linked service properties.
@@ -198749,7 +204121,7 @@ type SybaseLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -199121,6 +204493,11 @@ func (sls SybaseLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for SybaseLinkedService.
+func (sls SybaseLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for SybaseLinkedService.
func (sls SybaseLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -199161,6 +204538,16 @@ func (sls SybaseLinkedService) AsOracleLinkedService() (*OracleLinkedService, bo
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for SybaseLinkedService.
+func (sls SybaseLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for SybaseLinkedService.
+func (sls SybaseLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for SybaseLinkedService.
func (sls SybaseLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -201519,7 +206906,7 @@ type TeradataLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -201891,6 +207278,11 @@ func (TLSVar TeradataLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, b
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for TeradataLinkedService.
+func (TLSVar TeradataLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for TeradataLinkedService.
func (TLSVar TeradataLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -201931,6 +207323,16 @@ func (TLSVar TeradataLinkedService) AsOracleLinkedService() (*OracleLinkedServic
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for TeradataLinkedService.
+func (TLSVar TeradataLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for TeradataLinkedService.
+func (TLSVar TeradataLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for TeradataLinkedService.
func (TLSVar TeradataLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -204864,7 +210266,7 @@ type UntilActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -204926,6 +210328,11 @@ func (ua UntilActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQ
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for UntilActivity.
+func (ua UntilActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for UntilActivity.
func (ua UntilActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -205056,6 +210463,11 @@ func (ua UntilActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for UntilActivity.
+func (ua UntilActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for UntilActivity.
func (ua UntilActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -205268,7 +210680,7 @@ type ValidationActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -205330,6 +210742,11 @@ func (va ValidationActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyti
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for ValidationActivity.
+func (va ValidationActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for ValidationActivity.
func (va ValidationActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -205460,6 +210877,11 @@ func (va ValidationActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for ValidationActivity.
+func (va ValidationActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for ValidationActivity.
func (va ValidationActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -205617,7 +211039,7 @@ type VerticaLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -205989,6 +211411,11 @@ func (vls VerticaLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool)
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for VerticaLinkedService.
+func (vls VerticaLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for VerticaLinkedService.
func (vls VerticaLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -206029,6 +211456,16 @@ func (vls VerticaLinkedService) AsOracleLinkedService() (*OracleLinkedService, b
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for VerticaLinkedService.
+func (vls VerticaLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for VerticaLinkedService.
+func (vls VerticaLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for VerticaLinkedService.
func (vls VerticaLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -207410,7 +212847,7 @@ type WaitActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -207472,6 +212909,11 @@ func (wa WaitActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQL
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for WaitActivity.
+func (wa WaitActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for WaitActivity.
func (wa WaitActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -207602,6 +213044,11 @@ func (wa WaitActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for WaitActivity.
+func (wa WaitActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for WaitActivity.
func (wa WaitActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -207713,260 +213160,383 @@ func (wa *WaitActivity) UnmarshalJSON(body []byte) error {
return nil
}
-// WaitActivityTypeProperties wait activity properties.
-type WaitActivityTypeProperties struct {
- // WaitTimeInSeconds - Duration in seconds.
- WaitTimeInSeconds *int32 `json:"waitTimeInSeconds,omitempty"`
-}
-
-// WebActivity web activity.
-type WebActivity struct {
- // WebActivityTypeProperties - Web activity properties.
- *WebActivityTypeProperties `json:"typeProperties,omitempty"`
- // LinkedServiceName - Linked service reference.
- LinkedServiceName *LinkedServiceReference `json:"linkedServiceName,omitempty"`
- // Policy - Activity policy.
- Policy *ActivityPolicy `json:"policy,omitempty"`
- // AdditionalProperties - Unmatched properties from the message are deserialized this collection
- AdditionalProperties map[string]interface{} `json:""`
- // Name - Activity name.
- Name *string `json:"name,omitempty"`
- // Description - Activity description.
- Description *string `json:"description,omitempty"`
- // DependsOn - Activity depends on condition.
- DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
- // UserProperties - Activity user properties.
- UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
- Type TypeBasicActivity `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for WebActivity.
-func (wa WebActivity) MarshalJSON() ([]byte, error) {
- wa.Type = TypeWebActivity
- objectMap := make(map[string]interface{})
- if wa.WebActivityTypeProperties != nil {
- objectMap["typeProperties"] = wa.WebActivityTypeProperties
- }
- if wa.LinkedServiceName != nil {
- objectMap["linkedServiceName"] = wa.LinkedServiceName
- }
- if wa.Policy != nil {
- objectMap["policy"] = wa.Policy
- }
- if wa.Name != nil {
- objectMap["name"] = wa.Name
- }
- if wa.Description != nil {
- objectMap["description"] = wa.Description
- }
- if wa.DependsOn != nil {
- objectMap["dependsOn"] = wa.DependsOn
- }
- if wa.UserProperties != nil {
- objectMap["userProperties"] = wa.UserProperties
- }
- if wa.Type != "" {
- objectMap["type"] = wa.Type
- }
- for k, v := range wa.AdditionalProperties {
- objectMap[k] = v
- }
- return json.Marshal(objectMap)
-}
-
-// AsExecuteDataFlowActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsExecuteDataFlowActivity() (*ExecuteDataFlowActivity, bool) {
- return nil, false
-}
-
-// AsAzureFunctionActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsAzureFunctionActivity() (*AzureFunctionActivity, bool) {
- return nil, false
-}
-
-// AsDatabricksSparkPythonActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsDatabricksSparkPythonActivity() (*DatabricksSparkPythonActivity, bool) {
- return nil, false
-}
-
-// AsDatabricksSparkJarActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool) {
- return nil, false
-}
-
-// AsDatabricksNotebookActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool) {
- return nil, false
-}
-
-// AsDataLakeAnalyticsUSQLActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool) {
- return nil, false
-}
-
-// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
- return nil, false
-}
-
-// AsAzureMLBatchExecutionActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool) {
- return nil, false
-}
-
-// AsGetMetadataActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsGetMetadataActivity() (*GetMetadataActivity, bool) {
- return nil, false
-}
-
-// AsWebActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsWebActivity() (*WebActivity, bool) {
- return &wa, true
-}
-
-// AsLookupActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsLookupActivity() (*LookupActivity, bool) {
- return nil, false
-}
-
-// AsAzureDataExplorerCommandActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsAzureDataExplorerCommandActivity() (*AzureDataExplorerCommandActivity, bool) {
- return nil, false
-}
-
-// AsDeleteActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsDeleteActivity() (*DeleteActivity, bool) {
- return nil, false
-}
-
-// AsSQLServerStoredProcedureActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsSQLServerStoredProcedureActivity() (*SQLServerStoredProcedureActivity, bool) {
- return nil, false
-}
-
-// AsCustomActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsCustomActivity() (*CustomActivity, bool) {
- return nil, false
-}
-
-// AsExecuteSSISPackageActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsExecuteSSISPackageActivity() (*ExecuteSSISPackageActivity, bool) {
- return nil, false
-}
-
-// AsHDInsightSparkActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsHDInsightSparkActivity() (*HDInsightSparkActivity, bool) {
- return nil, false
-}
-
-// AsHDInsightStreamingActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsHDInsightStreamingActivity() (*HDInsightStreamingActivity, bool) {
- return nil, false
-}
-
-// AsHDInsightMapReduceActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsHDInsightMapReduceActivity() (*HDInsightMapReduceActivity, bool) {
- return nil, false
-}
-
-// AsHDInsightPigActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsHDInsightPigActivity() (*HDInsightPigActivity, bool) {
- return nil, false
-}
-
-// AsHDInsightHiveActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsHDInsightHiveActivity() (*HDInsightHiveActivity, bool) {
- return nil, false
-}
-
-// AsCopyActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsCopyActivity() (*CopyActivity, bool) {
- return nil, false
-}
-
-// AsExecutionActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsExecutionActivity() (*ExecutionActivity, bool) {
- return nil, false
-}
-
-// AsBasicExecutionActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsBasicExecutionActivity() (BasicExecutionActivity, bool) {
- return &wa, true
-}
-
-// AsWebHookActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsWebHookActivity() (*WebHookActivity, bool) {
- return nil, false
-}
-
-// AsAppendVariableActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsAppendVariableActivity() (*AppendVariableActivity, bool) {
- return nil, false
-}
-
-// AsSetVariableActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsSetVariableActivity() (*SetVariableActivity, bool) {
- return nil, false
-}
-
-// AsFilterActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsFilterActivity() (*FilterActivity, bool) {
- return nil, false
-}
-
-// AsValidationActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsValidationActivity() (*ValidationActivity, bool) {
- return nil, false
-}
-
-// AsUntilActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsUntilActivity() (*UntilActivity, bool) {
- return nil, false
-}
-
-// AsWaitActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsWaitActivity() (*WaitActivity, bool) {
- return nil, false
-}
-
-// AsForEachActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsForEachActivity() (*ForEachActivity, bool) {
- return nil, false
-}
-
-// AsIfConditionActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
- return nil, false
-}
-
-// AsExecutePipelineActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsExecutePipelineActivity() (*ExecutePipelineActivity, bool) {
- return nil, false
-}
-
-// AsControlActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsControlActivity() (*ControlActivity, bool) {
- return nil, false
-}
-
-// AsBasicControlActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsBasicControlActivity() (BasicControlActivity, bool) {
- return nil, false
-}
-
-// AsActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsActivity() (*Activity, bool) {
- return nil, false
-}
-
-// AsBasicActivity is the BasicActivity implementation for WebActivity.
-func (wa WebActivity) AsBasicActivity() (BasicActivity, bool) {
- return &wa, true
+// WaitActivityTypeProperties wait activity properties.
+type WaitActivityTypeProperties struct {
+ // WaitTimeInSeconds - Duration in seconds.
+ WaitTimeInSeconds *int32 `json:"waitTimeInSeconds,omitempty"`
+}
+
+// WebActivity web activity.
+type WebActivity struct {
+ // WebActivityTypeProperties - Web activity properties.
+ *WebActivityTypeProperties `json:"typeProperties,omitempty"`
+ // LinkedServiceName - Linked service reference.
+ LinkedServiceName *LinkedServiceReference `json:"linkedServiceName,omitempty"`
+ // Policy - Activity policy.
+ Policy *ActivityPolicy `json:"policy,omitempty"`
+ // AdditionalProperties - Unmatched properties from the message are deserialized this collection
+ AdditionalProperties map[string]interface{} `json:""`
+ // Name - Activity name.
+ Name *string `json:"name,omitempty"`
+ // Description - Activity description.
+ Description *string `json:"description,omitempty"`
+ // DependsOn - Activity depends on condition.
+ DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
+ // UserProperties - Activity user properties.
+ UserProperties *[]UserProperty `json:"userProperties,omitempty"`
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ Type TypeBasicActivity `json:"type,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for WebActivity.
+func (wa WebActivity) MarshalJSON() ([]byte, error) {
+ wa.Type = TypeWebActivity
+ objectMap := make(map[string]interface{})
+ if wa.WebActivityTypeProperties != nil {
+ objectMap["typeProperties"] = wa.WebActivityTypeProperties
+ }
+ if wa.LinkedServiceName != nil {
+ objectMap["linkedServiceName"] = wa.LinkedServiceName
+ }
+ if wa.Policy != nil {
+ objectMap["policy"] = wa.Policy
+ }
+ if wa.Name != nil {
+ objectMap["name"] = wa.Name
+ }
+ if wa.Description != nil {
+ objectMap["description"] = wa.Description
+ }
+ if wa.DependsOn != nil {
+ objectMap["dependsOn"] = wa.DependsOn
+ }
+ if wa.UserProperties != nil {
+ objectMap["userProperties"] = wa.UserProperties
+ }
+ if wa.Type != "" {
+ objectMap["type"] = wa.Type
+ }
+ for k, v := range wa.AdditionalProperties {
+ objectMap[k] = v
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsExecuteDataFlowActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsExecuteDataFlowActivity() (*ExecuteDataFlowActivity, bool) {
+ return nil, false
+}
+
+// AsAzureFunctionActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAzureFunctionActivity() (*AzureFunctionActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkPythonActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsDatabricksSparkPythonActivity() (*DatabricksSparkPythonActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksSparkJarActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsDatabricksSparkJarActivity() (*DatabricksSparkJarActivity, bool) {
+ return nil, false
+}
+
+// AsDatabricksNotebookActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsDatabricksNotebookActivity() (*DatabricksNotebookActivity, bool) {
+ return nil, false
+}
+
+// AsDataLakeAnalyticsUSQLActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalyticsUSQLActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
+ return nil, false
+}
+
+// AsAzureMLBatchExecutionActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAzureMLBatchExecutionActivity() (*AzureMLBatchExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsGetMetadataActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsGetMetadataActivity() (*GetMetadataActivity, bool) {
+ return nil, false
+}
+
+// AsWebActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsWebActivity() (*WebActivity, bool) {
+ return &wa, true
+}
+
+// AsLookupActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsLookupActivity() (*LookupActivity, bool) {
+ return nil, false
+}
+
+// AsAzureDataExplorerCommandActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAzureDataExplorerCommandActivity() (*AzureDataExplorerCommandActivity, bool) {
+ return nil, false
+}
+
+// AsDeleteActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsDeleteActivity() (*DeleteActivity, bool) {
+ return nil, false
+}
+
+// AsSQLServerStoredProcedureActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsSQLServerStoredProcedureActivity() (*SQLServerStoredProcedureActivity, bool) {
+ return nil, false
+}
+
+// AsCustomActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsCustomActivity() (*CustomActivity, bool) {
+ return nil, false
+}
+
+// AsExecuteSSISPackageActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsExecuteSSISPackageActivity() (*ExecuteSSISPackageActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightSparkActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsHDInsightSparkActivity() (*HDInsightSparkActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightStreamingActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsHDInsightStreamingActivity() (*HDInsightStreamingActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightMapReduceActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsHDInsightMapReduceActivity() (*HDInsightMapReduceActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightPigActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsHDInsightPigActivity() (*HDInsightPigActivity, bool) {
+ return nil, false
+}
+
+// AsHDInsightHiveActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsHDInsightHiveActivity() (*HDInsightHiveActivity, bool) {
+ return nil, false
+}
+
+// AsCopyActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsCopyActivity() (*CopyActivity, bool) {
+ return nil, false
+}
+
+// AsExecutionActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsExecutionActivity() (*ExecutionActivity, bool) {
+ return nil, false
+}
+
+// AsBasicExecutionActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsBasicExecutionActivity() (BasicExecutionActivity, bool) {
+ return &wa, true
+}
+
+// AsWebHookActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsWebHookActivity() (*WebHookActivity, bool) {
+ return nil, false
+}
+
+// AsAppendVariableActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsAppendVariableActivity() (*AppendVariableActivity, bool) {
+ return nil, false
+}
+
+// AsSetVariableActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsSetVariableActivity() (*SetVariableActivity, bool) {
+ return nil, false
+}
+
+// AsFilterActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsFilterActivity() (*FilterActivity, bool) {
+ return nil, false
+}
+
+// AsValidationActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsValidationActivity() (*ValidationActivity, bool) {
+ return nil, false
+}
+
+// AsUntilActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsUntilActivity() (*UntilActivity, bool) {
+ return nil, false
+}
+
+// AsWaitActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsWaitActivity() (*WaitActivity, bool) {
+ return nil, false
+}
+
+// AsForEachActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsForEachActivity() (*ForEachActivity, bool) {
+ return nil, false
+}
+
+// AsSwitchActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
+// AsIfConditionActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
+ return nil, false
+}
+
+// AsExecutePipelineActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsExecutePipelineActivity() (*ExecutePipelineActivity, bool) {
+ return nil, false
+}
+
+// AsControlActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsControlActivity() (*ControlActivity, bool) {
+ return nil, false
+}
+
+// AsBasicControlActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsBasicControlActivity() (BasicControlActivity, bool) {
+ return nil, false
+}
+
+// AsActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsActivity() (*Activity, bool) {
+ return nil, false
+}
+
+// AsBasicActivity is the BasicActivity implementation for WebActivity.
+func (wa WebActivity) AsBasicActivity() (BasicActivity, bool) {
+ return &wa, true
+}
+
+// UnmarshalJSON is the custom unmarshaler for WebActivity struct.
+func (wa *WebActivity) UnmarshalJSON(body []byte) error {
+ var m map[string]*json.RawMessage
+ err := json.Unmarshal(body, &m)
+ if err != nil {
+ return err
+ }
+ for k, v := range m {
+ switch k {
+ case "typeProperties":
+ if v != nil {
+ var webActivityTypeProperties WebActivityTypeProperties
+ err = json.Unmarshal(*v, &webActivityTypeProperties)
+ if err != nil {
+ return err
+ }
+ wa.WebActivityTypeProperties = &webActivityTypeProperties
+ }
+ case "linkedServiceName":
+ if v != nil {
+ var linkedServiceName LinkedServiceReference
+ err = json.Unmarshal(*v, &linkedServiceName)
+ if err != nil {
+ return err
+ }
+ wa.LinkedServiceName = &linkedServiceName
+ }
+ case "policy":
+ if v != nil {
+ var policy ActivityPolicy
+ err = json.Unmarshal(*v, &policy)
+ if err != nil {
+ return err
+ }
+ wa.Policy = &policy
+ }
+ default:
+ if v != nil {
+ var additionalProperties interface{}
+ err = json.Unmarshal(*v, &additionalProperties)
+ if err != nil {
+ return err
+ }
+ if wa.AdditionalProperties == nil {
+ wa.AdditionalProperties = make(map[string]interface{})
+ }
+ wa.AdditionalProperties[k] = additionalProperties
+ }
+ case "name":
+ if v != nil {
+ var name string
+ err = json.Unmarshal(*v, &name)
+ if err != nil {
+ return err
+ }
+ wa.Name = &name
+ }
+ case "description":
+ if v != nil {
+ var description string
+ err = json.Unmarshal(*v, &description)
+ if err != nil {
+ return err
+ }
+ wa.Description = &description
+ }
+ case "dependsOn":
+ if v != nil {
+ var dependsOn []ActivityDependency
+ err = json.Unmarshal(*v, &dependsOn)
+ if err != nil {
+ return err
+ }
+ wa.DependsOn = &dependsOn
+ }
+ case "userProperties":
+ if v != nil {
+ var userProperties []UserProperty
+ err = json.Unmarshal(*v, &userProperties)
+ if err != nil {
+ return err
+ }
+ wa.UserProperties = &userProperties
+ }
+ case "type":
+ if v != nil {
+ var typeVar TypeBasicActivity
+ err = json.Unmarshal(*v, &typeVar)
+ if err != nil {
+ return err
+ }
+ wa.Type = typeVar
+ }
+ }
+ }
+
+ return nil
+}
+
+// WebActivityAuthentication web activity authentication properties.
+type WebActivityAuthentication struct {
+ // Type - Web activity authentication (Basic/ClientCertificate/MSI)
+ Type *string `json:"type,omitempty"`
+ // Pfx - Base64-encoded contents of a PFX file.
+ Pfx BasicSecretBase `json:"pfx,omitempty"`
+ // Username - Web activity authentication user name for basic authentication.
+ Username *string `json:"username,omitempty"`
+ // Password - Password for the PFX file or basic authentication.
+ Password BasicSecretBase `json:"password,omitempty"`
+ // Resource - Resource for which Azure Auth token will be requested when using MSI Authentication.
+ Resource *string `json:"resource,omitempty"`
}
-// UnmarshalJSON is the custom unmarshaler for WebActivity struct.
-func (wa *WebActivity) UnmarshalJSON(body []byte) error {
+// UnmarshalJSON is the custom unmarshaler for WebActivityAuthentication struct.
+func (waa *WebActivityAuthentication) UnmarshalJSON(body []byte) error {
var m map[string]*json.RawMessage
err := json.Unmarshal(body, &m)
if err != nil {
@@ -207974,89 +213544,48 @@ func (wa *WebActivity) UnmarshalJSON(body []byte) error {
}
for k, v := range m {
switch k {
- case "typeProperties":
- if v != nil {
- var webActivityTypeProperties WebActivityTypeProperties
- err = json.Unmarshal(*v, &webActivityTypeProperties)
- if err != nil {
- return err
- }
- wa.WebActivityTypeProperties = &webActivityTypeProperties
- }
- case "linkedServiceName":
- if v != nil {
- var linkedServiceName LinkedServiceReference
- err = json.Unmarshal(*v, &linkedServiceName)
- if err != nil {
- return err
- }
- wa.LinkedServiceName = &linkedServiceName
- }
- case "policy":
- if v != nil {
- var policy ActivityPolicy
- err = json.Unmarshal(*v, &policy)
- if err != nil {
- return err
- }
- wa.Policy = &policy
- }
- default:
+ case "type":
if v != nil {
- var additionalProperties interface{}
- err = json.Unmarshal(*v, &additionalProperties)
+ var typeVar string
+ err = json.Unmarshal(*v, &typeVar)
if err != nil {
return err
}
- if wa.AdditionalProperties == nil {
- wa.AdditionalProperties = make(map[string]interface{})
- }
- wa.AdditionalProperties[k] = additionalProperties
+ waa.Type = &typeVar
}
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- wa.Name = &name
- }
- case "description":
+ case "pfx":
if v != nil {
- var description string
- err = json.Unmarshal(*v, &description)
+ pfx, err := unmarshalBasicSecretBase(*v)
if err != nil {
return err
}
- wa.Description = &description
+ waa.Pfx = pfx
}
- case "dependsOn":
+ case "username":
if v != nil {
- var dependsOn []ActivityDependency
- err = json.Unmarshal(*v, &dependsOn)
+ var username string
+ err = json.Unmarshal(*v, &username)
if err != nil {
return err
}
- wa.DependsOn = &dependsOn
+ waa.Username = &username
}
- case "userProperties":
+ case "password":
if v != nil {
- var userProperties []UserProperty
- err = json.Unmarshal(*v, &userProperties)
+ password, err := unmarshalBasicSecretBase(*v)
if err != nil {
return err
}
- wa.UserProperties = &userProperties
+ waa.Password = password
}
- case "type":
+ case "resource":
if v != nil {
- var typeVar TypeBasicActivity
- err = json.Unmarshal(*v, &typeVar)
+ var resource string
+ err = json.Unmarshal(*v, &resource)
if err != nil {
return err
}
- wa.Type = typeVar
+ waa.Resource = &resource
}
}
}
@@ -208064,20 +213593,6 @@ func (wa *WebActivity) UnmarshalJSON(body []byte) error {
return nil
}
-// WebActivityAuthentication web activity authentication properties.
-type WebActivityAuthentication struct {
- // Type - Web activity authentication (Basic/ClientCertificate/MSI)
- Type *string `json:"type,omitempty"`
- // Pfx - Base64-encoded contents of a PFX file.
- Pfx *SecureString `json:"pfx,omitempty"`
- // Username - Web activity authentication user name for basic authentication.
- Username *string `json:"username,omitempty"`
- // Password - Password for the PFX file or basic authentication.
- Password *SecureString `json:"password,omitempty"`
- // Resource - Resource for which Azure Auth token will be requested when using MSI Authentication.
- Resource *string `json:"resource,omitempty"`
-}
-
// WebActivityTypeProperties web activity type properties.
type WebActivityTypeProperties struct {
// Method - Rest API method for target endpoint. Possible values include: 'WebActivityMethodGET', 'WebActivityMethodPOST', 'WebActivityMethodPUT', 'WebActivityMethodDELETE'
@@ -208365,7 +213880,7 @@ type WebHookActivity struct {
DependsOn *[]ActivityDependency `json:"dependsOn,omitempty"`
// UserProperties - Activity user properties.
UserProperties *[]UserProperty `json:"userProperties,omitempty"`
- // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
+ // Type - Possible values include: 'TypeActivity', 'TypeExecuteDataFlow', 'TypeAzureFunctionActivity', 'TypeDatabricksSparkPython', 'TypeDatabricksSparkJar', 'TypeDatabricksNotebook', 'TypeDataLakeAnalyticsUSQL', 'TypeAzureMLExecutePipeline', 'TypeAzureMLUpdateResource', 'TypeAzureMLBatchExecution', 'TypeGetMetadata', 'TypeWebActivity', 'TypeLookup', 'TypeAzureDataExplorerCommand', 'TypeDelete', 'TypeSQLServerStoredProcedure', 'TypeCustom', 'TypeExecuteSSISPackage', 'TypeHDInsightSpark', 'TypeHDInsightStreaming', 'TypeHDInsightMapReduce', 'TypeHDInsightPig', 'TypeHDInsightHive', 'TypeCopy', 'TypeExecution', 'TypeWebHook', 'TypeAppendVariable', 'TypeSetVariable', 'TypeFilter', 'TypeValidation', 'TypeUntil', 'TypeWait', 'TypeForEach', 'TypeSwitch', 'TypeIfCondition', 'TypeExecutePipeline', 'TypeContainer'
Type TypeBasicActivity `json:"type,omitempty"`
}
@@ -208427,6 +213942,11 @@ func (wha WebHookActivity) AsDataLakeAnalyticsUSQLActivity() (*DataLakeAnalytics
return nil, false
}
+// AsAzureMLExecutePipelineActivity is the BasicActivity implementation for WebHookActivity.
+func (wha WebHookActivity) AsAzureMLExecutePipelineActivity() (*AzureMLExecutePipelineActivity, bool) {
+ return nil, false
+}
+
// AsAzureMLUpdateResourceActivity is the BasicActivity implementation for WebHookActivity.
func (wha WebHookActivity) AsAzureMLUpdateResourceActivity() (*AzureMLUpdateResourceActivity, bool) {
return nil, false
@@ -208557,6 +214077,11 @@ func (wha WebHookActivity) AsForEachActivity() (*ForEachActivity, bool) {
return nil, false
}
+// AsSwitchActivity is the BasicActivity implementation for WebHookActivity.
+func (wha WebHookActivity) AsSwitchActivity() (*SwitchActivity, bool) {
+ return nil, false
+}
+
// AsIfConditionActivity is the BasicActivity implementation for WebHookActivity.
func (wha WebHookActivity) AsIfConditionActivity() (*IfConditionActivity, bool) {
return nil, false
@@ -208698,7 +214223,7 @@ type WebLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -209068,6 +214593,11 @@ func (wls WebLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for WebLinkedService.
+func (wls WebLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for WebLinkedService.
func (wls WebLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -209108,6 +214638,16 @@ func (wls WebLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool)
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for WebLinkedService.
+func (wls WebLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for WebLinkedService.
+func (wls WebLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for WebLinkedService.
func (wls WebLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -210559,7 +216099,7 @@ type XeroLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -210931,6 +216471,11 @@ func (xls XeroLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for XeroLinkedService.
+func (xls XeroLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for XeroLinkedService.
func (xls XeroLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -210971,6 +216516,16 @@ func (xls XeroLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for XeroLinkedService.
+func (xls XeroLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for XeroLinkedService.
+func (xls XeroLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for XeroLinkedService.
func (xls XeroLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
@@ -212437,7 +217992,7 @@ type ZohoLinkedService struct {
Parameters map[string]*ParameterSpecification `json:"parameters"`
// Annotations - List of tags that can be used for describing the linked service.
Annotations *[]interface{} `json:"annotations,omitempty"`
- // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
+ // Type - Possible values include: 'TypeLinkedService', 'TypeAzureFunction', 'TypeAzureDataExplorer', 'TypeSapTable', 'TypeGoogleAdWords', 'TypeOracleServiceCloud', 'TypeDynamicsAX', 'TypeResponsys', 'TypeAzureDatabricks', 'TypeAzureDataLakeAnalytics', 'TypeHDInsightOnDemand', 'TypeSalesforceMarketingCloud', 'TypeNetezza', 'TypeVertica', 'TypeZoho', 'TypeXero', 'TypeSquare', 'TypeSpark', 'TypeShopify', 'TypeServiceNow', 'TypeQuickBooks', 'TypePresto', 'TypePhoenix', 'TypePaypal', 'TypeMarketo', 'TypeAzureMariaDB', 'TypeMariaDB', 'TypeMagento', 'TypeJira', 'TypeImpala', 'TypeHubspot', 'TypeHive', 'TypeHBase', 'TypeGreenplum', 'TypeGoogleBigQuery', 'TypeEloqua', 'TypeDrill', 'TypeCouchbase', 'TypeConcur', 'TypeAzurePostgreSQL', 'TypeAmazonMWS', 'TypeSapHana', 'TypeSapBW', 'TypeSftp', 'TypeFtpServer', 'TypeHTTPServer', 'TypeAzureSearch', 'TypeCustomDataSource', 'TypeAmazonRedshift', 'TypeAmazonS3', 'TypeRestService', 'TypeSapOpenHub', 'TypeSapEcc', 'TypeSapCloudForCustomer', 'TypeSalesforceServiceCloud', 'TypeSalesforce', 'TypeOffice365', 'TypeAzureBlobFS', 'TypeAzureDataLakeStore', 'TypeCosmosDbMongoDbAPI', 'TypeMongoDbV2', 'TypeMongoDb', 'TypeCassandra', 'TypeWeb', 'TypeOData', 'TypeHdfs', 'TypeMicrosoftAccess', 'TypeInformix', 'TypeOdbc', 'TypeAzureMLService', 'TypeAzureML', 'TypeTeradata', 'TypeDb2', 'TypeSybase', 'TypePostgreSQL', 'TypeMySQL', 'TypeAzureMySQL', 'TypeOracle', 'TypeGoogleCloudStorage', 'TypeAzureFileStorage', 'TypeFileServer', 'TypeHDInsight', 'TypeCommonDataServiceForApps', 'TypeDynamicsCrm', 'TypeDynamics', 'TypeCosmosDb', 'TypeAzureKeyVault', 'TypeAzureBatch', 'TypeAzureSQLMI', 'TypeAzureSQLDatabase', 'TypeSQLServer', 'TypeAzureSQLDW', 'TypeAzureTableStorage', 'TypeAzureBlobStorage', 'TypeAzureStorage'
Type TypeBasicLinkedService `json:"type,omitempty"`
}
@@ -212809,6 +218364,11 @@ func (zls ZohoLinkedService) AsOdbcLinkedService() (*OdbcLinkedService, bool) {
return nil, false
}
+// AsAzureMLServiceLinkedService is the BasicLinkedService implementation for ZohoLinkedService.
+func (zls ZohoLinkedService) AsAzureMLServiceLinkedService() (*AzureMLServiceLinkedService, bool) {
+ return nil, false
+}
+
// AsAzureMLLinkedService is the BasicLinkedService implementation for ZohoLinkedService.
func (zls ZohoLinkedService) AsAzureMLLinkedService() (*AzureMLLinkedService, bool) {
return nil, false
@@ -212849,6 +218409,16 @@ func (zls ZohoLinkedService) AsOracleLinkedService() (*OracleLinkedService, bool
return nil, false
}
+// AsGoogleCloudStorageLinkedService is the BasicLinkedService implementation for ZohoLinkedService.
+func (zls ZohoLinkedService) AsGoogleCloudStorageLinkedService() (*GoogleCloudStorageLinkedService, bool) {
+ return nil, false
+}
+
+// AsAzureFileStorageLinkedService is the BasicLinkedService implementation for ZohoLinkedService.
+func (zls ZohoLinkedService) AsAzureFileStorageLinkedService() (*AzureFileStorageLinkedService, bool) {
+ return nil, false
+}
+
// AsFileServerLinkedService is the BasicLinkedService implementation for ZohoLinkedService.
func (zls ZohoLinkedService) AsFileServerLinkedService() (*FileServerLinkedService, bool) {
return nil, false
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go
index c8679a059aff..ec244d5e7a5c 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight/models.go
@@ -30,34 +30,6 @@ import (
// The package's fully qualified name.
const fqdn = "github.com/Azure/azure-sdk-for-go/services/preview/hdinsight/mgmt/2018-06-01-preview/hdinsight"
-// ApplicationHTTPSEndpointAccessMode enumerates the values for application https endpoint access mode.
-type ApplicationHTTPSEndpointAccessMode string
-
-const (
- // WebPage ...
- WebPage ApplicationHTTPSEndpointAccessMode = "WebPage"
-)
-
-// PossibleApplicationHTTPSEndpointAccessModeValues returns an array of possible values for the ApplicationHTTPSEndpointAccessMode const type.
-func PossibleApplicationHTTPSEndpointAccessModeValues() []ApplicationHTTPSEndpointAccessMode {
- return []ApplicationHTTPSEndpointAccessMode{WebPage}
-}
-
-// ApplicationType enumerates the values for application type.
-type ApplicationType string
-
-const (
- // CustomApplication ...
- CustomApplication ApplicationType = "CustomApplication"
- // RServer ...
- RServer ApplicationType = "RServer"
-)
-
-// PossibleApplicationTypeValues returns an array of possible values for the ApplicationType const type.
-func PossibleApplicationTypeValues() []ApplicationType {
- return []ApplicationType{CustomApplication, RServer}
-}
-
// AsyncOperationState enumerates the values for async operation state.
type AsyncOperationState string
@@ -260,7 +232,7 @@ type ApplicationGetEndpoint struct {
// ApplicationGetHTTPSEndpoint gets the application HTTP endpoints.
type ApplicationGetHTTPSEndpoint struct {
// AccessModes - The list of access modes for the application.
- AccessModes *[]ApplicationHTTPSEndpointAccessMode `json:"accessModes,omitempty"`
+ AccessModes *[]string `json:"accessModes,omitempty"`
// Location - The location of the endpoint.
Location *string `json:"location,omitempty"`
// DestinationPort - The destination port to connect to.
@@ -434,8 +406,8 @@ type ApplicationProperties struct {
SSHEndpoints *[]ApplicationGetEndpoint `json:"sshEndpoints,omitempty"`
// ProvisioningState - READ-ONLY; The provisioning state of the application.
ProvisioningState *string `json:"provisioningState,omitempty"`
- // ApplicationType - The application type. Possible values include: 'CustomApplication', 'RServer'
- ApplicationType ApplicationType `json:"applicationType,omitempty"`
+ // ApplicationType - The application type.
+ ApplicationType *string `json:"applicationType,omitempty"`
// ApplicationState - READ-ONLY; The application state.
ApplicationState *string `json:"applicationState,omitempty"`
// Errors - The list of errors.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go
index b71302b59126..a47383465675 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/operationalinsights/mgmt/2015-11-01-preview/operationalinsights/models.go
@@ -872,11 +872,11 @@ type WorkspaceListUsagesResult struct {
type WorkspaceProperties struct {
// ProvisioningState - The provisioning state of the workspace. Possible values include: 'Creating', 'Succeeded', 'Failed', 'Canceled', 'Deleting', 'ProvisioningAccount'
ProvisioningState EntityStatus `json:"provisioningState,omitempty"`
- // Source - The source of the workspace. Source defines where the workspace was created. 'Azure' implies it was created in Azure. 'External' implies it was created via the Operational Insights Portal. This value is set on the service side and read-only on the client side.
+ // Source - READ-ONLY; This is a read-only legacy property. It is always set to 'Azure' by the service. Kept here for backward compatibility.
Source *string `json:"source,omitempty"`
- // CustomerID - The ID associated with the workspace. Setting this value at creation time allows the workspace being created to be linked to an existing workspace.
+ // CustomerID - READ-ONLY; This is a read-only property. Represents the ID associated with the workspace.
CustomerID *string `json:"customerId,omitempty"`
- // PortalURL - The URL of the Operational Insights portal for this workspace. This value is set on the service side and read-only on the client side.
+ // PortalURL - READ-ONLY; This is a legacy property and is not used anymore. Kept here for backward compatibility.
PortalURL *string `json:"portalUrl,omitempty"`
// Sku - The SKU of the workspace.
Sku *Sku `json:"sku,omitempty"`
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionpolicies.go
index f603ba468134..d106b0595037 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionpolicies.go
@@ -1,298 +1,298 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// BackupLongTermRetentionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type BackupLongTermRetentionPoliciesClient struct {
- BaseClient
-}
-
-// NewBackupLongTermRetentionPoliciesClient creates an instance of the BackupLongTermRetentionPoliciesClient client.
-func NewBackupLongTermRetentionPoliciesClient(subscriptionID string) BackupLongTermRetentionPoliciesClient {
- return NewBackupLongTermRetentionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewBackupLongTermRetentionPoliciesClientWithBaseURI creates an instance of the BackupLongTermRetentionPoliciesClient
-// client.
-func NewBackupLongTermRetentionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) BackupLongTermRetentionPoliciesClient {
- return BackupLongTermRetentionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database backup long term retention policy
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database
-// parameters - the required parameters to update a backup long term retention policy
-func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters BackupLongTermRetentionPolicy) (result BackupLongTermRetentionPoliciesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionPolicyProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionPolicyProperties.RecoveryServicesBackupPolicyResourceID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters BackupLongTermRetentionPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "backupLongTermRetentionPolicyName": autorest.Encode("path", "Default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{backupLongTermRetentionPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdateSender(req *http.Request) (future BackupLongTermRetentionPoliciesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result BackupLongTermRetentionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get returns a database backup long term retention policy
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client BackupLongTermRetentionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result BackupLongTermRetentionPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client BackupLongTermRetentionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "backupLongTermRetentionPolicyName": autorest.Encode("path", "Default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{backupLongTermRetentionPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionPoliciesClient) GetResponder(resp *http.Response) (result BackupLongTermRetentionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase returns a database backup long term retention policy
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client BackupLongTermRetentionPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result BackupLongTermRetentionPolicyListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client BackupLongTermRetentionPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result BackupLongTermRetentionPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// BackupLongTermRetentionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type BackupLongTermRetentionPoliciesClient struct {
+ BaseClient
+}
+
+// NewBackupLongTermRetentionPoliciesClient creates an instance of the BackupLongTermRetentionPoliciesClient client.
+func NewBackupLongTermRetentionPoliciesClient(subscriptionID string) BackupLongTermRetentionPoliciesClient {
+ return NewBackupLongTermRetentionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewBackupLongTermRetentionPoliciesClientWithBaseURI creates an instance of the BackupLongTermRetentionPoliciesClient
+// client.
+func NewBackupLongTermRetentionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) BackupLongTermRetentionPoliciesClient {
+ return BackupLongTermRetentionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database backup long term retention policy
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database
+// parameters - the required parameters to update a backup long term retention policy
+func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters BackupLongTermRetentionPolicy) (result BackupLongTermRetentionPoliciesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionPolicyProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionPolicyProperties.RecoveryServicesBackupPolicyResourceID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters BackupLongTermRetentionPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupLongTermRetentionPolicyName": autorest.Encode("path", "Default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{backupLongTermRetentionPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdateSender(req *http.Request) (future BackupLongTermRetentionPoliciesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result BackupLongTermRetentionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get returns a database backup long term retention policy
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client BackupLongTermRetentionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result BackupLongTermRetentionPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client BackupLongTermRetentionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupLongTermRetentionPolicyName": autorest.Encode("path", "Default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{backupLongTermRetentionPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionPoliciesClient) GetResponder(resp *http.Response) (result BackupLongTermRetentionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase returns a database backup long term retention policy
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client BackupLongTermRetentionPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result BackupLongTermRetentionPolicyListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client BackupLongTermRetentionPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result BackupLongTermRetentionPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionvaults.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionvaults.go
index a2bdd813127b..da3db554f53d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionvaults.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/backuplongtermretentionvaults.go
@@ -1,292 +1,292 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// BackupLongTermRetentionVaultsClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type BackupLongTermRetentionVaultsClient struct {
- BaseClient
-}
-
-// NewBackupLongTermRetentionVaultsClient creates an instance of the BackupLongTermRetentionVaultsClient client.
-func NewBackupLongTermRetentionVaultsClient(subscriptionID string) BackupLongTermRetentionVaultsClient {
- return NewBackupLongTermRetentionVaultsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewBackupLongTermRetentionVaultsClientWithBaseURI creates an instance of the BackupLongTermRetentionVaultsClient
-// client.
-func NewBackupLongTermRetentionVaultsClientWithBaseURI(baseURI string, subscriptionID string) BackupLongTermRetentionVaultsClient {
- return BackupLongTermRetentionVaultsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate updates a server backup long term retention vault
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the required parameters to update a backup long term retention vault
-func (client BackupLongTermRetentionVaultsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters BackupLongTermRetentionVault) (result BackupLongTermRetentionVaultsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionVaultProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionVaultProperties.RecoveryServicesVaultResourceID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client BackupLongTermRetentionVaultsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters BackupLongTermRetentionVault) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "backupLongTermRetentionVaultName": autorest.Encode("path", "RegisteredVault"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/backupLongTermRetentionVaults/{backupLongTermRetentionVaultName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionVaultsClient) CreateOrUpdateSender(req *http.Request) (future BackupLongTermRetentionVaultsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionVaultsClient) CreateOrUpdateResponder(resp *http.Response) (result BackupLongTermRetentionVault, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a server backup long term retention vault
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client BackupLongTermRetentionVaultsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result BackupLongTermRetentionVault, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client BackupLongTermRetentionVaultsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "backupLongTermRetentionVaultName": autorest.Encode("path", "RegisteredVault"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/backupLongTermRetentionVaults/{backupLongTermRetentionVaultName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionVaultsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionVaultsClient) GetResponder(resp *http.Response) (result BackupLongTermRetentionVault, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets server backup long term retention vaults in a server
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client BackupLongTermRetentionVaultsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result BackupLongTermRetentionVaultListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client BackupLongTermRetentionVaultsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/backupLongTermRetentionVaults", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client BackupLongTermRetentionVaultsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client BackupLongTermRetentionVaultsClient) ListByServerResponder(resp *http.Response) (result BackupLongTermRetentionVaultListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// BackupLongTermRetentionVaultsClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type BackupLongTermRetentionVaultsClient struct {
+ BaseClient
+}
+
+// NewBackupLongTermRetentionVaultsClient creates an instance of the BackupLongTermRetentionVaultsClient client.
+func NewBackupLongTermRetentionVaultsClient(subscriptionID string) BackupLongTermRetentionVaultsClient {
+ return NewBackupLongTermRetentionVaultsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewBackupLongTermRetentionVaultsClientWithBaseURI creates an instance of the BackupLongTermRetentionVaultsClient
+// client.
+func NewBackupLongTermRetentionVaultsClientWithBaseURI(baseURI string, subscriptionID string) BackupLongTermRetentionVaultsClient {
+ return BackupLongTermRetentionVaultsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate updates a server backup long term retention vault
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the required parameters to update a backup long term retention vault
+func (client BackupLongTermRetentionVaultsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters BackupLongTermRetentionVault) (result BackupLongTermRetentionVaultsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionVaultProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.BackupLongTermRetentionVaultProperties.RecoveryServicesVaultResourceID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client BackupLongTermRetentionVaultsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters BackupLongTermRetentionVault) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupLongTermRetentionVaultName": autorest.Encode("path", "RegisteredVault"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/backupLongTermRetentionVaults/{backupLongTermRetentionVaultName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionVaultsClient) CreateOrUpdateSender(req *http.Request) (future BackupLongTermRetentionVaultsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionVaultsClient) CreateOrUpdateResponder(resp *http.Response) (result BackupLongTermRetentionVault, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a server backup long term retention vault
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client BackupLongTermRetentionVaultsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result BackupLongTermRetentionVault, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client BackupLongTermRetentionVaultsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupLongTermRetentionVaultName": autorest.Encode("path", "RegisteredVault"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/backupLongTermRetentionVaults/{backupLongTermRetentionVaultName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionVaultsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionVaultsClient) GetResponder(resp *http.Response) (result BackupLongTermRetentionVault, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets server backup long term retention vaults in a server
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client BackupLongTermRetentionVaultsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result BackupLongTermRetentionVaultListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/BackupLongTermRetentionVaultsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.BackupLongTermRetentionVaultsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client BackupLongTermRetentionVaultsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/backupLongTermRetentionVaults", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client BackupLongTermRetentionVaultsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client BackupLongTermRetentionVaultsClient) ListByServerResponder(resp *http.Response) (result BackupLongTermRetentionVaultListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/capabilities.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/capabilities.go
index 9bd69bc43e1c..c5718dd09fbe 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/capabilities.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/capabilities.go
@@ -1,118 +1,118 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// CapabilitiesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type CapabilitiesClient struct {
- BaseClient
-}
-
-// NewCapabilitiesClient creates an instance of the CapabilitiesClient client.
-func NewCapabilitiesClient(subscriptionID string) CapabilitiesClient {
- return NewCapabilitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewCapabilitiesClientWithBaseURI creates an instance of the CapabilitiesClient client.
-func NewCapabilitiesClientWithBaseURI(baseURI string, subscriptionID string) CapabilitiesClient {
- return CapabilitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByLocation gets the capabilities available for the specified location.
-// Parameters:
-// locationID - the location id whose capabilities are retrieved.
-func (client CapabilitiesClient) ListByLocation(ctx context.Context, locationID string) (result LocationCapabilities, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/CapabilitiesClient.ListByLocation")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByLocationPreparer(ctx, locationID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByLocationSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByLocationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByLocationPreparer prepares the ListByLocation request.
-func (client CapabilitiesClient) ListByLocationPreparer(ctx context.Context, locationID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "locationId": autorest.Encode("path", locationID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationId}/capabilities", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByLocationSender sends the ListByLocation request. The method will close the
-// http.Response Body if it receives an error.
-func (client CapabilitiesClient) ListByLocationSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByLocationResponder handles the response to the ListByLocation request. The method always
-// closes the http.Response Body.
-func (client CapabilitiesClient) ListByLocationResponder(resp *http.Response) (result LocationCapabilities, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// CapabilitiesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type CapabilitiesClient struct {
+ BaseClient
+}
+
+// NewCapabilitiesClient creates an instance of the CapabilitiesClient client.
+func NewCapabilitiesClient(subscriptionID string) CapabilitiesClient {
+ return NewCapabilitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewCapabilitiesClientWithBaseURI creates an instance of the CapabilitiesClient client.
+func NewCapabilitiesClientWithBaseURI(baseURI string, subscriptionID string) CapabilitiesClient {
+ return CapabilitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByLocation gets the capabilities available for the specified location.
+// Parameters:
+// locationID - the location id whose capabilities are retrieved.
+func (client CapabilitiesClient) ListByLocation(ctx context.Context, locationID string) (result LocationCapabilities, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/CapabilitiesClient.ListByLocation")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByLocationPreparer(ctx, locationID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByLocationSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByLocationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.CapabilitiesClient", "ListByLocation", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByLocationPreparer prepares the ListByLocation request.
+func (client CapabilitiesClient) ListByLocationPreparer(ctx context.Context, locationID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "locationId": autorest.Encode("path", locationID),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationId}/capabilities", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByLocationSender sends the ListByLocation request. The method will close the
+// http.Response Body if it receives an error.
+func (client CapabilitiesClient) ListByLocationSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByLocationResponder handles the response to the ListByLocation request. The method always
+// closes the http.Response Body.
+func (client CapabilitiesClient) ListByLocationResponder(resp *http.Response) (result LocationCapabilities, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/client.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/client.go
index 49628f84de47..40ec57b36bab 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/client.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/client.go
@@ -1,52 +1,52 @@
-// Package sql implements the Azure ARM Sql service API version .
-//
-// The Azure SQL Database management API provides a RESTful set of web services that interact with Azure SQL Database
-// services to manage your databases. The API enables you to create, retrieve, update, and delete databases.
-package sql
-
-// 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"
-)
-
-const (
- // DefaultBaseURI is the default URI used for the service Sql
- DefaultBaseURI = "https://management.azure.com"
-)
-
-// BaseClient is the base client for Sql.
-type BaseClient struct {
- autorest.Client
- BaseURI string
- SubscriptionID string
-}
-
-// New creates an instance of the BaseClient client.
-func New(subscriptionID string) BaseClient {
- return NewWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewWithBaseURI creates an instance of the BaseClient client.
-func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient {
- return BaseClient{
- Client: autorest.NewClientWithUserAgent(UserAgent()),
- BaseURI: baseURI,
- SubscriptionID: subscriptionID,
- }
-}
+// Package sql implements the Azure ARM Sql service API version .
+//
+// The Azure SQL Database management API provides a RESTful set of web services that interact with Azure SQL Database
+// services to manage your databases. The API enables you to create, retrieve, update, and delete databases.
+package sql
+
+// 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"
+)
+
+const (
+ // DefaultBaseURI is the default URI used for the service Sql
+ DefaultBaseURI = "https://management.azure.com"
+)
+
+// BaseClient is the base client for Sql.
+type BaseClient struct {
+ autorest.Client
+ BaseURI string
+ SubscriptionID string
+}
+
+// New creates an instance of the BaseClient client.
+func New(subscriptionID string) BaseClient {
+ return NewWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewWithBaseURI creates an instance of the BaseClient client.
+func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient {
+ return BaseClient{
+ Client: autorest.NewClientWithUserAgent(UserAgent()),
+ BaseURI: baseURI,
+ SubscriptionID: subscriptionID,
+ }
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseautomatictuning.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseautomatictuning.go
index d3be20fc4e0d..2b7edb2d0e14 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseautomatictuning.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseautomatictuning.go
@@ -1,206 +1,206 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseAutomaticTuningClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type DatabaseAutomaticTuningClient struct {
- BaseClient
-}
-
-// NewDatabaseAutomaticTuningClient creates an instance of the DatabaseAutomaticTuningClient client.
-func NewDatabaseAutomaticTuningClient(subscriptionID string) DatabaseAutomaticTuningClient {
- return NewDatabaseAutomaticTuningClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseAutomaticTuningClientWithBaseURI creates an instance of the DatabaseAutomaticTuningClient client.
-func NewDatabaseAutomaticTuningClientWithBaseURI(baseURI string, subscriptionID string) DatabaseAutomaticTuningClient {
- return DatabaseAutomaticTuningClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a database's automatic tuning.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabaseAutomaticTuningClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseAutomaticTuning, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseAutomaticTuningClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabaseAutomaticTuningClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/automaticTuning/current", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseAutomaticTuningClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabaseAutomaticTuningClient) GetResponder(resp *http.Response) (result DatabaseAutomaticTuning, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Update update automatic tuning properties for target database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - the requested automatic tuning resource state.
-func (client DatabaseAutomaticTuningClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseAutomaticTuning) (result DatabaseAutomaticTuning, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseAutomaticTuningClient.Update")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.UpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", resp, "Failure sending request")
- return
- }
-
- result, err = client.UpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", resp, "Failure responding to request")
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client DatabaseAutomaticTuningClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseAutomaticTuning) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/automaticTuning/current", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseAutomaticTuningClient) UpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client DatabaseAutomaticTuningClient) UpdateResponder(resp *http.Response) (result DatabaseAutomaticTuning, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseAutomaticTuningClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type DatabaseAutomaticTuningClient struct {
+ BaseClient
+}
+
+// NewDatabaseAutomaticTuningClient creates an instance of the DatabaseAutomaticTuningClient client.
+func NewDatabaseAutomaticTuningClient(subscriptionID string) DatabaseAutomaticTuningClient {
+ return NewDatabaseAutomaticTuningClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseAutomaticTuningClientWithBaseURI creates an instance of the DatabaseAutomaticTuningClient client.
+func NewDatabaseAutomaticTuningClientWithBaseURI(baseURI string, subscriptionID string) DatabaseAutomaticTuningClient {
+ return DatabaseAutomaticTuningClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a database's automatic tuning.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabaseAutomaticTuningClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseAutomaticTuning, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseAutomaticTuningClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabaseAutomaticTuningClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/automaticTuning/current", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseAutomaticTuningClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabaseAutomaticTuningClient) GetResponder(resp *http.Response) (result DatabaseAutomaticTuning, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Update update automatic tuning properties for target database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - the requested automatic tuning resource state.
+func (client DatabaseAutomaticTuningClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseAutomaticTuning) (result DatabaseAutomaticTuning, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseAutomaticTuningClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseAutomaticTuningClient", "Update", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client DatabaseAutomaticTuningClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseAutomaticTuning) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/automaticTuning/current", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseAutomaticTuningClient) UpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client DatabaseAutomaticTuningClient) UpdateResponder(resp *http.Response) (result DatabaseAutomaticTuning, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseblobauditingpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseblobauditingpolicies.go
index 4c23981350b3..8e61953bbeae 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseblobauditingpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseblobauditingpolicies.go
@@ -1,328 +1,328 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type DatabaseBlobAuditingPoliciesClient struct {
- BaseClient
-}
-
-// NewDatabaseBlobAuditingPoliciesClient creates an instance of the DatabaseBlobAuditingPoliciesClient client.
-func NewDatabaseBlobAuditingPoliciesClient(subscriptionID string) DatabaseBlobAuditingPoliciesClient {
- return NewDatabaseBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseBlobAuditingPoliciesClientWithBaseURI creates an instance of the DatabaseBlobAuditingPoliciesClient
-// client.
-func NewDatabaseBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseBlobAuditingPoliciesClient {
- return DatabaseBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - the database blob auditing policy.
-func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseBlobAuditingPolicy) (result DatabaseBlobAuditingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseBlobAuditingPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a database's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabaseBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabaseBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabaseBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result DatabaseBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase lists auditing settings of a database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabaseBlobAuditingPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicyListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.dbaplr.Response.Response != nil {
- sc = result.dbaplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByDatabaseNextResults
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.dbaplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result.dbaplr, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client DatabaseBlobAuditingPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseBlobAuditingPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByDatabaseNextResults retrieves the next set of results, if any.
-func (client DatabaseBlobAuditingPoliciesClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseBlobAuditingPolicyListResult) (result DatabaseBlobAuditingPolicyListResult, err error) {
- req, err := lastResults.databaseBlobAuditingPolicyListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicyListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type DatabaseBlobAuditingPoliciesClient struct {
+ BaseClient
+}
+
+// NewDatabaseBlobAuditingPoliciesClient creates an instance of the DatabaseBlobAuditingPoliciesClient client.
+func NewDatabaseBlobAuditingPoliciesClient(subscriptionID string) DatabaseBlobAuditingPoliciesClient {
+ return NewDatabaseBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseBlobAuditingPoliciesClientWithBaseURI creates an instance of the DatabaseBlobAuditingPoliciesClient
+// client.
+func NewDatabaseBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseBlobAuditingPoliciesClient {
+ return DatabaseBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - the database blob auditing policy.
+func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseBlobAuditingPolicy) (result DatabaseBlobAuditingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseBlobAuditingPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DatabaseBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a database's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabaseBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabaseBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabaseBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result DatabaseBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase lists auditing settings of a database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabaseBlobAuditingPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicyListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.dbaplr.Response.Response != nil {
+ sc = result.dbaplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByDatabaseNextResults
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.dbaplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.dbaplr, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client DatabaseBlobAuditingPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/auditingSettings", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseBlobAuditingPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByDatabaseNextResults retrieves the next set of results, if any.
+func (client DatabaseBlobAuditingPoliciesClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseBlobAuditingPolicyListResult) (result DatabaseBlobAuditingPolicyListResult, err error) {
+ req, err := lastResults.databaseBlobAuditingPolicyListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseBlobAuditingPoliciesClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client DatabaseBlobAuditingPoliciesClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseBlobAuditingPolicyListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseBlobAuditingPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseoperations.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseoperations.go
index 10e844c24b94..b9960bcb12e8 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseoperations.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseoperations.go
@@ -1,243 +1,243 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "github.com/satori/go.uuid"
- "net/http"
-)
-
-// DatabaseOperationsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type DatabaseOperationsClient struct {
- BaseClient
-}
-
-// NewDatabaseOperationsClient creates an instance of the DatabaseOperationsClient client.
-func NewDatabaseOperationsClient(subscriptionID string) DatabaseOperationsClient {
- return NewDatabaseOperationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseOperationsClientWithBaseURI creates an instance of the DatabaseOperationsClient client.
-func NewDatabaseOperationsClientWithBaseURI(baseURI string, subscriptionID string) DatabaseOperationsClient {
- return DatabaseOperationsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Cancel cancels the asynchronous operation on the database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// operationID - the operation identifier.
-func (client DatabaseOperationsClient) Cancel(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.Cancel")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CancelPreparer(ctx, resourceGroupName, serverName, databaseName, operationID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CancelSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", resp, "Failure sending request")
- return
- }
-
- result, err = client.CancelResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CancelPreparer prepares the Cancel request.
-func (client DatabaseOperationsClient) CancelPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "operationId": autorest.Encode("path", operationID),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/operations/{operationId}/cancel", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CancelSender sends the Cancel request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseOperationsClient) CancelSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CancelResponder handles the response to the Cancel request. The method always
-// closes the http.Response Body.
-func (client DatabaseOperationsClient) CancelResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// ListByDatabase gets a list of operations performed on the database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabaseOperationsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseOperationListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.dolr.Response.Response != nil {
- sc = result.dolr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByDatabaseNextResults
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.dolr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result.dolr, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client DatabaseOperationsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/operations", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseOperationsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client DatabaseOperationsClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseOperationListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByDatabaseNextResults retrieves the next set of results, if any.
-func (client DatabaseOperationsClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseOperationListResult) (result DatabaseOperationListResult, err error) {
- req, err := lastResults.databaseOperationListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client DatabaseOperationsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseOperationListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "github.com/satori/go.uuid"
+ "net/http"
+)
+
+// DatabaseOperationsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type DatabaseOperationsClient struct {
+ BaseClient
+}
+
+// NewDatabaseOperationsClient creates an instance of the DatabaseOperationsClient client.
+func NewDatabaseOperationsClient(subscriptionID string) DatabaseOperationsClient {
+ return NewDatabaseOperationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseOperationsClientWithBaseURI creates an instance of the DatabaseOperationsClient client.
+func NewDatabaseOperationsClientWithBaseURI(baseURI string, subscriptionID string) DatabaseOperationsClient {
+ return DatabaseOperationsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Cancel cancels the asynchronous operation on the database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// operationID - the operation identifier.
+func (client DatabaseOperationsClient) Cancel(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.Cancel")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CancelPreparer(ctx, resourceGroupName, serverName, databaseName, operationID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CancelSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CancelResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "Cancel", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CancelPreparer prepares the Cancel request.
+func (client DatabaseOperationsClient) CancelPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "operationId": autorest.Encode("path", operationID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/operations/{operationId}/cancel", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CancelSender sends the Cancel request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseOperationsClient) CancelSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CancelResponder handles the response to the Cancel request. The method always
+// closes the http.Response Body.
+func (client DatabaseOperationsClient) CancelResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// ListByDatabase gets a list of operations performed on the database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabaseOperationsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseOperationListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.dolr.Response.Response != nil {
+ sc = result.dolr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByDatabaseNextResults
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.dolr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.dolr, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client DatabaseOperationsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/operations", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseOperationsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client DatabaseOperationsClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseOperationListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByDatabaseNextResults retrieves the next set of results, if any.
+func (client DatabaseOperationsClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseOperationListResult) (result DatabaseOperationListResult, err error) {
+ req, err := lastResults.databaseOperationListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseOperationsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client DatabaseOperationsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseOperationListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseOperationsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databases.go
index 19139735af10..327d066b6f53 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databases.go
@@ -1,1466 +1,1466 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type DatabasesClient struct {
- BaseClient
-}
-
-// NewDatabasesClient creates an instance of the DatabasesClient client.
-func NewDatabasesClient(subscriptionID string) DatabasesClient {
- return NewDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabasesClientWithBaseURI creates an instance of the DatabasesClient client.
-func NewDatabasesClientWithBaseURI(baseURI string, subscriptionID string) DatabasesClient {
- return DatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateImportOperation creates an import operation that imports a bacpac into an existing database. The existing
-// database must be empty.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to import into
-// parameters - the required parameters for importing a Bacpac into a database.
-func (client DatabasesClient) CreateImportOperation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ImportExtensionRequest) (result DatabasesCreateImportOperationFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.CreateImportOperation")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.ImportExtensionProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.ImportExtensionProperties.OperationMode", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.DatabasesClient", "CreateImportOperation", err.Error())
- }
-
- req, err := client.CreateImportOperationPreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateImportOperation", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateImportOperationSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateImportOperation", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateImportOperationPreparer prepares the CreateImportOperation request.
-func (client DatabasesClient) CreateImportOperationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ImportExtensionRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "extensionName": autorest.Encode("path", "import"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extensions/{extensionName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateImportOperationSender sends the CreateImportOperation request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) CreateImportOperationSender(req *http.Request) (future DatabasesCreateImportOperationFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateImportOperationResponder handles the response to the CreateImportOperation request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) CreateImportOperationResponder(resp *http.Response) (result ImportExportResponse, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// CreateOrUpdate creates a new database or updates an existing database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to be operated on (updated or created).
-// parameters - the required parameters for creating or updating a database.
-func (client DatabasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters Database) (result DatabasesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DatabasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters Database) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) CreateOrUpdateSender(req *http.Request) (future DatabasesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) CreateOrUpdateResponder(resp *http.Response) (result Database, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to be deleted.
-func (client DatabasesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client DatabasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) 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
-}
-
-// Export exports a database to a bacpac.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to be exported.
-// parameters - the required parameters for exporting a database.
-func (client DatabasesClient) Export(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExportRequest) (result DatabasesExportFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Export")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.StorageKey", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.StorageURI", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.AdministratorLogin", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.AdministratorLoginPassword", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.DatabasesClient", "Export", err.Error())
- }
-
- req, err := client.ExportPreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Export", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ExportSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Export", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ExportPreparer prepares the Export request.
-func (client DatabasesClient) ExportPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExportRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/export", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ExportSender sends the Export request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ExportSender(req *http.Request) (future DatabasesExportFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ExportResponder handles the response to the Export request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ExportResponder(resp *http.Response) (result ImportExportResponse, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to be retrieved.
-// expand - a comma separated list of child objects to expand in the response. Possible properties:
-// serviceTierAdvisors, transparentDataEncryption.
-func (client DatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, expand string) (result Database, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, expand)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, expand string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if len(expand) > 0 {
- queryParameters["$expand"] = autorest.Encode("query", expand)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) GetResponder(resp *http.Response) (result Database, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetByElasticPool gets a database inside of an elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be retrieved.
-// databaseName - the name of the database to be retrieved.
-func (client DatabasesClient) GetByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, databaseName string) (result Database, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.GetByElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetByElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetByElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetByElasticPoolPreparer prepares the GetByElasticPool request.
-func (client DatabasesClient) GetByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetByElasticPoolSender sends the GetByElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) GetByElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetByElasticPoolResponder handles the response to the GetByElasticPool request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) GetByElasticPoolResponder(resp *http.Response) (result Database, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetByRecommendedElasticPool gets a database inside of a recommended elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// recommendedElasticPoolName - the name of the elastic pool to be retrieved.
-// databaseName - the name of the database to be retrieved.
-func (client DatabasesClient) GetByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string, databaseName string) (result Database, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.GetByRecommendedElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetByRecommendedElasticPoolPreparer(ctx, resourceGroupName, serverName, recommendedElasticPoolName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetByRecommendedElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetByRecommendedElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetByRecommendedElasticPoolPreparer prepares the GetByRecommendedElasticPool request.
-func (client DatabasesClient) GetByRecommendedElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "recommendedElasticPoolName": autorest.Encode("path", recommendedElasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/recommendedElasticPools/{recommendedElasticPoolName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetByRecommendedElasticPoolSender sends the GetByRecommendedElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) GetByRecommendedElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetByRecommendedElasticPoolResponder handles the response to the GetByRecommendedElasticPool request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) GetByRecommendedElasticPoolResponder(resp *http.Response) (result Database, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Import imports a bacpac into a new database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the required parameters for importing a Bacpac into a database.
-func (client DatabasesClient) Import(ctx context.Context, resourceGroupName string, serverName string, parameters ImportRequest) (result DatabasesImportFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Import")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.DatabaseName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.MaxSizeBytes", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.DatabasesClient", "Import", err.Error())
- }
-
- req, err := client.ImportPreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Import", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ImportSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Import", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ImportPreparer prepares the Import request.
-func (client DatabasesClient) ImportPreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ImportRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/import", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ImportSender sends the Import request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ImportSender(req *http.Request) (future DatabasesImportFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ImportResponder handles the response to the Import request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ImportResponder(resp *http.Response) (result ImportExportResponse, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByElasticPool returns a list of databases in an elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be retrieved.
-func (client DatabasesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result DatabaseListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByElasticPoolPreparer prepares the ListByElasticPool request.
-func (client DatabasesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/databases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ListByElasticPoolResponder(resp *http.Response) (result DatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByRecommendedElasticPool returns a list of databases inside a recommended elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// recommendedElasticPoolName - the name of the recommended elastic pool to be retrieved.
-func (client DatabasesClient) ListByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string) (result DatabaseListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByRecommendedElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByRecommendedElasticPoolPreparer(ctx, resourceGroupName, serverName, recommendedElasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByRecommendedElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByRecommendedElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByRecommendedElasticPoolPreparer prepares the ListByRecommendedElasticPool request.
-func (client DatabasesClient) ListByRecommendedElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "recommendedElasticPoolName": autorest.Encode("path", recommendedElasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/recommendedElasticPools/{recommendedElasticPoolName}/databases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByRecommendedElasticPoolSender sends the ListByRecommendedElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ListByRecommendedElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByRecommendedElasticPoolResponder handles the response to the ListByRecommendedElasticPool request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ListByRecommendedElasticPoolResponder(resp *http.Response) (result DatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer returns a list of databases in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// expand - a comma separated list of child objects to expand in the response. Possible properties:
-// serviceTierAdvisors, transparentDataEncryption.
-// filter - an OData filter expression that describes a subset of databases to return.
-func (client DatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string, expand string, filter string) (result DatabaseListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName, expand, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client DatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string, expand string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if len(expand) > 0 {
- queryParameters["$expand"] = autorest.Encode("query", expand)
- }
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ListByServerResponder(resp *http.Response) (result DatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListMetricDefinitions returns database metric definitions.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabasesClient) ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result MetricDefinitionListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListMetricDefinitions")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListMetricDefinitionsPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListMetricDefinitionsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListMetricDefinitionsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListMetricDefinitionsPreparer prepares the ListMetricDefinitions request.
-func (client DatabasesClient) ListMetricDefinitionsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/metricDefinitions", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListMetricDefinitionsSender sends the ListMetricDefinitions request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ListMetricDefinitionsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListMetricDefinitionsResponder handles the response to the ListMetricDefinitions request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ListMetricDefinitionsResponder(resp *http.Response) (result MetricDefinitionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListMetrics returns database metrics.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// filter - an OData filter expression that describes a subset of metrics to return.
-func (client DatabasesClient) ListMetrics(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result MetricListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListMetrics")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListMetricsPreparer(ctx, resourceGroupName, serverName, databaseName, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListMetricsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListMetricsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListMetricsPreparer prepares the ListMetrics request.
-func (client DatabasesClient) ListMetricsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "$filter": autorest.Encode("query", filter),
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/metrics", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListMetricsSender sends the ListMetrics request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ListMetricsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListMetricsResponder handles the response to the ListMetrics request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ListMetricsResponder(resp *http.Response) (result MetricListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Pause pauses a data warehouse.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the data warehouse to pause.
-func (client DatabasesClient) Pause(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabasesPauseFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Pause")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.PausePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Pause", nil, "Failure preparing request")
- return
- }
-
- result, err = client.PauseSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Pause", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// PausePreparer prepares the Pause request.
-func (client DatabasesClient) PausePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/pause", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// PauseSender sends the Pause request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) PauseSender(req *http.Request) (future DatabasesPauseFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// PauseResponder handles the response to the Pause request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) PauseResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Rename renames a database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to rename.
-// parameters - the resource move definition for renaming this database.
-func (client DatabasesClient) Rename(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ResourceMoveDefinition) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Rename")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.ID", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.DatabasesClient", "Rename", err.Error())
- }
-
- req, err := client.RenamePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.RenameSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", resp, "Failure sending request")
- return
- }
-
- result, err = client.RenameResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", resp, "Failure responding to request")
- }
-
- return
-}
-
-// RenamePreparer prepares the Rename request.
-func (client DatabasesClient) RenamePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ResourceMoveDefinition) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/move", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// RenameSender sends the Rename request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) RenameSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// RenameResponder handles the response to the Rename request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) RenameResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Resume resumes a data warehouse.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the data warehouse to resume.
-func (client DatabasesClient) Resume(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabasesResumeFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Resume")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ResumePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Resume", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ResumeSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Resume", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ResumePreparer prepares the Resume request.
-func (client DatabasesClient) ResumePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/resume", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ResumeSender sends the Resume request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) ResumeSender(req *http.Request) (future DatabasesResumeFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ResumeResponder handles the response to the Resume request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) ResumeResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Update updates an existing database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to be updated.
-// parameters - the required parameters for updating a database.
-func (client DatabasesClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseUpdate) (result DatabasesUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client DatabasesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabasesClient) UpdateSender(req *http.Request) (future DatabasesUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client DatabasesClient) UpdateResponder(resp *http.Response) (result Database, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type DatabasesClient struct {
+ BaseClient
+}
+
+// NewDatabasesClient creates an instance of the DatabasesClient client.
+func NewDatabasesClient(subscriptionID string) DatabasesClient {
+ return NewDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabasesClientWithBaseURI creates an instance of the DatabasesClient client.
+func NewDatabasesClientWithBaseURI(baseURI string, subscriptionID string) DatabasesClient {
+ return DatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateImportOperation creates an import operation that imports a bacpac into an existing database. The existing
+// database must be empty.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to import into
+// parameters - the required parameters for importing a Bacpac into a database.
+func (client DatabasesClient) CreateImportOperation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ImportExtensionRequest) (result DatabasesCreateImportOperationFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.CreateImportOperation")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.ImportExtensionProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.ImportExtensionProperties.OperationMode", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.DatabasesClient", "CreateImportOperation", err.Error())
+ }
+
+ req, err := client.CreateImportOperationPreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateImportOperation", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateImportOperationSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateImportOperation", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateImportOperationPreparer prepares the CreateImportOperation request.
+func (client DatabasesClient) CreateImportOperationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ImportExtensionRequest) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "extensionName": autorest.Encode("path", "import"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extensions/{extensionName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateImportOperationSender sends the CreateImportOperation request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) CreateImportOperationSender(req *http.Request) (future DatabasesCreateImportOperationFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateImportOperationResponder handles the response to the CreateImportOperation request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) CreateImportOperationResponder(resp *http.Response) (result ImportExportResponse, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// CreateOrUpdate creates a new database or updates an existing database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to be operated on (updated or created).
+// parameters - the required parameters for creating or updating a database.
+func (client DatabasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters Database) (result DatabasesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DatabasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters Database) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) CreateOrUpdateSender(req *http.Request) (future DatabasesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) CreateOrUpdateResponder(resp *http.Response) (result Database, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to be deleted.
+func (client DatabasesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client DatabasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) 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
+}
+
+// Export exports a database to a bacpac.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to be exported.
+// parameters - the required parameters for exporting a database.
+func (client DatabasesClient) Export(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExportRequest) (result DatabasesExportFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Export")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.StorageKey", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.StorageURI", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AdministratorLogin", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AdministratorLoginPassword", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.DatabasesClient", "Export", err.Error())
+ }
+
+ req, err := client.ExportPreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Export", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.ExportSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Export", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// ExportPreparer prepares the Export request.
+func (client DatabasesClient) ExportPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExportRequest) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/export", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ExportSender sends the Export request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ExportSender(req *http.Request) (future DatabasesExportFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// ExportResponder handles the response to the Export request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ExportResponder(resp *http.Response) (result ImportExportResponse, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to be retrieved.
+// expand - a comma separated list of child objects to expand in the response. Possible properties:
+// serviceTierAdvisors, transparentDataEncryption.
+func (client DatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, expand string) (result Database, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, expand)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, expand string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(expand) > 0 {
+ queryParameters["$expand"] = autorest.Encode("query", expand)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) GetResponder(resp *http.Response) (result Database, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetByElasticPool gets a database inside of an elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be retrieved.
+// databaseName - the name of the database to be retrieved.
+func (client DatabasesClient) GetByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, databaseName string) (result Database, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.GetByElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetByElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetByElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetByElasticPoolPreparer prepares the GetByElasticPool request.
+func (client DatabasesClient) GetByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetByElasticPoolSender sends the GetByElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) GetByElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetByElasticPoolResponder handles the response to the GetByElasticPool request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) GetByElasticPoolResponder(resp *http.Response) (result Database, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetByRecommendedElasticPool gets a database inside of a recommended elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// recommendedElasticPoolName - the name of the elastic pool to be retrieved.
+// databaseName - the name of the database to be retrieved.
+func (client DatabasesClient) GetByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string, databaseName string) (result Database, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.GetByRecommendedElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetByRecommendedElasticPoolPreparer(ctx, resourceGroupName, serverName, recommendedElasticPoolName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetByRecommendedElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetByRecommendedElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "GetByRecommendedElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetByRecommendedElasticPoolPreparer prepares the GetByRecommendedElasticPool request.
+func (client DatabasesClient) GetByRecommendedElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "recommendedElasticPoolName": autorest.Encode("path", recommendedElasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/recommendedElasticPools/{recommendedElasticPoolName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetByRecommendedElasticPoolSender sends the GetByRecommendedElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) GetByRecommendedElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetByRecommendedElasticPoolResponder handles the response to the GetByRecommendedElasticPool request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) GetByRecommendedElasticPoolResponder(resp *http.Response) (result Database, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Import imports a bacpac into a new database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the required parameters for importing a Bacpac into a database.
+func (client DatabasesClient) Import(ctx context.Context, resourceGroupName string, serverName string, parameters ImportRequest) (result DatabasesImportFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Import")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.DatabaseName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.MaxSizeBytes", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.DatabasesClient", "Import", err.Error())
+ }
+
+ req, err := client.ImportPreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Import", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.ImportSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Import", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// ImportPreparer prepares the Import request.
+func (client DatabasesClient) ImportPreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ImportRequest) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/import", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ImportSender sends the Import request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ImportSender(req *http.Request) (future DatabasesImportFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// ImportResponder handles the response to the Import request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ImportResponder(resp *http.Response) (result ImportExportResponse, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByElasticPool returns a list of databases in an elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be retrieved.
+func (client DatabasesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result DatabaseListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByElasticPoolPreparer prepares the ListByElasticPool request.
+func (client DatabasesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/databases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ListByElasticPoolResponder(resp *http.Response) (result DatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByRecommendedElasticPool returns a list of databases inside a recommended elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// recommendedElasticPoolName - the name of the recommended elastic pool to be retrieved.
+func (client DatabasesClient) ListByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string) (result DatabaseListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByRecommendedElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByRecommendedElasticPoolPreparer(ctx, resourceGroupName, serverName, recommendedElasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByRecommendedElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByRecommendedElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByRecommendedElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByRecommendedElasticPoolPreparer prepares the ListByRecommendedElasticPool request.
+func (client DatabasesClient) ListByRecommendedElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "recommendedElasticPoolName": autorest.Encode("path", recommendedElasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/recommendedElasticPools/{recommendedElasticPoolName}/databases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByRecommendedElasticPoolSender sends the ListByRecommendedElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ListByRecommendedElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByRecommendedElasticPoolResponder handles the response to the ListByRecommendedElasticPool request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ListByRecommendedElasticPoolResponder(resp *http.Response) (result DatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer returns a list of databases in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// expand - a comma separated list of child objects to expand in the response. Possible properties:
+// serviceTierAdvisors, transparentDataEncryption.
+// filter - an OData filter expression that describes a subset of databases to return.
+func (client DatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string, expand string, filter string) (result DatabaseListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName, expand, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client DatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string, expand string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(expand) > 0 {
+ queryParameters["$expand"] = autorest.Encode("query", expand)
+ }
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ListByServerResponder(resp *http.Response) (result DatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListMetricDefinitions returns database metric definitions.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabasesClient) ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result MetricDefinitionListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListMetricDefinitions")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListMetricDefinitionsPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListMetricDefinitionsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListMetricDefinitionsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetricDefinitions", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListMetricDefinitionsPreparer prepares the ListMetricDefinitions request.
+func (client DatabasesClient) ListMetricDefinitionsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/metricDefinitions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListMetricDefinitionsSender sends the ListMetricDefinitions request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ListMetricDefinitionsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListMetricDefinitionsResponder handles the response to the ListMetricDefinitions request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ListMetricDefinitionsResponder(resp *http.Response) (result MetricDefinitionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListMetrics returns database metrics.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// filter - an OData filter expression that describes a subset of metrics to return.
+func (client DatabasesClient) ListMetrics(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result MetricListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.ListMetrics")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListMetricsPreparer(ctx, resourceGroupName, serverName, databaseName, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListMetricsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListMetricsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "ListMetrics", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListMetricsPreparer prepares the ListMetrics request.
+func (client DatabasesClient) ListMetricsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "$filter": autorest.Encode("query", filter),
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/metrics", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListMetricsSender sends the ListMetrics request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ListMetricsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListMetricsResponder handles the response to the ListMetrics request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ListMetricsResponder(resp *http.Response) (result MetricListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Pause pauses a data warehouse.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the data warehouse to pause.
+func (client DatabasesClient) Pause(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabasesPauseFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Pause")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.PausePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Pause", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.PauseSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Pause", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// PausePreparer prepares the Pause request.
+func (client DatabasesClient) PausePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/pause", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// PauseSender sends the Pause request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) PauseSender(req *http.Request) (future DatabasesPauseFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// PauseResponder handles the response to the Pause request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) PauseResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Rename renames a database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to rename.
+// parameters - the resource move definition for renaming this database.
+func (client DatabasesClient) Rename(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ResourceMoveDefinition) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Rename")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.ID", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.DatabasesClient", "Rename", err.Error())
+ }
+
+ req, err := client.RenamePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.RenameSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.RenameResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Rename", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// RenamePreparer prepares the Rename request.
+func (client DatabasesClient) RenamePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ResourceMoveDefinition) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/move", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// RenameSender sends the Rename request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) RenameSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// RenameResponder handles the response to the Rename request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) RenameResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Resume resumes a data warehouse.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the data warehouse to resume.
+func (client DatabasesClient) Resume(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabasesResumeFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Resume")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ResumePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Resume", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.ResumeSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Resume", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// ResumePreparer prepares the Resume request.
+func (client DatabasesClient) ResumePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/resume", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ResumeSender sends the Resume request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) ResumeSender(req *http.Request) (future DatabasesResumeFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// ResumeResponder handles the response to the Resume request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) ResumeResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Update updates an existing database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to be updated.
+// parameters - the required parameters for updating a database.
+func (client DatabasesClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseUpdate) (result DatabasesUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabasesClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabasesClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client DatabasesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabasesClient) UpdateSender(req *http.Request) (future DatabasesUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client DatabasesClient) UpdateResponder(resp *http.Response) (result Database, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasethreatdetectionpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasethreatdetectionpolicies.go
index 1485fd291e2f..9c858036755f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasethreatdetectionpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasethreatdetectionpolicies.go
@@ -1,210 +1,210 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseThreatDetectionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type DatabaseThreatDetectionPoliciesClient struct {
- BaseClient
-}
-
-// NewDatabaseThreatDetectionPoliciesClient creates an instance of the DatabaseThreatDetectionPoliciesClient client.
-func NewDatabaseThreatDetectionPoliciesClient(subscriptionID string) DatabaseThreatDetectionPoliciesClient {
- return NewDatabaseThreatDetectionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseThreatDetectionPoliciesClientWithBaseURI creates an instance of the DatabaseThreatDetectionPoliciesClient
-// client.
-func NewDatabaseThreatDetectionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseThreatDetectionPoliciesClient {
- return DatabaseThreatDetectionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database's threat detection policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which database Threat Detection policy is defined.
-// parameters - the database Threat Detection policy.
-func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseSecurityAlertPolicy) (result DatabaseSecurityAlertPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseThreatDetectionPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseSecurityAlertPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "securityAlertPolicyName": autorest.Encode("path", "default"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseSecurityAlertPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a database's threat detection policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which database Threat Detection policy is defined.
-func (client DatabaseThreatDetectionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseSecurityAlertPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseThreatDetectionPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabaseThreatDetectionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "securityAlertPolicyName": autorest.Encode("path", "default"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseThreatDetectionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabaseThreatDetectionPoliciesClient) GetResponder(resp *http.Response) (result DatabaseSecurityAlertPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseThreatDetectionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type DatabaseThreatDetectionPoliciesClient struct {
+ BaseClient
+}
+
+// NewDatabaseThreatDetectionPoliciesClient creates an instance of the DatabaseThreatDetectionPoliciesClient client.
+func NewDatabaseThreatDetectionPoliciesClient(subscriptionID string) DatabaseThreatDetectionPoliciesClient {
+ return NewDatabaseThreatDetectionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseThreatDetectionPoliciesClientWithBaseURI creates an instance of the DatabaseThreatDetectionPoliciesClient
+// client.
+func NewDatabaseThreatDetectionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseThreatDetectionPoliciesClient {
+ return DatabaseThreatDetectionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database's threat detection policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which database Threat Detection policy is defined.
+// parameters - the database Threat Detection policy.
+func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseSecurityAlertPolicy) (result DatabaseSecurityAlertPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseThreatDetectionPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseSecurityAlertPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "securityAlertPolicyName": autorest.Encode("path", "default"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DatabaseThreatDetectionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseSecurityAlertPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a database's threat detection policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which database Threat Detection policy is defined.
+func (client DatabaseThreatDetectionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseSecurityAlertPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseThreatDetectionPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseThreatDetectionPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabaseThreatDetectionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "securityAlertPolicyName": autorest.Encode("path", "default"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseThreatDetectionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabaseThreatDetectionPoliciesClient) GetResponder(resp *http.Response) (result DatabaseSecurityAlertPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseusages.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseusages.go
index 1bd0555c0b41..45f0a1e730a4 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseusages.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databaseusages.go
@@ -1,123 +1,123 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type DatabaseUsagesClient struct {
- BaseClient
-}
-
-// NewDatabaseUsagesClient creates an instance of the DatabaseUsagesClient client.
-func NewDatabaseUsagesClient(subscriptionID string) DatabaseUsagesClient {
- return NewDatabaseUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseUsagesClientWithBaseURI creates an instance of the DatabaseUsagesClient client.
-func NewDatabaseUsagesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseUsagesClient {
- return DatabaseUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByDatabase returns database usages.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DatabaseUsagesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseUsageListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseUsagesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client DatabaseUsagesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/usages", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseUsagesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client DatabaseUsagesClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseUsageListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type DatabaseUsagesClient struct {
+ BaseClient
+}
+
+// NewDatabaseUsagesClient creates an instance of the DatabaseUsagesClient client.
+func NewDatabaseUsagesClient(subscriptionID string) DatabaseUsagesClient {
+ return NewDatabaseUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseUsagesClientWithBaseURI creates an instance of the DatabaseUsagesClient client.
+func NewDatabaseUsagesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseUsagesClient {
+ return DatabaseUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByDatabase returns database usages.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DatabaseUsagesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseUsageListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseUsagesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseUsagesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client DatabaseUsagesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/usages", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseUsagesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client DatabaseUsagesClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseUsageListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessmentrulebaselines.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessmentrulebaselines.go
index 2b3cc57f714b..c4de2c1ee8e8 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessmentrulebaselines.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessmentrulebaselines.go
@@ -1,313 +1,313 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseVulnerabilityAssessmentRuleBaselinesClient is the the Azure SQL Database management API provides a RESTful
-// set of web services that interact with Azure SQL Database services to manage your databases. The API enables you to
-// create, retrieve, update, and delete databases.
-type DatabaseVulnerabilityAssessmentRuleBaselinesClient struct {
- BaseClient
-}
-
-// NewDatabaseVulnerabilityAssessmentRuleBaselinesClient creates an instance of the
-// DatabaseVulnerabilityAssessmentRuleBaselinesClient client.
-func NewDatabaseVulnerabilityAssessmentRuleBaselinesClient(subscriptionID string) DatabaseVulnerabilityAssessmentRuleBaselinesClient {
- return NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI creates an instance of the
-// DatabaseVulnerabilityAssessmentRuleBaselinesClient client.
-func NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseVulnerabilityAssessmentRuleBaselinesClient {
- return DatabaseVulnerabilityAssessmentRuleBaselinesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database's vulnerability assessment rule baseline.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
-// ruleID - the vulnerability assessment rule ID.
-// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
-// database level rule and master for server level rule).
-// parameters - the requested rule baseline resource.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName, parameters DatabaseVulnerabilityAssessmentRuleBaseline) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.DatabaseVulnerabilityAssessmentRuleBaselineProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.DatabaseVulnerabilityAssessmentRuleBaselineProperties.BaselineResults", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName, parameters DatabaseVulnerabilityAssessmentRuleBaseline) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "baselineName": autorest.Encode("path", baselineName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "ruleId": autorest.Encode("path", ruleID),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentRuleBaseline, 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 removes the database's vulnerability assessment rule baseline.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
-// ruleID - the vulnerability assessment rule ID.
-// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
-// database level rule and master for server level rule).
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "baselineName": autorest.Encode("path", baselineName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "ruleId": autorest.Encode("path", ruleID),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a database's vulnerability assessment rule baseline.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
-// ruleID - the vulnerability assessment rule ID.
-// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
-// database level rule and master for server level rule).
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "baselineName": autorest.Encode("path", baselineName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "ruleId": autorest.Encode("path", ruleID),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseVulnerabilityAssessmentRuleBaselinesClient is the the Azure SQL Database management API provides a RESTful
+// set of web services that interact with Azure SQL Database services to manage your databases. The API enables you to
+// create, retrieve, update, and delete databases.
+type DatabaseVulnerabilityAssessmentRuleBaselinesClient struct {
+ BaseClient
+}
+
+// NewDatabaseVulnerabilityAssessmentRuleBaselinesClient creates an instance of the
+// DatabaseVulnerabilityAssessmentRuleBaselinesClient client.
+func NewDatabaseVulnerabilityAssessmentRuleBaselinesClient(subscriptionID string) DatabaseVulnerabilityAssessmentRuleBaselinesClient {
+ return NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI creates an instance of the
+// DatabaseVulnerabilityAssessmentRuleBaselinesClient client.
+func NewDatabaseVulnerabilityAssessmentRuleBaselinesClientWithBaseURI(baseURI string, subscriptionID string) DatabaseVulnerabilityAssessmentRuleBaselinesClient {
+ return DatabaseVulnerabilityAssessmentRuleBaselinesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database's vulnerability assessment rule baseline.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
+// ruleID - the vulnerability assessment rule ID.
+// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
+// database level rule and master for server level rule).
+// parameters - the requested rule baseline resource.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName, parameters DatabaseVulnerabilityAssessmentRuleBaseline) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.DatabaseVulnerabilityAssessmentRuleBaselineProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.DatabaseVulnerabilityAssessmentRuleBaselineProperties.BaselineResults", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName, parameters DatabaseVulnerabilityAssessmentRuleBaseline) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "baselineName": autorest.Encode("path", baselineName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "ruleId": autorest.Encode("path", ruleID),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentRuleBaseline, 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 removes the database's vulnerability assessment rule baseline.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
+// ruleID - the vulnerability assessment rule ID.
+// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
+// database level rule and master for server level rule).
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "baselineName": autorest.Encode("path", baselineName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "ruleId": autorest.Encode("path", ruleID),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a database's vulnerability assessment rule baseline.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment rule baseline is defined.
+// ruleID - the vulnerability assessment rule ID.
+// baselineName - the name of the vulnerability assessment rule baseline (default implies a baseline on a
+// database level rule and master for server level rule).
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentRuleBaselinesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, ruleID, baselineName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName VulnerabilityAssessmentPolicyBaselineName) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "baselineName": autorest.Encode("path", baselineName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "ruleId": autorest.Encode("path", ruleID),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}/rules/{ruleId}/baselines/{baselineName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentRuleBaselinesClient) GetResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentRuleBaseline, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessments.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessments.go
index 9dbd0f65c075..e953704645ce 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessments.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/databasevulnerabilityassessments.go
@@ -1,407 +1,407 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DatabaseVulnerabilityAssessmentsClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type DatabaseVulnerabilityAssessmentsClient struct {
- BaseClient
-}
-
-// NewDatabaseVulnerabilityAssessmentsClient creates an instance of the DatabaseVulnerabilityAssessmentsClient client.
-func NewDatabaseVulnerabilityAssessmentsClient(subscriptionID string) DatabaseVulnerabilityAssessmentsClient {
- return NewDatabaseVulnerabilityAssessmentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDatabaseVulnerabilityAssessmentsClientWithBaseURI creates an instance of the
-// DatabaseVulnerabilityAssessmentsClient client.
-func NewDatabaseVulnerabilityAssessmentsClientWithBaseURI(baseURI string, subscriptionID string) DatabaseVulnerabilityAssessmentsClient {
- return DatabaseVulnerabilityAssessmentsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates the database's vulnerability assessment.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment is defined.
-// parameters - the requested resource.
-func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseVulnerabilityAssessment) (result DatabaseVulnerabilityAssessment, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseVulnerabilityAssessment) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseVulnerabilityAssessment, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete removes the database's vulnerability assessment.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment is defined.
-func (client DatabaseVulnerabilityAssessmentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client DatabaseVulnerabilityAssessmentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the database's vulnerability assessment.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment is defined.
-func (client DatabaseVulnerabilityAssessmentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessment, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DatabaseVulnerabilityAssessmentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentsClient) GetResponder(resp *http.Response) (result DatabaseVulnerabilityAssessment, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase lists the vulnerability assessment policies associated with a database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the vulnerability assessment policies are defined.
-func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessmentListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.dvalr.Response.Response != nil {
- sc = result.dvalr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByDatabaseNextResults
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.dvalr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result.dvalr, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByDatabaseNextResults retrieves the next set of results, if any.
-func (client DatabaseVulnerabilityAssessmentsClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseVulnerabilityAssessmentListResult) (result DatabaseVulnerabilityAssessmentListResult, err error) {
- req, err := lastResults.databaseVulnerabilityAssessmentListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessmentListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DatabaseVulnerabilityAssessmentsClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type DatabaseVulnerabilityAssessmentsClient struct {
+ BaseClient
+}
+
+// NewDatabaseVulnerabilityAssessmentsClient creates an instance of the DatabaseVulnerabilityAssessmentsClient client.
+func NewDatabaseVulnerabilityAssessmentsClient(subscriptionID string) DatabaseVulnerabilityAssessmentsClient {
+ return NewDatabaseVulnerabilityAssessmentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDatabaseVulnerabilityAssessmentsClientWithBaseURI creates an instance of the
+// DatabaseVulnerabilityAssessmentsClient client.
+func NewDatabaseVulnerabilityAssessmentsClientWithBaseURI(baseURI string, subscriptionID string) DatabaseVulnerabilityAssessmentsClient {
+ return DatabaseVulnerabilityAssessmentsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates the database's vulnerability assessment.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment is defined.
+// parameters - the requested resource.
+func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseVulnerabilityAssessment) (result DatabaseVulnerabilityAssessment, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DatabaseVulnerabilityAssessment) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentsClient) CreateOrUpdateResponder(resp *http.Response) (result DatabaseVulnerabilityAssessment, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete removes the database's vulnerability assessment.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment is defined.
+func (client DatabaseVulnerabilityAssessmentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client DatabaseVulnerabilityAssessmentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets the database's vulnerability assessment.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment is defined.
+func (client DatabaseVulnerabilityAssessmentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessment, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DatabaseVulnerabilityAssessmentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vulnerabilityAssessmentName": autorest.Encode("path", "default"),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments/{vulnerabilityAssessmentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentsClient) GetResponder(resp *http.Response) (result DatabaseVulnerabilityAssessment, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase lists the vulnerability assessment policies associated with a database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the vulnerability assessment policies are defined.
+func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessmentListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.dvalr.Response.Response != nil {
+ sc = result.dvalr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByDatabaseNextResults
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.dvalr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.dvalr, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/vulnerabilityAssessments", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseResponder(resp *http.Response) (result DatabaseVulnerabilityAssessmentListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByDatabaseNextResults retrieves the next set of results, if any.
+func (client DatabaseVulnerabilityAssessmentsClient) listByDatabaseNextResults(ctx context.Context, lastResults DatabaseVulnerabilityAssessmentListResult) (result DatabaseVulnerabilityAssessmentListResult, err error) {
+ req, err := lastResults.databaseVulnerabilityAssessmentListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DatabaseVulnerabilityAssessmentsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client DatabaseVulnerabilityAssessmentsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DatabaseVulnerabilityAssessmentListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DatabaseVulnerabilityAssessmentsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingpolicies.go
index c33ead523aec..65303d3d345a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingpolicies.go
@@ -1,210 +1,210 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DataMaskingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type DataMaskingPoliciesClient struct {
- BaseClient
-}
-
-// NewDataMaskingPoliciesClient creates an instance of the DataMaskingPoliciesClient client.
-func NewDataMaskingPoliciesClient(subscriptionID string) DataMaskingPoliciesClient {
- return NewDataMaskingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDataMaskingPoliciesClientWithBaseURI creates an instance of the DataMaskingPoliciesClient client.
-func NewDataMaskingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DataMaskingPoliciesClient {
- return DataMaskingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database data masking policy
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - parameters for creating or updating a data masking policy.
-func (client DataMaskingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DataMaskingPolicy) (result DataMaskingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DataMaskingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DataMaskingPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "dataMaskingPolicyName": autorest.Encode("path", "Default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DataMaskingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DataMaskingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DataMaskingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a database data masking policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DataMaskingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataMaskingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DataMaskingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "dataMaskingPolicyName": autorest.Encode("path", "Default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DataMaskingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DataMaskingPoliciesClient) GetResponder(resp *http.Response) (result DataMaskingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DataMaskingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type DataMaskingPoliciesClient struct {
+ BaseClient
+}
+
+// NewDataMaskingPoliciesClient creates an instance of the DataMaskingPoliciesClient client.
+func NewDataMaskingPoliciesClient(subscriptionID string) DataMaskingPoliciesClient {
+ return NewDataMaskingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDataMaskingPoliciesClientWithBaseURI creates an instance of the DataMaskingPoliciesClient client.
+func NewDataMaskingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) DataMaskingPoliciesClient {
+ return DataMaskingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database data masking policy
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - parameters for creating or updating a data masking policy.
+func (client DataMaskingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DataMaskingPolicy) (result DataMaskingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DataMaskingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters DataMaskingPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "dataMaskingPolicyName": autorest.Encode("path", "Default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DataMaskingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DataMaskingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result DataMaskingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a database data masking policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DataMaskingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataMaskingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DataMaskingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "dataMaskingPolicyName": autorest.Encode("path", "Default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DataMaskingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DataMaskingPoliciesClient) GetResponder(resp *http.Response) (result DataMaskingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingrules.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingrules.go
index 0b42610e2476..d7a6ff263792 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingrules.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datamaskingrules.go
@@ -1,223 +1,223 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DataMaskingRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type DataMaskingRulesClient struct {
- BaseClient
-}
-
-// NewDataMaskingRulesClient creates an instance of the DataMaskingRulesClient client.
-func NewDataMaskingRulesClient(subscriptionID string) DataMaskingRulesClient {
- return NewDataMaskingRulesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDataMaskingRulesClientWithBaseURI creates an instance of the DataMaskingRulesClient client.
-func NewDataMaskingRulesClientWithBaseURI(baseURI string, subscriptionID string) DataMaskingRulesClient {
- return DataMaskingRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database data masking rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// dataMaskingRuleName - the name of the data masking rule.
-// parameters - the required parameters for creating or updating a data masking rule.
-func (client DataMaskingRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, dataMaskingRuleName string, parameters DataMaskingRule) (result DataMaskingRule, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingRulesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.DataMaskingRuleProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.DataMaskingRuleProperties.SchemaName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.DataMaskingRuleProperties.TableName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.DataMaskingRuleProperties.ColumnName", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.DataMaskingRulesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, dataMaskingRuleName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client DataMaskingRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, dataMaskingRuleName string, parameters DataMaskingRule) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "dataMaskingPolicyName": autorest.Encode("path", "Default"),
- "dataMaskingRuleName": autorest.Encode("path", dataMaskingRuleName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}/rules/{dataMaskingRuleName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client DataMaskingRulesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client DataMaskingRulesClient) CreateOrUpdateResponder(resp *http.Response) (result DataMaskingRule, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase gets a list of database data masking rules.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DataMaskingRulesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataMaskingRuleListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingRulesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client DataMaskingRulesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "dataMaskingPolicyName": autorest.Encode("path", "Default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}/rules", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client DataMaskingRulesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client DataMaskingRulesClient) ListByDatabaseResponder(resp *http.Response) (result DataMaskingRuleListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DataMaskingRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type DataMaskingRulesClient struct {
+ BaseClient
+}
+
+// NewDataMaskingRulesClient creates an instance of the DataMaskingRulesClient client.
+func NewDataMaskingRulesClient(subscriptionID string) DataMaskingRulesClient {
+ return NewDataMaskingRulesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDataMaskingRulesClientWithBaseURI creates an instance of the DataMaskingRulesClient client.
+func NewDataMaskingRulesClientWithBaseURI(baseURI string, subscriptionID string) DataMaskingRulesClient {
+ return DataMaskingRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database data masking rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// dataMaskingRuleName - the name of the data masking rule.
+// parameters - the required parameters for creating or updating a data masking rule.
+func (client DataMaskingRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, dataMaskingRuleName string, parameters DataMaskingRule) (result DataMaskingRule, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingRulesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.DataMaskingRuleProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.DataMaskingRuleProperties.SchemaName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.DataMaskingRuleProperties.TableName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.DataMaskingRuleProperties.ColumnName", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.DataMaskingRulesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, dataMaskingRuleName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client DataMaskingRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, dataMaskingRuleName string, parameters DataMaskingRule) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "dataMaskingPolicyName": autorest.Encode("path", "Default"),
+ "dataMaskingRuleName": autorest.Encode("path", dataMaskingRuleName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}/rules/{dataMaskingRuleName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client DataMaskingRulesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client DataMaskingRulesClient) CreateOrUpdateResponder(resp *http.Response) (result DataMaskingRule, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase gets a list of database data masking rules.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DataMaskingRulesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataMaskingRuleListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DataMaskingRulesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataMaskingRulesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client DataMaskingRulesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "dataMaskingPolicyName": autorest.Encode("path", "Default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/dataMaskingPolicies/{dataMaskingPolicyName}/rules", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client DataMaskingRulesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client DataMaskingRulesClient) ListByDatabaseResponder(resp *http.Response) (result DataMaskingRuleListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datawarehouseuseractivities.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datawarehouseuseractivities.go
index 14322923a6cc..3f4ba5338dcf 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datawarehouseuseractivities.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/datawarehouseuseractivities.go
@@ -1,124 +1,124 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// DataWarehouseUserActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type DataWarehouseUserActivitiesClient struct {
- BaseClient
-}
-
-// NewDataWarehouseUserActivitiesClient creates an instance of the DataWarehouseUserActivitiesClient client.
-func NewDataWarehouseUserActivitiesClient(subscriptionID string) DataWarehouseUserActivitiesClient {
- return NewDataWarehouseUserActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewDataWarehouseUserActivitiesClientWithBaseURI creates an instance of the DataWarehouseUserActivitiesClient client.
-func NewDataWarehouseUserActivitiesClientWithBaseURI(baseURI string, subscriptionID string) DataWarehouseUserActivitiesClient {
- return DataWarehouseUserActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets the user activities of a data warehouse which includes running and suspended queries
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client DataWarehouseUserActivitiesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataWarehouseUserActivities, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/DataWarehouseUserActivitiesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client DataWarehouseUserActivitiesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "dataWarehouseUserActivityName": autorest.Encode("path", "current"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataWarehouseUserActivities/{dataWarehouseUserActivityName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client DataWarehouseUserActivitiesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client DataWarehouseUserActivitiesClient) GetResponder(resp *http.Response) (result DataWarehouseUserActivities, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// DataWarehouseUserActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type DataWarehouseUserActivitiesClient struct {
+ BaseClient
+}
+
+// NewDataWarehouseUserActivitiesClient creates an instance of the DataWarehouseUserActivitiesClient client.
+func NewDataWarehouseUserActivitiesClient(subscriptionID string) DataWarehouseUserActivitiesClient {
+ return NewDataWarehouseUserActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewDataWarehouseUserActivitiesClientWithBaseURI creates an instance of the DataWarehouseUserActivitiesClient client.
+func NewDataWarehouseUserActivitiesClientWithBaseURI(baseURI string, subscriptionID string) DataWarehouseUserActivitiesClient {
+ return DataWarehouseUserActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets the user activities of a data warehouse which includes running and suspended queries
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client DataWarehouseUserActivitiesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result DataWarehouseUserActivities, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/DataWarehouseUserActivitiesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.DataWarehouseUserActivitiesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client DataWarehouseUserActivitiesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "dataWarehouseUserActivityName": autorest.Encode("path", "current"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/dataWarehouseUserActivities/{dataWarehouseUserActivityName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client DataWarehouseUserActivitiesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client DataWarehouseUserActivitiesClient) GetResponder(resp *http.Response) (result DataWarehouseUserActivities, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpoolactivities.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpoolactivities.go
index abaa1f0c7b18..94df73d2fff9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpoolactivities.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpoolactivities.go
@@ -1,123 +1,123 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ElasticPoolActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ElasticPoolActivitiesClient struct {
- BaseClient
-}
-
-// NewElasticPoolActivitiesClient creates an instance of the ElasticPoolActivitiesClient client.
-func NewElasticPoolActivitiesClient(subscriptionID string) ElasticPoolActivitiesClient {
- return NewElasticPoolActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewElasticPoolActivitiesClientWithBaseURI creates an instance of the ElasticPoolActivitiesClient client.
-func NewElasticPoolActivitiesClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolActivitiesClient {
- return ElasticPoolActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByElasticPool returns elastic pool activities.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool for which to get the current activity.
-func (client ElasticPoolActivitiesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPoolActivityListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolActivitiesClient.ListByElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByElasticPoolPreparer prepares the ListByElasticPool request.
-func (client ElasticPoolActivitiesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/elasticPoolActivity", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolActivitiesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolActivitiesClient) ListByElasticPoolResponder(resp *http.Response) (result ElasticPoolActivityListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ElasticPoolActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ElasticPoolActivitiesClient struct {
+ BaseClient
+}
+
+// NewElasticPoolActivitiesClient creates an instance of the ElasticPoolActivitiesClient client.
+func NewElasticPoolActivitiesClient(subscriptionID string) ElasticPoolActivitiesClient {
+ return NewElasticPoolActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewElasticPoolActivitiesClientWithBaseURI creates an instance of the ElasticPoolActivitiesClient client.
+func NewElasticPoolActivitiesClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolActivitiesClient {
+ return ElasticPoolActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByElasticPool returns elastic pool activities.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool for which to get the current activity.
+func (client ElasticPoolActivitiesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPoolActivityListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolActivitiesClient.ListByElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolActivitiesClient", "ListByElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByElasticPoolPreparer prepares the ListByElasticPool request.
+func (client ElasticPoolActivitiesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/elasticPoolActivity", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolActivitiesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolActivitiesClient) ListByElasticPoolResponder(resp *http.Response) (result ElasticPoolActivityListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpooldatabaseactivities.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpooldatabaseactivities.go
index f163c0bd8c0f..dd0e955db87f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpooldatabaseactivities.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpooldatabaseactivities.go
@@ -1,124 +1,124 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ElasticPoolDatabaseActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ElasticPoolDatabaseActivitiesClient struct {
- BaseClient
-}
-
-// NewElasticPoolDatabaseActivitiesClient creates an instance of the ElasticPoolDatabaseActivitiesClient client.
-func NewElasticPoolDatabaseActivitiesClient(subscriptionID string) ElasticPoolDatabaseActivitiesClient {
- return NewElasticPoolDatabaseActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewElasticPoolDatabaseActivitiesClientWithBaseURI creates an instance of the ElasticPoolDatabaseActivitiesClient
-// client.
-func NewElasticPoolDatabaseActivitiesClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolDatabaseActivitiesClient {
- return ElasticPoolDatabaseActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByElasticPool returns activity on databases inside of an elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool.
-func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPoolDatabaseActivityListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolDatabaseActivitiesClient.ListByElasticPool")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByElasticPoolSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByElasticPoolResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByElasticPoolPreparer prepares the ListByElasticPool request.
-func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/elasticPoolDatabaseActivity", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolResponder(resp *http.Response) (result ElasticPoolDatabaseActivityListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ElasticPoolDatabaseActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ElasticPoolDatabaseActivitiesClient struct {
+ BaseClient
+}
+
+// NewElasticPoolDatabaseActivitiesClient creates an instance of the ElasticPoolDatabaseActivitiesClient client.
+func NewElasticPoolDatabaseActivitiesClient(subscriptionID string) ElasticPoolDatabaseActivitiesClient {
+ return NewElasticPoolDatabaseActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewElasticPoolDatabaseActivitiesClientWithBaseURI creates an instance of the ElasticPoolDatabaseActivitiesClient
+// client.
+func NewElasticPoolDatabaseActivitiesClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolDatabaseActivitiesClient {
+ return ElasticPoolDatabaseActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByElasticPool returns activity on databases inside of an elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool.
+func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPoolDatabaseActivityListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolDatabaseActivitiesClient.ListByElasticPool")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByElasticPoolPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByElasticPoolSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByElasticPoolResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolDatabaseActivitiesClient", "ListByElasticPool", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByElasticPoolPreparer prepares the ListByElasticPool request.
+func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/elasticPoolDatabaseActivity", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByElasticPoolSender sends the ListByElasticPool request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByElasticPoolResponder handles the response to the ListByElasticPool request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolDatabaseActivitiesClient) ListByElasticPoolResponder(resp *http.Response) (result ElasticPoolDatabaseActivityListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpools.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpools.go
index cd304fb9def4..8b2ff84aad84 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpools.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/elasticpools.go
@@ -1,609 +1,609 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ElasticPoolsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type ElasticPoolsClient struct {
- BaseClient
-}
-
-// NewElasticPoolsClient creates an instance of the ElasticPoolsClient client.
-func NewElasticPoolsClient(subscriptionID string) ElasticPoolsClient {
- return NewElasticPoolsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewElasticPoolsClientWithBaseURI creates an instance of the ElasticPoolsClient client.
-func NewElasticPoolsClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolsClient {
- return ElasticPoolsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates a new elastic pool or updates an existing elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be operated on (updated or created).
-// parameters - the required parameters for creating or updating an elastic pool.
-func (client ElasticPoolsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPool) (result ElasticPoolsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, elasticPoolName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ElasticPoolsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPool) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) CreateOrUpdateSender(req *http.Request) (future ElasticPoolsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) CreateOrUpdateResponder(resp *http.Response) (result ElasticPool, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes the elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be deleted.
-func (client ElasticPoolsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ElasticPoolsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) 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 an elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be retrieved.
-func (client ElasticPoolsClient) Get(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPool, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ElasticPoolsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) GetResponder(resp *http.Response) (result ElasticPool, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer returns a list of elastic pools in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ElasticPoolsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ElasticPoolListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ElasticPoolsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) ListByServerResponder(resp *http.Response) (result ElasticPoolListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListMetricDefinitions returns elastic pool metric definitions.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool.
-func (client ElasticPoolsClient) ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result MetricDefinitionListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListMetricDefinitions")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListMetricDefinitionsPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListMetricDefinitionsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListMetricDefinitionsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListMetricDefinitionsPreparer prepares the ListMetricDefinitions request.
-func (client ElasticPoolsClient) ListMetricDefinitionsPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/metricDefinitions", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListMetricDefinitionsSender sends the ListMetricDefinitions request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) ListMetricDefinitionsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListMetricDefinitionsResponder handles the response to the ListMetricDefinitions request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) ListMetricDefinitionsResponder(resp *http.Response) (result MetricDefinitionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListMetrics returns elastic pool metrics.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool.
-// filter - an OData filter expression that describes a subset of metrics to return.
-func (client ElasticPoolsClient) ListMetrics(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, filter string) (result MetricListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListMetrics")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListMetricsPreparer(ctx, resourceGroupName, serverName, elasticPoolName, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListMetricsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListMetricsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListMetricsPreparer prepares the ListMetrics request.
-func (client ElasticPoolsClient) ListMetricsPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "$filter": autorest.Encode("query", filter),
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/metrics", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListMetricsSender sends the ListMetrics request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) ListMetricsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListMetricsResponder handles the response to the ListMetrics request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) ListMetricsResponder(resp *http.Response) (result MetricListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Update updates an existing elastic pool.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// elasticPoolName - the name of the elastic pool to be updated.
-// parameters - the required parameters for updating an elastic pool.
-func (client ElasticPoolsClient) Update(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPoolUpdate) (result ElasticPoolsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, elasticPoolName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ElasticPoolsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPoolUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "elasticPoolName": autorest.Encode("path", elasticPoolName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ElasticPoolsClient) UpdateSender(req *http.Request) (future ElasticPoolsUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ElasticPoolsClient) UpdateResponder(resp *http.Response) (result ElasticPool, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ElasticPoolsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type ElasticPoolsClient struct {
+ BaseClient
+}
+
+// NewElasticPoolsClient creates an instance of the ElasticPoolsClient client.
+func NewElasticPoolsClient(subscriptionID string) ElasticPoolsClient {
+ return NewElasticPoolsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewElasticPoolsClientWithBaseURI creates an instance of the ElasticPoolsClient client.
+func NewElasticPoolsClientWithBaseURI(baseURI string, subscriptionID string) ElasticPoolsClient {
+ return ElasticPoolsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates a new elastic pool or updates an existing elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be operated on (updated or created).
+// parameters - the required parameters for creating or updating an elastic pool.
+func (client ElasticPoolsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPool) (result ElasticPoolsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, elasticPoolName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ElasticPoolsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPool) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) CreateOrUpdateSender(req *http.Request) (future ElasticPoolsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) CreateOrUpdateResponder(resp *http.Response) (result ElasticPool, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes the elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be deleted.
+func (client ElasticPoolsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ElasticPoolsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) 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 an elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be retrieved.
+func (client ElasticPoolsClient) Get(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result ElasticPool, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ElasticPoolsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) GetResponder(resp *http.Response) (result ElasticPool, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer returns a list of elastic pools in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ElasticPoolsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ElasticPoolListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ElasticPoolsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) ListByServerResponder(resp *http.Response) (result ElasticPoolListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListMetricDefinitions returns elastic pool metric definitions.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool.
+func (client ElasticPoolsClient) ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result MetricDefinitionListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListMetricDefinitions")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListMetricDefinitionsPreparer(ctx, resourceGroupName, serverName, elasticPoolName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListMetricDefinitionsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListMetricDefinitionsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetricDefinitions", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListMetricDefinitionsPreparer prepares the ListMetricDefinitions request.
+func (client ElasticPoolsClient) ListMetricDefinitionsPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/metricDefinitions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListMetricDefinitionsSender sends the ListMetricDefinitions request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) ListMetricDefinitionsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListMetricDefinitionsResponder handles the response to the ListMetricDefinitions request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) ListMetricDefinitionsResponder(resp *http.Response) (result MetricDefinitionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListMetrics returns elastic pool metrics.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool.
+// filter - an OData filter expression that describes a subset of metrics to return.
+func (client ElasticPoolsClient) ListMetrics(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, filter string) (result MetricListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.ListMetrics")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListMetricsPreparer(ctx, resourceGroupName, serverName, elasticPoolName, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListMetricsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListMetricsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "ListMetrics", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListMetricsPreparer prepares the ListMetrics request.
+func (client ElasticPoolsClient) ListMetricsPreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "$filter": autorest.Encode("query", filter),
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}/metrics", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListMetricsSender sends the ListMetrics request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) ListMetricsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListMetricsResponder handles the response to the ListMetrics request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) ListMetricsResponder(resp *http.Response) (result MetricListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Update updates an existing elastic pool.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// elasticPoolName - the name of the elastic pool to be updated.
+// parameters - the required parameters for updating an elastic pool.
+func (client ElasticPoolsClient) Update(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPoolUpdate) (result ElasticPoolsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ElasticPoolsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, elasticPoolName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ElasticPoolsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ElasticPoolsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters ElasticPoolUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "elasticPoolName": autorest.Encode("path", elasticPoolName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/elasticPools/{elasticPoolName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ElasticPoolsClient) UpdateSender(req *http.Request) (future ElasticPoolsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ElasticPoolsClient) UpdateResponder(resp *http.Response) (result ElasticPool, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/encryptionprotectors.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/encryptionprotectors.go
index cd6a18ff782f..4bf6cc3947ab 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/encryptionprotectors.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/encryptionprotectors.go
@@ -1,400 +1,400 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// EncryptionProtectorsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type EncryptionProtectorsClient struct {
- BaseClient
-}
-
-// NewEncryptionProtectorsClient creates an instance of the EncryptionProtectorsClient client.
-func NewEncryptionProtectorsClient(subscriptionID string) EncryptionProtectorsClient {
- return NewEncryptionProtectorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewEncryptionProtectorsClientWithBaseURI creates an instance of the EncryptionProtectorsClient client.
-func NewEncryptionProtectorsClientWithBaseURI(baseURI string, subscriptionID string) EncryptionProtectorsClient {
- return EncryptionProtectorsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate updates an existing encryption protector.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the requested encryption protector resource state.
-func (client EncryptionProtectorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters EncryptionProtector) (result EncryptionProtectorsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client EncryptionProtectorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters EncryptionProtector) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "encryptionProtectorName": autorest.Encode("path", "current"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client EncryptionProtectorsClient) CreateOrUpdateSender(req *http.Request) (future EncryptionProtectorsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client EncryptionProtectorsClient) CreateOrUpdateResponder(resp *http.Response) (result EncryptionProtector, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a server encryption protector.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client EncryptionProtectorsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtector, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client EncryptionProtectorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "encryptionProtectorName": autorest.Encode("path", "current"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client EncryptionProtectorsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client EncryptionProtectorsClient) GetResponder(resp *http.Response) (result EncryptionProtector, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of server encryption protectors
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client EncryptionProtectorsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.ListByServer")
- defer func() {
- sc := -1
- if result.eplr.Response.Response != nil {
- sc = result.eplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.eplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.eplr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client EncryptionProtectorsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client EncryptionProtectorsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client EncryptionProtectorsClient) ListByServerResponder(resp *http.Response) (result EncryptionProtectorListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client EncryptionProtectorsClient) listByServerNextResults(ctx context.Context, lastResults EncryptionProtectorListResult) (result EncryptionProtectorListResult, err error) {
- req, err := lastResults.encryptionProtectorListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client EncryptionProtectorsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
-
-// Revalidate revalidates an existing encryption protector.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client EncryptionProtectorsClient) Revalidate(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorsRevalidateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.Revalidate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.RevalidatePreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Revalidate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.RevalidateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Revalidate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// RevalidatePreparer prepares the Revalidate request.
-func (client EncryptionProtectorsClient) RevalidatePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "encryptionProtectorName": autorest.Encode("path", "current"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}/revalidate", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// RevalidateSender sends the Revalidate request. The method will close the
-// http.Response Body if it receives an error.
-func (client EncryptionProtectorsClient) RevalidateSender(req *http.Request) (future EncryptionProtectorsRevalidateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// RevalidateResponder handles the response to the Revalidate request. The method always
-// closes the http.Response Body.
-func (client EncryptionProtectorsClient) RevalidateResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// EncryptionProtectorsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type EncryptionProtectorsClient struct {
+ BaseClient
+}
+
+// NewEncryptionProtectorsClient creates an instance of the EncryptionProtectorsClient client.
+func NewEncryptionProtectorsClient(subscriptionID string) EncryptionProtectorsClient {
+ return NewEncryptionProtectorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewEncryptionProtectorsClientWithBaseURI creates an instance of the EncryptionProtectorsClient client.
+func NewEncryptionProtectorsClientWithBaseURI(baseURI string, subscriptionID string) EncryptionProtectorsClient {
+ return EncryptionProtectorsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate updates an existing encryption protector.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the requested encryption protector resource state.
+func (client EncryptionProtectorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters EncryptionProtector) (result EncryptionProtectorsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client EncryptionProtectorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters EncryptionProtector) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "encryptionProtectorName": autorest.Encode("path", "current"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client EncryptionProtectorsClient) CreateOrUpdateSender(req *http.Request) (future EncryptionProtectorsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client EncryptionProtectorsClient) CreateOrUpdateResponder(resp *http.Response) (result EncryptionProtector, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a server encryption protector.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client EncryptionProtectorsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtector, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client EncryptionProtectorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "encryptionProtectorName": autorest.Encode("path", "current"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client EncryptionProtectorsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client EncryptionProtectorsClient) GetResponder(resp *http.Response) (result EncryptionProtector, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of server encryption protectors
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client EncryptionProtectorsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.eplr.Response.Response != nil {
+ sc = result.eplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.eplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.eplr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client EncryptionProtectorsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client EncryptionProtectorsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client EncryptionProtectorsClient) ListByServerResponder(resp *http.Response) (result EncryptionProtectorListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client EncryptionProtectorsClient) listByServerNextResults(ctx context.Context, lastResults EncryptionProtectorListResult) (result EncryptionProtectorListResult, err error) {
+ req, err := lastResults.encryptionProtectorListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client EncryptionProtectorsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
+
+// Revalidate revalidates an existing encryption protector.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client EncryptionProtectorsClient) Revalidate(ctx context.Context, resourceGroupName string, serverName string) (result EncryptionProtectorsRevalidateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/EncryptionProtectorsClient.Revalidate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.RevalidatePreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Revalidate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.RevalidateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.EncryptionProtectorsClient", "Revalidate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// RevalidatePreparer prepares the Revalidate request.
+func (client EncryptionProtectorsClient) RevalidatePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "encryptionProtectorName": autorest.Encode("path", "current"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/encryptionProtector/{encryptionProtectorName}/revalidate", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// RevalidateSender sends the Revalidate request. The method will close the
+// http.Response Body if it receives an error.
+func (client EncryptionProtectorsClient) RevalidateSender(req *http.Request) (future EncryptionProtectorsRevalidateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// RevalidateResponder handles the response to the Revalidate request. The method always
+// closes the http.Response Body.
+func (client EncryptionProtectorsClient) RevalidateResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/extendeddatabaseblobauditingpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/extendeddatabaseblobauditingpolicies.go
index 745514c25147..7c174fe2ad37 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/extendeddatabaseblobauditingpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/extendeddatabaseblobauditingpolicies.go
@@ -1,210 +1,210 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ExtendedDatabaseBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of
-// web services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ExtendedDatabaseBlobAuditingPoliciesClient struct {
- BaseClient
-}
-
-// NewExtendedDatabaseBlobAuditingPoliciesClient creates an instance of the ExtendedDatabaseBlobAuditingPoliciesClient
-// client.
-func NewExtendedDatabaseBlobAuditingPoliciesClient(subscriptionID string) ExtendedDatabaseBlobAuditingPoliciesClient {
- return NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI creates an instance of the
-// ExtendedDatabaseBlobAuditingPoliciesClient client.
-func NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ExtendedDatabaseBlobAuditingPoliciesClient {
- return ExtendedDatabaseBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates an extended database's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - the extended database blob auditing policy.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExtendedDatabaseBlobAuditingPolicy) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ExtendedDatabaseBlobAuditingPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExtendedDatabaseBlobAuditingPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extendedAuditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets an extended database's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ExtendedDatabaseBlobAuditingPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extendedAuditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ExtendedDatabaseBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of
+// web services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ExtendedDatabaseBlobAuditingPoliciesClient struct {
+ BaseClient
+}
+
+// NewExtendedDatabaseBlobAuditingPoliciesClient creates an instance of the ExtendedDatabaseBlobAuditingPoliciesClient
+// client.
+func NewExtendedDatabaseBlobAuditingPoliciesClient(subscriptionID string) ExtendedDatabaseBlobAuditingPoliciesClient {
+ return NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI creates an instance of the
+// ExtendedDatabaseBlobAuditingPoliciesClient client.
+func NewExtendedDatabaseBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ExtendedDatabaseBlobAuditingPoliciesClient {
+ return ExtendedDatabaseBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates an extended database's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - the extended database blob auditing policy.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExtendedDatabaseBlobAuditingPolicy) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ExtendedDatabaseBlobAuditingPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters ExtendedDatabaseBlobAuditingPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extendedAuditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets an extended database's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ExtendedDatabaseBlobAuditingPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ExtendedDatabaseBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extendedAuditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ExtendedDatabaseBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result ExtendedDatabaseBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/failovergroups.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/failovergroups.go
index ac6b22182b03..ea286e1e6aff 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/failovergroups.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/failovergroups.go
@@ -1,656 +1,656 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// FailoverGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type FailoverGroupsClient struct {
- BaseClient
-}
-
-// NewFailoverGroupsClient creates an instance of the FailoverGroupsClient client.
-func NewFailoverGroupsClient(subscriptionID string) FailoverGroupsClient {
- return NewFailoverGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewFailoverGroupsClientWithBaseURI creates an instance of the FailoverGroupsClient client.
-func NewFailoverGroupsClientWithBaseURI(baseURI string, subscriptionID string) FailoverGroupsClient {
- return FailoverGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a failover group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-// parameters - the failover group parameters.
-func (client FailoverGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroup) (result FailoverGroupsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.FailoverGroupProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.FailoverGroupProperties.ReadWriteEndpoint", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.FailoverGroupProperties.PartnerServers", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.FailoverGroupsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, failoverGroupName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client FailoverGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroup) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) CreateOrUpdateSender(req *http.Request) (future FailoverGroupsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result FailoverGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a failover group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-func (client FailoverGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, failoverGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client FailoverGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) DeleteSender(req *http.Request) (future FailoverGroupsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Failover fails over from the current primary server to this server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-func (client FailoverGroupsClient) Failover(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsFailoverFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Failover")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.FailoverPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Failover", nil, "Failure preparing request")
- return
- }
-
- result, err = client.FailoverSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Failover", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// FailoverPreparer prepares the Failover request.
-func (client FailoverGroupsClient) FailoverPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}/failover", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// FailoverSender sends the Failover request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) FailoverSender(req *http.Request) (future FailoverGroupsFailoverFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// FailoverResponder handles the response to the Failover request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) FailoverResponder(resp *http.Response) (result FailoverGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ForceFailoverAllowDataLoss fails over from the current primary server to this server. This operation might result in
-// data loss.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-func (client FailoverGroupsClient) ForceFailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsForceFailoverAllowDataLossFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ForceFailoverAllowDataLoss")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ForceFailoverAllowDataLossPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ForceFailoverAllowDataLoss", nil, "Failure preparing request")
- return
- }
-
- result, err = client.ForceFailoverAllowDataLossSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ForceFailoverAllowDataLoss", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// ForceFailoverAllowDataLossPreparer prepares the ForceFailoverAllowDataLoss request.
-func (client FailoverGroupsClient) ForceFailoverAllowDataLossPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}/forceFailoverAllowDataLoss", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ForceFailoverAllowDataLossSender sends the ForceFailoverAllowDataLoss request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) ForceFailoverAllowDataLossSender(req *http.Request) (future FailoverGroupsForceFailoverAllowDataLossFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// ForceFailoverAllowDataLossResponder handles the response to the ForceFailoverAllowDataLoss request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) ForceFailoverAllowDataLossResponder(resp *http.Response) (result FailoverGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a failover group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-func (client FailoverGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroup, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client FailoverGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) GetResponder(resp *http.Response) (result FailoverGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer lists the failover groups in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-func (client FailoverGroupsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result FailoverGroupListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ListByServer")
- defer func() {
- sc := -1
- if result.fglr.Response.Response != nil {
- sc = result.fglr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.fglr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.fglr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client FailoverGroupsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) ListByServerResponder(resp *http.Response) (result FailoverGroupListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client FailoverGroupsClient) listByServerNextResults(ctx context.Context, lastResults FailoverGroupListResult) (result FailoverGroupListResult, err error) {
- req, err := lastResults.failoverGroupListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client FailoverGroupsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result FailoverGroupListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
-
-// Update updates a failover group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server containing the failover group.
-// failoverGroupName - the name of the failover group.
-// parameters - the failover group parameters.
-func (client FailoverGroupsClient) Update(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroupUpdate) (result FailoverGroupsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, failoverGroupName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client FailoverGroupsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroupUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "failoverGroupName": autorest.Encode("path", failoverGroupName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client FailoverGroupsClient) UpdateSender(req *http.Request) (future FailoverGroupsUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client FailoverGroupsClient) UpdateResponder(resp *http.Response) (result FailoverGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// FailoverGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type FailoverGroupsClient struct {
+ BaseClient
+}
+
+// NewFailoverGroupsClient creates an instance of the FailoverGroupsClient client.
+func NewFailoverGroupsClient(subscriptionID string) FailoverGroupsClient {
+ return NewFailoverGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewFailoverGroupsClientWithBaseURI creates an instance of the FailoverGroupsClient client.
+func NewFailoverGroupsClientWithBaseURI(baseURI string, subscriptionID string) FailoverGroupsClient {
+ return FailoverGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a failover group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+// parameters - the failover group parameters.
+func (client FailoverGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroup) (result FailoverGroupsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.FailoverGroupProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.FailoverGroupProperties.ReadWriteEndpoint", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.FailoverGroupProperties.PartnerServers", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.FailoverGroupsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, failoverGroupName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client FailoverGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroup) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) CreateOrUpdateSender(req *http.Request) (future FailoverGroupsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result FailoverGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a failover group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+func (client FailoverGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, failoverGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client FailoverGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) DeleteSender(req *http.Request) (future FailoverGroupsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Failover fails over from the current primary server to this server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+func (client FailoverGroupsClient) Failover(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsFailoverFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Failover")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.FailoverPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Failover", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.FailoverSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Failover", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// FailoverPreparer prepares the Failover request.
+func (client FailoverGroupsClient) FailoverPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}/failover", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// FailoverSender sends the Failover request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) FailoverSender(req *http.Request) (future FailoverGroupsFailoverFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// FailoverResponder handles the response to the Failover request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) FailoverResponder(resp *http.Response) (result FailoverGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ForceFailoverAllowDataLoss fails over from the current primary server to this server. This operation might result in
+// data loss.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+func (client FailoverGroupsClient) ForceFailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroupsForceFailoverAllowDataLossFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ForceFailoverAllowDataLoss")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ForceFailoverAllowDataLossPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ForceFailoverAllowDataLoss", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.ForceFailoverAllowDataLossSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ForceFailoverAllowDataLoss", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// ForceFailoverAllowDataLossPreparer prepares the ForceFailoverAllowDataLoss request.
+func (client FailoverGroupsClient) ForceFailoverAllowDataLossPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}/forceFailoverAllowDataLoss", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ForceFailoverAllowDataLossSender sends the ForceFailoverAllowDataLoss request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) ForceFailoverAllowDataLossSender(req *http.Request) (future FailoverGroupsForceFailoverAllowDataLossFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// ForceFailoverAllowDataLossResponder handles the response to the ForceFailoverAllowDataLoss request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) ForceFailoverAllowDataLossResponder(resp *http.Response) (result FailoverGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a failover group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+func (client FailoverGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result FailoverGroup, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, failoverGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client FailoverGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) GetResponder(resp *http.Response) (result FailoverGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer lists the failover groups in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+func (client FailoverGroupsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result FailoverGroupListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.fglr.Response.Response != nil {
+ sc = result.fglr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.fglr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.fglr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client FailoverGroupsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) ListByServerResponder(resp *http.Response) (result FailoverGroupListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client FailoverGroupsClient) listByServerNextResults(ctx context.Context, lastResults FailoverGroupListResult) (result FailoverGroupListResult, err error) {
+ req, err := lastResults.failoverGroupListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client FailoverGroupsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result FailoverGroupListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
+
+// Update updates a failover group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server containing the failover group.
+// failoverGroupName - the name of the failover group.
+// parameters - the failover group parameters.
+func (client FailoverGroupsClient) Update(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroupUpdate) (result FailoverGroupsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FailoverGroupsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, failoverGroupName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FailoverGroupsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client FailoverGroupsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters FailoverGroupUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "failoverGroupName": autorest.Encode("path", failoverGroupName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/failoverGroups/{failoverGroupName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client FailoverGroupsClient) UpdateSender(req *http.Request) (future FailoverGroupsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client FailoverGroupsClient) UpdateResponder(resp *http.Response) (result FailoverGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/firewallrules.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/firewallrules.go
index cefa73d18e97..daa8a1f832c7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/firewallrules.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/firewallrules.go
@@ -1,375 +1,375 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// FirewallRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type FirewallRulesClient struct {
- BaseClient
-}
-
-// 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.
-func NewFirewallRulesClientWithBaseURI(baseURI string, subscriptionID string) FirewallRulesClient {
- return FirewallRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a firewall rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// firewallRuleName - the name of the firewall rule.
-// parameters - the required parameters for creating or updating a firewall rule.
-func (client FirewallRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string, parameters FirewallRule) (result FirewallRule, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.FirewallRuleProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.FirewallRuleProperties.StartIPAddress", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.FirewallRuleProperties.EndIPAddress", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.FirewallRulesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, firewallRuleName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client FirewallRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string, parameters FirewallRule) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "firewallRuleName": autorest.Encode("path", firewallRuleName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client FirewallRulesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client FirewallRulesClient) CreateOrUpdateResponder(resp *http.Response) (result FirewallRule, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a firewall rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// firewallRuleName - the name of the firewall rule.
-func (client FirewallRulesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, firewallRuleName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client FirewallRulesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "firewallRuleName": autorest.Encode("path", firewallRuleName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client FirewallRulesClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client FirewallRulesClient) 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 a firewall rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// firewallRuleName - the name of the firewall rule.
-func (client FirewallRulesClient) Get(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result FirewallRule, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, firewallRuleName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client FirewallRulesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "firewallRuleName": autorest.Encode("path", firewallRuleName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client FirewallRulesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client FirewallRulesClient) GetResponder(resp *http.Response) (result FirewallRule, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer returns a list of firewall rules.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client FirewallRulesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result FirewallRuleListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client FirewallRulesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client FirewallRulesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client FirewallRulesClient) ListByServerResponder(resp *http.Response) (result FirewallRuleListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// FirewallRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type FirewallRulesClient struct {
+ BaseClient
+}
+
+// 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.
+func NewFirewallRulesClientWithBaseURI(baseURI string, subscriptionID string) FirewallRulesClient {
+ return FirewallRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a firewall rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// firewallRuleName - the name of the firewall rule.
+// parameters - the required parameters for creating or updating a firewall rule.
+func (client FirewallRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string, parameters FirewallRule) (result FirewallRule, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.FirewallRuleProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.FirewallRuleProperties.StartIPAddress", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.FirewallRuleProperties.EndIPAddress", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.FirewallRulesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, firewallRuleName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client FirewallRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string, parameters FirewallRule) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "firewallRuleName": autorest.Encode("path", firewallRuleName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client FirewallRulesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client FirewallRulesClient) CreateOrUpdateResponder(resp *http.Response) (result FirewallRule, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a firewall rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// firewallRuleName - the name of the firewall rule.
+func (client FirewallRulesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, firewallRuleName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client FirewallRulesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "firewallRuleName": autorest.Encode("path", firewallRuleName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client FirewallRulesClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client FirewallRulesClient) 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 a firewall rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// firewallRuleName - the name of the firewall rule.
+func (client FirewallRulesClient) Get(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result FirewallRule, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, firewallRuleName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client FirewallRulesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "firewallRuleName": autorest.Encode("path", firewallRuleName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules/{firewallRuleName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client FirewallRulesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client FirewallRulesClient) GetResponder(resp *http.Response) (result FirewallRule, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer returns a list of firewall rules.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client FirewallRulesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result FirewallRuleListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/FirewallRulesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.FirewallRulesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client FirewallRulesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/firewallRules", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client FirewallRulesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client FirewallRulesClient) ListByServerResponder(resp *http.Response) (result FirewallRuleListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/geobackuppolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/geobackuppolicies.go
index 4a5ce51c37f3..28e35d715a1b 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/geobackuppolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/geobackuppolicies.go
@@ -1,297 +1,297 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// GeoBackupPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type GeoBackupPoliciesClient struct {
- BaseClient
-}
-
-// NewGeoBackupPoliciesClient creates an instance of the GeoBackupPoliciesClient client.
-func NewGeoBackupPoliciesClient(subscriptionID string) GeoBackupPoliciesClient {
- return NewGeoBackupPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewGeoBackupPoliciesClientWithBaseURI creates an instance of the GeoBackupPoliciesClient client.
-func NewGeoBackupPoliciesClientWithBaseURI(baseURI string, subscriptionID string) GeoBackupPoliciesClient {
- return GeoBackupPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate updates a database geo backup policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - the required parameters for creating or updating the geo backup policy.
-func (client GeoBackupPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters GeoBackupPolicy) (result GeoBackupPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.GeoBackupPolicyProperties", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.GeoBackupPoliciesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client GeoBackupPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters GeoBackupPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "geoBackupPolicyName": autorest.Encode("path", "Default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies/{geoBackupPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client GeoBackupPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client GeoBackupPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result GeoBackupPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a geo backup policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client GeoBackupPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result GeoBackupPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client GeoBackupPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "geoBackupPolicyName": autorest.Encode("path", "Default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies/{geoBackupPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client GeoBackupPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client GeoBackupPoliciesClient) GetResponder(resp *http.Response) (result GeoBackupPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase returns a list of geo backup policies.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client GeoBackupPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result GeoBackupPolicyListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client GeoBackupPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client GeoBackupPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client GeoBackupPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result GeoBackupPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// GeoBackupPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type GeoBackupPoliciesClient struct {
+ BaseClient
+}
+
+// NewGeoBackupPoliciesClient creates an instance of the GeoBackupPoliciesClient client.
+func NewGeoBackupPoliciesClient(subscriptionID string) GeoBackupPoliciesClient {
+ return NewGeoBackupPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewGeoBackupPoliciesClientWithBaseURI creates an instance of the GeoBackupPoliciesClient client.
+func NewGeoBackupPoliciesClientWithBaseURI(baseURI string, subscriptionID string) GeoBackupPoliciesClient {
+ return GeoBackupPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate updates a database geo backup policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - the required parameters for creating or updating the geo backup policy.
+func (client GeoBackupPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters GeoBackupPolicy) (result GeoBackupPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.GeoBackupPolicyProperties", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.GeoBackupPoliciesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client GeoBackupPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters GeoBackupPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "geoBackupPolicyName": autorest.Encode("path", "Default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies/{geoBackupPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client GeoBackupPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client GeoBackupPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result GeoBackupPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a geo backup policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client GeoBackupPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result GeoBackupPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client GeoBackupPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "geoBackupPolicyName": autorest.Encode("path", "Default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies/{geoBackupPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client GeoBackupPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client GeoBackupPoliciesClient) GetResponder(resp *http.Response) (result GeoBackupPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase returns a list of geo backup policies.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client GeoBackupPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result GeoBackupPolicyListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/GeoBackupPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.GeoBackupPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client GeoBackupPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/geoBackupPolicies", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client GeoBackupPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client GeoBackupPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result GeoBackupPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobagents.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobagents.go
index f96f760ee4e7..ee60e7d85f2e 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobagents.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobagents.go
@@ -1,494 +1,494 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobAgentsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type JobAgentsClient struct {
- BaseClient
-}
-
-// NewJobAgentsClient creates an instance of the JobAgentsClient client.
-func NewJobAgentsClient(subscriptionID string) JobAgentsClient {
- return NewJobAgentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobAgentsClientWithBaseURI creates an instance of the JobAgentsClient client.
-func NewJobAgentsClientWithBaseURI(baseURI string, subscriptionID string) JobAgentsClient {
- return JobAgentsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a job agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent to be created or updated.
-// parameters - the requested job agent resource state.
-func (client JobAgentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgent) (result JobAgentsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Sku", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}},
- {Target: "parameters.JobAgentProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.JobAgentProperties.DatabaseID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.JobAgentsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobAgentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgent) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobAgentsClient) CreateOrUpdateSender(req *http.Request) (future JobAgentsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobAgentsClient) CreateOrUpdateResponder(resp *http.Response) (result JobAgent, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a job agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent to be deleted.
-func (client JobAgentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobAgentsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client JobAgentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobAgentsClient) DeleteSender(req *http.Request) (future JobAgentsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client JobAgentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a job agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent to be retrieved.
-func (client JobAgentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobAgent, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobAgentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobAgentsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobAgentsClient) GetResponder(resp *http.Response) (result JobAgent, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of job agents in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client JobAgentsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result JobAgentListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.ListByServer")
- defer func() {
- sc := -1
- if result.jalr.Response.Response != nil {
- sc = result.jalr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.jalr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.jalr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client JobAgentsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobAgentsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client JobAgentsClient) ListByServerResponder(resp *http.Response) (result JobAgentListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client JobAgentsClient) listByServerNextResults(ctx context.Context, lastResults JobAgentListResult) (result JobAgentListResult, err error) {
- req, err := lastResults.jobAgentListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobAgentsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result JobAgentListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
-
-// Update updates a job agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent to be updated.
-// parameters - the update to the job agent.
-func (client JobAgentsClient) Update(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgentUpdate) (result JobAgentsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client JobAgentsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgentUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobAgentsClient) UpdateSender(req *http.Request) (future JobAgentsUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client JobAgentsClient) UpdateResponder(resp *http.Response) (result JobAgent, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobAgentsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type JobAgentsClient struct {
+ BaseClient
+}
+
+// NewJobAgentsClient creates an instance of the JobAgentsClient client.
+func NewJobAgentsClient(subscriptionID string) JobAgentsClient {
+ return NewJobAgentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobAgentsClientWithBaseURI creates an instance of the JobAgentsClient client.
+func NewJobAgentsClientWithBaseURI(baseURI string, subscriptionID string) JobAgentsClient {
+ return JobAgentsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a job agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent to be created or updated.
+// parameters - the requested job agent resource state.
+func (client JobAgentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgent) (result JobAgentsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.Sku", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}},
+ {Target: "parameters.JobAgentProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.JobAgentProperties.DatabaseID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.JobAgentsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobAgentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgent) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobAgentsClient) CreateOrUpdateSender(req *http.Request) (future JobAgentsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobAgentsClient) CreateOrUpdateResponder(resp *http.Response) (result JobAgent, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a job agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent to be deleted.
+func (client JobAgentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobAgentsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client JobAgentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobAgentsClient) DeleteSender(req *http.Request) (future JobAgentsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client JobAgentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a job agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent to be retrieved.
+func (client JobAgentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobAgent, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobAgentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobAgentsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobAgentsClient) GetResponder(resp *http.Response) (result JobAgent, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of job agents in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client JobAgentsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result JobAgentListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.jalr.Response.Response != nil {
+ sc = result.jalr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.jalr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.jalr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client JobAgentsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobAgentsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client JobAgentsClient) ListByServerResponder(resp *http.Response) (result JobAgentListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client JobAgentsClient) listByServerNextResults(ctx context.Context, lastResults JobAgentListResult) (result JobAgentListResult, err error) {
+ req, err := lastResults.jobAgentListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobAgentsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result JobAgentListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
+
+// Update updates a job agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent to be updated.
+// parameters - the update to the job agent.
+func (client JobAgentsClient) Update(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgentUpdate) (result JobAgentsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobAgentsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobAgentsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client JobAgentsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters JobAgentUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobAgentsClient) UpdateSender(req *http.Request) (future JobAgentsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client JobAgentsClient) UpdateResponder(resp *http.Response) (result JobAgent, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobcredentials.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobcredentials.go
index 2e8b32bc5451..684e3d528af6 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobcredentials.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobcredentials.go
@@ -1,419 +1,419 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobCredentialsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type JobCredentialsClient struct {
- BaseClient
-}
-
-// NewJobCredentialsClient creates an instance of the JobCredentialsClient client.
-func NewJobCredentialsClient(subscriptionID string) JobCredentialsClient {
- return NewJobCredentialsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobCredentialsClientWithBaseURI creates an instance of the JobCredentialsClient client.
-func NewJobCredentialsClientWithBaseURI(baseURI string, subscriptionID string) JobCredentialsClient {
- return JobCredentialsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a job credential.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// credentialName - the name of the credential.
-// parameters - the requested job credential state.
-func (client JobCredentialsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string, parameters JobCredential) (result JobCredential, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.JobCredentialProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.JobCredentialProperties.Username", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobCredentialProperties.Password", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.JobCredentialsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobCredentialsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string, parameters JobCredential) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "credentialName": autorest.Encode("path", credentialName),
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobCredentialsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobCredentialsClient) CreateOrUpdateResponder(resp *http.Response) (result JobCredential, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a job credential.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// credentialName - the name of the credential.
-func (client JobCredentialsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client JobCredentialsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "credentialName": autorest.Encode("path", credentialName),
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobCredentialsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client JobCredentialsClient) 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 a jobs credential.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// credentialName - the name of the credential.
-func (client JobCredentialsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result JobCredential, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobCredentialsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "credentialName": autorest.Encode("path", credentialName),
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobCredentialsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobCredentialsClient) GetResponder(resp *http.Response) (result JobCredential, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByAgent gets a list of jobs credentials.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-func (client JobCredentialsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobCredentialListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.jclr.Response.Response != nil {
- sc = result.jclr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByAgentNextResults
- req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.jclr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", resp, "Failure sending request")
- return
- }
-
- result.jclr, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByAgentPreparer prepares the ListByAgent request.
-func (client JobCredentialsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByAgentSender sends the ListByAgent request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobCredentialsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByAgentResponder handles the response to the ListByAgent request. The method always
-// closes the http.Response Body.
-func (client JobCredentialsClient) ListByAgentResponder(resp *http.Response) (result JobCredentialListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByAgentNextResults retrieves the next set of results, if any.
-func (client JobCredentialsClient) listByAgentNextResults(ctx context.Context, lastResults JobCredentialListResult) (result JobCredentialListResult, err error) {
- req, err := lastResults.jobCredentialListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobCredentialsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobCredentialListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobCredentialsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type JobCredentialsClient struct {
+ BaseClient
+}
+
+// NewJobCredentialsClient creates an instance of the JobCredentialsClient client.
+func NewJobCredentialsClient(subscriptionID string) JobCredentialsClient {
+ return NewJobCredentialsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobCredentialsClientWithBaseURI creates an instance of the JobCredentialsClient client.
+func NewJobCredentialsClientWithBaseURI(baseURI string, subscriptionID string) JobCredentialsClient {
+ return JobCredentialsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a job credential.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// credentialName - the name of the credential.
+// parameters - the requested job credential state.
+func (client JobCredentialsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string, parameters JobCredential) (result JobCredential, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.JobCredentialProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.JobCredentialProperties.Username", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobCredentialProperties.Password", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.JobCredentialsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobCredentialsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string, parameters JobCredential) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "credentialName": autorest.Encode("path", credentialName),
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobCredentialsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobCredentialsClient) CreateOrUpdateResponder(resp *http.Response) (result JobCredential, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a job credential.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// credentialName - the name of the credential.
+func (client JobCredentialsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client JobCredentialsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "credentialName": autorest.Encode("path", credentialName),
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobCredentialsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client JobCredentialsClient) 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 a jobs credential.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// credentialName - the name of the credential.
+func (client JobCredentialsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result JobCredential, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, credentialName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobCredentialsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "credentialName": autorest.Encode("path", credentialName),
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials/{credentialName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobCredentialsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobCredentialsClient) GetResponder(resp *http.Response) (result JobCredential, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByAgent gets a list of jobs credentials.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+func (client JobCredentialsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobCredentialListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.jclr.Response.Response != nil {
+ sc = result.jclr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByAgentNextResults
+ req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.jclr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", resp, "Failure sending request")
+ return
+ }
+
+ result.jclr, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "ListByAgent", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByAgentPreparer prepares the ListByAgent request.
+func (client JobCredentialsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/credentials", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByAgentSender sends the ListByAgent request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobCredentialsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByAgentResponder handles the response to the ListByAgent request. The method always
+// closes the http.Response Body.
+func (client JobCredentialsClient) ListByAgentResponder(resp *http.Response) (result JobCredentialListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByAgentNextResults retrieves the next set of results, if any.
+func (client JobCredentialsClient) listByAgentNextResults(ctx context.Context, lastResults JobCredentialListResult) (result JobCredentialListResult, err error) {
+ req, err := lastResults.jobCredentialListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobCredentialsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobCredentialsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobCredentialListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobCredentialsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobexecutions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobexecutions.go
index 96bf8e5b1ad3..eb0535c6f24a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobexecutions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobexecutions.go
@@ -1,672 +1,672 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/date"
- "github.com/Azure/go-autorest/tracing"
- "github.com/satori/go.uuid"
- "net/http"
-)
-
-// JobExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type JobExecutionsClient struct {
- BaseClient
-}
-
-// NewJobExecutionsClient creates an instance of the JobExecutionsClient client.
-func NewJobExecutionsClient(subscriptionID string) JobExecutionsClient {
- return NewJobExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobExecutionsClientWithBaseURI creates an instance of the JobExecutionsClient client.
-func NewJobExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobExecutionsClient {
- return JobExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Cancel requests cancellation of a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// jobExecutionID - the id of the job execution to cancel.
-func (client JobExecutionsClient) Cancel(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Cancel")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CancelPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CancelSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", resp, "Failure sending request")
- return
- }
-
- result, err = client.CancelResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CancelPreparer prepares the Cancel request.
-func (client JobExecutionsClient) CancelPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/cancel", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CancelSender sends the Cancel request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) CancelSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CancelResponder handles the response to the Cancel request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) CancelResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Create starts an elastic job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-func (client JobExecutionsClient) Create(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobExecutionsCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client JobExecutionsClient) CreatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/start", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) CreateSender(req *http.Request) (future JobExecutionsCreateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) CreateResponder(resp *http.Response) (result JobExecution, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// CreateOrUpdate creates or updates a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the job execution id to create the job execution under.
-func (client JobExecutionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result JobExecutionsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobExecutionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) CreateOrUpdateSender(req *http.Request) (future JobExecutionsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) CreateOrUpdateResponder(resp *http.Response) (result JobExecution, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// jobExecutionID - the id of the job execution
-func (client JobExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result JobExecution, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByAgent lists all executions in a job agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// createTimeMin - if specified, only job executions created at or after the specified time are included.
-// createTimeMax - if specified, only job executions created before the specified time are included.
-// endTimeMin - if specified, only job executions completed at or after the specified time are included.
-// endTimeMax - if specified, only job executions completed before the specified time are included.
-// isActive - if specified, only active or only completed job executions are included.
-// skip - the number of elements in the collection to skip.
-// top - the number of elements to return from the collection.
-func (client JobExecutionsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.jelr.Response.Response != nil {
- sc = result.jelr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByAgentNextResults
- req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.jelr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", resp, "Failure sending request")
- return
- }
-
- result.jelr, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByAgentPreparer prepares the ListByAgent request.
-func (client JobExecutionsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if createTimeMin != nil {
- queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
- }
- if createTimeMax != nil {
- queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
- }
- if endTimeMin != nil {
- queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
- }
- if endTimeMax != nil {
- queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
- }
- if isActive != nil {
- queryParameters["isActive"] = autorest.Encode("query", *isActive)
- }
- if skip != nil {
- queryParameters["$skip"] = autorest.Encode("query", *skip)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/executions", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByAgentSender sends the ListByAgent request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByAgentResponder handles the response to the ListByAgent request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) ListByAgentResponder(resp *http.Response) (result JobExecutionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByAgentNextResults retrieves the next set of results, if any.
-func (client JobExecutionsClient) listByAgentNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
- req, err := lastResults.jobExecutionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobExecutionsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- return
-}
-
-// ListByJob lists a job's executions.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// createTimeMin - if specified, only job executions created at or after the specified time are included.
-// createTimeMax - if specified, only job executions created before the specified time are included.
-// endTimeMin - if specified, only job executions completed at or after the specified time are included.
-// endTimeMax - if specified, only job executions completed before the specified time are included.
-// isActive - if specified, only active or only completed job executions are included.
-// skip - the number of elements in the collection to skip.
-// top - the number of elements to return from the collection.
-func (client JobExecutionsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByJob")
- defer func() {
- sc := -1
- if result.jelr.Response.Response != nil {
- sc = result.jelr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByJobNextResults
- req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.jelr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", resp, "Failure sending request")
- return
- }
-
- result.jelr, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByJobPreparer prepares the ListByJob request.
-func (client JobExecutionsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if createTimeMin != nil {
- queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
- }
- if createTimeMax != nil {
- queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
- }
- if endTimeMin != nil {
- queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
- }
- if endTimeMax != nil {
- queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
- }
- if isActive != nil {
- queryParameters["isActive"] = autorest.Encode("query", *isActive)
- }
- if skip != nil {
- queryParameters["$skip"] = autorest.Encode("query", *skip)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByJobSender sends the ListByJob request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobExecutionsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByJobResponder handles the response to the ListByJob request. The method always
-// closes the http.Response Body.
-func (client JobExecutionsClient) ListByJobResponder(resp *http.Response) (result JobExecutionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByJobNextResults retrieves the next set of results, if any.
-func (client JobExecutionsClient) listByJobNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
- req, err := lastResults.jobExecutionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobExecutionsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByJob")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/date"
+ "github.com/Azure/go-autorest/tracing"
+ "github.com/satori/go.uuid"
+ "net/http"
+)
+
+// JobExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type JobExecutionsClient struct {
+ BaseClient
+}
+
+// NewJobExecutionsClient creates an instance of the JobExecutionsClient client.
+func NewJobExecutionsClient(subscriptionID string) JobExecutionsClient {
+ return NewJobExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobExecutionsClientWithBaseURI creates an instance of the JobExecutionsClient client.
+func NewJobExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobExecutionsClient {
+ return JobExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Cancel requests cancellation of a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// jobExecutionID - the id of the job execution to cancel.
+func (client JobExecutionsClient) Cancel(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Cancel")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CancelPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CancelSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CancelResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Cancel", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CancelPreparer prepares the Cancel request.
+func (client JobExecutionsClient) CancelPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/cancel", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CancelSender sends the Cancel request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) CancelSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CancelResponder handles the response to the Cancel request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) CancelResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Create starts an elastic job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+func (client JobExecutionsClient) Create(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobExecutionsCreateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Create")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Create", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Create", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreatePreparer prepares the Create request.
+func (client JobExecutionsClient) CreatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/start", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateSender sends the Create request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) CreateSender(req *http.Request) (future JobExecutionsCreateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateResponder handles the response to the Create request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) CreateResponder(resp *http.Response) (result JobExecution, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// CreateOrUpdate creates or updates a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the job execution id to create the job execution under.
+func (client JobExecutionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result JobExecutionsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobExecutionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) CreateOrUpdateSender(req *http.Request) (future JobExecutionsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) CreateOrUpdateResponder(resp *http.Response) (result JobExecution, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// jobExecutionID - the id of the job execution
+func (client JobExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result JobExecution, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByAgent lists all executions in a job agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// createTimeMin - if specified, only job executions created at or after the specified time are included.
+// createTimeMax - if specified, only job executions created before the specified time are included.
+// endTimeMin - if specified, only job executions completed at or after the specified time are included.
+// endTimeMax - if specified, only job executions completed before the specified time are included.
+// isActive - if specified, only active or only completed job executions are included.
+// skip - the number of elements in the collection to skip.
+// top - the number of elements to return from the collection.
+func (client JobExecutionsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.jelr.Response.Response != nil {
+ sc = result.jelr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByAgentNextResults
+ req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.jelr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", resp, "Failure sending request")
+ return
+ }
+
+ result.jelr, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByAgent", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByAgentPreparer prepares the ListByAgent request.
+func (client JobExecutionsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if createTimeMin != nil {
+ queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
+ }
+ if createTimeMax != nil {
+ queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
+ }
+ if endTimeMin != nil {
+ queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
+ }
+ if endTimeMax != nil {
+ queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
+ }
+ if isActive != nil {
+ queryParameters["isActive"] = autorest.Encode("query", *isActive)
+ }
+ if skip != nil {
+ queryParameters["$skip"] = autorest.Encode("query", *skip)
+ }
+ if top != nil {
+ queryParameters["$top"] = autorest.Encode("query", *top)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/executions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByAgentSender sends the ListByAgent request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByAgentResponder handles the response to the ListByAgent request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) ListByAgentResponder(resp *http.Response) (result JobExecutionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByAgentNextResults retrieves the next set of results, if any.
+func (client JobExecutionsClient) listByAgentNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
+ req, err := lastResults.jobExecutionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobExecutionsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ return
+}
+
+// ListByJob lists a job's executions.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// createTimeMin - if specified, only job executions created at or after the specified time are included.
+// createTimeMax - if specified, only job executions created before the specified time are included.
+// endTimeMin - if specified, only job executions completed at or after the specified time are included.
+// endTimeMax - if specified, only job executions completed before the specified time are included.
+// isActive - if specified, only active or only completed job executions are included.
+// skip - the number of elements in the collection to skip.
+// top - the number of elements to return from the collection.
+func (client JobExecutionsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.jelr.Response.Response != nil {
+ sc = result.jelr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByJobNextResults
+ req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.jelr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", resp, "Failure sending request")
+ return
+ }
+
+ result.jelr, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "ListByJob", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByJobPreparer prepares the ListByJob request.
+func (client JobExecutionsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if createTimeMin != nil {
+ queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
+ }
+ if createTimeMax != nil {
+ queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
+ }
+ if endTimeMin != nil {
+ queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
+ }
+ if endTimeMax != nil {
+ queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
+ }
+ if isActive != nil {
+ queryParameters["isActive"] = autorest.Encode("query", *isActive)
+ }
+ if skip != nil {
+ queryParameters["$skip"] = autorest.Encode("query", *skip)
+ }
+ if top != nil {
+ queryParameters["$top"] = autorest.Encode("query", *top)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByJobSender sends the ListByJob request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobExecutionsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByJobResponder handles the response to the ListByJob request. The method always
+// closes the http.Response Body.
+func (client JobExecutionsClient) ListByJobResponder(resp *http.Response) (result JobExecutionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByJobNextResults retrieves the next set of results, if any.
+func (client JobExecutionsClient) listByJobNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
+ req, err := lastResults.jobExecutionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobExecutionsClient", "listByJobNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobExecutionsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobExecutionsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobs.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobs.go
index e64abcdfa152..2112eef5585f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobs.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobs.go
@@ -1,409 +1,409 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact with
-// Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and delete
-// databases.
-type JobsClient struct {
- BaseClient
-}
-
-// NewJobsClient creates an instance of the JobsClient client.
-func NewJobsClient(subscriptionID string) JobsClient {
- return NewJobsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobsClientWithBaseURI creates an instance of the JobsClient client.
-func NewJobsClientWithBaseURI(baseURI string, subscriptionID string) JobsClient {
- return JobsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a job.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// parameters - the requested job state.
-func (client JobsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, parameters Job) (result Job, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, parameters Job) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobsClient) CreateOrUpdateResponder(resp *http.Response) (result Job, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a job.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to delete.
-func (client JobsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client JobsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client JobsClient) 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 a job.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-func (client JobsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result Job, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobsClient) GetResponder(resp *http.Response) (result Job, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByAgent gets a list of jobs.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-func (client JobsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.jlr.Response.Response != nil {
- sc = result.jlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByAgentNextResults
- req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.jlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", resp, "Failure sending request")
- return
- }
-
- result.jlr, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByAgentPreparer prepares the ListByAgent request.
-func (client JobsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByAgentSender sends the ListByAgent request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByAgentResponder handles the response to the ListByAgent request. The method always
-// closes the http.Response Body.
-func (client JobsClient) ListByAgentResponder(resp *http.Response) (result JobListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByAgentNextResults retrieves the next set of results, if any.
-func (client JobsClient) listByAgentNextResults(ctx context.Context, lastResults JobListResult) (result JobListResult, err error) {
- req, err := lastResults.jobListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact with
+// Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and delete
+// databases.
+type JobsClient struct {
+ BaseClient
+}
+
+// NewJobsClient creates an instance of the JobsClient client.
+func NewJobsClient(subscriptionID string) JobsClient {
+ return NewJobsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobsClientWithBaseURI creates an instance of the JobsClient client.
+func NewJobsClientWithBaseURI(baseURI string, subscriptionID string) JobsClient {
+ return JobsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a job.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// parameters - the requested job state.
+func (client JobsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, parameters Job) (result Job, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, parameters Job) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobsClient) CreateOrUpdateResponder(resp *http.Response) (result Job, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a job.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to delete.
+func (client JobsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client JobsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client JobsClient) 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 a job.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+func (client JobsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result Job, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobsClient) GetResponder(resp *http.Response) (result Job, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByAgent gets a list of jobs.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+func (client JobsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.jlr.Response.Response != nil {
+ sc = result.jlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByAgentNextResults
+ req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.jlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", resp, "Failure sending request")
+ return
+ }
+
+ result.jlr, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "ListByAgent", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByAgentPreparer prepares the ListByAgent request.
+func (client JobsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByAgentSender sends the ListByAgent request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByAgentResponder handles the response to the ListByAgent request. The method always
+// closes the http.Response Body.
+func (client JobsClient) ListByAgentResponder(resp *http.Response) (result JobListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByAgentNextResults retrieves the next set of results, if any.
+func (client JobsClient) listByAgentNextResults(ctx context.Context, lastResults JobListResult) (result JobListResult, err error) {
+ req, err := lastResults.jobListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobstepexecutions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobstepexecutions.go
index d5f6afd44dd7..1e12c6aa765c 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobstepexecutions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobstepexecutions.go
@@ -1,281 +1,281 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/date"
- "github.com/Azure/go-autorest/tracing"
- "github.com/satori/go.uuid"
- "net/http"
-)
-
-// JobStepExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type JobStepExecutionsClient struct {
- BaseClient
-}
-
-// NewJobStepExecutionsClient creates an instance of the JobStepExecutionsClient client.
-func NewJobStepExecutionsClient(subscriptionID string) JobStepExecutionsClient {
- return NewJobStepExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobStepExecutionsClientWithBaseURI creates an instance of the JobStepExecutionsClient client.
-func NewJobStepExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobStepExecutionsClient {
- return JobStepExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a step execution of a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the unique id of the job execution
-// stepName - the name of the step.
-func (client JobStepExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string) (result JobExecution, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobStepExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobStepExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByJobExecution lists the step executions of a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the id of the job execution
-// createTimeMin - if specified, only job executions created at or after the specified time are included.
-// createTimeMax - if specified, only job executions created before the specified time are included.
-// endTimeMin - if specified, only job executions completed at or after the specified time are included.
-// endTimeMax - if specified, only job executions completed before the specified time are included.
-// isActive - if specified, only active or only completed job executions are included.
-// skip - the number of elements in the collection to skip.
-// top - the number of elements to return from the collection.
-func (client JobStepExecutionsClient) ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.ListByJobExecution")
- defer func() {
- sc := -1
- if result.jelr.Response.Response != nil {
- sc = result.jelr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByJobExecutionNextResults
- req, err := client.ListByJobExecutionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByJobExecutionSender(req)
- if err != nil {
- result.jelr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", resp, "Failure sending request")
- return
- }
-
- result.jelr, err = client.ListByJobExecutionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByJobExecutionPreparer prepares the ListByJobExecution request.
-func (client JobStepExecutionsClient) ListByJobExecutionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if createTimeMin != nil {
- queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
- }
- if createTimeMax != nil {
- queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
- }
- if endTimeMin != nil {
- queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
- }
- if endTimeMax != nil {
- queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
- }
- if isActive != nil {
- queryParameters["isActive"] = autorest.Encode("query", *isActive)
- }
- if skip != nil {
- queryParameters["$skip"] = autorest.Encode("query", *skip)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByJobExecutionSender sends the ListByJobExecution request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepExecutionsClient) ListByJobExecutionSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByJobExecutionResponder handles the response to the ListByJobExecution request. The method always
-// closes the http.Response Body.
-func (client JobStepExecutionsClient) ListByJobExecutionResponder(resp *http.Response) (result JobExecutionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByJobExecutionNextResults retrieves the next set of results, if any.
-func (client JobStepExecutionsClient) listByJobExecutionNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
- req, err := lastResults.jobExecutionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByJobExecutionSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByJobExecutionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByJobExecutionComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobStepExecutionsClient) ListByJobExecutionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.ListByJobExecution")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByJobExecution(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/date"
+ "github.com/Azure/go-autorest/tracing"
+ "github.com/satori/go.uuid"
+ "net/http"
+)
+
+// JobStepExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type JobStepExecutionsClient struct {
+ BaseClient
+}
+
+// NewJobStepExecutionsClient creates an instance of the JobStepExecutionsClient client.
+func NewJobStepExecutionsClient(subscriptionID string) JobStepExecutionsClient {
+ return NewJobStepExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobStepExecutionsClientWithBaseURI creates an instance of the JobStepExecutionsClient client.
+func NewJobStepExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobStepExecutionsClient {
+ return JobStepExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a step execution of a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the unique id of the job execution
+// stepName - the name of the step.
+func (client JobStepExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string) (result JobExecution, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobStepExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobStepExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByJobExecution lists the step executions of a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the id of the job execution
+// createTimeMin - if specified, only job executions created at or after the specified time are included.
+// createTimeMax - if specified, only job executions created before the specified time are included.
+// endTimeMin - if specified, only job executions completed at or after the specified time are included.
+// endTimeMax - if specified, only job executions completed before the specified time are included.
+// isActive - if specified, only active or only completed job executions are included.
+// skip - the number of elements in the collection to skip.
+// top - the number of elements to return from the collection.
+func (client JobStepExecutionsClient) ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.ListByJobExecution")
+ defer func() {
+ sc := -1
+ if result.jelr.Response.Response != nil {
+ sc = result.jelr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByJobExecutionNextResults
+ req, err := client.ListByJobExecutionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByJobExecutionSender(req)
+ if err != nil {
+ result.jelr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", resp, "Failure sending request")
+ return
+ }
+
+ result.jelr, err = client.ListByJobExecutionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "ListByJobExecution", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByJobExecutionPreparer prepares the ListByJobExecution request.
+func (client JobStepExecutionsClient) ListByJobExecutionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if createTimeMin != nil {
+ queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
+ }
+ if createTimeMax != nil {
+ queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
+ }
+ if endTimeMin != nil {
+ queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
+ }
+ if endTimeMax != nil {
+ queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
+ }
+ if isActive != nil {
+ queryParameters["isActive"] = autorest.Encode("query", *isActive)
+ }
+ if skip != nil {
+ queryParameters["$skip"] = autorest.Encode("query", *skip)
+ }
+ if top != nil {
+ queryParameters["$top"] = autorest.Encode("query", *top)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByJobExecutionSender sends the ListByJobExecution request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepExecutionsClient) ListByJobExecutionSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByJobExecutionResponder handles the response to the ListByJobExecution request. The method always
+// closes the http.Response Body.
+func (client JobStepExecutionsClient) ListByJobExecutionResponder(resp *http.Response) (result JobExecutionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByJobExecutionNextResults retrieves the next set of results, if any.
+func (client JobStepExecutionsClient) listByJobExecutionNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
+ req, err := lastResults.jobExecutionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByJobExecutionSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByJobExecutionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepExecutionsClient", "listByJobExecutionNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByJobExecutionComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobStepExecutionsClient) ListByJobExecutionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepExecutionsClient.ListByJobExecution")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByJobExecution(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobsteps.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobsteps.go
index 141dec50a90d..15abd56ff2fe 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobsteps.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobsteps.go
@@ -1,643 +1,643 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobStepsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type JobStepsClient struct {
- BaseClient
-}
-
-// NewJobStepsClient creates an instance of the JobStepsClient client.
-func NewJobStepsClient(subscriptionID string) JobStepsClient {
- return NewJobStepsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobStepsClientWithBaseURI creates an instance of the JobStepsClient client.
-func NewJobStepsClientWithBaseURI(baseURI string, subscriptionID string) JobStepsClient {
- return JobStepsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a job step. This will implicitly create a new job version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// stepName - the name of the job step.
-// parameters - the requested state of the job step.
-func (client JobStepsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string, parameters JobStep) (result JobStep, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.JobStepProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.TargetGroup", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobStepProperties.Credential", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobStepProperties.Action", Name: validation.Null, Rule: true,
- Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.Action.Value", Name: validation.Null, Rule: true, Chain: nil}}},
- {Target: "parameters.JobStepProperties.Output", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.Output.ServerName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobStepProperties.Output.DatabaseName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobStepProperties.Output.TableName", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.JobStepProperties.Output.Credential", Name: validation.Null, Rule: true, Chain: nil},
- }},
- }}}}}); err != nil {
- return result, validation.NewError("sql.JobStepsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobStepsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string, parameters JobStep) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) CreateOrUpdateResponder(resp *http.Response) (result JobStep, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a job step. This will implicitly create a new job version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// stepName - the name of the job step to delete.
-func (client JobStepsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client JobStepsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) 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 a job step in a job's current version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// stepName - the name of the job step.
-func (client JobStepsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result JobStep, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobStepsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) GetResponder(resp *http.Response) (result JobStep, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// GetByVersion gets the specified version of a job step.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// jobVersion - the version of the job to get.
-// stepName - the name of the job step.
-func (client JobStepsClient) GetByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32, stepName string) (result JobStep, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.GetByVersion")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetByVersionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion, stepName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetByVersionSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetByVersionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetByVersionPreparer prepares the GetByVersion request.
-func (client JobStepsClient) GetByVersionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32, stepName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "jobVersion": autorest.Encode("path", jobVersion),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}/steps/{stepName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetByVersionSender sends the GetByVersion request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) GetByVersionSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetByVersionResponder handles the response to the GetByVersion request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) GetByVersionResponder(resp *http.Response) (result JobStep, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByJob gets all job steps for a job's current version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-func (client JobStepsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobStepListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByJob")
- defer func() {
- sc := -1
- if result.jslr.Response.Response != nil {
- sc = result.jslr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByJobNextResults
- req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.jslr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", resp, "Failure sending request")
- return
- }
-
- result.jslr, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByJobPreparer prepares the ListByJob request.
-func (client JobStepsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByJobSender sends the ListByJob request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByJobResponder handles the response to the ListByJob request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) ListByJobResponder(resp *http.Response) (result JobStepListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByJobNextResults retrieves the next set of results, if any.
-func (client JobStepsClient) listByJobNextResults(ctx context.Context, lastResults JobStepListResult) (result JobStepListResult, err error) {
- req, err := lastResults.jobStepListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobStepsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobStepListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByJob")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- return
-}
-
-// ListByVersion gets all job steps in the specified job version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobVersion - the version of the job to get.
-func (client JobStepsClient) ListByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobStepListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByVersion")
- defer func() {
- sc := -1
- if result.jslr.Response.Response != nil {
- sc = result.jslr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByVersionNextResults
- req, err := client.ListByVersionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByVersionSender(req)
- if err != nil {
- result.jslr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", resp, "Failure sending request")
- return
- }
-
- result.jslr, err = client.ListByVersionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByVersionPreparer prepares the ListByVersion request.
-func (client JobStepsClient) ListByVersionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "jobVersion": autorest.Encode("path", jobVersion),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}/steps", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByVersionSender sends the ListByVersion request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobStepsClient) ListByVersionSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByVersionResponder handles the response to the ListByVersion request. The method always
-// closes the http.Response Body.
-func (client JobStepsClient) ListByVersionResponder(resp *http.Response) (result JobStepListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByVersionNextResults retrieves the next set of results, if any.
-func (client JobStepsClient) listByVersionNextResults(ctx context.Context, lastResults JobStepListResult) (result JobStepListResult, err error) {
- req, err := lastResults.jobStepListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByVersionSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByVersionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByVersionComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobStepsClient) ListByVersionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobStepListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByVersion")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByVersion(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobStepsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type JobStepsClient struct {
+ BaseClient
+}
+
+// NewJobStepsClient creates an instance of the JobStepsClient client.
+func NewJobStepsClient(subscriptionID string) JobStepsClient {
+ return NewJobStepsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobStepsClientWithBaseURI creates an instance of the JobStepsClient client.
+func NewJobStepsClientWithBaseURI(baseURI string, subscriptionID string) JobStepsClient {
+ return JobStepsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a job step. This will implicitly create a new job version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// stepName - the name of the job step.
+// parameters - the requested state of the job step.
+func (client JobStepsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string, parameters JobStep) (result JobStep, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.JobStepProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.TargetGroup", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobStepProperties.Credential", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobStepProperties.Action", Name: validation.Null, Rule: true,
+ Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.Action.Value", Name: validation.Null, Rule: true, Chain: nil}}},
+ {Target: "parameters.JobStepProperties.Output", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.JobStepProperties.Output.ServerName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobStepProperties.Output.DatabaseName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobStepProperties.Output.TableName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.JobStepProperties.Output.Credential", Name: validation.Null, Rule: true, Chain: nil},
+ }},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.JobStepsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobStepsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string, parameters JobStep) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) CreateOrUpdateResponder(resp *http.Response) (result JobStep, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a job step. This will implicitly create a new job version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// stepName - the name of the job step to delete.
+func (client JobStepsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client JobStepsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) 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 a job step in a job's current version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// stepName - the name of the job step.
+func (client JobStepsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result JobStep, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, stepName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobStepsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps/{stepName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) GetResponder(resp *http.Response) (result JobStep, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// GetByVersion gets the specified version of a job step.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// jobVersion - the version of the job to get.
+// stepName - the name of the job step.
+func (client JobStepsClient) GetByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32, stepName string) (result JobStep, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.GetByVersion")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetByVersionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion, stepName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetByVersionSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetByVersionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "GetByVersion", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetByVersionPreparer prepares the GetByVersion request.
+func (client JobStepsClient) GetByVersionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32, stepName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "jobVersion": autorest.Encode("path", jobVersion),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}/steps/{stepName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetByVersionSender sends the GetByVersion request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) GetByVersionSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetByVersionResponder handles the response to the GetByVersion request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) GetByVersionResponder(resp *http.Response) (result JobStep, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByJob gets all job steps for a job's current version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+func (client JobStepsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobStepListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.jslr.Response.Response != nil {
+ sc = result.jslr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByJobNextResults
+ req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.jslr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", resp, "Failure sending request")
+ return
+ }
+
+ result.jslr, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByJob", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByJobPreparer prepares the ListByJob request.
+func (client JobStepsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/steps", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByJobSender sends the ListByJob request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByJobResponder handles the response to the ListByJob request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) ListByJobResponder(resp *http.Response) (result JobStepListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByJobNextResults retrieves the next set of results, if any.
+func (client JobStepsClient) listByJobNextResults(ctx context.Context, lastResults JobStepListResult) (result JobStepListResult, err error) {
+ req, err := lastResults.jobStepListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByJobNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobStepsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobStepListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ return
+}
+
+// ListByVersion gets all job steps in the specified job version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobVersion - the version of the job to get.
+func (client JobStepsClient) ListByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobStepListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByVersion")
+ defer func() {
+ sc := -1
+ if result.jslr.Response.Response != nil {
+ sc = result.jslr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByVersionNextResults
+ req, err := client.ListByVersionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByVersionSender(req)
+ if err != nil {
+ result.jslr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", resp, "Failure sending request")
+ return
+ }
+
+ result.jslr, err = client.ListByVersionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "ListByVersion", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByVersionPreparer prepares the ListByVersion request.
+func (client JobStepsClient) ListByVersionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "jobVersion": autorest.Encode("path", jobVersion),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}/steps", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByVersionSender sends the ListByVersion request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobStepsClient) ListByVersionSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByVersionResponder handles the response to the ListByVersion request. The method always
+// closes the http.Response Body.
+func (client JobStepsClient) ListByVersionResponder(resp *http.Response) (result JobStepListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByVersionNextResults retrieves the next set of results, if any.
+func (client JobStepsClient) listByVersionNextResults(ctx context.Context, lastResults JobStepListResult) (result JobStepListResult, err error) {
+ req, err := lastResults.jobStepListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByVersionSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByVersionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobStepsClient", "listByVersionNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByVersionComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobStepsClient) ListByVersionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobStepListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobStepsClient.ListByVersion")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByVersion(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetexecutions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetexecutions.go
index d3f3add7e3ad..726a66db0835 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetexecutions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetexecutions.go
@@ -1,435 +1,435 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/date"
- "github.com/Azure/go-autorest/tracing"
- "github.com/satori/go.uuid"
- "net/http"
-)
-
-// JobTargetExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type JobTargetExecutionsClient struct {
- BaseClient
-}
-
-// NewJobTargetExecutionsClient creates an instance of the JobTargetExecutionsClient client.
-func NewJobTargetExecutionsClient(subscriptionID string) JobTargetExecutionsClient {
- return NewJobTargetExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobTargetExecutionsClientWithBaseURI creates an instance of the JobTargetExecutionsClient client.
-func NewJobTargetExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobTargetExecutionsClient {
- return JobTargetExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a target execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the unique id of the job execution
-// stepName - the name of the step.
-// targetID - the target id.
-func (client JobTargetExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, targetID uuid.UUID) (result JobExecution, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, targetID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobTargetExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, targetID uuid.UUID) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "targetId": autorest.Encode("path", targetID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}/targets/{targetId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobTargetExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByJobExecution lists target executions for all steps of a job execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the id of the job execution
-// createTimeMin - if specified, only job executions created at or after the specified time are included.
-// createTimeMax - if specified, only job executions created before the specified time are included.
-// endTimeMin - if specified, only job executions completed at or after the specified time are included.
-// endTimeMax - if specified, only job executions completed before the specified time are included.
-// isActive - if specified, only active or only completed job executions are included.
-// skip - the number of elements in the collection to skip.
-// top - the number of elements to return from the collection.
-func (client JobTargetExecutionsClient) ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByJobExecution")
- defer func() {
- sc := -1
- if result.jelr.Response.Response != nil {
- sc = result.jelr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByJobExecutionNextResults
- req, err := client.ListByJobExecutionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByJobExecutionSender(req)
- if err != nil {
- result.jelr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", resp, "Failure sending request")
- return
- }
-
- result.jelr, err = client.ListByJobExecutionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByJobExecutionPreparer prepares the ListByJobExecution request.
-func (client JobTargetExecutionsClient) ListByJobExecutionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if createTimeMin != nil {
- queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
- }
- if createTimeMax != nil {
- queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
- }
- if endTimeMin != nil {
- queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
- }
- if endTimeMax != nil {
- queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
- }
- if isActive != nil {
- queryParameters["isActive"] = autorest.Encode("query", *isActive)
- }
- if skip != nil {
- queryParameters["$skip"] = autorest.Encode("query", *skip)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/targets", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByJobExecutionSender sends the ListByJobExecution request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetExecutionsClient) ListByJobExecutionSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByJobExecutionResponder handles the response to the ListByJobExecution request. The method always
-// closes the http.Response Body.
-func (client JobTargetExecutionsClient) ListByJobExecutionResponder(resp *http.Response) (result JobExecutionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByJobExecutionNextResults retrieves the next set of results, if any.
-func (client JobTargetExecutionsClient) listByJobExecutionNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
- req, err := lastResults.jobExecutionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByJobExecutionSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByJobExecutionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByJobExecutionComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobTargetExecutionsClient) ListByJobExecutionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByJobExecution")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByJobExecution(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- return
-}
-
-// ListByStep lists the target executions of a job step execution.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-// jobExecutionID - the id of the job execution
-// stepName - the name of the step.
-// createTimeMin - if specified, only job executions created at or after the specified time are included.
-// createTimeMax - if specified, only job executions created before the specified time are included.
-// endTimeMin - if specified, only job executions completed at or after the specified time are included.
-// endTimeMax - if specified, only job executions completed before the specified time are included.
-// isActive - if specified, only active or only completed job executions are included.
-// skip - the number of elements in the collection to skip.
-// top - the number of elements to return from the collection.
-func (client JobTargetExecutionsClient) ListByStep(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByStep")
- defer func() {
- sc := -1
- if result.jelr.Response.Response != nil {
- sc = result.jelr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByStepNextResults
- req, err := client.ListByStepPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByStepSender(req)
- if err != nil {
- result.jelr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", resp, "Failure sending request")
- return
- }
-
- result.jelr, err = client.ListByStepResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByStepPreparer prepares the ListByStep request.
-func (client JobTargetExecutionsClient) ListByStepPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobExecutionId": autorest.Encode("path", jobExecutionID),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "stepName": autorest.Encode("path", stepName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if createTimeMin != nil {
- queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
- }
- if createTimeMax != nil {
- queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
- }
- if endTimeMin != nil {
- queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
- }
- if endTimeMax != nil {
- queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
- }
- if isActive != nil {
- queryParameters["isActive"] = autorest.Encode("query", *isActive)
- }
- if skip != nil {
- queryParameters["$skip"] = autorest.Encode("query", *skip)
- }
- if top != nil {
- queryParameters["$top"] = autorest.Encode("query", *top)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}/targets", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByStepSender sends the ListByStep request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetExecutionsClient) ListByStepSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByStepResponder handles the response to the ListByStep request. The method always
-// closes the http.Response Body.
-func (client JobTargetExecutionsClient) ListByStepResponder(resp *http.Response) (result JobExecutionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByStepNextResults retrieves the next set of results, if any.
-func (client JobTargetExecutionsClient) listByStepNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
- req, err := lastResults.jobExecutionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByStepSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByStepResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByStepComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobTargetExecutionsClient) ListByStepComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByStep")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByStep(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/date"
+ "github.com/Azure/go-autorest/tracing"
+ "github.com/satori/go.uuid"
+ "net/http"
+)
+
+// JobTargetExecutionsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type JobTargetExecutionsClient struct {
+ BaseClient
+}
+
+// NewJobTargetExecutionsClient creates an instance of the JobTargetExecutionsClient client.
+func NewJobTargetExecutionsClient(subscriptionID string) JobTargetExecutionsClient {
+ return NewJobTargetExecutionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobTargetExecutionsClientWithBaseURI creates an instance of the JobTargetExecutionsClient client.
+func NewJobTargetExecutionsClientWithBaseURI(baseURI string, subscriptionID string) JobTargetExecutionsClient {
+ return JobTargetExecutionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a target execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the unique id of the job execution
+// stepName - the name of the step.
+// targetID - the target id.
+func (client JobTargetExecutionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, targetID uuid.UUID) (result JobExecution, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, targetID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobTargetExecutionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, targetID uuid.UUID) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "targetId": autorest.Encode("path", targetID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}/targets/{targetId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetExecutionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobTargetExecutionsClient) GetResponder(resp *http.Response) (result JobExecution, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByJobExecution lists target executions for all steps of a job execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the id of the job execution
+// createTimeMin - if specified, only job executions created at or after the specified time are included.
+// createTimeMax - if specified, only job executions created before the specified time are included.
+// endTimeMin - if specified, only job executions completed at or after the specified time are included.
+// endTimeMax - if specified, only job executions completed before the specified time are included.
+// isActive - if specified, only active or only completed job executions are included.
+// skip - the number of elements in the collection to skip.
+// top - the number of elements to return from the collection.
+func (client JobTargetExecutionsClient) ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByJobExecution")
+ defer func() {
+ sc := -1
+ if result.jelr.Response.Response != nil {
+ sc = result.jelr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByJobExecutionNextResults
+ req, err := client.ListByJobExecutionPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByJobExecutionSender(req)
+ if err != nil {
+ result.jelr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", resp, "Failure sending request")
+ return
+ }
+
+ result.jelr, err = client.ListByJobExecutionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByJobExecution", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByJobExecutionPreparer prepares the ListByJobExecution request.
+func (client JobTargetExecutionsClient) ListByJobExecutionPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if createTimeMin != nil {
+ queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
+ }
+ if createTimeMax != nil {
+ queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
+ }
+ if endTimeMin != nil {
+ queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
+ }
+ if endTimeMax != nil {
+ queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
+ }
+ if isActive != nil {
+ queryParameters["isActive"] = autorest.Encode("query", *isActive)
+ }
+ if skip != nil {
+ queryParameters["$skip"] = autorest.Encode("query", *skip)
+ }
+ if top != nil {
+ queryParameters["$top"] = autorest.Encode("query", *top)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/targets", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByJobExecutionSender sends the ListByJobExecution request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetExecutionsClient) ListByJobExecutionSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByJobExecutionResponder handles the response to the ListByJobExecution request. The method always
+// closes the http.Response Body.
+func (client JobTargetExecutionsClient) ListByJobExecutionResponder(resp *http.Response) (result JobExecutionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByJobExecutionNextResults retrieves the next set of results, if any.
+func (client JobTargetExecutionsClient) listByJobExecutionNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
+ req, err := lastResults.jobExecutionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByJobExecutionSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByJobExecutionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByJobExecutionNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByJobExecutionComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobTargetExecutionsClient) ListByJobExecutionComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByJobExecution")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByJobExecution(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ return
+}
+
+// ListByStep lists the target executions of a job step execution.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+// jobExecutionID - the id of the job execution
+// stepName - the name of the step.
+// createTimeMin - if specified, only job executions created at or after the specified time are included.
+// createTimeMax - if specified, only job executions created before the specified time are included.
+// endTimeMin - if specified, only job executions completed at or after the specified time are included.
+// endTimeMax - if specified, only job executions completed before the specified time are included.
+// isActive - if specified, only active or only completed job executions are included.
+// skip - the number of elements in the collection to skip.
+// top - the number of elements to return from the collection.
+func (client JobTargetExecutionsClient) ListByStep(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByStep")
+ defer func() {
+ sc := -1
+ if result.jelr.Response.Response != nil {
+ sc = result.jelr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByStepNextResults
+ req, err := client.ListByStepPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByStepSender(req)
+ if err != nil {
+ result.jelr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", resp, "Failure sending request")
+ return
+ }
+
+ result.jelr, err = client.ListByStepResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "ListByStep", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByStepPreparer prepares the ListByStep request.
+func (client JobTargetExecutionsClient) ListByStepPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobExecutionId": autorest.Encode("path", jobExecutionID),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "stepName": autorest.Encode("path", stepName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if createTimeMin != nil {
+ queryParameters["createTimeMin"] = autorest.Encode("query", *createTimeMin)
+ }
+ if createTimeMax != nil {
+ queryParameters["createTimeMax"] = autorest.Encode("query", *createTimeMax)
+ }
+ if endTimeMin != nil {
+ queryParameters["endTimeMin"] = autorest.Encode("query", *endTimeMin)
+ }
+ if endTimeMax != nil {
+ queryParameters["endTimeMax"] = autorest.Encode("query", *endTimeMax)
+ }
+ if isActive != nil {
+ queryParameters["isActive"] = autorest.Encode("query", *isActive)
+ }
+ if skip != nil {
+ queryParameters["$skip"] = autorest.Encode("query", *skip)
+ }
+ if top != nil {
+ queryParameters["$top"] = autorest.Encode("query", *top)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/executions/{jobExecutionId}/steps/{stepName}/targets", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByStepSender sends the ListByStep request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetExecutionsClient) ListByStepSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByStepResponder handles the response to the ListByStep request. The method always
+// closes the http.Response Body.
+func (client JobTargetExecutionsClient) ListByStepResponder(resp *http.Response) (result JobExecutionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByStepNextResults retrieves the next set of results, if any.
+func (client JobTargetExecutionsClient) listByStepNextResults(ctx context.Context, lastResults JobExecutionListResult) (result JobExecutionListResult, err error) {
+ req, err := lastResults.jobExecutionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByStepSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByStepResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetExecutionsClient", "listByStepNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByStepComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobTargetExecutionsClient) ListByStepComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result JobExecutionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetExecutionsClient.ListByStep")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByStep(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobExecutionID, stepName, createTimeMin, createTimeMax, endTimeMin, endTimeMax, isActive, skip, top)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetgroups.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetgroups.go
index 2906858aca6f..662b16e9dfb3 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetgroups.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobtargetgroups.go
@@ -1,417 +1,417 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobTargetGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type JobTargetGroupsClient struct {
- BaseClient
-}
-
-// NewJobTargetGroupsClient creates an instance of the JobTargetGroupsClient client.
-func NewJobTargetGroupsClient(subscriptionID string) JobTargetGroupsClient {
- return NewJobTargetGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobTargetGroupsClientWithBaseURI creates an instance of the JobTargetGroupsClient client.
-func NewJobTargetGroupsClientWithBaseURI(baseURI string, subscriptionID string) JobTargetGroupsClient {
- return JobTargetGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a target group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// targetGroupName - the name of the target group.
-// parameters - the requested state of the target group.
-func (client JobTargetGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string, parameters JobTargetGroup) (result JobTargetGroup, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.JobTargetGroupProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.JobTargetGroupProperties.Members", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.JobTargetGroupsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client JobTargetGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string, parameters JobTargetGroup) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "targetGroupName": autorest.Encode("path", targetGroupName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetGroupsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client JobTargetGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result JobTargetGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a target group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// targetGroupName - the name of the target group.
-func (client JobTargetGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client JobTargetGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "targetGroupName": autorest.Encode("path", targetGroupName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetGroupsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client JobTargetGroupsClient) 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 a target group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// targetGroupName - the name of the target group.
-func (client JobTargetGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result JobTargetGroup, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobTargetGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "targetGroupName": autorest.Encode("path", targetGroupName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobTargetGroupsClient) GetResponder(resp *http.Response) (result JobTargetGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByAgent gets all target groups in an agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-func (client JobTargetGroupsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobTargetGroupListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.jtglr.Response.Response != nil {
- sc = result.jtglr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByAgentNextResults
- req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.jtglr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", resp, "Failure sending request")
- return
- }
-
- result.jtglr, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByAgentPreparer prepares the ListByAgent request.
-func (client JobTargetGroupsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByAgentSender sends the ListByAgent request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobTargetGroupsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByAgentResponder handles the response to the ListByAgent request. The method always
-// closes the http.Response Body.
-func (client JobTargetGroupsClient) ListByAgentResponder(resp *http.Response) (result JobTargetGroupListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByAgentNextResults retrieves the next set of results, if any.
-func (client JobTargetGroupsClient) listByAgentNextResults(ctx context.Context, lastResults JobTargetGroupListResult) (result JobTargetGroupListResult, err error) {
- req, err := lastResults.jobTargetGroupListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByAgentSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByAgentResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobTargetGroupsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobTargetGroupListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.ListByAgent")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobTargetGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type JobTargetGroupsClient struct {
+ BaseClient
+}
+
+// NewJobTargetGroupsClient creates an instance of the JobTargetGroupsClient client.
+func NewJobTargetGroupsClient(subscriptionID string) JobTargetGroupsClient {
+ return NewJobTargetGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobTargetGroupsClientWithBaseURI creates an instance of the JobTargetGroupsClient client.
+func NewJobTargetGroupsClientWithBaseURI(baseURI string, subscriptionID string) JobTargetGroupsClient {
+ return JobTargetGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a target group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// targetGroupName - the name of the target group.
+// parameters - the requested state of the target group.
+func (client JobTargetGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string, parameters JobTargetGroup) (result JobTargetGroup, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.JobTargetGroupProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.JobTargetGroupProperties.Members", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.JobTargetGroupsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client JobTargetGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string, parameters JobTargetGroup) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "targetGroupName": autorest.Encode("path", targetGroupName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetGroupsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client JobTargetGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result JobTargetGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a target group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// targetGroupName - the name of the target group.
+func (client JobTargetGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client JobTargetGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "targetGroupName": autorest.Encode("path", targetGroupName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetGroupsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client JobTargetGroupsClient) 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 a target group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// targetGroupName - the name of the target group.
+func (client JobTargetGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result JobTargetGroup, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, targetGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobTargetGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "targetGroupName": autorest.Encode("path", targetGroupName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups/{targetGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobTargetGroupsClient) GetResponder(resp *http.Response) (result JobTargetGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByAgent gets all target groups in an agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+func (client JobTargetGroupsClient) ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobTargetGroupListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.jtglr.Response.Response != nil {
+ sc = result.jtglr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByAgentNextResults
+ req, err := client.ListByAgentPreparer(ctx, resourceGroupName, serverName, jobAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.jtglr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", resp, "Failure sending request")
+ return
+ }
+
+ result.jtglr, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "ListByAgent", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByAgentPreparer prepares the ListByAgent request.
+func (client JobTargetGroupsClient) ListByAgentPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/targetGroups", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByAgentSender sends the ListByAgent request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobTargetGroupsClient) ListByAgentSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByAgentResponder handles the response to the ListByAgent request. The method always
+// closes the http.Response Body.
+func (client JobTargetGroupsClient) ListByAgentResponder(resp *http.Response) (result JobTargetGroupListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByAgentNextResults retrieves the next set of results, if any.
+func (client JobTargetGroupsClient) listByAgentNextResults(ctx context.Context, lastResults JobTargetGroupListResult) (result JobTargetGroupListResult, err error) {
+ req, err := lastResults.jobTargetGroupListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByAgentSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByAgentResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobTargetGroupsClient", "listByAgentNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByAgentComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobTargetGroupsClient) ListByAgentComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result JobTargetGroupListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobTargetGroupsClient.ListByAgent")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByAgent(ctx, resourceGroupName, serverName, jobAgentName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobversions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobversions.go
index 56a626836277..9b81112ab2a0 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobversions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/jobversions.go
@@ -1,247 +1,247 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// JobVersionsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type JobVersionsClient struct {
- BaseClient
-}
-
-// NewJobVersionsClient creates an instance of the JobVersionsClient client.
-func NewJobVersionsClient(subscriptionID string) JobVersionsClient {
- return NewJobVersionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewJobVersionsClientWithBaseURI creates an instance of the JobVersionsClient client.
-func NewJobVersionsClientWithBaseURI(baseURI string, subscriptionID string) JobVersionsClient {
- return JobVersionsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a job version.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job.
-// jobVersion - the version of the job to get.
-func (client JobVersionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobVersion, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client JobVersionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "jobVersion": autorest.Encode("path", jobVersion),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobVersionsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client JobVersionsClient) GetResponder(resp *http.Response) (result JobVersion, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByJob gets all versions of a job.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// jobAgentName - the name of the job agent.
-// jobName - the name of the job to get.
-func (client JobVersionsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobVersionListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.ListByJob")
- defer func() {
- sc := -1
- if result.jvlr.Response.Response != nil {
- sc = result.jvlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByJobNextResults
- req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.jvlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", resp, "Failure sending request")
- return
- }
-
- result.jvlr, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByJobPreparer prepares the ListByJob request.
-func (client JobVersionsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "jobAgentName": autorest.Encode("path", jobAgentName),
- "jobName": autorest.Encode("path", jobName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByJobSender sends the ListByJob request. The method will close the
-// http.Response Body if it receives an error.
-func (client JobVersionsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByJobResponder handles the response to the ListByJob request. The method always
-// closes the http.Response Body.
-func (client JobVersionsClient) ListByJobResponder(resp *http.Response) (result JobVersionListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByJobNextResults retrieves the next set of results, if any.
-func (client JobVersionsClient) listByJobNextResults(ctx context.Context, lastResults JobVersionListResult) (result JobVersionListResult, err error) {
- req, err := lastResults.jobVersionListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByJobSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByJobResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
-func (client JobVersionsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobVersionListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.ListByJob")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// JobVersionsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type JobVersionsClient struct {
+ BaseClient
+}
+
+// NewJobVersionsClient creates an instance of the JobVersionsClient client.
+func NewJobVersionsClient(subscriptionID string) JobVersionsClient {
+ return NewJobVersionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewJobVersionsClientWithBaseURI creates an instance of the JobVersionsClient client.
+func NewJobVersionsClientWithBaseURI(baseURI string, subscriptionID string) JobVersionsClient {
+ return JobVersionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a job version.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job.
+// jobVersion - the version of the job to get.
+func (client JobVersionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result JobVersion, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName, jobVersion)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client JobVersionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "jobVersion": autorest.Encode("path", jobVersion),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions/{jobVersion}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobVersionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client JobVersionsClient) GetResponder(resp *http.Response) (result JobVersion, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByJob gets all versions of a job.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// jobAgentName - the name of the job agent.
+// jobName - the name of the job to get.
+func (client JobVersionsClient) ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobVersionListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.jvlr.Response.Response != nil {
+ sc = result.jvlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByJobNextResults
+ req, err := client.ListByJobPreparer(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.jvlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", resp, "Failure sending request")
+ return
+ }
+
+ result.jvlr, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "ListByJob", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByJobPreparer prepares the ListByJob request.
+func (client JobVersionsClient) ListByJobPreparer(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "jobAgentName": autorest.Encode("path", jobAgentName),
+ "jobName": autorest.Encode("path", jobName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/jobAgents/{jobAgentName}/jobs/{jobName}/versions", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByJobSender sends the ListByJob request. The method will close the
+// http.Response Body if it receives an error.
+func (client JobVersionsClient) ListByJobSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByJobResponder handles the response to the ListByJob request. The method always
+// closes the http.Response Body.
+func (client JobVersionsClient) ListByJobResponder(resp *http.Response) (result JobVersionListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByJobNextResults retrieves the next set of results, if any.
+func (client JobVersionsClient) listByJobNextResults(ctx context.Context, lastResults JobVersionListResult) (result JobVersionListResult, err error) {
+ req, err := lastResults.jobVersionListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByJobSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByJobResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.JobVersionsClient", "listByJobNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByJobComplete enumerates all values, automatically crossing page boundaries as required.
+func (client JobVersionsClient) ListByJobComplete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result JobVersionListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/JobVersionsClient.ListByJob")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByJob(ctx, resourceGroupName, serverName, jobAgentName, jobName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedbackupshorttermretentionpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedbackupshorttermretentionpolicies.go
index c9428110307f..dec37cea9ef0 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedbackupshorttermretentionpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedbackupshorttermretentionpolicies.go
@@ -1,412 +1,412 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ManagedBackupShortTermRetentionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of
-// web services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ManagedBackupShortTermRetentionPoliciesClient struct {
- BaseClient
-}
-
-// NewManagedBackupShortTermRetentionPoliciesClient creates an instance of the
-// ManagedBackupShortTermRetentionPoliciesClient client.
-func NewManagedBackupShortTermRetentionPoliciesClient(subscriptionID string) ManagedBackupShortTermRetentionPoliciesClient {
- return NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI creates an instance of the
-// ManagedBackupShortTermRetentionPoliciesClient client.
-func NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ManagedBackupShortTermRetentionPoliciesClient {
- return ManagedBackupShortTermRetentionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate updates a managed database's short term retention policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-// parameters - the short term retention policy info.
-func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (result ManagedBackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "policyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ManagedBackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a managed database's short term retention policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-func (client ManagedBackupShortTermRetentionPoliciesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ManagedBackupShortTermRetentionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "policyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedBackupShortTermRetentionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ManagedBackupShortTermRetentionPoliciesClient) GetResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase gets a managed database's short term retention policy list.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicyListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.mbstrplr.Response.Response != nil {
- sc = result.mbstrplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByDatabaseNextResults
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.mbstrplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result.mbstrplr, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByDatabaseNextResults retrieves the next set of results, if any.
-func (client ManagedBackupShortTermRetentionPoliciesClient) listByDatabaseNextResults(ctx context.Context, lastResults ManagedBackupShortTermRetentionPolicyListResult) (result ManagedBackupShortTermRetentionPolicyListResult, err error) {
- req, err := lastResults.managedBackupShortTermRetentionPolicyListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicyListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByDatabase(ctx, resourceGroupName, managedInstanceName, databaseName)
- return
-}
-
-// Update updates a managed database's short term retention policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-// parameters - the short term retention policy info.
-func (client ManagedBackupShortTermRetentionPoliciesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (result ManagedBackupShortTermRetentionPoliciesUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ManagedBackupShortTermRetentionPoliciesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "policyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedBackupShortTermRetentionPoliciesClient) UpdateSender(req *http.Request) (future ManagedBackupShortTermRetentionPoliciesUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ManagedBackupShortTermRetentionPoliciesClient) UpdateResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ManagedBackupShortTermRetentionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of
+// web services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ManagedBackupShortTermRetentionPoliciesClient struct {
+ BaseClient
+}
+
+// NewManagedBackupShortTermRetentionPoliciesClient creates an instance of the
+// ManagedBackupShortTermRetentionPoliciesClient client.
+func NewManagedBackupShortTermRetentionPoliciesClient(subscriptionID string) ManagedBackupShortTermRetentionPoliciesClient {
+ return NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI creates an instance of the
+// ManagedBackupShortTermRetentionPoliciesClient client.
+func NewManagedBackupShortTermRetentionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ManagedBackupShortTermRetentionPoliciesClient {
+ return ManagedBackupShortTermRetentionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate updates a managed database's short term retention policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+// parameters - the short term retention policy info.
+func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (result ManagedBackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "policyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ManagedBackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ManagedBackupShortTermRetentionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a managed database's short term retention policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+func (client ManagedBackupShortTermRetentionPoliciesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ManagedBackupShortTermRetentionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "policyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedBackupShortTermRetentionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ManagedBackupShortTermRetentionPoliciesClient) GetResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase gets a managed database's short term retention policy list.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabase(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicyListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.mbstrplr.Response.Response != nil {
+ sc = result.mbstrplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByDatabaseNextResults
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.mbstrplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.mbstrplr, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByDatabaseNextResults retrieves the next set of results, if any.
+func (client ManagedBackupShortTermRetentionPoliciesClient) listByDatabaseNextResults(ctx context.Context, lastResults ManagedBackupShortTermRetentionPolicyListResult) (result ManagedBackupShortTermRetentionPolicyListResult, err error) {
+ req, err := lastResults.managedBackupShortTermRetentionPolicyListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ManagedBackupShortTermRetentionPoliciesClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedBackupShortTermRetentionPolicyListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByDatabase(ctx, resourceGroupName, managedInstanceName, databaseName)
+ return
+}
+
+// Update updates a managed database's short term retention policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+// parameters - the short term retention policy info.
+func (client ManagedBackupShortTermRetentionPoliciesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (result ManagedBackupShortTermRetentionPoliciesUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedBackupShortTermRetentionPoliciesClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedBackupShortTermRetentionPoliciesClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ManagedBackupShortTermRetentionPoliciesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedBackupShortTermRetentionPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "policyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedBackupShortTermRetentionPoliciesClient) UpdateSender(req *http.Request) (future ManagedBackupShortTermRetentionPoliciesUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ManagedBackupShortTermRetentionPoliciesClient) UpdateResponder(resp *http.Response) (result ManagedBackupShortTermRetentionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/manageddatabases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/manageddatabases.go
index cbd9034d68c5..89418cc07632 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/manageddatabases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/manageddatabases.go
@@ -1,571 +1,571 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "github.com/satori/go.uuid"
- "net/http"
-)
-
-// ManagedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ManagedDatabasesClient struct {
- BaseClient
-}
-
-// NewManagedDatabasesClient creates an instance of the ManagedDatabasesClient client.
-func NewManagedDatabasesClient(subscriptionID string) ManagedDatabasesClient {
- return NewManagedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewManagedDatabasesClientWithBaseURI creates an instance of the ManagedDatabasesClient client.
-func NewManagedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) ManagedDatabasesClient {
- return ManagedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CompleteRestore completes the restore operation on a managed database.
-// Parameters:
-// locationName - the name of the region where the resource is located.
-// operationID - management operation id that this request tries to complete.
-// parameters - the definition for completing the restore of this managed database.
-func (client ManagedDatabasesClient) CompleteRestore(ctx context.Context, locationName string, operationID uuid.UUID, parameters CompleteDatabaseRestoreDefinition) (result ManagedDatabasesCompleteRestoreFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.CompleteRestore")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.LastBackupName", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.ManagedDatabasesClient", "CompleteRestore", err.Error())
- }
-
- req, err := client.CompleteRestorePreparer(ctx, locationName, operationID, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CompleteRestore", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CompleteRestoreSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CompleteRestore", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CompleteRestorePreparer prepares the CompleteRestore request.
-func (client ManagedDatabasesClient) CompleteRestorePreparer(ctx context.Context, locationName string, operationID uuid.UUID, parameters CompleteDatabaseRestoreDefinition) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "locationName": autorest.Encode("path", locationName),
- "operationId": autorest.Encode("path", operationID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/managedDatabaseRestoreAzureAsyncOperation/{operationId}/completeRestore", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CompleteRestoreSender sends the CompleteRestore request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) CompleteRestoreSender(req *http.Request) (future ManagedDatabasesCompleteRestoreFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CompleteRestoreResponder handles the response to the CompleteRestore request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) CompleteRestoreResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// CreateOrUpdate creates a new database or updates an existing database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-// parameters - the requested database resource state.
-func (client ManagedDatabasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabase) (result ManagedDatabasesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ManagedDatabasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabase) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) CreateOrUpdateSender(req *http.Request) (future ManagedDatabasesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a managed database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-func (client ManagedDatabasesClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedDatabasesDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ManagedDatabasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) DeleteSender(req *http.Request) (future ManagedDatabasesDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a managed database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-func (client ManagedDatabasesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedDatabase, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ManagedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) GetResponder(resp *http.Response) (result ManagedDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByInstance gets a list of managed databases.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client ManagedDatabasesClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedDatabaseListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.ListByInstance")
- defer func() {
- sc := -1
- if result.mdlr.Response.Response != nil {
- sc = result.mdlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByInstanceNextResults
- req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.mdlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", resp, "Failure sending request")
- return
- }
-
- result.mdlr, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByInstancePreparer prepares the ListByInstance request.
-func (client ManagedDatabasesClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByInstanceSender sends the ListByInstance request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByInstanceResponder handles the response to the ListByInstance request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) ListByInstanceResponder(resp *http.Response) (result ManagedDatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByInstanceNextResults retrieves the next set of results, if any.
-func (client ManagedDatabasesClient) listByInstanceNextResults(ctx context.Context, lastResults ManagedDatabaseListResult) (result ManagedDatabaseListResult, err error) {
- req, err := lastResults.managedDatabaseListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ManagedDatabasesClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedDatabaseListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.ListByInstance")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
- return
-}
-
-// Update updates an existing database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// databaseName - the name of the database.
-// parameters - the requested database resource state.
-func (client ManagedDatabasesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabaseUpdate) (result ManagedDatabasesUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ManagedDatabasesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabaseUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedDatabasesClient) UpdateSender(req *http.Request) (future ManagedDatabasesUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ManagedDatabasesClient) UpdateResponder(resp *http.Response) (result ManagedDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "github.com/satori/go.uuid"
+ "net/http"
+)
+
+// ManagedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ManagedDatabasesClient struct {
+ BaseClient
+}
+
+// NewManagedDatabasesClient creates an instance of the ManagedDatabasesClient client.
+func NewManagedDatabasesClient(subscriptionID string) ManagedDatabasesClient {
+ return NewManagedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewManagedDatabasesClientWithBaseURI creates an instance of the ManagedDatabasesClient client.
+func NewManagedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) ManagedDatabasesClient {
+ return ManagedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CompleteRestore completes the restore operation on a managed database.
+// Parameters:
+// locationName - the name of the region where the resource is located.
+// operationID - management operation id that this request tries to complete.
+// parameters - the definition for completing the restore of this managed database.
+func (client ManagedDatabasesClient) CompleteRestore(ctx context.Context, locationName string, operationID uuid.UUID, parameters CompleteDatabaseRestoreDefinition) (result ManagedDatabasesCompleteRestoreFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.CompleteRestore")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.LastBackupName", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.ManagedDatabasesClient", "CompleteRestore", err.Error())
+ }
+
+ req, err := client.CompleteRestorePreparer(ctx, locationName, operationID, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CompleteRestore", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CompleteRestoreSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CompleteRestore", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CompleteRestorePreparer prepares the CompleteRestore request.
+func (client ManagedDatabasesClient) CompleteRestorePreparer(ctx context.Context, locationName string, operationID uuid.UUID, parameters CompleteDatabaseRestoreDefinition) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "locationName": autorest.Encode("path", locationName),
+ "operationId": autorest.Encode("path", operationID),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/managedDatabaseRestoreAzureAsyncOperation/{operationId}/completeRestore", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CompleteRestoreSender sends the CompleteRestore request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) CompleteRestoreSender(req *http.Request) (future ManagedDatabasesCompleteRestoreFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CompleteRestoreResponder handles the response to the CompleteRestore request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) CompleteRestoreResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// CreateOrUpdate creates a new database or updates an existing database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+// parameters - the requested database resource state.
+func (client ManagedDatabasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabase) (result ManagedDatabasesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ManagedDatabasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabase) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) CreateOrUpdateSender(req *http.Request) (future ManagedDatabasesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a managed database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+func (client ManagedDatabasesClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedDatabasesDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ManagedDatabasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) DeleteSender(req *http.Request) (future ManagedDatabasesDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a managed database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+func (client ManagedDatabasesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result ManagedDatabase, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ManagedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) GetResponder(resp *http.Response) (result ManagedDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByInstance gets a list of managed databases.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client ManagedDatabasesClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedDatabaseListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.mdlr.Response.Response != nil {
+ sc = result.mdlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByInstanceNextResults
+ req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.mdlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", resp, "Failure sending request")
+ return
+ }
+
+ result.mdlr, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "ListByInstance", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByInstancePreparer prepares the ListByInstance request.
+func (client ManagedDatabasesClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByInstanceSender sends the ListByInstance request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByInstanceResponder handles the response to the ListByInstance request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) ListByInstanceResponder(resp *http.Response) (result ManagedDatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByInstanceNextResults retrieves the next set of results, if any.
+func (client ManagedDatabasesClient) listByInstanceNextResults(ctx context.Context, lastResults ManagedDatabaseListResult) (result ManagedDatabaseListResult, err error) {
+ req, err := lastResults.managedDatabaseListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ManagedDatabasesClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedDatabaseListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
+ return
+}
+
+// Update updates an existing database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// databaseName - the name of the database.
+// parameters - the requested database resource state.
+func (client ManagedDatabasesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabaseUpdate) (result ManagedDatabasesUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedDatabasesClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedDatabasesClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ManagedDatabasesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters ManagedDatabaseUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/databases/{databaseName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedDatabasesClient) UpdateSender(req *http.Request) (future ManagedDatabasesUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ManagedDatabasesClient) UpdateResponder(resp *http.Response) (result ManagedDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstanceadministrators.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstanceadministrators.go
index 41794c40a123..ce3fa15903af 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstanceadministrators.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstanceadministrators.go
@@ -1,413 +1,413 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ManagedInstanceAdministratorsClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ManagedInstanceAdministratorsClient struct {
- BaseClient
-}
-
-// NewManagedInstanceAdministratorsClient creates an instance of the ManagedInstanceAdministratorsClient client.
-func NewManagedInstanceAdministratorsClient(subscriptionID string) ManagedInstanceAdministratorsClient {
- return NewManagedInstanceAdministratorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewManagedInstanceAdministratorsClientWithBaseURI creates an instance of the ManagedInstanceAdministratorsClient
-// client.
-func NewManagedInstanceAdministratorsClientWithBaseURI(baseURI string, subscriptionID string) ManagedInstanceAdministratorsClient {
- return ManagedInstanceAdministratorsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a managed instance administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// administratorName - the requested administrator name.
-// parameters - the requested administrator parameters.
-func (client ManagedInstanceAdministratorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string, parameters ManagedInstanceAdministrator) (result ManagedInstanceAdministratorsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.ManagedInstanceAdministratorProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.ManagedInstanceAdministratorProperties.AdministratorType", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.ManagedInstanceAdministratorProperties.Login", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.ManagedInstanceAdministratorProperties.Sid", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, administratorName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ManagedInstanceAdministratorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string, parameters ManagedInstanceAdministrator) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", administratorName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstanceAdministratorsClient) CreateOrUpdateSender(req *http.Request) (future ManagedInstanceAdministratorsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ManagedInstanceAdministratorsClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedInstanceAdministrator, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a managed instance administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// administratorName - the administrator name.
-func (client ManagedInstanceAdministratorsClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result ManagedInstanceAdministratorsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName, administratorName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ManagedInstanceAdministratorsClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", administratorName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstanceAdministratorsClient) DeleteSender(req *http.Request) (future ManagedInstanceAdministratorsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ManagedInstanceAdministratorsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a managed instance administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// administratorName - the administrator name.
-func (client ManagedInstanceAdministratorsClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result ManagedInstanceAdministrator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, administratorName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ManagedInstanceAdministratorsClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", administratorName),
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstanceAdministratorsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ManagedInstanceAdministratorsClient) GetResponder(resp *http.Response) (result ManagedInstanceAdministrator, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByInstance gets a list of managed instance administrators.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client ManagedInstanceAdministratorsClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstanceAdministratorListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.ListByInstance")
- defer func() {
- sc := -1
- if result.mialr.Response.Response != nil {
- sc = result.mialr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByInstanceNextResults
- req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.mialr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", resp, "Failure sending request")
- return
- }
-
- result.mialr, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByInstancePreparer prepares the ListByInstance request.
-func (client ManagedInstanceAdministratorsClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByInstanceSender sends the ListByInstance request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstanceAdministratorsClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByInstanceResponder handles the response to the ListByInstance request. The method always
-// closes the http.Response Body.
-func (client ManagedInstanceAdministratorsClient) ListByInstanceResponder(resp *http.Response) (result ManagedInstanceAdministratorListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByInstanceNextResults retrieves the next set of results, if any.
-func (client ManagedInstanceAdministratorsClient) listByInstanceNextResults(ctx context.Context, lastResults ManagedInstanceAdministratorListResult) (result ManagedInstanceAdministratorListResult, err error) {
- req, err := lastResults.managedInstanceAdministratorListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ManagedInstanceAdministratorsClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstanceAdministratorListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.ListByInstance")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ManagedInstanceAdministratorsClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ManagedInstanceAdministratorsClient struct {
+ BaseClient
+}
+
+// NewManagedInstanceAdministratorsClient creates an instance of the ManagedInstanceAdministratorsClient client.
+func NewManagedInstanceAdministratorsClient(subscriptionID string) ManagedInstanceAdministratorsClient {
+ return NewManagedInstanceAdministratorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewManagedInstanceAdministratorsClientWithBaseURI creates an instance of the ManagedInstanceAdministratorsClient
+// client.
+func NewManagedInstanceAdministratorsClientWithBaseURI(baseURI string, subscriptionID string) ManagedInstanceAdministratorsClient {
+ return ManagedInstanceAdministratorsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a managed instance administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// administratorName - the requested administrator name.
+// parameters - the requested administrator parameters.
+func (client ManagedInstanceAdministratorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string, parameters ManagedInstanceAdministrator) (result ManagedInstanceAdministratorsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.ManagedInstanceAdministratorProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.ManagedInstanceAdministratorProperties.AdministratorType", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.ManagedInstanceAdministratorProperties.Login", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.ManagedInstanceAdministratorProperties.Sid", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, administratorName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ManagedInstanceAdministratorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string, parameters ManagedInstanceAdministrator) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", administratorName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstanceAdministratorsClient) CreateOrUpdateSender(req *http.Request) (future ManagedInstanceAdministratorsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ManagedInstanceAdministratorsClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedInstanceAdministrator, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a managed instance administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// administratorName - the administrator name.
+func (client ManagedInstanceAdministratorsClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result ManagedInstanceAdministratorsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName, administratorName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ManagedInstanceAdministratorsClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", administratorName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstanceAdministratorsClient) DeleteSender(req *http.Request) (future ManagedInstanceAdministratorsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ManagedInstanceAdministratorsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a managed instance administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// administratorName - the administrator name.
+func (client ManagedInstanceAdministratorsClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result ManagedInstanceAdministrator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, administratorName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ManagedInstanceAdministratorsClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", administratorName),
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators/{administratorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstanceAdministratorsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ManagedInstanceAdministratorsClient) GetResponder(resp *http.Response) (result ManagedInstanceAdministrator, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByInstance gets a list of managed instance administrators.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client ManagedInstanceAdministratorsClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstanceAdministratorListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.mialr.Response.Response != nil {
+ sc = result.mialr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByInstanceNextResults
+ req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.mialr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", resp, "Failure sending request")
+ return
+ }
+
+ result.mialr, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "ListByInstance", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByInstancePreparer prepares the ListByInstance request.
+func (client ManagedInstanceAdministratorsClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/administrators", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByInstanceSender sends the ListByInstance request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstanceAdministratorsClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByInstanceResponder handles the response to the ListByInstance request. The method always
+// closes the http.Response Body.
+func (client ManagedInstanceAdministratorsClient) ListByInstanceResponder(resp *http.Response) (result ManagedInstanceAdministratorListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByInstanceNextResults retrieves the next set of results, if any.
+func (client ManagedInstanceAdministratorsClient) listByInstanceNextResults(ctx context.Context, lastResults ManagedInstanceAdministratorListResult) (result ManagedInstanceAdministratorListResult, err error) {
+ req, err := lastResults.managedInstanceAdministratorListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstanceAdministratorsClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ManagedInstanceAdministratorsClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstanceAdministratorListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstanceAdministratorsClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstances.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstances.go
index 27240401c1f5..ffdde71d15ef 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstances.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/managedinstances.go
@@ -1,592 +1,592 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ManagedInstancesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ManagedInstancesClient struct {
- BaseClient
-}
-
-// NewManagedInstancesClient creates an instance of the ManagedInstancesClient client.
-func NewManagedInstancesClient(subscriptionID string) ManagedInstancesClient {
- return NewManagedInstancesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewManagedInstancesClientWithBaseURI creates an instance of the ManagedInstancesClient client.
-func NewManagedInstancesClientWithBaseURI(baseURI string, subscriptionID string) ManagedInstancesClient {
- return ManagedInstancesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a managed instance.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// parameters - the requested managed instance resource state.
-func (client ManagedInstancesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstance) (result ManagedInstancesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Sku", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.ManagedInstancesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ManagedInstancesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstance) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) CreateOrUpdateSender(req *http.Request) (future ManagedInstancesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedInstance, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a managed instance.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client ManagedInstancesClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstancesDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ManagedInstancesClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) DeleteSender(req *http.Request) (future ManagedInstancesDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a managed instance.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client ManagedInstancesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstance, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ManagedInstancesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) GetResponder(resp *http.Response) (result ManagedInstance, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List gets a list of all managed instances in the subscription.
-func (client ManagedInstancesClient) List(ctx context.Context) (result ManagedInstanceListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.List")
- defer func() {
- sc := -1
- if result.milr.Response.Response != nil {
- sc = result.milr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.milr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", resp, "Failure sending request")
- return
- }
-
- result.milr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client ManagedInstancesClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) ListSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) ListResponder(resp *http.Response) (result ManagedInstanceListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client ManagedInstancesClient) listNextResults(ctx context.Context, lastResults ManagedInstanceListResult) (result ManagedInstanceListResult, err error) {
- req, err := lastResults.managedInstanceListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ManagedInstancesClient) ListComplete(ctx context.Context) (result ManagedInstanceListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
-
-// ListByResourceGroup gets a list of managed instances in a resource group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-func (client ManagedInstancesClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result ManagedInstanceListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.milr.Response.Response != nil {
- sc = result.milr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByResourceGroupNextResults
- req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.milr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", resp, "Failure sending request")
- return
- }
-
- result.milr, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
-func (client ManagedInstancesClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) ListByResourceGroupResponder(resp *http.Response) (result ManagedInstanceListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByResourceGroupNextResults retrieves the next set of results, if any.
-func (client ManagedInstancesClient) listByResourceGroupNextResults(ctx context.Context, lastResults ManagedInstanceListResult) (result ManagedInstanceListResult, err error) {
- req, err := lastResults.managedInstanceListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ManagedInstancesClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result ManagedInstanceListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
- return
-}
-
-// Update updates a managed instance.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-// parameters - the requested managed instance resource state.
-func (client ManagedInstancesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstanceUpdate) (result ManagedInstancesUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ManagedInstancesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstanceUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ManagedInstancesClient) UpdateSender(req *http.Request) (future ManagedInstancesUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ManagedInstancesClient) UpdateResponder(resp *http.Response) (result ManagedInstance, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ManagedInstancesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ManagedInstancesClient struct {
+ BaseClient
+}
+
+// NewManagedInstancesClient creates an instance of the ManagedInstancesClient client.
+func NewManagedInstancesClient(subscriptionID string) ManagedInstancesClient {
+ return NewManagedInstancesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewManagedInstancesClientWithBaseURI creates an instance of the ManagedInstancesClient client.
+func NewManagedInstancesClientWithBaseURI(baseURI string, subscriptionID string) ManagedInstancesClient {
+ return ManagedInstancesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a managed instance.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// parameters - the requested managed instance resource state.
+func (client ManagedInstancesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstance) (result ManagedInstancesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.Sku", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.Sku.Name", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.ManagedInstancesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, managedInstanceName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ManagedInstancesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstance) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) CreateOrUpdateSender(req *http.Request) (future ManagedInstancesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) CreateOrUpdateResponder(resp *http.Response) (result ManagedInstance, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a managed instance.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client ManagedInstancesClient) Delete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstancesDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, managedInstanceName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ManagedInstancesClient) DeletePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) DeleteSender(req *http.Request) (future ManagedInstancesDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a managed instance.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client ManagedInstancesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string) (result ManagedInstance, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ManagedInstancesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) GetResponder(resp *http.Response) (result ManagedInstance, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List gets a list of all managed instances in the subscription.
+func (client ManagedInstancesClient) List(ctx context.Context) (result ManagedInstanceListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.List")
+ defer func() {
+ sc := -1
+ if result.milr.Response.Response != nil {
+ sc = result.milr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.milr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.milr, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client ManagedInstancesClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) ListResponder(resp *http.Response) (result ManagedInstanceListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client ManagedInstancesClient) listNextResults(ctx context.Context, lastResults ManagedInstanceListResult) (result ManagedInstanceListResult, err error) {
+ req, err := lastResults.managedInstanceListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ManagedInstancesClient) ListComplete(ctx context.Context) (result ManagedInstanceListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
+
+// ListByResourceGroup gets a list of managed instances in a resource group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+func (client ManagedInstancesClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result ManagedInstanceListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.milr.Response.Response != nil {
+ sc = result.milr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByResourceGroupNextResults
+ req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.milr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.milr, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "ListByResourceGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
+func (client ManagedInstancesClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) ListByResourceGroupResponder(resp *http.Response) (result ManagedInstanceListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByResourceGroupNextResults retrieves the next set of results, if any.
+func (client ManagedInstancesClient) listByResourceGroupNextResults(ctx context.Context, lastResults ManagedInstanceListResult) (result ManagedInstanceListResult, err error) {
+ req, err := lastResults.managedInstanceListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ManagedInstancesClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result ManagedInstanceListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
+ return
+}
+
+// Update updates a managed instance.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+// parameters - the requested managed instance resource state.
+func (client ManagedInstancesClient) Update(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstanceUpdate) (result ManagedInstancesUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ManagedInstancesClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, managedInstanceName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ManagedInstancesClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ManagedInstancesClient) UpdatePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters ManagedInstanceUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ManagedInstancesClient) UpdateSender(req *http.Request) (future ManagedInstancesUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ManagedInstancesClient) UpdateResponder(resp *http.Response) (result ManagedInstance, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/operations.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/operations.go
index 7583f8c838d9..bd0657225fde 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/operations.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/operations.go
@@ -1,149 +1,149 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// OperationsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type OperationsClient struct {
- BaseClient
-}
-
-// NewOperationsClient creates an instance of the OperationsClient client.
-func NewOperationsClient(subscriptionID string) OperationsClient {
- return NewOperationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewOperationsClientWithBaseURI creates an instance of the OperationsClient client.
-func NewOperationsClientWithBaseURI(baseURI string, subscriptionID string) OperationsClient {
- return OperationsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// List lists all of the available SQL Rest API operations.
-func (client OperationsClient) List(ctx context.Context) (result OperationListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
- defer func() {
- sc := -1
- if result.olr.Response.Response != nil {
- sc = result.olr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.olr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", resp, "Failure sending request")
- return
- }
-
- result.olr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPath("/providers/Microsoft.Sql/operations"),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client OperationsClient) ListSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client OperationsClient) ListResponder(resp *http.Response) (result OperationListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client OperationsClient) listNextResults(ctx context.Context, lastResults OperationListResult) (result OperationListResult, err error) {
- req, err := lastResults.operationListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client OperationsClient) ListComplete(ctx context.Context) (result OperationListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// OperationsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type OperationsClient struct {
+ BaseClient
+}
+
+// NewOperationsClient creates an instance of the OperationsClient client.
+func NewOperationsClient(subscriptionID string) OperationsClient {
+ return NewOperationsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewOperationsClientWithBaseURI creates an instance of the OperationsClient client.
+func NewOperationsClientWithBaseURI(baseURI string, subscriptionID string) OperationsClient {
+ return OperationsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// List lists all of the available SQL Rest API operations.
+func (client OperationsClient) List(ctx context.Context) (result OperationListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
+ defer func() {
+ sc := -1
+ if result.olr.Response.Response != nil {
+ sc = result.olr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.olr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.olr, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.OperationsClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client OperationsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPath("/providers/Microsoft.Sql/operations"),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client OperationsClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client OperationsClient) ListResponder(resp *http.Response) (result OperationListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client OperationsClient) listNextResults(ctx context.Context, lastResults OperationListResult) (result OperationListResult, err error) {
+ req, err := lastResults.operationListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.OperationsClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client OperationsClient) ListComplete(ctx context.Context) (result OperationListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/OperationsClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/recoverabledatabases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/recoverabledatabases.go
index 7b253f865405..bfa9b2425b97 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/recoverabledatabases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/recoverabledatabases.go
@@ -1,201 +1,201 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RecoverableDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type RecoverableDatabasesClient struct {
- BaseClient
-}
-
-// NewRecoverableDatabasesClient creates an instance of the RecoverableDatabasesClient client.
-func NewRecoverableDatabasesClient(subscriptionID string) RecoverableDatabasesClient {
- return NewRecoverableDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRecoverableDatabasesClientWithBaseURI creates an instance of the RecoverableDatabasesClient client.
-func NewRecoverableDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RecoverableDatabasesClient {
- return RecoverableDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a recoverable database, which is a resource representing a database's geo backup
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database
-func (client RecoverableDatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result RecoverableDatabase, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RecoverableDatabasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RecoverableDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/recoverableDatabases/{databaseName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RecoverableDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RecoverableDatabasesClient) GetResponder(resp *http.Response) (result RecoverableDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of recoverable databases
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client RecoverableDatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result RecoverableDatabaseListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RecoverableDatabasesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client RecoverableDatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/recoverableDatabases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client RecoverableDatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client RecoverableDatabasesClient) ListByServerResponder(resp *http.Response) (result RecoverableDatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RecoverableDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type RecoverableDatabasesClient struct {
+ BaseClient
+}
+
+// NewRecoverableDatabasesClient creates an instance of the RecoverableDatabasesClient client.
+func NewRecoverableDatabasesClient(subscriptionID string) RecoverableDatabasesClient {
+ return NewRecoverableDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewRecoverableDatabasesClientWithBaseURI creates an instance of the RecoverableDatabasesClient client.
+func NewRecoverableDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RecoverableDatabasesClient {
+ return RecoverableDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a recoverable database, which is a resource representing a database's geo backup
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database
+func (client RecoverableDatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result RecoverableDatabase, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RecoverableDatabasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client RecoverableDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/recoverableDatabases/{databaseName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client RecoverableDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client RecoverableDatabasesClient) GetResponder(resp *http.Response) (result RecoverableDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of recoverable databases
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client RecoverableDatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result RecoverableDatabaseListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RecoverableDatabasesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RecoverableDatabasesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client RecoverableDatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/recoverableDatabases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client RecoverableDatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client RecoverableDatabasesClient) ListByServerResponder(resp *http.Response) (result RecoverableDatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/replicationlinks.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/replicationlinks.go
index 9b2a9e1f4c3a..4122dbff6cef 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/replicationlinks.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/replicationlinks.go
@@ -1,449 +1,449 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ReplicationLinksClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ReplicationLinksClient struct {
- BaseClient
-}
-
-// NewReplicationLinksClient creates an instance of the ReplicationLinksClient client.
-func NewReplicationLinksClient(subscriptionID string) ReplicationLinksClient {
- return NewReplicationLinksClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewReplicationLinksClientWithBaseURI creates an instance of the ReplicationLinksClient client.
-func NewReplicationLinksClientWithBaseURI(baseURI string, subscriptionID string) ReplicationLinksClient {
- return ReplicationLinksClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Delete deletes a database replication link. Cannot be done during failover.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database that has the replication link to be dropped.
-// linkID - the ID of the replication link to be deleted.
-func (client ReplicationLinksClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ReplicationLinksClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "linkId": autorest.Encode("path", linkID),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationLinksClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ReplicationLinksClient) 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
-}
-
-// Failover sets which replica database is primary by failing over from the current primary replica database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database that has the replication link to be failed over.
-// linkID - the ID of the replication link to be failed over.
-func (client ReplicationLinksClient) Failover(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLinksFailoverFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Failover")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.FailoverPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Failover", nil, "Failure preparing request")
- return
- }
-
- result, err = client.FailoverSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Failover", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// FailoverPreparer prepares the Failover request.
-func (client ReplicationLinksClient) FailoverPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "linkId": autorest.Encode("path", linkID),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/failover", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// FailoverSender sends the Failover request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationLinksClient) FailoverSender(req *http.Request) (future ReplicationLinksFailoverFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// FailoverResponder handles the response to the Failover request. The method always
-// closes the http.Response Body.
-func (client ReplicationLinksClient) FailoverResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// FailoverAllowDataLoss sets which replica database is primary by failing over from the current primary replica
-// database. This operation might result in data loss.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database that has the replication link to be failed over.
-// linkID - the ID of the replication link to be failed over.
-func (client ReplicationLinksClient) FailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLinksFailoverAllowDataLossFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.FailoverAllowDataLoss")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.FailoverAllowDataLossPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "FailoverAllowDataLoss", nil, "Failure preparing request")
- return
- }
-
- result, err = client.FailoverAllowDataLossSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "FailoverAllowDataLoss", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// FailoverAllowDataLossPreparer prepares the FailoverAllowDataLoss request.
-func (client ReplicationLinksClient) FailoverAllowDataLossPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "linkId": autorest.Encode("path", linkID),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/forceFailoverAllowDataLoss", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// FailoverAllowDataLossSender sends the FailoverAllowDataLoss request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationLinksClient) FailoverAllowDataLossSender(req *http.Request) (future ReplicationLinksFailoverAllowDataLossFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// FailoverAllowDataLossResponder handles the response to the FailoverAllowDataLoss request. The method always
-// closes the http.Response Body.
-func (client ReplicationLinksClient) FailoverAllowDataLossResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a database replication link.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to get the link for.
-// linkID - the replication link ID to be retrieved.
-func (client ReplicationLinksClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLink, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ReplicationLinksClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "linkId": autorest.Encode("path", linkID),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationLinksClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ReplicationLinksClient) GetResponder(resp *http.Response) (result ReplicationLink, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase lists a database's replication links.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database to retrieve links for.
-func (client ReplicationLinksClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ReplicationLinkListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client ReplicationLinksClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client ReplicationLinksClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client ReplicationLinksClient) ListByDatabaseResponder(resp *http.Response) (result ReplicationLinkListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ReplicationLinksClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ReplicationLinksClient struct {
+ BaseClient
+}
+
+// NewReplicationLinksClient creates an instance of the ReplicationLinksClient client.
+func NewReplicationLinksClient(subscriptionID string) ReplicationLinksClient {
+ return NewReplicationLinksClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewReplicationLinksClientWithBaseURI creates an instance of the ReplicationLinksClient client.
+func NewReplicationLinksClientWithBaseURI(baseURI string, subscriptionID string) ReplicationLinksClient {
+ return ReplicationLinksClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Delete deletes a database replication link. Cannot be done during failover.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database that has the replication link to be dropped.
+// linkID - the ID of the replication link to be deleted.
+func (client ReplicationLinksClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ReplicationLinksClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "linkId": autorest.Encode("path", linkID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ReplicationLinksClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ReplicationLinksClient) 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
+}
+
+// Failover sets which replica database is primary by failing over from the current primary replica database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database that has the replication link to be failed over.
+// linkID - the ID of the replication link to be failed over.
+func (client ReplicationLinksClient) Failover(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLinksFailoverFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Failover")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.FailoverPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Failover", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.FailoverSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Failover", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// FailoverPreparer prepares the Failover request.
+func (client ReplicationLinksClient) FailoverPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "linkId": autorest.Encode("path", linkID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/failover", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// FailoverSender sends the Failover request. The method will close the
+// http.Response Body if it receives an error.
+func (client ReplicationLinksClient) FailoverSender(req *http.Request) (future ReplicationLinksFailoverFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// FailoverResponder handles the response to the Failover request. The method always
+// closes the http.Response Body.
+func (client ReplicationLinksClient) FailoverResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// FailoverAllowDataLoss sets which replica database is primary by failing over from the current primary replica
+// database. This operation might result in data loss.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database that has the replication link to be failed over.
+// linkID - the ID of the replication link to be failed over.
+func (client ReplicationLinksClient) FailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLinksFailoverAllowDataLossFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.FailoverAllowDataLoss")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.FailoverAllowDataLossPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "FailoverAllowDataLoss", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.FailoverAllowDataLossSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "FailoverAllowDataLoss", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// FailoverAllowDataLossPreparer prepares the FailoverAllowDataLoss request.
+func (client ReplicationLinksClient) FailoverAllowDataLossPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "linkId": autorest.Encode("path", linkID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/forceFailoverAllowDataLoss", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// FailoverAllowDataLossSender sends the FailoverAllowDataLoss request. The method will close the
+// http.Response Body if it receives an error.
+func (client ReplicationLinksClient) FailoverAllowDataLossSender(req *http.Request) (future ReplicationLinksFailoverAllowDataLossFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// FailoverAllowDataLossResponder handles the response to the FailoverAllowDataLoss request. The method always
+// closes the http.Response Body.
+func (client ReplicationLinksClient) FailoverAllowDataLossResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a database replication link.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to get the link for.
+// linkID - the replication link ID to be retrieved.
+func (client ReplicationLinksClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result ReplicationLink, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, linkID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ReplicationLinksClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "linkId": autorest.Encode("path", linkID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ReplicationLinksClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ReplicationLinksClient) GetResponder(resp *http.Response) (result ReplicationLink, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase lists a database's replication links.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database to retrieve links for.
+func (client ReplicationLinksClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ReplicationLinkListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ReplicationLinksClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ReplicationLinksClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client ReplicationLinksClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client ReplicationLinksClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client ReplicationLinksClient) ListByDatabaseResponder(resp *http.Response) (result ReplicationLinkListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppeddatabases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppeddatabases.go
index ba9cc4bf6d62..ee9433fcd23a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppeddatabases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppeddatabases.go
@@ -1,202 +1,202 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RestorableDroppedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type RestorableDroppedDatabasesClient struct {
- BaseClient
-}
-
-// NewRestorableDroppedDatabasesClient creates an instance of the RestorableDroppedDatabasesClient client.
-func NewRestorableDroppedDatabasesClient(subscriptionID string) RestorableDroppedDatabasesClient {
- return NewRestorableDroppedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRestorableDroppedDatabasesClientWithBaseURI creates an instance of the RestorableDroppedDatabasesClient client.
-func NewRestorableDroppedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RestorableDroppedDatabasesClient {
- return RestorableDroppedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a deleted database that can be restored
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// restorableDroppededDatabaseID - the id of the deleted database in the form of
-// databaseName,deletionTimeInFileTimeFormat
-func (client RestorableDroppedDatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, restorableDroppededDatabaseID string) (result RestorableDroppedDatabase, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedDatabasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, restorableDroppededDatabaseID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RestorableDroppedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, restorableDroppededDatabaseID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "restorableDroppededDatabaseId": autorest.Encode("path", restorableDroppededDatabaseID),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/restorableDroppedDatabases/{restorableDroppededDatabaseId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorableDroppedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RestorableDroppedDatabasesClient) GetResponder(resp *http.Response) (result RestorableDroppedDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of deleted databases that can be restored
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client RestorableDroppedDatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result RestorableDroppedDatabaseListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedDatabasesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client RestorableDroppedDatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/restorableDroppedDatabases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorableDroppedDatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client RestorableDroppedDatabasesClient) ListByServerResponder(resp *http.Response) (result RestorableDroppedDatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RestorableDroppedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type RestorableDroppedDatabasesClient struct {
+ BaseClient
+}
+
+// NewRestorableDroppedDatabasesClient creates an instance of the RestorableDroppedDatabasesClient client.
+func NewRestorableDroppedDatabasesClient(subscriptionID string) RestorableDroppedDatabasesClient {
+ return NewRestorableDroppedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewRestorableDroppedDatabasesClientWithBaseURI creates an instance of the RestorableDroppedDatabasesClient client.
+func NewRestorableDroppedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RestorableDroppedDatabasesClient {
+ return RestorableDroppedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a deleted database that can be restored
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// restorableDroppededDatabaseID - the id of the deleted database in the form of
+// databaseName,deletionTimeInFileTimeFormat
+func (client RestorableDroppedDatabasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, restorableDroppededDatabaseID string) (result RestorableDroppedDatabase, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedDatabasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, restorableDroppededDatabaseID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client RestorableDroppedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, restorableDroppededDatabaseID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "restorableDroppededDatabaseId": autorest.Encode("path", restorableDroppededDatabaseID),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/restorableDroppedDatabases/{restorableDroppededDatabaseId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorableDroppedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client RestorableDroppedDatabasesClient) GetResponder(resp *http.Response) (result RestorableDroppedDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of deleted databases that can be restored
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client RestorableDroppedDatabasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result RestorableDroppedDatabaseListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedDatabasesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedDatabasesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client RestorableDroppedDatabasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/restorableDroppedDatabases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorableDroppedDatabasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client RestorableDroppedDatabasesClient) ListByServerResponder(resp *http.Response) (result RestorableDroppedDatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppedmanageddatabases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppedmanageddatabases.go
index ea6e2f2c9a4e..b9bd15b1a36b 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppedmanageddatabases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorabledroppedmanageddatabases.go
@@ -1,240 +1,240 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RestorableDroppedManagedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type RestorableDroppedManagedDatabasesClient struct {
- BaseClient
-}
-
-// NewRestorableDroppedManagedDatabasesClient creates an instance of the RestorableDroppedManagedDatabasesClient
-// client.
-func NewRestorableDroppedManagedDatabasesClient(subscriptionID string) RestorableDroppedManagedDatabasesClient {
- return NewRestorableDroppedManagedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRestorableDroppedManagedDatabasesClientWithBaseURI creates an instance of the
-// RestorableDroppedManagedDatabasesClient client.
-func NewRestorableDroppedManagedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RestorableDroppedManagedDatabasesClient {
- return RestorableDroppedManagedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a restorable dropped managed database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client RestorableDroppedManagedDatabasesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, restorableDroppedDatabaseID string) (result RestorableDroppedManagedDatabase, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, restorableDroppedDatabaseID)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RestorableDroppedManagedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, restorableDroppedDatabaseID string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "restorableDroppedDatabaseId": autorest.Encode("path", restorableDroppedDatabaseID),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/restorableDroppedDatabases/{restorableDroppedDatabaseId}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorableDroppedManagedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RestorableDroppedManagedDatabasesClient) GetResponder(resp *http.Response) (result RestorableDroppedManagedDatabase, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByInstance gets a list of restorable dropped managed databases.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// managedInstanceName - the name of the managed instance.
-func (client RestorableDroppedManagedDatabasesClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result RestorableDroppedManagedDatabaseListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.ListByInstance")
- defer func() {
- sc := -1
- if result.rdmdlr.Response.Response != nil {
- sc = result.rdmdlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByInstanceNextResults
- req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.rdmdlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", resp, "Failure sending request")
- return
- }
-
- result.rdmdlr, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByInstancePreparer prepares the ListByInstance request.
-func (client RestorableDroppedManagedDatabasesClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "managedInstanceName": autorest.Encode("path", managedInstanceName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/restorableDroppedDatabases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByInstanceSender sends the ListByInstance request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorableDroppedManagedDatabasesClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByInstanceResponder handles the response to the ListByInstance request. The method always
-// closes the http.Response Body.
-func (client RestorableDroppedManagedDatabasesClient) ListByInstanceResponder(resp *http.Response) (result RestorableDroppedManagedDatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByInstanceNextResults retrieves the next set of results, if any.
-func (client RestorableDroppedManagedDatabasesClient) listByInstanceNextResults(ctx context.Context, lastResults RestorableDroppedManagedDatabaseListResult) (result RestorableDroppedManagedDatabaseListResult, err error) {
- req, err := lastResults.restorableDroppedManagedDatabaseListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByInstanceSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByInstanceResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
-func (client RestorableDroppedManagedDatabasesClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result RestorableDroppedManagedDatabaseListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.ListByInstance")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RestorableDroppedManagedDatabasesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type RestorableDroppedManagedDatabasesClient struct {
+ BaseClient
+}
+
+// NewRestorableDroppedManagedDatabasesClient creates an instance of the RestorableDroppedManagedDatabasesClient
+// client.
+func NewRestorableDroppedManagedDatabasesClient(subscriptionID string) RestorableDroppedManagedDatabasesClient {
+ return NewRestorableDroppedManagedDatabasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewRestorableDroppedManagedDatabasesClientWithBaseURI creates an instance of the
+// RestorableDroppedManagedDatabasesClient client.
+func NewRestorableDroppedManagedDatabasesClientWithBaseURI(baseURI string, subscriptionID string) RestorableDroppedManagedDatabasesClient {
+ return RestorableDroppedManagedDatabasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a restorable dropped managed database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client RestorableDroppedManagedDatabasesClient) Get(ctx context.Context, resourceGroupName string, managedInstanceName string, restorableDroppedDatabaseID string) (result RestorableDroppedManagedDatabase, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, managedInstanceName, restorableDroppedDatabaseID)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client RestorableDroppedManagedDatabasesClient) GetPreparer(ctx context.Context, resourceGroupName string, managedInstanceName string, restorableDroppedDatabaseID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "restorableDroppedDatabaseId": autorest.Encode("path", restorableDroppedDatabaseID),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/restorableDroppedDatabases/{restorableDroppedDatabaseId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorableDroppedManagedDatabasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client RestorableDroppedManagedDatabasesClient) GetResponder(resp *http.Response) (result RestorableDroppedManagedDatabase, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByInstance gets a list of restorable dropped managed databases.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// managedInstanceName - the name of the managed instance.
+func (client RestorableDroppedManagedDatabasesClient) ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result RestorableDroppedManagedDatabaseListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.rdmdlr.Response.Response != nil {
+ sc = result.rdmdlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByInstanceNextResults
+ req, err := client.ListByInstancePreparer(ctx, resourceGroupName, managedInstanceName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.rdmdlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", resp, "Failure sending request")
+ return
+ }
+
+ result.rdmdlr, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "ListByInstance", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByInstancePreparer prepares the ListByInstance request.
+func (client RestorableDroppedManagedDatabasesClient) ListByInstancePreparer(ctx context.Context, resourceGroupName string, managedInstanceName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "managedInstanceName": autorest.Encode("path", managedInstanceName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/restorableDroppedDatabases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByInstanceSender sends the ListByInstance request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorableDroppedManagedDatabasesClient) ListByInstanceSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByInstanceResponder handles the response to the ListByInstance request. The method always
+// closes the http.Response Body.
+func (client RestorableDroppedManagedDatabasesClient) ListByInstanceResponder(resp *http.Response) (result RestorableDroppedManagedDatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByInstanceNextResults retrieves the next set of results, if any.
+func (client RestorableDroppedManagedDatabasesClient) listByInstanceNextResults(ctx context.Context, lastResults RestorableDroppedManagedDatabaseListResult) (result RestorableDroppedManagedDatabaseListResult, err error) {
+ req, err := lastResults.restorableDroppedManagedDatabaseListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByInstanceSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByInstanceResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorableDroppedManagedDatabasesClient", "listByInstanceNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByInstanceComplete enumerates all values, automatically crossing page boundaries as required.
+func (client RestorableDroppedManagedDatabasesClient) ListByInstanceComplete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result RestorableDroppedManagedDatabaseListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorableDroppedManagedDatabasesClient.ListByInstance")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByInstance(ctx, resourceGroupName, managedInstanceName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorepoints.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorepoints.go
index 393d49377782..8ae3d7ba5caf 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorepoints.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/restorepoints.go
@@ -1,376 +1,376 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// RestorePointsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type RestorePointsClient struct {
- BaseClient
-}
-
-// NewRestorePointsClient creates an instance of the RestorePointsClient client.
-func NewRestorePointsClient(subscriptionID string) RestorePointsClient {
- return NewRestorePointsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewRestorePointsClientWithBaseURI creates an instance of the RestorePointsClient client.
-func NewRestorePointsClientWithBaseURI(baseURI string, subscriptionID string) RestorePointsClient {
- return RestorePointsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Create creates a restore point for a data warehouse.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// parameters - the definition for creating the restore point of this database.
-func (client RestorePointsClient) Create(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters CreateDatabaseRestorePointDefinition) (result RestorePointsCreateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Create")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.RestorePointLabel", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.RestorePointsClient", "Create", err.Error())
- }
-
- req, err := client.CreatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Create", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Create", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreatePreparer prepares the Create request.
-func (client RestorePointsClient) CreatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters CreateDatabaseRestorePointDefinition) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateSender sends the Create request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorePointsClient) CreateSender(req *http.Request) (future RestorePointsCreateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateResponder handles the response to the Create request. The method always
-// closes the http.Response Body.
-func (client RestorePointsClient) CreateResponder(resp *http.Response) (result RestorePoint, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a restore point.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// restorePointName - the name of the restore point.
-func (client RestorePointsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, restorePointName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client RestorePointsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "restorePointName": autorest.Encode("path", restorePointName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints/{restorePointName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorePointsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client RestorePointsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a restore point.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// restorePointName - the name of the restore point.
-func (client RestorePointsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result RestorePoint, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, restorePointName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client RestorePointsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "restorePointName": autorest.Encode("path", restorePointName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints/{restorePointName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorePointsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client RestorePointsClient) GetResponder(resp *http.Response) (result RestorePoint, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase gets a list of database restore points.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-func (client RestorePointsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result RestorePointListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client RestorePointsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client RestorePointsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client RestorePointsClient) ListByDatabaseResponder(resp *http.Response) (result RestorePointListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// RestorePointsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type RestorePointsClient struct {
+ BaseClient
+}
+
+// NewRestorePointsClient creates an instance of the RestorePointsClient client.
+func NewRestorePointsClient(subscriptionID string) RestorePointsClient {
+ return NewRestorePointsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewRestorePointsClientWithBaseURI creates an instance of the RestorePointsClient client.
+func NewRestorePointsClientWithBaseURI(baseURI string, subscriptionID string) RestorePointsClient {
+ return RestorePointsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Create creates a restore point for a data warehouse.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// parameters - the definition for creating the restore point of this database.
+func (client RestorePointsClient) Create(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters CreateDatabaseRestorePointDefinition) (result RestorePointsCreateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Create")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.RestorePointLabel", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.RestorePointsClient", "Create", err.Error())
+ }
+
+ req, err := client.CreatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Create", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Create", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreatePreparer prepares the Create request.
+func (client RestorePointsClient) CreatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters CreateDatabaseRestorePointDefinition) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateSender sends the Create request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorePointsClient) CreateSender(req *http.Request) (future RestorePointsCreateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateResponder handles the response to the Create request. The method always
+// closes the http.Response Body.
+func (client RestorePointsClient) CreateResponder(resp *http.Response) (result RestorePoint, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a restore point.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// restorePointName - the name of the restore point.
+func (client RestorePointsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, restorePointName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client RestorePointsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "restorePointName": autorest.Encode("path", restorePointName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints/{restorePointName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorePointsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client RestorePointsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a restore point.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// restorePointName - the name of the restore point.
+func (client RestorePointsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result RestorePoint, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, restorePointName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client RestorePointsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "restorePointName": autorest.Encode("path", restorePointName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints/{restorePointName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorePointsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client RestorePointsClient) GetResponder(resp *http.Response) (result RestorePoint, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase gets a list of database restore points.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+func (client RestorePointsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result RestorePointListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/RestorePointsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.RestorePointsClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client RestorePointsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/restorePoints", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client RestorePointsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client RestorePointsClient) ListByDatabaseResponder(resp *http.Response) (result RestorePointListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sensitivitylabels.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sensitivitylabels.go
index c2db48619613..a267ca01c530 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sensitivitylabels.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sensitivitylabels.go
@@ -1,731 +1,731 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// SensitivityLabelsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type SensitivityLabelsClient struct {
- BaseClient
-}
-
-// NewSensitivityLabelsClient creates an instance of the SensitivityLabelsClient client.
-func NewSensitivityLabelsClient(subscriptionID string) SensitivityLabelsClient {
- return NewSensitivityLabelsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewSensitivityLabelsClientWithBaseURI creates an instance of the SensitivityLabelsClient client.
-func NewSensitivityLabelsClientWithBaseURI(baseURI string, subscriptionID string) SensitivityLabelsClient {
- return SensitivityLabelsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates the sensitivity label of a given column
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// schemaName - the name of the schema.
-// tableName - the name of the table.
-// columnName - the name of the column.
-// parameters - the column sensitivity label resource.
-func (client SensitivityLabelsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, parameters SensitivityLabel) (result SensitivityLabel, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client SensitivityLabelsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, parameters SensitivityLabel) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "columnName": autorest.Encode("path", columnName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "schemaName": autorest.Encode("path", schemaName),
- "sensitivityLabelSource": autorest.Encode("path", "current"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "tableName": autorest.Encode("path", tableName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) CreateOrUpdateResponder(resp *http.Response) (result SensitivityLabel, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes the sensitivity label of a given column
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// schemaName - the name of the schema.
-// tableName - the name of the table.
-// columnName - the name of the column.
-func (client SensitivityLabelsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client SensitivityLabelsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "columnName": autorest.Encode("path", columnName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "schemaName": autorest.Encode("path", schemaName),
- "sensitivityLabelSource": autorest.Encode("path", "current"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "tableName": autorest.Encode("path", tableName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// DisableRecommendation disables sensitivity recommendations on a given column
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// schemaName - the name of the schema.
-// tableName - the name of the table.
-// columnName - the name of the column.
-func (client SensitivityLabelsClient) DisableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.DisableRecommendation")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DisableRecommendationPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DisableRecommendationSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", resp, "Failure sending request")
- return
- }
-
- result, err = client.DisableRecommendationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DisableRecommendationPreparer prepares the DisableRecommendation request.
-func (client SensitivityLabelsClient) DisableRecommendationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "columnName": autorest.Encode("path", columnName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "schemaName": autorest.Encode("path", schemaName),
- "sensitivityLabelSource": autorest.Encode("path", "recommended"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "tableName": autorest.Encode("path", tableName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/disable", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DisableRecommendationSender sends the DisableRecommendation request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) DisableRecommendationSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DisableRecommendationResponder handles the response to the DisableRecommendation request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) DisableRecommendationResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// EnableRecommendation enables sensitivity recommendations on a given column (recommendations are enabled by default
-// on all columns)
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// schemaName - the name of the schema.
-// tableName - the name of the table.
-// columnName - the name of the column.
-func (client SensitivityLabelsClient) EnableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.EnableRecommendation")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.EnableRecommendationPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.EnableRecommendationSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", resp, "Failure sending request")
- return
- }
-
- result, err = client.EnableRecommendationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", resp, "Failure responding to request")
- }
-
- return
-}
-
-// EnableRecommendationPreparer prepares the EnableRecommendation request.
-func (client SensitivityLabelsClient) EnableRecommendationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "columnName": autorest.Encode("path", columnName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "schemaName": autorest.Encode("path", schemaName),
- "sensitivityLabelSource": autorest.Encode("path", "recommended"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "tableName": autorest.Encode("path", tableName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/enable", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// EnableRecommendationSender sends the EnableRecommendation request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) EnableRecommendationSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// EnableRecommendationResponder handles the response to the EnableRecommendation request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) EnableRecommendationResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets the sensitivity label of a given column
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// schemaName - the name of the schema.
-// tableName - the name of the table.
-// columnName - the name of the column.
-// sensitivityLabelSource - the source of the sensitivity label.
-func (client SensitivityLabelsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, sensitivityLabelSource SensitivityLabelSource) (result SensitivityLabel, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName, sensitivityLabelSource)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client SensitivityLabelsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, sensitivityLabelSource SensitivityLabelSource) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "columnName": autorest.Encode("path", columnName),
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "schemaName": autorest.Encode("path", schemaName),
- "sensitivityLabelSource": autorest.Encode("path", sensitivityLabelSource),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "tableName": autorest.Encode("path", tableName),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) GetResponder(resp *http.Response) (result SensitivityLabel, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListCurrentByDatabase gets the sensitivity labels of a given database
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// filter - an OData filter expression that filters elements in the collection.
-func (client SensitivityLabelsClient) ListCurrentByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result SensitivityLabelListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListCurrentByDatabase")
- defer func() {
- sc := -1
- if result.sllr.Response.Response != nil {
- sc = result.sllr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listCurrentByDatabaseNextResults
- req, err := client.ListCurrentByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListCurrentByDatabaseSender(req)
- if err != nil {
- result.sllr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", resp, "Failure sending request")
- return
- }
-
- result.sllr, err = client.ListCurrentByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListCurrentByDatabasePreparer prepares the ListCurrentByDatabase request.
-func (client SensitivityLabelsClient) ListCurrentByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/currentSensitivityLabels", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListCurrentByDatabaseSender sends the ListCurrentByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) ListCurrentByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListCurrentByDatabaseResponder handles the response to the ListCurrentByDatabase request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) ListCurrentByDatabaseResponder(resp *http.Response) (result SensitivityLabelListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listCurrentByDatabaseNextResults retrieves the next set of results, if any.
-func (client SensitivityLabelsClient) listCurrentByDatabaseNextResults(ctx context.Context, lastResults SensitivityLabelListResult) (result SensitivityLabelListResult, err error) {
- req, err := lastResults.sensitivityLabelListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListCurrentByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListCurrentByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListCurrentByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SensitivityLabelsClient) ListCurrentByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result SensitivityLabelListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListCurrentByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListCurrentByDatabase(ctx, resourceGroupName, serverName, databaseName, filter)
- return
-}
-
-// ListRecommendedByDatabase gets the sensitivity labels of a given database
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database.
-// includeDisabledRecommendations - specifies whether to include disabled recommendations or not.
-// filter - an OData filter expression that filters elements in the collection.
-func (client SensitivityLabelsClient) ListRecommendedByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (result SensitivityLabelListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListRecommendedByDatabase")
- defer func() {
- sc := -1
- if result.sllr.Response.Response != nil {
- sc = result.sllr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listRecommendedByDatabaseNextResults
- req, err := client.ListRecommendedByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName, includeDisabledRecommendations, skipToken, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListRecommendedByDatabaseSender(req)
- if err != nil {
- result.sllr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", resp, "Failure sending request")
- return
- }
-
- result.sllr, err = client.ListRecommendedByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListRecommendedByDatabasePreparer prepares the ListRecommendedByDatabase request.
-func (client SensitivityLabelsClient) ListRecommendedByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if includeDisabledRecommendations != nil {
- queryParameters["includeDisabledRecommendations"] = autorest.Encode("query", *includeDisabledRecommendations)
- }
- if len(skipToken) > 0 {
- queryParameters["$skipToken"] = autorest.Encode("query", skipToken)
- }
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/recommendedSensitivityLabels", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListRecommendedByDatabaseSender sends the ListRecommendedByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client SensitivityLabelsClient) ListRecommendedByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListRecommendedByDatabaseResponder handles the response to the ListRecommendedByDatabase request. The method always
-// closes the http.Response Body.
-func (client SensitivityLabelsClient) ListRecommendedByDatabaseResponder(resp *http.Response) (result SensitivityLabelListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listRecommendedByDatabaseNextResults retrieves the next set of results, if any.
-func (client SensitivityLabelsClient) listRecommendedByDatabaseNextResults(ctx context.Context, lastResults SensitivityLabelListResult) (result SensitivityLabelListResult, err error) {
- req, err := lastResults.sensitivityLabelListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListRecommendedByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListRecommendedByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListRecommendedByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SensitivityLabelsClient) ListRecommendedByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (result SensitivityLabelListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListRecommendedByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListRecommendedByDatabase(ctx, resourceGroupName, serverName, databaseName, includeDisabledRecommendations, skipToken, filter)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// SensitivityLabelsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type SensitivityLabelsClient struct {
+ BaseClient
+}
+
+// NewSensitivityLabelsClient creates an instance of the SensitivityLabelsClient client.
+func NewSensitivityLabelsClient(subscriptionID string) SensitivityLabelsClient {
+ return NewSensitivityLabelsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewSensitivityLabelsClientWithBaseURI creates an instance of the SensitivityLabelsClient client.
+func NewSensitivityLabelsClientWithBaseURI(baseURI string, subscriptionID string) SensitivityLabelsClient {
+ return SensitivityLabelsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates the sensitivity label of a given column
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// schemaName - the name of the schema.
+// tableName - the name of the table.
+// columnName - the name of the column.
+// parameters - the column sensitivity label resource.
+func (client SensitivityLabelsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, parameters SensitivityLabel) (result SensitivityLabel, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client SensitivityLabelsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, parameters SensitivityLabel) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "columnName": autorest.Encode("path", columnName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "schemaName": autorest.Encode("path", schemaName),
+ "sensitivityLabelSource": autorest.Encode("path", "current"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "tableName": autorest.Encode("path", tableName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) CreateOrUpdateResponder(resp *http.Response) (result SensitivityLabel, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes the sensitivity label of a given column
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// schemaName - the name of the schema.
+// tableName - the name of the table.
+// columnName - the name of the column.
+func (client SensitivityLabelsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client SensitivityLabelsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "columnName": autorest.Encode("path", columnName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "schemaName": autorest.Encode("path", schemaName),
+ "sensitivityLabelSource": autorest.Encode("path", "current"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "tableName": autorest.Encode("path", tableName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// DisableRecommendation disables sensitivity recommendations on a given column
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// schemaName - the name of the schema.
+// tableName - the name of the table.
+// columnName - the name of the column.
+func (client SensitivityLabelsClient) DisableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.DisableRecommendation")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DisableRecommendationPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DisableRecommendationSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DisableRecommendationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "DisableRecommendation", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DisableRecommendationPreparer prepares the DisableRecommendation request.
+func (client SensitivityLabelsClient) DisableRecommendationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "columnName": autorest.Encode("path", columnName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "schemaName": autorest.Encode("path", schemaName),
+ "sensitivityLabelSource": autorest.Encode("path", "recommended"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "tableName": autorest.Encode("path", tableName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/disable", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DisableRecommendationSender sends the DisableRecommendation request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) DisableRecommendationSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DisableRecommendationResponder handles the response to the DisableRecommendation request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) DisableRecommendationResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// EnableRecommendation enables sensitivity recommendations on a given column (recommendations are enabled by default
+// on all columns)
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// schemaName - the name of the schema.
+// tableName - the name of the table.
+// columnName - the name of the column.
+func (client SensitivityLabelsClient) EnableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.EnableRecommendation")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.EnableRecommendationPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.EnableRecommendationSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.EnableRecommendationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "EnableRecommendation", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// EnableRecommendationPreparer prepares the EnableRecommendation request.
+func (client SensitivityLabelsClient) EnableRecommendationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "columnName": autorest.Encode("path", columnName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "schemaName": autorest.Encode("path", schemaName),
+ "sensitivityLabelSource": autorest.Encode("path", "recommended"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "tableName": autorest.Encode("path", tableName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}/enable", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// EnableRecommendationSender sends the EnableRecommendation request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) EnableRecommendationSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// EnableRecommendationResponder handles the response to the EnableRecommendation request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) EnableRecommendationResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets the sensitivity label of a given column
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// schemaName - the name of the schema.
+// tableName - the name of the table.
+// columnName - the name of the column.
+// sensitivityLabelSource - the source of the sensitivity label.
+func (client SensitivityLabelsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, sensitivityLabelSource SensitivityLabelSource) (result SensitivityLabel, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, schemaName, tableName, columnName, sensitivityLabelSource)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client SensitivityLabelsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, sensitivityLabelSource SensitivityLabelSource) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "columnName": autorest.Encode("path", columnName),
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "schemaName": autorest.Encode("path", schemaName),
+ "sensitivityLabelSource": autorest.Encode("path", sensitivityLabelSource),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "tableName": autorest.Encode("path", tableName),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/schemas/{schemaName}/tables/{tableName}/columns/{columnName}/sensitivityLabels/{sensitivityLabelSource}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) GetResponder(resp *http.Response) (result SensitivityLabel, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListCurrentByDatabase gets the sensitivity labels of a given database
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// filter - an OData filter expression that filters elements in the collection.
+func (client SensitivityLabelsClient) ListCurrentByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result SensitivityLabelListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListCurrentByDatabase")
+ defer func() {
+ sc := -1
+ if result.sllr.Response.Response != nil {
+ sc = result.sllr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listCurrentByDatabaseNextResults
+ req, err := client.ListCurrentByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListCurrentByDatabaseSender(req)
+ if err != nil {
+ result.sllr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.sllr, err = client.ListCurrentByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListCurrentByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListCurrentByDatabasePreparer prepares the ListCurrentByDatabase request.
+func (client SensitivityLabelsClient) ListCurrentByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/currentSensitivityLabels", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListCurrentByDatabaseSender sends the ListCurrentByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) ListCurrentByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListCurrentByDatabaseResponder handles the response to the ListCurrentByDatabase request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) ListCurrentByDatabaseResponder(resp *http.Response) (result SensitivityLabelListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listCurrentByDatabaseNextResults retrieves the next set of results, if any.
+func (client SensitivityLabelsClient) listCurrentByDatabaseNextResults(ctx context.Context, lastResults SensitivityLabelListResult) (result SensitivityLabelListResult, err error) {
+ req, err := lastResults.sensitivityLabelListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListCurrentByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListCurrentByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listCurrentByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListCurrentByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SensitivityLabelsClient) ListCurrentByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result SensitivityLabelListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListCurrentByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListCurrentByDatabase(ctx, resourceGroupName, serverName, databaseName, filter)
+ return
+}
+
+// ListRecommendedByDatabase gets the sensitivity labels of a given database
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database.
+// includeDisabledRecommendations - specifies whether to include disabled recommendations or not.
+// filter - an OData filter expression that filters elements in the collection.
+func (client SensitivityLabelsClient) ListRecommendedByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (result SensitivityLabelListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListRecommendedByDatabase")
+ defer func() {
+ sc := -1
+ if result.sllr.Response.Response != nil {
+ sc = result.sllr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listRecommendedByDatabaseNextResults
+ req, err := client.ListRecommendedByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName, includeDisabledRecommendations, skipToken, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListRecommendedByDatabaseSender(req)
+ if err != nil {
+ result.sllr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.sllr, err = client.ListRecommendedByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "ListRecommendedByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListRecommendedByDatabasePreparer prepares the ListRecommendedByDatabase request.
+func (client SensitivityLabelsClient) ListRecommendedByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if includeDisabledRecommendations != nil {
+ queryParameters["includeDisabledRecommendations"] = autorest.Encode("query", *includeDisabledRecommendations)
+ }
+ if len(skipToken) > 0 {
+ queryParameters["$skipToken"] = autorest.Encode("query", skipToken)
+ }
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/recommendedSensitivityLabels", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListRecommendedByDatabaseSender sends the ListRecommendedByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client SensitivityLabelsClient) ListRecommendedByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListRecommendedByDatabaseResponder handles the response to the ListRecommendedByDatabase request. The method always
+// closes the http.Response Body.
+func (client SensitivityLabelsClient) ListRecommendedByDatabaseResponder(resp *http.Response) (result SensitivityLabelListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listRecommendedByDatabaseNextResults retrieves the next set of results, if any.
+func (client SensitivityLabelsClient) listRecommendedByDatabaseNextResults(ctx context.Context, lastResults SensitivityLabelListResult) (result SensitivityLabelListResult, err error) {
+ req, err := lastResults.sensitivityLabelListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListRecommendedByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListRecommendedByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SensitivityLabelsClient", "listRecommendedByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListRecommendedByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SensitivityLabelsClient) ListRecommendedByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (result SensitivityLabelListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SensitivityLabelsClient.ListRecommendedByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListRecommendedByDatabase(ctx, resourceGroupName, serverName, databaseName, includeDisabledRecommendations, skipToken, filter)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverautomatictuning.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverautomatictuning.go
index fda0e8deea1b..00e40cce10dd 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverautomatictuning.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverautomatictuning.go
@@ -1,202 +1,202 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerAutomaticTuningClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ServerAutomaticTuningClient struct {
- BaseClient
-}
-
-// NewServerAutomaticTuningClient creates an instance of the ServerAutomaticTuningClient client.
-func NewServerAutomaticTuningClient(subscriptionID string) ServerAutomaticTuningClient {
- return NewServerAutomaticTuningClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerAutomaticTuningClientWithBaseURI creates an instance of the ServerAutomaticTuningClient client.
-func NewServerAutomaticTuningClientWithBaseURI(baseURI string, subscriptionID string) ServerAutomaticTuningClient {
- return ServerAutomaticTuningClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get retrieves server automatic tuning options.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerAutomaticTuningClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerAutomaticTuning, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAutomaticTuningClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerAutomaticTuningClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/automaticTuning/current", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAutomaticTuningClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerAutomaticTuningClient) GetResponder(resp *http.Response) (result ServerAutomaticTuning, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Update update automatic tuning options on server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the requested automatic tuning resource state.
-func (client ServerAutomaticTuningClient) Update(ctx context.Context, resourceGroupName string, serverName string, parameters ServerAutomaticTuning) (result ServerAutomaticTuning, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAutomaticTuningClient.Update")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.UpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", resp, "Failure sending request")
- return
- }
-
- result, err = client.UpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", resp, "Failure responding to request")
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ServerAutomaticTuningClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerAutomaticTuning) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/automaticTuning/current", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAutomaticTuningClient) UpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ServerAutomaticTuningClient) UpdateResponder(resp *http.Response) (result ServerAutomaticTuning, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerAutomaticTuningClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ServerAutomaticTuningClient struct {
+ BaseClient
+}
+
+// NewServerAutomaticTuningClient creates an instance of the ServerAutomaticTuningClient client.
+func NewServerAutomaticTuningClient(subscriptionID string) ServerAutomaticTuningClient {
+ return NewServerAutomaticTuningClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerAutomaticTuningClientWithBaseURI creates an instance of the ServerAutomaticTuningClient client.
+func NewServerAutomaticTuningClientWithBaseURI(baseURI string, subscriptionID string) ServerAutomaticTuningClient {
+ return ServerAutomaticTuningClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get retrieves server automatic tuning options.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerAutomaticTuningClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerAutomaticTuning, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAutomaticTuningClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerAutomaticTuningClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/automaticTuning/current", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAutomaticTuningClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerAutomaticTuningClient) GetResponder(resp *http.Response) (result ServerAutomaticTuning, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Update update automatic tuning options on server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the requested automatic tuning resource state.
+func (client ServerAutomaticTuningClient) Update(ctx context.Context, resourceGroupName string, serverName string, parameters ServerAutomaticTuning) (result ServerAutomaticTuning, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAutomaticTuningClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.UpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.UpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAutomaticTuningClient", "Update", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ServerAutomaticTuningClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerAutomaticTuning) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/automaticTuning/current", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAutomaticTuningClient) UpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ServerAutomaticTuningClient) UpdateResponder(resp *http.Response) (result ServerAutomaticTuning, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverazureadadministrators.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverazureadadministrators.go
index 19a954c0bc90..8f68bc664109 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverazureadadministrators.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverazureadadministrators.go
@@ -1,374 +1,374 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerAzureADAdministratorsClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ServerAzureADAdministratorsClient struct {
- BaseClient
-}
-
-// NewServerAzureADAdministratorsClient creates an instance of the ServerAzureADAdministratorsClient client.
-func NewServerAzureADAdministratorsClient(subscriptionID string) ServerAzureADAdministratorsClient {
- return NewServerAzureADAdministratorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerAzureADAdministratorsClientWithBaseURI creates an instance of the ServerAzureADAdministratorsClient client.
-func NewServerAzureADAdministratorsClientWithBaseURI(baseURI string, subscriptionID string) ServerAzureADAdministratorsClient {
- return ServerAzureADAdministratorsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates a new Server Active Directory Administrator or updates an existing server Active Directory
-// Administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// properties - the required parameters for creating or updating an Active Directory Administrator.
-func (client ServerAzureADAdministratorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, properties ServerAzureADAdministrator) (result ServerAzureADAdministratorsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: properties,
- Constraints: []validation.Constraint{{Target: "properties.ServerAdministratorProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "properties.ServerAdministratorProperties.AdministratorType", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "properties.ServerAdministratorProperties.Login", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "properties.ServerAdministratorProperties.Sid", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "properties.ServerAdministratorProperties.TenantID", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, properties)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerAzureADAdministratorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, properties ServerAzureADAdministrator) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", "activeDirectory"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
- autorest.WithJSON(properties),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAzureADAdministratorsClient) CreateOrUpdateSender(req *http.Request) (future ServerAzureADAdministratorsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerAzureADAdministratorsClient) CreateOrUpdateResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes an existing server Active Directory Administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerAzureADAdministratorsClient) Delete(ctx context.Context, resourceGroupName string, serverName string) (result ServerAzureADAdministratorsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ServerAzureADAdministratorsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", "activeDirectory"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAzureADAdministratorsClient) DeleteSender(req *http.Request) (future ServerAzureADAdministratorsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ServerAzureADAdministratorsClient) DeleteResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get returns an server Administrator.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerAzureADAdministratorsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerAzureADAdministrator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerAzureADAdministratorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "administratorName": autorest.Encode("path", "activeDirectory"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAzureADAdministratorsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerAzureADAdministratorsClient) GetResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer returns a list of server Administrators.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerAzureADAdministratorsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerAdministratorListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerAzureADAdministratorsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerAzureADAdministratorsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerAzureADAdministratorsClient) ListByServerResponder(resp *http.Response) (result ServerAdministratorListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerAzureADAdministratorsClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ServerAzureADAdministratorsClient struct {
+ BaseClient
+}
+
+// NewServerAzureADAdministratorsClient creates an instance of the ServerAzureADAdministratorsClient client.
+func NewServerAzureADAdministratorsClient(subscriptionID string) ServerAzureADAdministratorsClient {
+ return NewServerAzureADAdministratorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerAzureADAdministratorsClientWithBaseURI creates an instance of the ServerAzureADAdministratorsClient client.
+func NewServerAzureADAdministratorsClientWithBaseURI(baseURI string, subscriptionID string) ServerAzureADAdministratorsClient {
+ return ServerAzureADAdministratorsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates a new Server Active Directory Administrator or updates an existing server Active Directory
+// Administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// properties - the required parameters for creating or updating an Active Directory Administrator.
+func (client ServerAzureADAdministratorsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, properties ServerAzureADAdministrator) (result ServerAzureADAdministratorsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: properties,
+ Constraints: []validation.Constraint{{Target: "properties.ServerAdministratorProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "properties.ServerAdministratorProperties.AdministratorType", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "properties.ServerAdministratorProperties.Login", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "properties.ServerAdministratorProperties.Sid", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "properties.ServerAdministratorProperties.TenantID", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, properties)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerAzureADAdministratorsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, properties ServerAzureADAdministrator) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", "activeDirectory"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
+ autorest.WithJSON(properties),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAzureADAdministratorsClient) CreateOrUpdateSender(req *http.Request) (future ServerAzureADAdministratorsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerAzureADAdministratorsClient) CreateOrUpdateResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes an existing server Active Directory Administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerAzureADAdministratorsClient) Delete(ctx context.Context, resourceGroupName string, serverName string) (result ServerAzureADAdministratorsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ServerAzureADAdministratorsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", "activeDirectory"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAzureADAdministratorsClient) DeleteSender(req *http.Request) (future ServerAzureADAdministratorsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ServerAzureADAdministratorsClient) DeleteResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get returns an server Administrator.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerAzureADAdministratorsClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerAzureADAdministrator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerAzureADAdministratorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "administratorName": autorest.Encode("path", "activeDirectory"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators/{administratorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAzureADAdministratorsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerAzureADAdministratorsClient) GetResponder(resp *http.Response) (result ServerAzureADAdministrator, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer returns a list of server Administrators.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerAzureADAdministratorsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerAdministratorListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerAzureADAdministratorsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerAzureADAdministratorsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerAzureADAdministratorsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/administrators", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerAzureADAdministratorsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerAzureADAdministratorsClient) ListByServerResponder(resp *http.Response) (result ServerAdministratorListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverblobauditingpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverblobauditingpolicies.go
index 4aabd26f80f0..48d2fde5ed0d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverblobauditingpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverblobauditingpolicies.go
@@ -1,320 +1,320 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type ServerBlobAuditingPoliciesClient struct {
- BaseClient
-}
-
-// NewServerBlobAuditingPoliciesClient creates an instance of the ServerBlobAuditingPoliciesClient client.
-func NewServerBlobAuditingPoliciesClient(subscriptionID string) ServerBlobAuditingPoliciesClient {
- return NewServerBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerBlobAuditingPoliciesClientWithBaseURI creates an instance of the ServerBlobAuditingPoliciesClient client.
-func NewServerBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerBlobAuditingPoliciesClient {
- return ServerBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a server's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - properties of blob auditing policy
-func (client ServerBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerBlobAuditingPolicy) (result ServerBlobAuditingPoliciesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerBlobAuditingPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ServerBlobAuditingPoliciesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a server's blob auditing policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "blobAuditingPolicyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result ServerBlobAuditingPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer lists auditing settings of a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerBlobAuditingPoliciesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicyListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.ListByServer")
- defer func() {
- sc := -1
- if result.sbaplr.Response.Response != nil {
- sc = result.sbaplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.sbaplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.sbaplr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerBlobAuditingPoliciesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerBlobAuditingPoliciesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerBlobAuditingPoliciesClient) ListByServerResponder(resp *http.Response) (result ServerBlobAuditingPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client ServerBlobAuditingPoliciesClient) listByServerNextResults(ctx context.Context, lastResults ServerBlobAuditingPolicyListResult) (result ServerBlobAuditingPolicyListResult, err error) {
- req, err := lastResults.serverBlobAuditingPolicyListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServerBlobAuditingPoliciesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicyListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerBlobAuditingPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type ServerBlobAuditingPoliciesClient struct {
+ BaseClient
+}
+
+// NewServerBlobAuditingPoliciesClient creates an instance of the ServerBlobAuditingPoliciesClient client.
+func NewServerBlobAuditingPoliciesClient(subscriptionID string) ServerBlobAuditingPoliciesClient {
+ return NewServerBlobAuditingPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerBlobAuditingPoliciesClientWithBaseURI creates an instance of the ServerBlobAuditingPoliciesClient client.
+func NewServerBlobAuditingPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerBlobAuditingPoliciesClient {
+ return ServerBlobAuditingPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a server's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - properties of blob auditing policy
+func (client ServerBlobAuditingPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerBlobAuditingPolicy) (result ServerBlobAuditingPoliciesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerBlobAuditingPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerBlobAuditingPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerBlobAuditingPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ServerBlobAuditingPoliciesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerBlobAuditingPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a server's blob auditing policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerBlobAuditingPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerBlobAuditingPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "blobAuditingPolicyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings/{blobAuditingPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerBlobAuditingPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerBlobAuditingPoliciesClient) GetResponder(resp *http.Response) (result ServerBlobAuditingPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer lists auditing settings of a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerBlobAuditingPoliciesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicyListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.sbaplr.Response.Response != nil {
+ sc = result.sbaplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.sbaplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.sbaplr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerBlobAuditingPoliciesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/auditingSettings", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerBlobAuditingPoliciesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerBlobAuditingPoliciesClient) ListByServerResponder(resp *http.Response) (result ServerBlobAuditingPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client ServerBlobAuditingPoliciesClient) listByServerNextResults(ctx context.Context, lastResults ServerBlobAuditingPolicyListResult) (result ServerBlobAuditingPolicyListResult, err error) {
+ req, err := lastResults.serverBlobAuditingPolicyListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerBlobAuditingPoliciesClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServerBlobAuditingPoliciesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerBlobAuditingPolicyListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerBlobAuditingPoliciesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servercommunicationlinks.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servercommunicationlinks.go
index 6a71e58a8abe..8c89241fa93f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servercommunicationlinks.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servercommunicationlinks.go
@@ -1,373 +1,373 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerCommunicationLinksClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type ServerCommunicationLinksClient struct {
- BaseClient
-}
-
-// NewServerCommunicationLinksClient creates an instance of the ServerCommunicationLinksClient client.
-func NewServerCommunicationLinksClient(subscriptionID string) ServerCommunicationLinksClient {
- return NewServerCommunicationLinksClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerCommunicationLinksClientWithBaseURI creates an instance of the ServerCommunicationLinksClient client.
-func NewServerCommunicationLinksClientWithBaseURI(baseURI string, subscriptionID string) ServerCommunicationLinksClient {
- return ServerCommunicationLinksClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates a server communication link.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// communicationLinkName - the name of the server communication link.
-// parameters - the required parameters for creating a server communication link.
-func (client ServerCommunicationLinksClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string, parameters ServerCommunicationLink) (result ServerCommunicationLinksCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.ServerCommunicationLinkProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.ServerCommunicationLinkProperties.PartnerServer", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.ServerCommunicationLinksClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, communicationLinkName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerCommunicationLinksClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string, parameters ServerCommunicationLink) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "communicationLinkName": autorest.Encode("path", communicationLinkName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerCommunicationLinksClient) CreateOrUpdateSender(req *http.Request) (future ServerCommunicationLinksCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerCommunicationLinksClient) CreateOrUpdateResponder(resp *http.Response) (result ServerCommunicationLink, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a server communication link.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// communicationLinkName - the name of the server communication link.
-func (client ServerCommunicationLinksClient) Delete(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, communicationLinkName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", resp, "Failure sending request")
- return
- }
-
- result, err = client.DeleteResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ServerCommunicationLinksClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "communicationLinkName": autorest.Encode("path", communicationLinkName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerCommunicationLinksClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ServerCommunicationLinksClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get returns a server communication link.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// communicationLinkName - the name of the server communication link.
-func (client ServerCommunicationLinksClient) Get(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result ServerCommunicationLink, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, communicationLinkName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerCommunicationLinksClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "communicationLinkName": autorest.Encode("path", communicationLinkName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerCommunicationLinksClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerCommunicationLinksClient) GetResponder(resp *http.Response) (result ServerCommunicationLink, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of server communication links.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerCommunicationLinksClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerCommunicationLinkListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerCommunicationLinksClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerCommunicationLinksClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerCommunicationLinksClient) ListByServerResponder(resp *http.Response) (result ServerCommunicationLinkListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerCommunicationLinksClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type ServerCommunicationLinksClient struct {
+ BaseClient
+}
+
+// NewServerCommunicationLinksClient creates an instance of the ServerCommunicationLinksClient client.
+func NewServerCommunicationLinksClient(subscriptionID string) ServerCommunicationLinksClient {
+ return NewServerCommunicationLinksClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerCommunicationLinksClientWithBaseURI creates an instance of the ServerCommunicationLinksClient client.
+func NewServerCommunicationLinksClientWithBaseURI(baseURI string, subscriptionID string) ServerCommunicationLinksClient {
+ return ServerCommunicationLinksClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates a server communication link.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// communicationLinkName - the name of the server communication link.
+// parameters - the required parameters for creating a server communication link.
+func (client ServerCommunicationLinksClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string, parameters ServerCommunicationLink) (result ServerCommunicationLinksCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.ServerCommunicationLinkProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.ServerCommunicationLinkProperties.PartnerServer", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.ServerCommunicationLinksClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, communicationLinkName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerCommunicationLinksClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string, parameters ServerCommunicationLink) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "communicationLinkName": autorest.Encode("path", communicationLinkName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerCommunicationLinksClient) CreateOrUpdateSender(req *http.Request) (future ServerCommunicationLinksCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerCommunicationLinksClient) CreateOrUpdateResponder(resp *http.Response) (result ServerCommunicationLink, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a server communication link.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// communicationLinkName - the name of the server communication link.
+func (client ServerCommunicationLinksClient) Delete(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, communicationLinkName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.DeleteSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.DeleteResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Delete", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ServerCommunicationLinksClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "communicationLinkName": autorest.Encode("path", communicationLinkName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerCommunicationLinksClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ServerCommunicationLinksClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get returns a server communication link.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// communicationLinkName - the name of the server communication link.
+func (client ServerCommunicationLinksClient) Get(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result ServerCommunicationLink, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, communicationLinkName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerCommunicationLinksClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "communicationLinkName": autorest.Encode("path", communicationLinkName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks/{communicationLinkName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerCommunicationLinksClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerCommunicationLinksClient) GetResponder(resp *http.Response) (result ServerCommunicationLink, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of server communication links.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerCommunicationLinksClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerCommunicationLinkListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerCommunicationLinksClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerCommunicationLinksClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerCommunicationLinksClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/communicationLinks", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerCommunicationLinksClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerCommunicationLinksClient) ListByServerResponder(resp *http.Response) (result ServerCommunicationLinkListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverconnectionpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverconnectionpolicies.go
index eadf1fa6e9cf..281669c15993 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverconnectionpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverconnectionpolicies.go
@@ -1,206 +1,206 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerConnectionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type ServerConnectionPoliciesClient struct {
- BaseClient
-}
-
-// NewServerConnectionPoliciesClient creates an instance of the ServerConnectionPoliciesClient client.
-func NewServerConnectionPoliciesClient(subscriptionID string) ServerConnectionPoliciesClient {
- return NewServerConnectionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerConnectionPoliciesClientWithBaseURI creates an instance of the ServerConnectionPoliciesClient client.
-func NewServerConnectionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerConnectionPoliciesClient {
- return ServerConnectionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates the server's connection policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the required parameters for updating a secure connection policy.
-func (client ServerConnectionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerConnectionPolicy) (result ServerConnectionPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerConnectionPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerConnectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerConnectionPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "connectionPolicyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/connectionPolicies/{connectionPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerConnectionPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerConnectionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerConnectionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets the server's secure connection policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerConnectionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerConnectionPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerConnectionPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerConnectionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "connectionPolicyName": autorest.Encode("path", "default"),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/connectionPolicies/{connectionPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerConnectionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerConnectionPoliciesClient) GetResponder(resp *http.Response) (result ServerConnectionPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerConnectionPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type ServerConnectionPoliciesClient struct {
+ BaseClient
+}
+
+// NewServerConnectionPoliciesClient creates an instance of the ServerConnectionPoliciesClient client.
+func NewServerConnectionPoliciesClient(subscriptionID string) ServerConnectionPoliciesClient {
+ return NewServerConnectionPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerConnectionPoliciesClientWithBaseURI creates an instance of the ServerConnectionPoliciesClient client.
+func NewServerConnectionPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerConnectionPoliciesClient {
+ return ServerConnectionPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates the server's connection policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the required parameters for updating a secure connection policy.
+func (client ServerConnectionPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerConnectionPolicy) (result ServerConnectionPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerConnectionPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerConnectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerConnectionPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "connectionPolicyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/connectionPolicies/{connectionPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerConnectionPoliciesClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerConnectionPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerConnectionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets the server's secure connection policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerConnectionPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerConnectionPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerConnectionPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerConnectionPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerConnectionPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "connectionPolicyName": autorest.Encode("path", "default"),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/connectionPolicies/{connectionPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerConnectionPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerConnectionPoliciesClient) GetResponder(resp *http.Response) (result ServerConnectionPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverdnsaliases.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverdnsaliases.go
index be613a85c98d..51074322a772 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverdnsaliases.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverdnsaliases.go
@@ -1,479 +1,479 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerDNSAliasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ServerDNSAliasesClient struct {
- BaseClient
-}
-
-// NewServerDNSAliasesClient creates an instance of the ServerDNSAliasesClient client.
-func NewServerDNSAliasesClient(subscriptionID string) ServerDNSAliasesClient {
- return NewServerDNSAliasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerDNSAliasesClientWithBaseURI creates an instance of the ServerDNSAliasesClient client.
-func NewServerDNSAliasesClientWithBaseURI(baseURI string, subscriptionID string) ServerDNSAliasesClient {
- return ServerDNSAliasesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Acquire acquires server DNS alias from another server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server that the alias is pointing to.
-// DNSAliasName - the name of the server dns alias.
-func (client ServerDNSAliasesClient) Acquire(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string, parameters ServerDNSAliasAcquisition) (result ServerDNSAliasesAcquireFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Acquire")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.AcquirePreparer(ctx, resourceGroupName, serverName, DNSAliasName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Acquire", nil, "Failure preparing request")
- return
- }
-
- result, err = client.AcquireSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Acquire", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// AcquirePreparer prepares the Acquire request.
-func (client ServerDNSAliasesClient) AcquirePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string, parameters ServerDNSAliasAcquisition) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "dnsAliasName": autorest.Encode("path", DNSAliasName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}/acquire", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// AcquireSender sends the Acquire request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerDNSAliasesClient) AcquireSender(req *http.Request) (future ServerDNSAliasesAcquireFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// AcquireResponder handles the response to the Acquire request. The method always
-// closes the http.Response Body.
-func (client ServerDNSAliasesClient) AcquireResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// CreateOrUpdate creates a server dns alias.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server that the alias is pointing to.
-// DNSAliasName - the name of the server DNS alias.
-func (client ServerDNSAliasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAliasesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, DNSAliasName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerDNSAliasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "dnsAliasName": autorest.Encode("path", DNSAliasName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerDNSAliasesClient) CreateOrUpdateSender(req *http.Request) (future ServerDNSAliasesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerDNSAliasesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerDNSAlias, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes the server DNS alias with the given name.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server that the alias is pointing to.
-// DNSAliasName - the name of the server DNS alias.
-func (client ServerDNSAliasesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAliasesDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, DNSAliasName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ServerDNSAliasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "dnsAliasName": autorest.Encode("path", DNSAliasName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerDNSAliasesClient) DeleteSender(req *http.Request) (future ServerDNSAliasesDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ServerDNSAliasesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a server DNS alias.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server that the alias is pointing to.
-// DNSAliasName - the name of the server DNS alias.
-func (client ServerDNSAliasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAlias, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, DNSAliasName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerDNSAliasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "dnsAliasName": autorest.Encode("path", DNSAliasName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerDNSAliasesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerDNSAliasesClient) GetResponder(resp *http.Response) (result ServerDNSAlias, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of server DNS aliases for a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server that the alias is pointing to.
-func (client ServerDNSAliasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerDNSAliasListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.ListByServer")
- defer func() {
- sc := -1
- if result.sdalr.Response.Response != nil {
- sc = result.sdalr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.sdalr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.sdalr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerDNSAliasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerDNSAliasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerDNSAliasesClient) ListByServerResponder(resp *http.Response) (result ServerDNSAliasListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client ServerDNSAliasesClient) listByServerNextResults(ctx context.Context, lastResults ServerDNSAliasListResult) (result ServerDNSAliasListResult, err error) {
- req, err := lastResults.serverDNSAliasListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServerDNSAliasesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerDNSAliasListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerDNSAliasesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ServerDNSAliasesClient struct {
+ BaseClient
+}
+
+// NewServerDNSAliasesClient creates an instance of the ServerDNSAliasesClient client.
+func NewServerDNSAliasesClient(subscriptionID string) ServerDNSAliasesClient {
+ return NewServerDNSAliasesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerDNSAliasesClientWithBaseURI creates an instance of the ServerDNSAliasesClient client.
+func NewServerDNSAliasesClientWithBaseURI(baseURI string, subscriptionID string) ServerDNSAliasesClient {
+ return ServerDNSAliasesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Acquire acquires server DNS alias from another server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server that the alias is pointing to.
+// DNSAliasName - the name of the server dns alias.
+func (client ServerDNSAliasesClient) Acquire(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string, parameters ServerDNSAliasAcquisition) (result ServerDNSAliasesAcquireFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Acquire")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.AcquirePreparer(ctx, resourceGroupName, serverName, DNSAliasName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Acquire", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.AcquireSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Acquire", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// AcquirePreparer prepares the Acquire request.
+func (client ServerDNSAliasesClient) AcquirePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string, parameters ServerDNSAliasAcquisition) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "dnsAliasName": autorest.Encode("path", DNSAliasName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}/acquire", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// AcquireSender sends the Acquire request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerDNSAliasesClient) AcquireSender(req *http.Request) (future ServerDNSAliasesAcquireFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// AcquireResponder handles the response to the Acquire request. The method always
+// closes the http.Response Body.
+func (client ServerDNSAliasesClient) AcquireResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// CreateOrUpdate creates a server dns alias.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server that the alias is pointing to.
+// DNSAliasName - the name of the server DNS alias.
+func (client ServerDNSAliasesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAliasesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, DNSAliasName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerDNSAliasesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "dnsAliasName": autorest.Encode("path", DNSAliasName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerDNSAliasesClient) CreateOrUpdateSender(req *http.Request) (future ServerDNSAliasesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerDNSAliasesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerDNSAlias, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes the server DNS alias with the given name.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server that the alias is pointing to.
+// DNSAliasName - the name of the server DNS alias.
+func (client ServerDNSAliasesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAliasesDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, DNSAliasName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ServerDNSAliasesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "dnsAliasName": autorest.Encode("path", DNSAliasName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerDNSAliasesClient) DeleteSender(req *http.Request) (future ServerDNSAliasesDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ServerDNSAliasesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a server DNS alias.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server that the alias is pointing to.
+// DNSAliasName - the name of the server DNS alias.
+func (client ServerDNSAliasesClient) Get(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result ServerDNSAlias, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, DNSAliasName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerDNSAliasesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "dnsAliasName": autorest.Encode("path", DNSAliasName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases/{dnsAliasName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerDNSAliasesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerDNSAliasesClient) GetResponder(resp *http.Response) (result ServerDNSAlias, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of server DNS aliases for a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server that the alias is pointing to.
+func (client ServerDNSAliasesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerDNSAliasListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.sdalr.Response.Response != nil {
+ sc = result.sdalr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.sdalr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.sdalr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerDNSAliasesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/dnsAliases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerDNSAliasesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerDNSAliasesClient) ListByServerResponder(resp *http.Response) (result ServerDNSAliasListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client ServerDNSAliasesClient) listByServerNextResults(ctx context.Context, lastResults ServerDNSAliasListResult) (result ServerDNSAliasListResult, err error) {
+ req, err := lastResults.serverDNSAliasListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerDNSAliasesClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServerDNSAliasesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerDNSAliasListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerDNSAliasesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverkeys.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverkeys.go
index c12a79c5bd49..9e9e38abbe15 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverkeys.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverkeys.go
@@ -1,405 +1,405 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerKeysClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type ServerKeysClient struct {
- BaseClient
-}
-
-// NewServerKeysClient creates an instance of the ServerKeysClient client.
-func NewServerKeysClient(subscriptionID string) ServerKeysClient {
- return NewServerKeysClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerKeysClientWithBaseURI creates an instance of the ServerKeysClient client.
-func NewServerKeysClientWithBaseURI(baseURI string, subscriptionID string) ServerKeysClient {
- return ServerKeysClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a server key.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// keyName - the name of the server key to be operated on (updated or created). The key name is required to be
-// in the format of 'vault_key_version'. For example, if the keyId is
-// https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, then the server key
-// name should be formatted as: YourVaultName_YourKeyName_01234567890123456789012345678901
-// parameters - the requested server key resource state.
-func (client ServerKeysClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, keyName string, parameters ServerKey) (result ServerKeysCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, keyName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerKeysClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string, parameters ServerKey) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "keyName": autorest.Encode("path", keyName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerKeysClient) CreateOrUpdateSender(req *http.Request) (future ServerKeysCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerKeysClient) CreateOrUpdateResponder(resp *http.Response) (result ServerKey, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes the server key with the given name.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// keyName - the name of the server key to be deleted.
-func (client ServerKeysClient) Delete(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result ServerKeysDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, keyName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ServerKeysClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "keyName": autorest.Encode("path", keyName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerKeysClient) DeleteSender(req *http.Request) (future ServerKeysDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ServerKeysClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a server key.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// keyName - the name of the server key to be retrieved.
-func (client ServerKeysClient) Get(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result ServerKey, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, keyName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerKeysClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "keyName": autorest.Encode("path", keyName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerKeysClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerKeysClient) GetResponder(resp *http.Response) (result ServerKey, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of server keys.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerKeysClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerKeyListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.ListByServer")
- defer func() {
- sc := -1
- if result.sklr.Response.Response != nil {
- sc = result.sklr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.sklr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.sklr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerKeysClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerKeysClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerKeysClient) ListByServerResponder(resp *http.Response) (result ServerKeyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client ServerKeysClient) listByServerNextResults(ctx context.Context, lastResults ServerKeyListResult) (result ServerKeyListResult, err error) {
- req, err := lastResults.serverKeyListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServerKeysClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerKeyListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerKeysClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type ServerKeysClient struct {
+ BaseClient
+}
+
+// NewServerKeysClient creates an instance of the ServerKeysClient client.
+func NewServerKeysClient(subscriptionID string) ServerKeysClient {
+ return NewServerKeysClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerKeysClientWithBaseURI creates an instance of the ServerKeysClient client.
+func NewServerKeysClientWithBaseURI(baseURI string, subscriptionID string) ServerKeysClient {
+ return ServerKeysClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a server key.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// keyName - the name of the server key to be operated on (updated or created). The key name is required to be
+// in the format of 'vault_key_version'. For example, if the keyId is
+// https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, then the server key
+// name should be formatted as: YourVaultName_YourKeyName_01234567890123456789012345678901
+// parameters - the requested server key resource state.
+func (client ServerKeysClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, keyName string, parameters ServerKey) (result ServerKeysCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, keyName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerKeysClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string, parameters ServerKey) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "keyName": autorest.Encode("path", keyName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerKeysClient) CreateOrUpdateSender(req *http.Request) (future ServerKeysCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerKeysClient) CreateOrUpdateResponder(resp *http.Response) (result ServerKey, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes the server key with the given name.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// keyName - the name of the server key to be deleted.
+func (client ServerKeysClient) Delete(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result ServerKeysDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, keyName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ServerKeysClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "keyName": autorest.Encode("path", keyName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerKeysClient) DeleteSender(req *http.Request) (future ServerKeysDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ServerKeysClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a server key.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// keyName - the name of the server key to be retrieved.
+func (client ServerKeysClient) Get(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result ServerKey, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, keyName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerKeysClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, keyName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "keyName": autorest.Encode("path", keyName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys/{keyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerKeysClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerKeysClient) GetResponder(resp *http.Response) (result ServerKey, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of server keys.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerKeysClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerKeyListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.sklr.Response.Response != nil {
+ sc = result.sklr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.sklr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.sklr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerKeysClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/keys", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerKeysClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerKeysClient) ListByServerResponder(resp *http.Response) (result ServerKeyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client ServerKeysClient) listByServerNextResults(ctx context.Context, lastResults ServerKeyListResult) (result ServerKeyListResult, err error) {
+ req, err := lastResults.serverKeyListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerKeysClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServerKeysClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result ServerKeyListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerKeysClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servers.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servers.go
index a91749ce2241..388a123d7685 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servers.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servers.go
@@ -1,669 +1,669 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServersClient is the the Azure SQL Database management API provides a RESTful set of web services that interact with
-// Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and delete
-// databases.
-type ServersClient struct {
- BaseClient
-}
-
-// NewServersClient creates an instance of the ServersClient client.
-func NewServersClient(subscriptionID string) ServersClient {
- return NewServersClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServersClientWithBaseURI creates an instance of the ServersClient client.
-func NewServersClientWithBaseURI(baseURI string, subscriptionID string) ServersClient {
- return ServersClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CheckNameAvailability determines whether a resource can be created with the specified name.
-// Parameters:
-// parameters - the parameters to request for name availability.
-func (client ServersClient) CheckNameAvailability(ctx context.Context, parameters CheckNameAvailabilityRequest) (result CheckNameAvailabilityResponse, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.CheckNameAvailability")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.Name", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "parameters.Type", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
- return result, validation.NewError("sql.ServersClient", "CheckNameAvailability", err.Error())
- }
-
- req, err := client.CheckNameAvailabilityPreparer(ctx, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CheckNameAvailabilitySender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", resp, "Failure sending request")
- return
- }
-
- result, err = client.CheckNameAvailabilityResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CheckNameAvailabilityPreparer prepares the CheckNameAvailability request.
-func (client ServersClient) CheckNameAvailabilityPreparer(ctx context.Context, parameters CheckNameAvailabilityRequest) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/checkNameAvailability", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CheckNameAvailabilitySender sends the CheckNameAvailability request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) CheckNameAvailabilitySender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CheckNameAvailabilityResponder handles the response to the CheckNameAvailability request. The method always
-// closes the http.Response Body.
-func (client ServersClient) CheckNameAvailabilityResponder(resp *http.Response) (result CheckNameAvailabilityResponse, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// CreateOrUpdate creates or updates a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the requested server resource state.
-func (client ServersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters Server) (result ServersCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServersClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters Server) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Kind = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) CreateOrUpdateSender(req *http.Request) (future ServersCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServersClient) CreateOrUpdateResponder(resp *http.Response) (result Server, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServersClient) Delete(ctx context.Context, resourceGroupName string, serverName string) (result ServersDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ServersClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) DeleteSender(req *http.Request) (future ServersDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ServersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServersClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result Server, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServersClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServersClient) GetResponder(resp *http.Response) (result Server, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List gets a list of all servers in the subscription.
-func (client ServersClient) List(ctx context.Context) (result ServerListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.List")
- defer func() {
- sc := -1
- if result.slr.Response.Response != nil {
- sc = result.slr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.slr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", resp, "Failure sending request")
- return
- }
-
- result.slr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client ServersClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/servers", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) ListSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client ServersClient) ListResponder(resp *http.Response) (result ServerListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client ServersClient) listNextResults(ctx context.Context, lastResults ServerListResult) (result ServerListResult, err error) {
- req, err := lastResults.serverListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServersClient) ListComplete(ctx context.Context) (result ServerListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
-
-// ListByResourceGroup gets a list of servers in a resource groups.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-func (client ServersClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result ServerListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.slr.Response.Response != nil {
- sc = result.slr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByResourceGroupNextResults
- req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.slr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", resp, "Failure sending request")
- return
- }
-
- result.slr, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
-func (client ServersClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
-// closes the http.Response Body.
-func (client ServersClient) ListByResourceGroupResponder(resp *http.Response) (result ServerListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByResourceGroupNextResults retrieves the next set of results, if any.
-func (client ServersClient) listByResourceGroupNextResults(ctx context.Context, lastResults ServerListResult) (result ServerListResult, err error) {
- req, err := lastResults.serverListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServersClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result ServerListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
- return
-}
-
-// Update updates a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the requested server resource state.
-func (client ServersClient) Update(ctx context.Context, resourceGroupName string, serverName string, parameters ServerUpdate) (result ServersUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServersClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client ServersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServersClient) UpdateSender(req *http.Request) (future ServersUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client ServersClient) UpdateResponder(resp *http.Response) (result Server, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServersClient is the the Azure SQL Database management API provides a RESTful set of web services that interact with
+// Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and delete
+// databases.
+type ServersClient struct {
+ BaseClient
+}
+
+// NewServersClient creates an instance of the ServersClient client.
+func NewServersClient(subscriptionID string) ServersClient {
+ return NewServersClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServersClientWithBaseURI creates an instance of the ServersClient client.
+func NewServersClientWithBaseURI(baseURI string, subscriptionID string) ServersClient {
+ return ServersClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CheckNameAvailability determines whether a resource can be created with the specified name.
+// Parameters:
+// parameters - the parameters to request for name availability.
+func (client ServersClient) CheckNameAvailability(ctx context.Context, parameters CheckNameAvailabilityRequest) (result CheckNameAvailabilityResponse, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.CheckNameAvailability")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.Name", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.Type", Name: validation.Null, Rule: true, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("sql.ServersClient", "CheckNameAvailability", err.Error())
+ }
+
+ req, err := client.CheckNameAvailabilityPreparer(ctx, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CheckNameAvailabilitySender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CheckNameAvailabilityResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "CheckNameAvailability", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CheckNameAvailabilityPreparer prepares the CheckNameAvailability request.
+func (client ServersClient) CheckNameAvailabilityPreparer(ctx context.Context, parameters CheckNameAvailabilityRequest) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/checkNameAvailability", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CheckNameAvailabilitySender sends the CheckNameAvailability request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) CheckNameAvailabilitySender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CheckNameAvailabilityResponder handles the response to the CheckNameAvailability request. The method always
+// closes the http.Response Body.
+func (client ServersClient) CheckNameAvailabilityResponder(resp *http.Response) (result CheckNameAvailabilityResponse, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// CreateOrUpdate creates or updates a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the requested server resource state.
+func (client ServersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters Server) (result ServersCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServersClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters Server) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Kind = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) CreateOrUpdateSender(req *http.Request) (future ServersCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServersClient) CreateOrUpdateResponder(resp *http.Response) (result Server, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServersClient) Delete(ctx context.Context, resourceGroupName string, serverName string) (result ServersDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ServersClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) DeleteSender(req *http.Request) (future ServersDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ServersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServersClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result Server, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServersClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServersClient) GetResponder(resp *http.Response) (result Server, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List gets a list of all servers in the subscription.
+func (client ServersClient) List(ctx context.Context) (result ServerListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.List")
+ defer func() {
+ sc := -1
+ if result.slr.Response.Response != nil {
+ sc = result.slr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.slr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.slr, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client ServersClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/servers", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client ServersClient) ListResponder(resp *http.Response) (result ServerListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client ServersClient) listNextResults(ctx context.Context, lastResults ServerListResult) (result ServerListResult, err error) {
+ req, err := lastResults.serverListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServersClient) ListComplete(ctx context.Context) (result ServerListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
+
+// ListByResourceGroup gets a list of servers in a resource groups.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+func (client ServersClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result ServerListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.slr.Response.Response != nil {
+ sc = result.slr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByResourceGroupNextResults
+ req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.slr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.slr, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "ListByResourceGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
+func (client ServersClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
+// closes the http.Response Body.
+func (client ServersClient) ListByResourceGroupResponder(resp *http.Response) (result ServerListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByResourceGroupNextResults retrieves the next set of results, if any.
+func (client ServersClient) listByResourceGroupNextResults(ctx context.Context, lastResults ServerListResult) (result ServerListResult, err error) {
+ req, err := lastResults.serverListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServersClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result ServerListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
+ return
+}
+
+// Update updates a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the requested server resource state.
+func (client ServersClient) Update(ctx context.Context, resourceGroupName string, serverName string, parameters ServerUpdate) (result ServersUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServersClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServersClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client ServersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServersClient) UpdateSender(req *http.Request) (future ServersUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client ServersClient) UpdateResponder(resp *http.Response) (result Server, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serversecurityalertpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serversecurityalertpolicies.go
index 49d540579f6a..89d98348b85a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serversecurityalertpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serversecurityalertpolicies.go
@@ -1,320 +1,320 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerSecurityAlertPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type ServerSecurityAlertPoliciesClient struct {
- BaseClient
-}
-
-// NewServerSecurityAlertPoliciesClient creates an instance of the ServerSecurityAlertPoliciesClient client.
-func NewServerSecurityAlertPoliciesClient(subscriptionID string) ServerSecurityAlertPoliciesClient {
- return NewServerSecurityAlertPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerSecurityAlertPoliciesClientWithBaseURI creates an instance of the ServerSecurityAlertPoliciesClient client.
-func NewServerSecurityAlertPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerSecurityAlertPoliciesClient {
- return ServerSecurityAlertPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a threat detection policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// parameters - the server security alert policy.
-func (client ServerSecurityAlertPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerSecurityAlertPolicy) (result ServerSecurityAlertPoliciesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ServerSecurityAlertPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerSecurityAlertPolicy) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "securityAlertPolicyName": autorest.Encode("path", "Default"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerSecurityAlertPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ServerSecurityAlertPoliciesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client ServerSecurityAlertPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerSecurityAlertPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get get a server's security alert policy.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerSecurityAlertPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerSecurityAlertPolicy, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServerSecurityAlertPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "securityAlertPolicyName": autorest.Encode("path", "Default"),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerSecurityAlertPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServerSecurityAlertPoliciesClient) GetResponder(resp *http.Response) (result ServerSecurityAlertPolicy, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer get the server's threat detection policies.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerSecurityAlertPoliciesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result LogicalServerSecurityAlertPolicyListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.ListByServer")
- defer func() {
- sc := -1
- if result.lssaplr.Response.Response != nil {
- sc = result.lssaplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.lssaplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.lssaplr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerSecurityAlertPoliciesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2017-03-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerSecurityAlertPoliciesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerSecurityAlertPoliciesClient) ListByServerResponder(resp *http.Response) (result LogicalServerSecurityAlertPolicyListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client ServerSecurityAlertPoliciesClient) listByServerNextResults(ctx context.Context, lastResults LogicalServerSecurityAlertPolicyListResult) (result LogicalServerSecurityAlertPolicyListResult, err error) {
- req, err := lastResults.logicalServerSecurityAlertPolicyListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ServerSecurityAlertPoliciesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result LogicalServerSecurityAlertPolicyListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerSecurityAlertPoliciesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type ServerSecurityAlertPoliciesClient struct {
+ BaseClient
+}
+
+// NewServerSecurityAlertPoliciesClient creates an instance of the ServerSecurityAlertPoliciesClient client.
+func NewServerSecurityAlertPoliciesClient(subscriptionID string) ServerSecurityAlertPoliciesClient {
+ return NewServerSecurityAlertPoliciesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerSecurityAlertPoliciesClientWithBaseURI creates an instance of the ServerSecurityAlertPoliciesClient client.
+func NewServerSecurityAlertPoliciesClientWithBaseURI(baseURI string, subscriptionID string) ServerSecurityAlertPoliciesClient {
+ return ServerSecurityAlertPoliciesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a threat detection policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// parameters - the server security alert policy.
+func (client ServerSecurityAlertPoliciesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters ServerSecurityAlertPolicy) (result ServerSecurityAlertPoliciesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ServerSecurityAlertPoliciesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, parameters ServerSecurityAlertPolicy) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "securityAlertPolicyName": autorest.Encode("path", "Default"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerSecurityAlertPoliciesClient) CreateOrUpdateSender(req *http.Request) (future ServerSecurityAlertPoliciesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client ServerSecurityAlertPoliciesClient) CreateOrUpdateResponder(resp *http.Response) (result ServerSecurityAlertPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get get a server's security alert policy.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerSecurityAlertPoliciesClient) Get(ctx context.Context, resourceGroupName string, serverName string) (result ServerSecurityAlertPolicy, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServerSecurityAlertPoliciesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "securityAlertPolicyName": autorest.Encode("path", "Default"),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies/{securityAlertPolicyName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerSecurityAlertPoliciesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServerSecurityAlertPoliciesClient) GetResponder(resp *http.Response) (result ServerSecurityAlertPolicy, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer get the server's threat detection policies.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerSecurityAlertPoliciesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result LogicalServerSecurityAlertPolicyListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.lssaplr.Response.Response != nil {
+ sc = result.lssaplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.lssaplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.lssaplr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerSecurityAlertPoliciesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2017-03-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/securityAlertPolicies", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerSecurityAlertPoliciesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerSecurityAlertPoliciesClient) ListByServerResponder(resp *http.Response) (result LogicalServerSecurityAlertPolicyListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client ServerSecurityAlertPoliciesClient) listByServerNextResults(ctx context.Context, lastResults LogicalServerSecurityAlertPolicyListResult) (result LogicalServerSecurityAlertPolicyListResult, err error) {
+ req, err := lastResults.logicalServerSecurityAlertPolicyListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerSecurityAlertPoliciesClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ServerSecurityAlertPoliciesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result LogicalServerSecurityAlertPolicyListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerSecurityAlertPoliciesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverusages.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverusages.go
index f2b645822640..65f3fd8d5b43 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverusages.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serverusages.go
@@ -1,121 +1,121 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServerUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type ServerUsagesClient struct {
- BaseClient
-}
-
-// NewServerUsagesClient creates an instance of the ServerUsagesClient client.
-func NewServerUsagesClient(subscriptionID string) ServerUsagesClient {
- return NewServerUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServerUsagesClientWithBaseURI creates an instance of the ServerUsagesClient client.
-func NewServerUsagesClientWithBaseURI(baseURI string, subscriptionID string) ServerUsagesClient {
- return ServerUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByServer returns server usages.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServerUsagesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerUsageListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServerUsagesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServerUsagesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/usages", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServerUsagesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServerUsagesClient) ListByServerResponder(resp *http.Response) (result ServerUsageListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServerUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type ServerUsagesClient struct {
+ BaseClient
+}
+
+// NewServerUsagesClient creates an instance of the ServerUsagesClient client.
+func NewServerUsagesClient(subscriptionID string) ServerUsagesClient {
+ return NewServerUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServerUsagesClientWithBaseURI creates an instance of the ServerUsagesClient client.
+func NewServerUsagesClientWithBaseURI(baseURI string, subscriptionID string) ServerUsagesClient {
+ return ServerUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByServer returns server usages.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServerUsagesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServerUsageListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServerUsagesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServerUsagesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServerUsagesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/usages", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServerUsagesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServerUsagesClient) ListByServerResponder(resp *http.Response) (result ServerUsageListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serviceobjectives.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serviceobjectives.go
index 4ee3c263b7c0..971180b812c7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serviceobjectives.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/serviceobjectives.go
@@ -1,201 +1,201 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServiceObjectivesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ServiceObjectivesClient struct {
- BaseClient
-}
-
-// NewServiceObjectivesClient creates an instance of the ServiceObjectivesClient client.
-func NewServiceObjectivesClient(subscriptionID string) ServiceObjectivesClient {
- return NewServiceObjectivesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServiceObjectivesClientWithBaseURI creates an instance of the ServiceObjectivesClient client.
-func NewServiceObjectivesClientWithBaseURI(baseURI string, subscriptionID string) ServiceObjectivesClient {
- return ServiceObjectivesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a database service objective.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// serviceObjectiveName - the name of the service objective to retrieve.
-func (client ServiceObjectivesClient) Get(ctx context.Context, resourceGroupName string, serverName string, serviceObjectiveName string) (result ServiceObjective, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServiceObjectivesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, serviceObjectiveName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServiceObjectivesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, serviceObjectiveName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "serviceObjectiveName": autorest.Encode("path", serviceObjectiveName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/serviceObjectives/{serviceObjectiveName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServiceObjectivesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServiceObjectivesClient) GetResponder(resp *http.Response) (result ServiceObjective, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer returns database service objectives.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client ServiceObjectivesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServiceObjectiveListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServiceObjectivesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client ServiceObjectivesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/serviceObjectives", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServiceObjectivesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client ServiceObjectivesClient) ListByServerResponder(resp *http.Response) (result ServiceObjectiveListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServiceObjectivesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ServiceObjectivesClient struct {
+ BaseClient
+}
+
+// NewServiceObjectivesClient creates an instance of the ServiceObjectivesClient client.
+func NewServiceObjectivesClient(subscriptionID string) ServiceObjectivesClient {
+ return NewServiceObjectivesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServiceObjectivesClientWithBaseURI creates an instance of the ServiceObjectivesClient client.
+func NewServiceObjectivesClientWithBaseURI(baseURI string, subscriptionID string) ServiceObjectivesClient {
+ return ServiceObjectivesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a database service objective.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// serviceObjectiveName - the name of the service objective to retrieve.
+func (client ServiceObjectivesClient) Get(ctx context.Context, resourceGroupName string, serverName string, serviceObjectiveName string) (result ServiceObjective, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServiceObjectivesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, serviceObjectiveName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServiceObjectivesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, serviceObjectiveName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "serviceObjectiveName": autorest.Encode("path", serviceObjectiveName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/serviceObjectives/{serviceObjectiveName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServiceObjectivesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServiceObjectivesClient) GetResponder(resp *http.Response) (result ServiceObjective, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer returns database service objectives.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client ServiceObjectivesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result ServiceObjectiveListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServiceObjectivesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceObjectivesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client ServiceObjectivesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/serviceObjectives", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServiceObjectivesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client ServiceObjectivesClient) ListByServerResponder(resp *http.Response) (result ServiceObjectiveListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servicetieradvisors.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servicetieradvisors.go
index 4445a988b027..8fc1f2d7ae8a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servicetieradvisors.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/servicetieradvisors.go
@@ -1,205 +1,205 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// ServiceTierAdvisorsClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type ServiceTierAdvisorsClient struct {
- BaseClient
-}
-
-// NewServiceTierAdvisorsClient creates an instance of the ServiceTierAdvisorsClient client.
-func NewServiceTierAdvisorsClient(subscriptionID string) ServiceTierAdvisorsClient {
- return NewServiceTierAdvisorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewServiceTierAdvisorsClientWithBaseURI creates an instance of the ServiceTierAdvisorsClient client.
-func NewServiceTierAdvisorsClientWithBaseURI(baseURI string, subscriptionID string) ServiceTierAdvisorsClient {
- return ServiceTierAdvisorsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a service tier advisor.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of database.
-// serviceTierAdvisorName - the name of service tier advisor.
-func (client ServiceTierAdvisorsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, serviceTierAdvisorName string) (result ServiceTierAdvisor, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServiceTierAdvisorsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, serviceTierAdvisorName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ServiceTierAdvisorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, serviceTierAdvisorName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "serviceTierAdvisorName": autorest.Encode("path", serviceTierAdvisorName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/serviceTierAdvisors/{serviceTierAdvisorName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServiceTierAdvisorsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ServiceTierAdvisorsClient) GetResponder(resp *http.Response) (result ServiceTierAdvisor, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase returns service tier advisors for specified database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of database.
-func (client ServiceTierAdvisorsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ServiceTierAdvisorListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ServiceTierAdvisorsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client ServiceTierAdvisorsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/serviceTierAdvisors", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client ServiceTierAdvisorsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client ServiceTierAdvisorsClient) ListByDatabaseResponder(resp *http.Response) (result ServiceTierAdvisorListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// ServiceTierAdvisorsClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type ServiceTierAdvisorsClient struct {
+ BaseClient
+}
+
+// NewServiceTierAdvisorsClient creates an instance of the ServiceTierAdvisorsClient client.
+func NewServiceTierAdvisorsClient(subscriptionID string) ServiceTierAdvisorsClient {
+ return NewServiceTierAdvisorsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewServiceTierAdvisorsClientWithBaseURI creates an instance of the ServiceTierAdvisorsClient client.
+func NewServiceTierAdvisorsClientWithBaseURI(baseURI string, subscriptionID string) ServiceTierAdvisorsClient {
+ return ServiceTierAdvisorsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a service tier advisor.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of database.
+// serviceTierAdvisorName - the name of service tier advisor.
+func (client ServiceTierAdvisorsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, serviceTierAdvisorName string) (result ServiceTierAdvisor, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServiceTierAdvisorsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, serviceTierAdvisorName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ServiceTierAdvisorsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, serviceTierAdvisorName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "serviceTierAdvisorName": autorest.Encode("path", serviceTierAdvisorName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/serviceTierAdvisors/{serviceTierAdvisorName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServiceTierAdvisorsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ServiceTierAdvisorsClient) GetResponder(resp *http.Response) (result ServiceTierAdvisor, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase returns service tier advisors for specified database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of database.
+func (client ServiceTierAdvisorsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result ServiceTierAdvisorListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ServiceTierAdvisorsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.ServiceTierAdvisorsClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client ServiceTierAdvisorsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/serviceTierAdvisors", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client ServiceTierAdvisorsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client ServiceTierAdvisorsClient) ListByDatabaseResponder(resp *http.Response) (result ServiceTierAdvisorListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sqlapi/interfaces.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sqlapi/interfaces.go
deleted file mode 100644
index a0afc8c62143..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/sqlapi/interfaces.go
+++ /dev/null
@@ -1,637 +0,0 @@
-package sqlapi
-
-// 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 (
- "context"
- "github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/date"
- "github.com/satori/go.uuid"
-)
-
-// BackupLongTermRetentionPoliciesClientAPI contains the set of methods on the BackupLongTermRetentionPoliciesClient type.
-type BackupLongTermRetentionPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.BackupLongTermRetentionPolicy) (result sql.BackupLongTermRetentionPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.BackupLongTermRetentionPolicy, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.BackupLongTermRetentionPolicyListResult, err error)
-}
-
-var _ BackupLongTermRetentionPoliciesClientAPI = (*sql.BackupLongTermRetentionPoliciesClient)(nil)
-
-// BackupLongTermRetentionVaultsClientAPI contains the set of methods on the BackupLongTermRetentionVaultsClient type.
-type BackupLongTermRetentionVaultsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.BackupLongTermRetentionVault) (result sql.BackupLongTermRetentionVaultsCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.BackupLongTermRetentionVault, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.BackupLongTermRetentionVaultListResult, err error)
-}
-
-var _ BackupLongTermRetentionVaultsClientAPI = (*sql.BackupLongTermRetentionVaultsClient)(nil)
-
-// RecoverableDatabasesClientAPI contains the set of methods on the RecoverableDatabasesClient type.
-type RecoverableDatabasesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.RecoverableDatabase, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.RecoverableDatabaseListResult, err error)
-}
-
-var _ RecoverableDatabasesClientAPI = (*sql.RecoverableDatabasesClient)(nil)
-
-// RestorableDroppedDatabasesClientAPI contains the set of methods on the RestorableDroppedDatabasesClient type.
-type RestorableDroppedDatabasesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, restorableDroppededDatabaseID string) (result sql.RestorableDroppedDatabase, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.RestorableDroppedDatabaseListResult, err error)
-}
-
-var _ RestorableDroppedDatabasesClientAPI = (*sql.RestorableDroppedDatabasesClient)(nil)
-
-// CapabilitiesClientAPI contains the set of methods on the CapabilitiesClient type.
-type CapabilitiesClientAPI interface {
- ListByLocation(ctx context.Context, locationID string) (result sql.LocationCapabilities, err error)
-}
-
-var _ CapabilitiesClientAPI = (*sql.CapabilitiesClient)(nil)
-
-// ServersClientAPI contains the set of methods on the ServersClient type.
-type ServersClientAPI interface {
- CheckNameAvailability(ctx context.Context, parameters sql.CheckNameAvailabilityRequest) (result sql.CheckNameAvailabilityResponse, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.Server) (result sql.ServersCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServersDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.Server, err error)
- List(ctx context.Context) (result sql.ServerListResultPage, err error)
- ListByResourceGroup(ctx context.Context, resourceGroupName string) (result sql.ServerListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ServerUpdate) (result sql.ServersUpdateFuture, err error)
-}
-
-var _ ServersClientAPI = (*sql.ServersClient)(nil)
-
-// ServerConnectionPoliciesClientAPI contains the set of methods on the ServerConnectionPoliciesClient type.
-type ServerConnectionPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ServerConnectionPolicy) (result sql.ServerConnectionPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerConnectionPolicy, err error)
-}
-
-var _ ServerConnectionPoliciesClientAPI = (*sql.ServerConnectionPoliciesClient)(nil)
-
-// DatabasesClientAPI contains the set of methods on the DatabasesClient type.
-type DatabasesClientAPI interface {
- CreateImportOperation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.ImportExtensionRequest) (result sql.DatabasesCreateImportOperationFuture, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.Database) (result sql.DatabasesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error)
- Export(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.ExportRequest) (result sql.DatabasesExportFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, expand string) (result sql.Database, err error)
- GetByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, databaseName string) (result sql.Database, err error)
- GetByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string, databaseName string) (result sql.Database, err error)
- Import(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ImportRequest) (result sql.DatabasesImportFuture, err error)
- ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.DatabaseListResult, err error)
- ListByRecommendedElasticPool(ctx context.Context, resourceGroupName string, serverName string, recommendedElasticPoolName string) (result sql.DatabaseListResult, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string, expand string, filter string) (result sql.DatabaseListResult, err error)
- ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.MetricDefinitionListResult, err error)
- ListMetrics(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result sql.MetricListResult, err error)
- Pause(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesPauseFuture, err error)
- Rename(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.ResourceMoveDefinition) (result autorest.Response, err error)
- Resume(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesResumeFuture, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseUpdate) (result sql.DatabasesUpdateFuture, err error)
-}
-
-var _ DatabasesClientAPI = (*sql.DatabasesClient)(nil)
-
-// DatabaseThreatDetectionPoliciesClientAPI contains the set of methods on the DatabaseThreatDetectionPoliciesClient type.
-type DatabaseThreatDetectionPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseSecurityAlertPolicy) (result sql.DatabaseSecurityAlertPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseSecurityAlertPolicy, err error)
-}
-
-var _ DatabaseThreatDetectionPoliciesClientAPI = (*sql.DatabaseThreatDetectionPoliciesClient)(nil)
-
-// DataMaskingPoliciesClientAPI contains the set of methods on the DataMaskingPoliciesClient type.
-type DataMaskingPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DataMaskingPolicy) (result sql.DataMaskingPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DataMaskingPolicy, err error)
-}
-
-var _ DataMaskingPoliciesClientAPI = (*sql.DataMaskingPoliciesClient)(nil)
-
-// DataMaskingRulesClientAPI contains the set of methods on the DataMaskingRulesClient type.
-type DataMaskingRulesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, dataMaskingRuleName string, parameters sql.DataMaskingRule) (result sql.DataMaskingRule, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DataMaskingRuleListResult, err error)
-}
-
-var _ DataMaskingRulesClientAPI = (*sql.DataMaskingRulesClient)(nil)
-
-// ElasticPoolsClientAPI contains the set of methods on the ElasticPoolsClient type.
-type ElasticPoolsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters sql.ElasticPool) (result sql.ElasticPoolsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPool, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ElasticPoolListResult, err error)
- ListMetricDefinitions(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.MetricDefinitionListResult, err error)
- ListMetrics(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, filter string) (result sql.MetricListResult, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters sql.ElasticPoolUpdate) (result sql.ElasticPoolsUpdateFuture, err error)
-}
-
-var _ ElasticPoolsClientAPI = (*sql.ElasticPoolsClient)(nil)
-
-// FirewallRulesClientAPI contains the set of methods on the FirewallRulesClient type.
-type FirewallRulesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string, parameters sql.FirewallRule) (result sql.FirewallRule, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, firewallRuleName string) (result sql.FirewallRule, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.FirewallRuleListResult, err error)
-}
-
-var _ FirewallRulesClientAPI = (*sql.FirewallRulesClient)(nil)
-
-// GeoBackupPoliciesClientAPI contains the set of methods on the GeoBackupPoliciesClient type.
-type GeoBackupPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.GeoBackupPolicy) (result sql.GeoBackupPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.GeoBackupPolicy, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.GeoBackupPolicyListResult, err error)
-}
-
-var _ GeoBackupPoliciesClientAPI = (*sql.GeoBackupPoliciesClient)(nil)
-
-// ReplicationLinksClientAPI contains the set of methods on the ReplicationLinksClient type.
-type ReplicationLinksClientAPI interface {
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result autorest.Response, err error)
- Failover(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result sql.ReplicationLinksFailoverFuture, err error)
- FailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result sql.ReplicationLinksFailoverAllowDataLossFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, linkID string) (result sql.ReplicationLink, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.ReplicationLinkListResult, err error)
-}
-
-var _ ReplicationLinksClientAPI = (*sql.ReplicationLinksClient)(nil)
-
-// ServerAzureADAdministratorsClientAPI contains the set of methods on the ServerAzureADAdministratorsClient type.
-type ServerAzureADAdministratorsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, properties sql.ServerAzureADAdministrator) (result sql.ServerAzureADAdministratorsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerAzureADAdministratorsDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerAzureADAdministrator, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerAdministratorListResult, err error)
-}
-
-var _ ServerAzureADAdministratorsClientAPI = (*sql.ServerAzureADAdministratorsClient)(nil)
-
-// ServerCommunicationLinksClientAPI contains the set of methods on the ServerCommunicationLinksClient type.
-type ServerCommunicationLinksClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string, parameters sql.ServerCommunicationLink) (result sql.ServerCommunicationLinksCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, communicationLinkName string) (result sql.ServerCommunicationLink, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerCommunicationLinkListResult, err error)
-}
-
-var _ ServerCommunicationLinksClientAPI = (*sql.ServerCommunicationLinksClient)(nil)
-
-// ServiceObjectivesClientAPI contains the set of methods on the ServiceObjectivesClient type.
-type ServiceObjectivesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, serviceObjectiveName string) (result sql.ServiceObjective, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServiceObjectiveListResult, err error)
-}
-
-var _ ServiceObjectivesClientAPI = (*sql.ServiceObjectivesClient)(nil)
-
-// ElasticPoolActivitiesClientAPI contains the set of methods on the ElasticPoolActivitiesClient type.
-type ElasticPoolActivitiesClientAPI interface {
- ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPoolActivityListResult, err error)
-}
-
-var _ ElasticPoolActivitiesClientAPI = (*sql.ElasticPoolActivitiesClient)(nil)
-
-// ElasticPoolDatabaseActivitiesClientAPI contains the set of methods on the ElasticPoolDatabaseActivitiesClient type.
-type ElasticPoolDatabaseActivitiesClientAPI interface {
- ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPoolDatabaseActivityListResult, err error)
-}
-
-var _ ElasticPoolDatabaseActivitiesClientAPI = (*sql.ElasticPoolDatabaseActivitiesClient)(nil)
-
-// ServiceTierAdvisorsClientAPI contains the set of methods on the ServiceTierAdvisorsClient type.
-type ServiceTierAdvisorsClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, serviceTierAdvisorName string) (result sql.ServiceTierAdvisor, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.ServiceTierAdvisorListResult, err error)
-}
-
-var _ ServiceTierAdvisorsClientAPI = (*sql.ServiceTierAdvisorsClient)(nil)
-
-// TransparentDataEncryptionsClientAPI contains the set of methods on the TransparentDataEncryptionsClient type.
-type TransparentDataEncryptionsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.TransparentDataEncryption) (result sql.TransparentDataEncryption, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.TransparentDataEncryption, err error)
-}
-
-var _ TransparentDataEncryptionsClientAPI = (*sql.TransparentDataEncryptionsClient)(nil)
-
-// TransparentDataEncryptionActivitiesClientAPI contains the set of methods on the TransparentDataEncryptionActivitiesClient type.
-type TransparentDataEncryptionActivitiesClientAPI interface {
- ListByConfiguration(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.TransparentDataEncryptionActivityListResult, err error)
-}
-
-var _ TransparentDataEncryptionActivitiesClientAPI = (*sql.TransparentDataEncryptionActivitiesClient)(nil)
-
-// ServerUsagesClientAPI contains the set of methods on the ServerUsagesClient type.
-type ServerUsagesClientAPI interface {
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerUsageListResult, err error)
-}
-
-var _ ServerUsagesClientAPI = (*sql.ServerUsagesClient)(nil)
-
-// DatabaseUsagesClientAPI contains the set of methods on the DatabaseUsagesClient type.
-type DatabaseUsagesClientAPI interface {
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseUsageListResult, err error)
-}
-
-var _ DatabaseUsagesClientAPI = (*sql.DatabaseUsagesClient)(nil)
-
-// DatabaseAutomaticTuningClientAPI contains the set of methods on the DatabaseAutomaticTuningClient type.
-type DatabaseAutomaticTuningClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseAutomaticTuning, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseAutomaticTuning) (result sql.DatabaseAutomaticTuning, err error)
-}
-
-var _ DatabaseAutomaticTuningClientAPI = (*sql.DatabaseAutomaticTuningClient)(nil)
-
-// EncryptionProtectorsClientAPI contains the set of methods on the EncryptionProtectorsClient type.
-type EncryptionProtectorsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.EncryptionProtector) (result sql.EncryptionProtectorsCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.EncryptionProtector, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.EncryptionProtectorListResultPage, err error)
- Revalidate(ctx context.Context, resourceGroupName string, serverName string) (result sql.EncryptionProtectorsRevalidateFuture, err error)
-}
-
-var _ EncryptionProtectorsClientAPI = (*sql.EncryptionProtectorsClient)(nil)
-
-// FailoverGroupsClientAPI contains the set of methods on the FailoverGroupsClient type.
-type FailoverGroupsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters sql.FailoverGroup) (result sql.FailoverGroupsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result sql.FailoverGroupsDeleteFuture, err error)
- Failover(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result sql.FailoverGroupsFailoverFuture, err error)
- ForceFailoverAllowDataLoss(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result sql.FailoverGroupsForceFailoverAllowDataLossFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string) (result sql.FailoverGroup, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.FailoverGroupListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, failoverGroupName string, parameters sql.FailoverGroupUpdate) (result sql.FailoverGroupsUpdateFuture, err error)
-}
-
-var _ FailoverGroupsClientAPI = (*sql.FailoverGroupsClient)(nil)
-
-// ManagedInstancesClientAPI contains the set of methods on the ManagedInstancesClient type.
-type ManagedInstancesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters sql.ManagedInstance) (result sql.ManagedInstancesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstancesDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstance, err error)
- List(ctx context.Context) (result sql.ManagedInstanceListResultPage, err error)
- ListByResourceGroup(ctx context.Context, resourceGroupName string) (result sql.ManagedInstanceListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters sql.ManagedInstanceUpdate) (result sql.ManagedInstancesUpdateFuture, err error)
-}
-
-var _ ManagedInstancesClientAPI = (*sql.ManagedInstancesClient)(nil)
-
-// OperationsClientAPI contains the set of methods on the OperationsClient type.
-type OperationsClientAPI interface {
- List(ctx context.Context) (result sql.OperationListResultPage, err error)
-}
-
-var _ OperationsClientAPI = (*sql.OperationsClient)(nil)
-
-// ServerKeysClientAPI contains the set of methods on the ServerKeysClient type.
-type ServerKeysClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, keyName string, parameters sql.ServerKey) (result sql.ServerKeysCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result sql.ServerKeysDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, keyName string) (result sql.ServerKey, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerKeyListResultPage, err error)
-}
-
-var _ ServerKeysClientAPI = (*sql.ServerKeysClient)(nil)
-
-// SyncAgentsClientAPI contains the set of methods on the SyncAgentsClient type.
-type SyncAgentsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string, parameters sql.SyncAgent) (result sql.SyncAgentsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result sql.SyncAgentsDeleteFuture, err error)
- GenerateKey(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result sql.SyncAgentKeyProperties, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result sql.SyncAgent, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.SyncAgentListResultPage, err error)
- ListLinkedDatabases(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result sql.SyncAgentLinkedDatabaseListResultPage, err error)
-}
-
-var _ SyncAgentsClientAPI = (*sql.SyncAgentsClient)(nil)
-
-// SyncGroupsClientAPI contains the set of methods on the SyncGroupsClient type.
-type SyncGroupsClientAPI interface {
- CancelSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters sql.SyncGroup) (result sql.SyncGroupsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result sql.SyncGroupsDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result sql.SyncGroup, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.SyncGroupListResultPage, err error)
- ListHubSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result sql.SyncFullSchemaPropertiesListResultPage, err error)
- ListLogs(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (result sql.SyncGroupLogListResultPage, err error)
- ListSyncDatabaseIds(ctx context.Context, locationName string) (result sql.SyncDatabaseIDListResultPage, err error)
- RefreshHubSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result sql.SyncGroupsRefreshHubSchemaFuture, err error)
- TriggerSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters sql.SyncGroup) (result sql.SyncGroupsUpdateFuture, err error)
-}
-
-var _ SyncGroupsClientAPI = (*sql.SyncGroupsClient)(nil)
-
-// SyncMembersClientAPI contains the set of methods on the SyncMembersClient type.
-type SyncMembersClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters sql.SyncMember) (result sql.SyncMembersCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result sql.SyncMembersDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result sql.SyncMember, err error)
- ListBySyncGroup(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result sql.SyncMemberListResultPage, err error)
- ListMemberSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result sql.SyncFullSchemaPropertiesListResultPage, err error)
- RefreshMemberSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result sql.SyncMembersRefreshMemberSchemaFuture, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters sql.SyncMember) (result sql.SyncMembersUpdateFuture, err error)
-}
-
-var _ SyncMembersClientAPI = (*sql.SyncMembersClient)(nil)
-
-// SubscriptionUsagesClientAPI contains the set of methods on the SubscriptionUsagesClient type.
-type SubscriptionUsagesClientAPI interface {
- Get(ctx context.Context, locationName string, usageName string) (result sql.SubscriptionUsage, err error)
- ListByLocation(ctx context.Context, locationName string) (result sql.SubscriptionUsageListResultPage, err error)
-}
-
-var _ SubscriptionUsagesClientAPI = (*sql.SubscriptionUsagesClient)(nil)
-
-// VirtualClustersClientAPI contains the set of methods on the VirtualClustersClient type.
-type VirtualClustersClientAPI interface {
- Delete(ctx context.Context, resourceGroupName string, virtualClusterName string) (result sql.VirtualClustersDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, virtualClusterName string) (result sql.VirtualCluster, err error)
- List(ctx context.Context) (result sql.VirtualClusterListResultPage, err error)
- ListByResourceGroup(ctx context.Context, resourceGroupName string) (result sql.VirtualClusterListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, virtualClusterName string, parameters sql.VirtualClusterUpdate) (result sql.VirtualClustersUpdateFuture, err error)
-}
-
-var _ VirtualClustersClientAPI = (*sql.VirtualClustersClient)(nil)
-
-// ExtendedDatabaseBlobAuditingPoliciesClientAPI contains the set of methods on the ExtendedDatabaseBlobAuditingPoliciesClient type.
-type ExtendedDatabaseBlobAuditingPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.ExtendedDatabaseBlobAuditingPolicy) (result sql.ExtendedDatabaseBlobAuditingPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.ExtendedDatabaseBlobAuditingPolicy, err error)
-}
-
-var _ ExtendedDatabaseBlobAuditingPoliciesClientAPI = (*sql.ExtendedDatabaseBlobAuditingPoliciesClient)(nil)
-
-// ExtendedServerBlobAuditingPoliciesClientAPI contains the set of methods on the ExtendedServerBlobAuditingPoliciesClient type.
-type ExtendedServerBlobAuditingPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ExtendedServerBlobAuditingPolicy) (result sql.ExtendedServerBlobAuditingPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ExtendedServerBlobAuditingPolicy, err error)
-}
-
-var _ ExtendedServerBlobAuditingPoliciesClientAPI = (*sql.ExtendedServerBlobAuditingPoliciesClient)(nil)
-
-// ServerBlobAuditingPoliciesClientAPI contains the set of methods on the ServerBlobAuditingPoliciesClient type.
-type ServerBlobAuditingPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ServerBlobAuditingPolicy) (result sql.ServerBlobAuditingPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerBlobAuditingPolicy, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerBlobAuditingPolicyListResultPage, err error)
-}
-
-var _ ServerBlobAuditingPoliciesClientAPI = (*sql.ServerBlobAuditingPoliciesClient)(nil)
-
-// DatabaseBlobAuditingPoliciesClientAPI contains the set of methods on the DatabaseBlobAuditingPoliciesClient type.
-type DatabaseBlobAuditingPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseBlobAuditingPolicy) (result sql.DatabaseBlobAuditingPolicy, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseBlobAuditingPolicy, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseBlobAuditingPolicyListResultPage, err error)
-}
-
-var _ DatabaseBlobAuditingPoliciesClientAPI = (*sql.DatabaseBlobAuditingPoliciesClient)(nil)
-
-// DatabaseVulnerabilityAssessmentRuleBaselinesClientAPI contains the set of methods on the DatabaseVulnerabilityAssessmentRuleBaselinesClient type.
-type DatabaseVulnerabilityAssessmentRuleBaselinesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName, parameters sql.DatabaseVulnerabilityAssessmentRuleBaseline) (result sql.DatabaseVulnerabilityAssessmentRuleBaseline, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName) (result sql.DatabaseVulnerabilityAssessmentRuleBaseline, err error)
-}
-
-var _ DatabaseVulnerabilityAssessmentRuleBaselinesClientAPI = (*sql.DatabaseVulnerabilityAssessmentRuleBaselinesClient)(nil)
-
-// DatabaseVulnerabilityAssessmentsClientAPI contains the set of methods on the DatabaseVulnerabilityAssessmentsClient type.
-type DatabaseVulnerabilityAssessmentsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseVulnerabilityAssessment) (result sql.DatabaseVulnerabilityAssessment, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseVulnerabilityAssessment, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseVulnerabilityAssessmentListResultPage, err error)
-}
-
-var _ DatabaseVulnerabilityAssessmentsClientAPI = (*sql.DatabaseVulnerabilityAssessmentsClient)(nil)
-
-// VirtualNetworkRulesClientAPI contains the set of methods on the VirtualNetworkRulesClient type.
-type VirtualNetworkRulesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string, parameters sql.VirtualNetworkRule) (result sql.VirtualNetworkRulesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result sql.VirtualNetworkRulesDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result sql.VirtualNetworkRule, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.VirtualNetworkRuleListResultPage, err error)
-}
-
-var _ VirtualNetworkRulesClientAPI = (*sql.VirtualNetworkRulesClient)(nil)
-
-// DatabaseOperationsClientAPI contains the set of methods on the DatabaseOperationsClient type.
-type DatabaseOperationsClientAPI interface {
- Cancel(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (result autorest.Response, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseOperationListResultPage, err error)
-}
-
-var _ DatabaseOperationsClientAPI = (*sql.DatabaseOperationsClient)(nil)
-
-// DataWarehouseUserActivitiesClientAPI contains the set of methods on the DataWarehouseUserActivitiesClient type.
-type DataWarehouseUserActivitiesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DataWarehouseUserActivities, err error)
-}
-
-var _ DataWarehouseUserActivitiesClientAPI = (*sql.DataWarehouseUserActivitiesClient)(nil)
-
-// JobAgentsClientAPI contains the set of methods on the JobAgentsClient type.
-type JobAgentsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters sql.JobAgent) (result sql.JobAgentsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result sql.JobAgentsDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result sql.JobAgent, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.JobAgentListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, parameters sql.JobAgentUpdate) (result sql.JobAgentsUpdateFuture, err error)
-}
-
-var _ JobAgentsClientAPI = (*sql.JobAgentsClient)(nil)
-
-// JobCredentialsClientAPI contains the set of methods on the JobCredentialsClient type.
-type JobCredentialsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string, parameters sql.JobCredential) (result sql.JobCredential, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, credentialName string) (result sql.JobCredential, err error)
- ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result sql.JobCredentialListResultPage, err error)
-}
-
-var _ JobCredentialsClientAPI = (*sql.JobCredentialsClient)(nil)
-
-// JobExecutionsClientAPI contains the set of methods on the JobExecutionsClient type.
-type JobExecutionsClientAPI interface {
- Cancel(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result autorest.Response, err error)
- Create(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result sql.JobExecutionsCreateFuture, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result sql.JobExecutionsCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID) (result sql.JobExecution, err error)
- ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result sql.JobExecutionListResultPage, err error)
- ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result sql.JobExecutionListResultPage, err error)
-}
-
-var _ JobExecutionsClientAPI = (*sql.JobExecutionsClient)(nil)
-
-// JobsClientAPI contains the set of methods on the JobsClient type.
-type JobsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, parameters sql.Job) (result sql.Job, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result sql.Job, err error)
- ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result sql.JobListResultPage, err error)
-}
-
-var _ JobsClientAPI = (*sql.JobsClient)(nil)
-
-// JobStepExecutionsClientAPI contains the set of methods on the JobStepExecutionsClient type.
-type JobStepExecutionsClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string) (result sql.JobExecution, err error)
- ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result sql.JobExecutionListResultPage, err error)
-}
-
-var _ JobStepExecutionsClientAPI = (*sql.JobStepExecutionsClient)(nil)
-
-// JobStepsClientAPI contains the set of methods on the JobStepsClient type.
-type JobStepsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string, parameters sql.JobStep) (result sql.JobStep, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, stepName string) (result sql.JobStep, err error)
- GetByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32, stepName string) (result sql.JobStep, err error)
- ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result sql.JobStepListResultPage, err error)
- ListByVersion(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result sql.JobStepListResultPage, err error)
-}
-
-var _ JobStepsClientAPI = (*sql.JobStepsClient)(nil)
-
-// JobTargetExecutionsClientAPI contains the set of methods on the JobTargetExecutionsClient type.
-type JobTargetExecutionsClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, targetID uuid.UUID) (result sql.JobExecution, err error)
- ListByJobExecution(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result sql.JobExecutionListResultPage, err error)
- ListByStep(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobExecutionID uuid.UUID, stepName string, createTimeMin *date.Time, createTimeMax *date.Time, endTimeMin *date.Time, endTimeMax *date.Time, isActive *bool, skip *int32, top *int32) (result sql.JobExecutionListResultPage, err error)
-}
-
-var _ JobTargetExecutionsClientAPI = (*sql.JobTargetExecutionsClient)(nil)
-
-// JobTargetGroupsClientAPI contains the set of methods on the JobTargetGroupsClient type.
-type JobTargetGroupsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string, parameters sql.JobTargetGroup) (result sql.JobTargetGroup, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, targetGroupName string) (result sql.JobTargetGroup, err error)
- ListByAgent(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string) (result sql.JobTargetGroupListResultPage, err error)
-}
-
-var _ JobTargetGroupsClientAPI = (*sql.JobTargetGroupsClient)(nil)
-
-// JobVersionsClientAPI contains the set of methods on the JobVersionsClient type.
-type JobVersionsClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string, jobVersion int32) (result sql.JobVersion, err error)
- ListByJob(ctx context.Context, resourceGroupName string, serverName string, jobAgentName string, jobName string) (result sql.JobVersionListResultPage, err error)
-}
-
-var _ JobVersionsClientAPI = (*sql.JobVersionsClient)(nil)
-
-// ManagedBackupShortTermRetentionPoliciesClientAPI contains the set of methods on the ManagedBackupShortTermRetentionPoliciesClient type.
-type ManagedBackupShortTermRetentionPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters sql.ManagedBackupShortTermRetentionPolicy) (result sql.ManagedBackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.ManagedBackupShortTermRetentionPolicy, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.ManagedBackupShortTermRetentionPolicyListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters sql.ManagedBackupShortTermRetentionPolicy) (result sql.ManagedBackupShortTermRetentionPoliciesUpdateFuture, err error)
-}
-
-var _ ManagedBackupShortTermRetentionPoliciesClientAPI = (*sql.ManagedBackupShortTermRetentionPoliciesClient)(nil)
-
-// ManagedDatabasesClientAPI contains the set of methods on the ManagedDatabasesClient type.
-type ManagedDatabasesClientAPI interface {
- CompleteRestore(ctx context.Context, locationName string, operationID uuid.UUID, parameters sql.CompleteDatabaseRestoreDefinition) (result sql.ManagedDatabasesCompleteRestoreFuture, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters sql.ManagedDatabase) (result sql.ManagedDatabasesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.ManagedDatabasesDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.ManagedDatabase, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedDatabaseListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters sql.ManagedDatabaseUpdate) (result sql.ManagedDatabasesUpdateFuture, err error)
-}
-
-var _ ManagedDatabasesClientAPI = (*sql.ManagedDatabasesClient)(nil)
-
-// SensitivityLabelsClientAPI contains the set of methods on the SensitivityLabelsClient type.
-type SensitivityLabelsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, parameters sql.SensitivityLabel) (result sql.SensitivityLabel, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error)
- DisableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error)
- EnableRecommendation(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, schemaName string, tableName string, columnName string, sensitivityLabelSource sql.SensitivityLabelSource) (result sql.SensitivityLabel, err error)
- ListCurrentByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, filter string) (result sql.SensitivityLabelListResultPage, err error)
- ListRecommendedByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string, includeDisabledRecommendations *bool, skipToken string, filter string) (result sql.SensitivityLabelListResultPage, err error)
-}
-
-var _ SensitivityLabelsClientAPI = (*sql.SensitivityLabelsClient)(nil)
-
-// ManagedInstanceAdministratorsClientAPI contains the set of methods on the ManagedInstanceAdministratorsClient type.
-type ManagedInstanceAdministratorsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string, parameters sql.ManagedInstanceAdministrator) (result sql.ManagedInstanceAdministratorsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result sql.ManagedInstanceAdministratorsDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, administratorName string) (result sql.ManagedInstanceAdministrator, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstanceAdministratorListResultPage, err error)
-}
-
-var _ ManagedInstanceAdministratorsClientAPI = (*sql.ManagedInstanceAdministratorsClient)(nil)
-
-// ServerAutomaticTuningClientAPI contains the set of methods on the ServerAutomaticTuningClient type.
-type ServerAutomaticTuningClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerAutomaticTuning, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ServerAutomaticTuning) (result sql.ServerAutomaticTuning, err error)
-}
-
-var _ ServerAutomaticTuningClientAPI = (*sql.ServerAutomaticTuningClient)(nil)
-
-// ServerDNSAliasesClientAPI contains the set of methods on the ServerDNSAliasesClient type.
-type ServerDNSAliasesClientAPI interface {
- Acquire(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string, parameters sql.ServerDNSAliasAcquisition) (result sql.ServerDNSAliasesAcquireFuture, err error)
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result sql.ServerDNSAliasesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result sql.ServerDNSAliasesDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, DNSAliasName string) (result sql.ServerDNSAlias, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerDNSAliasListResultPage, err error)
-}
-
-var _ ServerDNSAliasesClientAPI = (*sql.ServerDNSAliasesClient)(nil)
-
-// ServerSecurityAlertPoliciesClientAPI contains the set of methods on the ServerSecurityAlertPoliciesClient type.
-type ServerSecurityAlertPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, parameters sql.ServerSecurityAlertPolicy) (result sql.ServerSecurityAlertPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string) (result sql.ServerSecurityAlertPolicy, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.LogicalServerSecurityAlertPolicyListResultPage, err error)
-}
-
-var _ ServerSecurityAlertPoliciesClientAPI = (*sql.ServerSecurityAlertPoliciesClient)(nil)
-
-// RestorableDroppedManagedDatabasesClientAPI contains the set of methods on the RestorableDroppedManagedDatabasesClient type.
-type RestorableDroppedManagedDatabasesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, restorableDroppedDatabaseID string) (result sql.RestorableDroppedManagedDatabase, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.RestorableDroppedManagedDatabaseListResultPage, err error)
-}
-
-var _ RestorableDroppedManagedDatabasesClientAPI = (*sql.RestorableDroppedManagedDatabasesClient)(nil)
-
-// RestorePointsClientAPI contains the set of methods on the RestorePointsClient type.
-type RestorePointsClientAPI interface {
- Create(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.CreateDatabaseRestorePointDefinition) (result sql.RestorePointsCreateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, restorePointName string) (result sql.RestorePoint, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.RestorePointListResult, err error)
-}
-
-var _ RestorePointsClientAPI = (*sql.RestorePointsClient)(nil)
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/subscriptionusages.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/subscriptionusages.go
index c30a81964a9c..05a7a1840a7a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/subscriptionusages.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/subscriptionusages.go
@@ -1,233 +1,233 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// SubscriptionUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type SubscriptionUsagesClient struct {
- BaseClient
-}
-
-// NewSubscriptionUsagesClient creates an instance of the SubscriptionUsagesClient client.
-func NewSubscriptionUsagesClient(subscriptionID string) SubscriptionUsagesClient {
- return NewSubscriptionUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewSubscriptionUsagesClientWithBaseURI creates an instance of the SubscriptionUsagesClient client.
-func NewSubscriptionUsagesClientWithBaseURI(baseURI string, subscriptionID string) SubscriptionUsagesClient {
- return SubscriptionUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Get gets a subscription usage metric.
-// Parameters:
-// locationName - the name of the region where the resource is located.
-// usageName - name of usage metric to return.
-func (client SubscriptionUsagesClient) Get(ctx context.Context, locationName string, usageName string) (result SubscriptionUsage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, locationName, usageName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client SubscriptionUsagesClient) GetPreparer(ctx context.Context, locationName string, usageName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "locationName": autorest.Encode("path", locationName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "usageName": autorest.Encode("path", usageName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/usages/{usageName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client SubscriptionUsagesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client SubscriptionUsagesClient) GetResponder(resp *http.Response) (result SubscriptionUsage, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByLocation gets all subscription usage metrics in a given location.
-// Parameters:
-// locationName - the name of the region where the resource is located.
-func (client SubscriptionUsagesClient) ListByLocation(ctx context.Context, locationName string) (result SubscriptionUsageListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.ListByLocation")
- defer func() {
- sc := -1
- if result.sulr.Response.Response != nil {
- sc = result.sulr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByLocationNextResults
- req, err := client.ListByLocationPreparer(ctx, locationName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByLocationSender(req)
- if err != nil {
- result.sulr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", resp, "Failure sending request")
- return
- }
-
- result.sulr, err = client.ListByLocationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByLocationPreparer prepares the ListByLocation request.
-func (client SubscriptionUsagesClient) ListByLocationPreparer(ctx context.Context, locationName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "locationName": autorest.Encode("path", locationName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/usages", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByLocationSender sends the ListByLocation request. The method will close the
-// http.Response Body if it receives an error.
-func (client SubscriptionUsagesClient) ListByLocationSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByLocationResponder handles the response to the ListByLocation request. The method always
-// closes the http.Response Body.
-func (client SubscriptionUsagesClient) ListByLocationResponder(resp *http.Response) (result SubscriptionUsageListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByLocationNextResults retrieves the next set of results, if any.
-func (client SubscriptionUsagesClient) listByLocationNextResults(ctx context.Context, lastResults SubscriptionUsageListResult) (result SubscriptionUsageListResult, err error) {
- req, err := lastResults.subscriptionUsageListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByLocationSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByLocationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByLocationComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SubscriptionUsagesClient) ListByLocationComplete(ctx context.Context, locationName string) (result SubscriptionUsageListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.ListByLocation")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByLocation(ctx, locationName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// SubscriptionUsagesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type SubscriptionUsagesClient struct {
+ BaseClient
+}
+
+// NewSubscriptionUsagesClient creates an instance of the SubscriptionUsagesClient client.
+func NewSubscriptionUsagesClient(subscriptionID string) SubscriptionUsagesClient {
+ return NewSubscriptionUsagesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewSubscriptionUsagesClientWithBaseURI creates an instance of the SubscriptionUsagesClient client.
+func NewSubscriptionUsagesClientWithBaseURI(baseURI string, subscriptionID string) SubscriptionUsagesClient {
+ return SubscriptionUsagesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Get gets a subscription usage metric.
+// Parameters:
+// locationName - the name of the region where the resource is located.
+// usageName - name of usage metric to return.
+func (client SubscriptionUsagesClient) Get(ctx context.Context, locationName string, usageName string) (result SubscriptionUsage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, locationName, usageName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client SubscriptionUsagesClient) GetPreparer(ctx context.Context, locationName string, usageName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "locationName": autorest.Encode("path", locationName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "usageName": autorest.Encode("path", usageName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/usages/{usageName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client SubscriptionUsagesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client SubscriptionUsagesClient) GetResponder(resp *http.Response) (result SubscriptionUsage, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByLocation gets all subscription usage metrics in a given location.
+// Parameters:
+// locationName - the name of the region where the resource is located.
+func (client SubscriptionUsagesClient) ListByLocation(ctx context.Context, locationName string) (result SubscriptionUsageListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.ListByLocation")
+ defer func() {
+ sc := -1
+ if result.sulr.Response.Response != nil {
+ sc = result.sulr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByLocationNextResults
+ req, err := client.ListByLocationPreparer(ctx, locationName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByLocationSender(req)
+ if err != nil {
+ result.sulr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", resp, "Failure sending request")
+ return
+ }
+
+ result.sulr, err = client.ListByLocationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "ListByLocation", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByLocationPreparer prepares the ListByLocation request.
+func (client SubscriptionUsagesClient) ListByLocationPreparer(ctx context.Context, locationName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "locationName": autorest.Encode("path", locationName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/usages", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByLocationSender sends the ListByLocation request. The method will close the
+// http.Response Body if it receives an error.
+func (client SubscriptionUsagesClient) ListByLocationSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByLocationResponder handles the response to the ListByLocation request. The method always
+// closes the http.Response Body.
+func (client SubscriptionUsagesClient) ListByLocationResponder(resp *http.Response) (result SubscriptionUsageListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByLocationNextResults retrieves the next set of results, if any.
+func (client SubscriptionUsagesClient) listByLocationNextResults(ctx context.Context, lastResults SubscriptionUsageListResult) (result SubscriptionUsageListResult, err error) {
+ req, err := lastResults.subscriptionUsageListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByLocationSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByLocationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SubscriptionUsagesClient", "listByLocationNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByLocationComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SubscriptionUsagesClient) ListByLocationComplete(ctx context.Context, locationName string) (result SubscriptionUsageListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SubscriptionUsagesClient.ListByLocation")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByLocation(ctx, locationName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncagents.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncagents.go
index 8e007853ab33..83d69dca7838 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncagents.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncagents.go
@@ -1,599 +1,599 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// SyncAgentsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type SyncAgentsClient struct {
- BaseClient
-}
-
-// NewSyncAgentsClient creates an instance of the SyncAgentsClient client.
-func NewSyncAgentsClient(subscriptionID string) SyncAgentsClient {
- return NewSyncAgentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewSyncAgentsClientWithBaseURI creates an instance of the SyncAgentsClient client.
-func NewSyncAgentsClientWithBaseURI(baseURI string, subscriptionID string) SyncAgentsClient {
- return SyncAgentsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a sync agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-// syncAgentName - the name of the sync agent.
-// parameters - the requested sync agent resource state.
-func (client SyncAgentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string, parameters SyncAgent) (result SyncAgentsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, syncAgentName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client SyncAgentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string, parameters SyncAgent) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncAgentName": autorest.Encode("path", syncAgentName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) CreateOrUpdateSender(req *http.Request) (future SyncAgentsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) CreateOrUpdateResponder(resp *http.Response) (result SyncAgent, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a sync agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-// syncAgentName - the name of the sync agent.
-func (client SyncAgentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, syncAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client SyncAgentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncAgentName": autorest.Encode("path", syncAgentName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) DeleteSender(req *http.Request) (future SyncAgentsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// GenerateKey generates a sync agent key.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-// syncAgentName - the name of the sync agent.
-func (client SyncAgentsClient) GenerateKey(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentKeyProperties, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.GenerateKey")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GenerateKeyPreparer(ctx, resourceGroupName, serverName, syncAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GenerateKeySender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", resp, "Failure sending request")
- return
- }
-
- result, err = client.GenerateKeyResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GenerateKeyPreparer prepares the GenerateKey request.
-func (client SyncAgentsClient) GenerateKeyPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncAgentName": autorest.Encode("path", syncAgentName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}/generateKey", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GenerateKeySender sends the GenerateKey request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) GenerateKeySender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GenerateKeyResponder handles the response to the GenerateKey request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) GenerateKeyResponder(resp *http.Response) (result SyncAgentKeyProperties, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a sync agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-// syncAgentName - the name of the sync agent.
-func (client SyncAgentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgent, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, syncAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client SyncAgentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncAgentName": autorest.Encode("path", syncAgentName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) GetResponder(resp *http.Response) (result SyncAgent, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer lists sync agents in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-func (client SyncAgentsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result SyncAgentListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListByServer")
- defer func() {
- sc := -1
- if result.salr.Response.Response != nil {
- sc = result.salr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.salr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.salr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client SyncAgentsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) ListByServerResponder(resp *http.Response) (result SyncAgentListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client SyncAgentsClient) listByServerNextResults(ctx context.Context, lastResults SyncAgentListResult) (result SyncAgentListResult, err error) {
- req, err := lastResults.syncAgentListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncAgentsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result SyncAgentListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
-
-// ListLinkedDatabases lists databases linked to a sync agent.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server on which the sync agent is hosted.
-// syncAgentName - the name of the sync agent.
-func (client SyncAgentsClient) ListLinkedDatabases(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentLinkedDatabaseListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListLinkedDatabases")
- defer func() {
- sc := -1
- if result.saldlr.Response.Response != nil {
- sc = result.saldlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listLinkedDatabasesNextResults
- req, err := client.ListLinkedDatabasesPreparer(ctx, resourceGroupName, serverName, syncAgentName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListLinkedDatabasesSender(req)
- if err != nil {
- result.saldlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", resp, "Failure sending request")
- return
- }
-
- result.saldlr, err = client.ListLinkedDatabasesResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListLinkedDatabasesPreparer prepares the ListLinkedDatabases request.
-func (client SyncAgentsClient) ListLinkedDatabasesPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncAgentName": autorest.Encode("path", syncAgentName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}/linkedDatabases", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListLinkedDatabasesSender sends the ListLinkedDatabases request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncAgentsClient) ListLinkedDatabasesSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListLinkedDatabasesResponder handles the response to the ListLinkedDatabases request. The method always
-// closes the http.Response Body.
-func (client SyncAgentsClient) ListLinkedDatabasesResponder(resp *http.Response) (result SyncAgentLinkedDatabaseListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listLinkedDatabasesNextResults retrieves the next set of results, if any.
-func (client SyncAgentsClient) listLinkedDatabasesNextResults(ctx context.Context, lastResults SyncAgentLinkedDatabaseListResult) (result SyncAgentLinkedDatabaseListResult, err error) {
- req, err := lastResults.syncAgentLinkedDatabaseListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListLinkedDatabasesSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListLinkedDatabasesResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListLinkedDatabasesComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncAgentsClient) ListLinkedDatabasesComplete(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentLinkedDatabaseListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListLinkedDatabases")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListLinkedDatabases(ctx, resourceGroupName, serverName, syncAgentName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// SyncAgentsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type SyncAgentsClient struct {
+ BaseClient
+}
+
+// NewSyncAgentsClient creates an instance of the SyncAgentsClient client.
+func NewSyncAgentsClient(subscriptionID string) SyncAgentsClient {
+ return NewSyncAgentsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewSyncAgentsClientWithBaseURI creates an instance of the SyncAgentsClient client.
+func NewSyncAgentsClientWithBaseURI(baseURI string, subscriptionID string) SyncAgentsClient {
+ return SyncAgentsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a sync agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+// syncAgentName - the name of the sync agent.
+// parameters - the requested sync agent resource state.
+func (client SyncAgentsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string, parameters SyncAgent) (result SyncAgentsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, syncAgentName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client SyncAgentsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string, parameters SyncAgent) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncAgentName": autorest.Encode("path", syncAgentName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) CreateOrUpdateSender(req *http.Request) (future SyncAgentsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) CreateOrUpdateResponder(resp *http.Response) (result SyncAgent, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a sync agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+// syncAgentName - the name of the sync agent.
+func (client SyncAgentsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, syncAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client SyncAgentsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncAgentName": autorest.Encode("path", syncAgentName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) DeleteSender(req *http.Request) (future SyncAgentsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// GenerateKey generates a sync agent key.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+// syncAgentName - the name of the sync agent.
+func (client SyncAgentsClient) GenerateKey(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentKeyProperties, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.GenerateKey")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GenerateKeyPreparer(ctx, resourceGroupName, serverName, syncAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GenerateKeySender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GenerateKeyResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "GenerateKey", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GenerateKeyPreparer prepares the GenerateKey request.
+func (client SyncAgentsClient) GenerateKeyPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncAgentName": autorest.Encode("path", syncAgentName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}/generateKey", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GenerateKeySender sends the GenerateKey request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) GenerateKeySender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GenerateKeyResponder handles the response to the GenerateKey request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) GenerateKeyResponder(resp *http.Response) (result SyncAgentKeyProperties, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a sync agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+// syncAgentName - the name of the sync agent.
+func (client SyncAgentsClient) Get(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgent, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, syncAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client SyncAgentsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncAgentName": autorest.Encode("path", syncAgentName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) GetResponder(resp *http.Response) (result SyncAgent, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer lists sync agents in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+func (client SyncAgentsClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result SyncAgentListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.salr.Response.Response != nil {
+ sc = result.salr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.salr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.salr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client SyncAgentsClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) ListByServerResponder(resp *http.Response) (result SyncAgentListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client SyncAgentsClient) listByServerNextResults(ctx context.Context, lastResults SyncAgentListResult) (result SyncAgentListResult, err error) {
+ req, err := lastResults.syncAgentListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncAgentsClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result SyncAgentListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
+
+// ListLinkedDatabases lists databases linked to a sync agent.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server on which the sync agent is hosted.
+// syncAgentName - the name of the sync agent.
+func (client SyncAgentsClient) ListLinkedDatabases(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentLinkedDatabaseListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListLinkedDatabases")
+ defer func() {
+ sc := -1
+ if result.saldlr.Response.Response != nil {
+ sc = result.saldlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listLinkedDatabasesNextResults
+ req, err := client.ListLinkedDatabasesPreparer(ctx, resourceGroupName, serverName, syncAgentName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListLinkedDatabasesSender(req)
+ if err != nil {
+ result.saldlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", resp, "Failure sending request")
+ return
+ }
+
+ result.saldlr, err = client.ListLinkedDatabasesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "ListLinkedDatabases", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListLinkedDatabasesPreparer prepares the ListLinkedDatabases request.
+func (client SyncAgentsClient) ListLinkedDatabasesPreparer(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncAgentName": autorest.Encode("path", syncAgentName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/syncAgents/{syncAgentName}/linkedDatabases", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListLinkedDatabasesSender sends the ListLinkedDatabases request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncAgentsClient) ListLinkedDatabasesSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListLinkedDatabasesResponder handles the response to the ListLinkedDatabases request. The method always
+// closes the http.Response Body.
+func (client SyncAgentsClient) ListLinkedDatabasesResponder(resp *http.Response) (result SyncAgentLinkedDatabaseListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listLinkedDatabasesNextResults retrieves the next set of results, if any.
+func (client SyncAgentsClient) listLinkedDatabasesNextResults(ctx context.Context, lastResults SyncAgentLinkedDatabaseListResult) (result SyncAgentLinkedDatabaseListResult, err error) {
+ req, err := lastResults.syncAgentLinkedDatabaseListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListLinkedDatabasesSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListLinkedDatabasesResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncAgentsClient", "listLinkedDatabasesNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListLinkedDatabasesComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncAgentsClient) ListLinkedDatabasesComplete(ctx context.Context, resourceGroupName string, serverName string, syncAgentName string) (result SyncAgentLinkedDatabaseListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncAgentsClient.ListLinkedDatabases")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListLinkedDatabases(ctx, resourceGroupName, serverName, syncAgentName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncgroups.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncgroups.go
index 2caa79297a5f..f16c28c30198 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncgroups.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncgroups.go
@@ -1,1100 +1,1100 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// SyncGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type SyncGroupsClient struct {
- BaseClient
-}
-
-// NewSyncGroupsClient creates an instance of the SyncGroupsClient client.
-func NewSyncGroupsClient(subscriptionID string) SyncGroupsClient {
- return NewSyncGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewSyncGroupsClientWithBaseURI creates an instance of the SyncGroupsClient client.
-func NewSyncGroupsClientWithBaseURI(baseURI string, subscriptionID string) SyncGroupsClient {
- return SyncGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CancelSync cancels a sync group synchronization.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) CancelSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.CancelSync")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CancelSyncPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CancelSyncSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", resp, "Failure sending request")
- return
- }
-
- result, err = client.CancelSyncResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CancelSyncPreparer prepares the CancelSync request.
-func (client SyncGroupsClient) CancelSyncPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/cancelSync", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CancelSyncSender sends the CancelSync request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) CancelSyncSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CancelSyncResponder handles the response to the CancelSync request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) CancelSyncResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// CreateOrUpdate creates or updates a sync group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-// parameters - the requested sync group resource state.
-func (client SyncGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (result SyncGroupsCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client SyncGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) CreateOrUpdateSender(req *http.Request) (future SyncGroupsCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result SyncGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a sync group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroupsDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client SyncGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) DeleteSender(req *http.Request) (future SyncGroupsDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a sync group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroup, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client SyncGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) GetResponder(resp *http.Response) (result SyncGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByDatabase lists sync groups under a hub database.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-func (client SyncGroupsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result SyncGroupListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.sglr.Response.Response != nil {
- sc = result.sglr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByDatabaseNextResults
- req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.sglr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", resp, "Failure sending request")
- return
- }
-
- result.sglr, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByDatabasePreparer prepares the ListByDatabase request.
-func (client SyncGroupsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByDatabaseSender sends the ListByDatabase request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) ListByDatabaseResponder(resp *http.Response) (result SyncGroupListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByDatabaseNextResults retrieves the next set of results, if any.
-func (client SyncGroupsClient) listByDatabaseNextResults(ctx context.Context, lastResults SyncGroupListResult) (result SyncGroupListResult, err error) {
- req, err := lastResults.syncGroupListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByDatabaseSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByDatabaseResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncGroupsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result SyncGroupListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListByDatabase")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
- return
-}
-
-// ListHubSchemas gets a collection of hub database schemas.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) ListHubSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncFullSchemaPropertiesListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListHubSchemas")
- defer func() {
- sc := -1
- if result.sfsplr.Response.Response != nil {
- sc = result.sfsplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listHubSchemasNextResults
- req, err := client.ListHubSchemasPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListHubSchemasSender(req)
- if err != nil {
- result.sfsplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", resp, "Failure sending request")
- return
- }
-
- result.sfsplr, err = client.ListHubSchemasResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListHubSchemasPreparer prepares the ListHubSchemas request.
-func (client SyncGroupsClient) ListHubSchemasPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/hubSchemas", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListHubSchemasSender sends the ListHubSchemas request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) ListHubSchemasSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListHubSchemasResponder handles the response to the ListHubSchemas request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) ListHubSchemasResponder(resp *http.Response) (result SyncFullSchemaPropertiesListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listHubSchemasNextResults retrieves the next set of results, if any.
-func (client SyncGroupsClient) listHubSchemasNextResults(ctx context.Context, lastResults SyncFullSchemaPropertiesListResult) (result SyncFullSchemaPropertiesListResult, err error) {
- req, err := lastResults.syncFullSchemaPropertiesListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListHubSchemasSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListHubSchemasResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListHubSchemasComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncGroupsClient) ListHubSchemasComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncFullSchemaPropertiesListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListHubSchemas")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListHubSchemas(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- return
-}
-
-// ListLogs gets a collection of sync group logs.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-// startTime - get logs generated after this time.
-// endTime - get logs generated before this time.
-// typeParameter - the types of logs to retrieve.
-// continuationToken - the continuation token for this operation.
-func (client SyncGroupsClient) ListLogs(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (result SyncGroupLogListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListLogs")
- defer func() {
- sc := -1
- if result.sgllr.Response.Response != nil {
- sc = result.sgllr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listLogsNextResults
- req, err := client.ListLogsPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, startTime, endTime, typeParameter, continuationToken)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListLogsSender(req)
- if err != nil {
- result.sgllr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", resp, "Failure sending request")
- return
- }
-
- result.sgllr, err = client.ListLogsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListLogsPreparer prepares the ListLogs request.
-func (client SyncGroupsClient) ListLogsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- "endTime": autorest.Encode("query", endTime),
- "startTime": autorest.Encode("query", startTime),
- "type": autorest.Encode("query", typeParameter),
- }
- if len(continuationToken) > 0 {
- queryParameters["continuationToken"] = autorest.Encode("query", continuationToken)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/logs", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListLogsSender sends the ListLogs request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) ListLogsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListLogsResponder handles the response to the ListLogs request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) ListLogsResponder(resp *http.Response) (result SyncGroupLogListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listLogsNextResults retrieves the next set of results, if any.
-func (client SyncGroupsClient) listLogsNextResults(ctx context.Context, lastResults SyncGroupLogListResult) (result SyncGroupLogListResult, err error) {
- req, err := lastResults.syncGroupLogListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListLogsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListLogsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListLogsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncGroupsClient) ListLogsComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (result SyncGroupLogListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListLogs")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListLogs(ctx, resourceGroupName, serverName, databaseName, syncGroupName, startTime, endTime, typeParameter, continuationToken)
- return
-}
-
-// ListSyncDatabaseIds gets a collection of sync database ids.
-// Parameters:
-// locationName - the name of the region where the resource is located.
-func (client SyncGroupsClient) ListSyncDatabaseIds(ctx context.Context, locationName string) (result SyncDatabaseIDListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListSyncDatabaseIds")
- defer func() {
- sc := -1
- if result.sdilr.Response.Response != nil {
- sc = result.sdilr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listSyncDatabaseIdsNextResults
- req, err := client.ListSyncDatabaseIdsPreparer(ctx, locationName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSyncDatabaseIdsSender(req)
- if err != nil {
- result.sdilr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", resp, "Failure sending request")
- return
- }
-
- result.sdilr, err = client.ListSyncDatabaseIdsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListSyncDatabaseIdsPreparer prepares the ListSyncDatabaseIds request.
-func (client SyncGroupsClient) ListSyncDatabaseIdsPreparer(ctx context.Context, locationName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "locationName": autorest.Encode("path", locationName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/syncDatabaseIds", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSyncDatabaseIdsSender sends the ListSyncDatabaseIds request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) ListSyncDatabaseIdsSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListSyncDatabaseIdsResponder handles the response to the ListSyncDatabaseIds request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) ListSyncDatabaseIdsResponder(resp *http.Response) (result SyncDatabaseIDListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listSyncDatabaseIdsNextResults retrieves the next set of results, if any.
-func (client SyncGroupsClient) listSyncDatabaseIdsNextResults(ctx context.Context, lastResults SyncDatabaseIDListResult) (result SyncDatabaseIDListResult, err error) {
- req, err := lastResults.syncDatabaseIDListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSyncDatabaseIdsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListSyncDatabaseIdsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListSyncDatabaseIdsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncGroupsClient) ListSyncDatabaseIdsComplete(ctx context.Context, locationName string) (result SyncDatabaseIDListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListSyncDatabaseIds")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListSyncDatabaseIds(ctx, locationName)
- return
-}
-
-// RefreshHubSchema refreshes a hub database schema.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) RefreshHubSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroupsRefreshHubSchemaFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.RefreshHubSchema")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.RefreshHubSchemaPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "RefreshHubSchema", nil, "Failure preparing request")
- return
- }
-
- result, err = client.RefreshHubSchemaSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "RefreshHubSchema", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// RefreshHubSchemaPreparer prepares the RefreshHubSchema request.
-func (client SyncGroupsClient) RefreshHubSchemaPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/refreshHubSchema", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// RefreshHubSchemaSender sends the RefreshHubSchema request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) RefreshHubSchemaSender(req *http.Request) (future SyncGroupsRefreshHubSchemaFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// RefreshHubSchemaResponder handles the response to the RefreshHubSchema request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) RefreshHubSchemaResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// TriggerSync triggers a sync group synchronization.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncGroupsClient) TriggerSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.TriggerSync")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.TriggerSyncPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.TriggerSyncSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", resp, "Failure sending request")
- return
- }
-
- result, err = client.TriggerSyncResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", resp, "Failure responding to request")
- }
-
- return
-}
-
-// TriggerSyncPreparer prepares the TriggerSync request.
-func (client SyncGroupsClient) TriggerSyncPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/triggerSync", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// TriggerSyncSender sends the TriggerSync request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) TriggerSyncSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// TriggerSyncResponder handles the response to the TriggerSync request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) TriggerSyncResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Update updates a sync group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-// parameters - the requested sync group resource state.
-func (client SyncGroupsClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (result SyncGroupsUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client SyncGroupsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncGroupsClient) UpdateSender(req *http.Request) (future SyncGroupsUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client SyncGroupsClient) UpdateResponder(resp *http.Response) (result SyncGroup, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// SyncGroupsClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type SyncGroupsClient struct {
+ BaseClient
+}
+
+// NewSyncGroupsClient creates an instance of the SyncGroupsClient client.
+func NewSyncGroupsClient(subscriptionID string) SyncGroupsClient {
+ return NewSyncGroupsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewSyncGroupsClientWithBaseURI creates an instance of the SyncGroupsClient client.
+func NewSyncGroupsClientWithBaseURI(baseURI string, subscriptionID string) SyncGroupsClient {
+ return SyncGroupsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CancelSync cancels a sync group synchronization.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) CancelSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.CancelSync")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CancelSyncPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CancelSyncSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CancelSyncResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CancelSync", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CancelSyncPreparer prepares the CancelSync request.
+func (client SyncGroupsClient) CancelSyncPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/cancelSync", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CancelSyncSender sends the CancelSync request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) CancelSyncSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CancelSyncResponder handles the response to the CancelSync request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) CancelSyncResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// CreateOrUpdate creates or updates a sync group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+// parameters - the requested sync group resource state.
+func (client SyncGroupsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (result SyncGroupsCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client SyncGroupsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) CreateOrUpdateSender(req *http.Request) (future SyncGroupsCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) CreateOrUpdateResponder(resp *http.Response) (result SyncGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a sync group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroupsDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client SyncGroupsClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) DeleteSender(req *http.Request) (future SyncGroupsDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a sync group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroup, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client SyncGroupsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) GetResponder(resp *http.Response) (result SyncGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByDatabase lists sync groups under a hub database.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+func (client SyncGroupsClient) ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result SyncGroupListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.sglr.Response.Response != nil {
+ sc = result.sglr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByDatabaseNextResults
+ req, err := client.ListByDatabasePreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.sglr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", resp, "Failure sending request")
+ return
+ }
+
+ result.sglr, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListByDatabase", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByDatabasePreparer prepares the ListByDatabase request.
+func (client SyncGroupsClient) ListByDatabasePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByDatabaseSender sends the ListByDatabase request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) ListByDatabaseSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByDatabaseResponder handles the response to the ListByDatabase request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) ListByDatabaseResponder(resp *http.Response) (result SyncGroupListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByDatabaseNextResults retrieves the next set of results, if any.
+func (client SyncGroupsClient) listByDatabaseNextResults(ctx context.Context, lastResults SyncGroupListResult) (result SyncGroupListResult, err error) {
+ req, err := lastResults.syncGroupListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByDatabaseSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByDatabaseResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listByDatabaseNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByDatabaseComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncGroupsClient) ListByDatabaseComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result SyncGroupListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListByDatabase")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByDatabase(ctx, resourceGroupName, serverName, databaseName)
+ return
+}
+
+// ListHubSchemas gets a collection of hub database schemas.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) ListHubSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncFullSchemaPropertiesListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListHubSchemas")
+ defer func() {
+ sc := -1
+ if result.sfsplr.Response.Response != nil {
+ sc = result.sfsplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listHubSchemasNextResults
+ req, err := client.ListHubSchemasPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListHubSchemasSender(req)
+ if err != nil {
+ result.sfsplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", resp, "Failure sending request")
+ return
+ }
+
+ result.sfsplr, err = client.ListHubSchemasResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListHubSchemas", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListHubSchemasPreparer prepares the ListHubSchemas request.
+func (client SyncGroupsClient) ListHubSchemasPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/hubSchemas", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListHubSchemasSender sends the ListHubSchemas request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) ListHubSchemasSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListHubSchemasResponder handles the response to the ListHubSchemas request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) ListHubSchemasResponder(resp *http.Response) (result SyncFullSchemaPropertiesListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listHubSchemasNextResults retrieves the next set of results, if any.
+func (client SyncGroupsClient) listHubSchemasNextResults(ctx context.Context, lastResults SyncFullSchemaPropertiesListResult) (result SyncFullSchemaPropertiesListResult, err error) {
+ req, err := lastResults.syncFullSchemaPropertiesListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListHubSchemasSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListHubSchemasResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listHubSchemasNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListHubSchemasComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncGroupsClient) ListHubSchemasComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncFullSchemaPropertiesListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListHubSchemas")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListHubSchemas(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ return
+}
+
+// ListLogs gets a collection of sync group logs.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+// startTime - get logs generated after this time.
+// endTime - get logs generated before this time.
+// typeParameter - the types of logs to retrieve.
+// continuationToken - the continuation token for this operation.
+func (client SyncGroupsClient) ListLogs(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (result SyncGroupLogListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListLogs")
+ defer func() {
+ sc := -1
+ if result.sgllr.Response.Response != nil {
+ sc = result.sgllr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listLogsNextResults
+ req, err := client.ListLogsPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, startTime, endTime, typeParameter, continuationToken)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListLogsSender(req)
+ if err != nil {
+ result.sgllr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", resp, "Failure sending request")
+ return
+ }
+
+ result.sgllr, err = client.ListLogsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListLogs", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListLogsPreparer prepares the ListLogs request.
+func (client SyncGroupsClient) ListLogsPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ "endTime": autorest.Encode("query", endTime),
+ "startTime": autorest.Encode("query", startTime),
+ "type": autorest.Encode("query", typeParameter),
+ }
+ if len(continuationToken) > 0 {
+ queryParameters["continuationToken"] = autorest.Encode("query", continuationToken)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/logs", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListLogsSender sends the ListLogs request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) ListLogsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListLogsResponder handles the response to the ListLogs request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) ListLogsResponder(resp *http.Response) (result SyncGroupLogListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listLogsNextResults retrieves the next set of results, if any.
+func (client SyncGroupsClient) listLogsNextResults(ctx context.Context, lastResults SyncGroupLogListResult) (result SyncGroupLogListResult, err error) {
+ req, err := lastResults.syncGroupLogListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListLogsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListLogsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listLogsNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListLogsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncGroupsClient) ListLogsComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, startTime string, endTime string, typeParameter string, continuationToken string) (result SyncGroupLogListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListLogs")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListLogs(ctx, resourceGroupName, serverName, databaseName, syncGroupName, startTime, endTime, typeParameter, continuationToken)
+ return
+}
+
+// ListSyncDatabaseIds gets a collection of sync database ids.
+// Parameters:
+// locationName - the name of the region where the resource is located.
+func (client SyncGroupsClient) ListSyncDatabaseIds(ctx context.Context, locationName string) (result SyncDatabaseIDListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListSyncDatabaseIds")
+ defer func() {
+ sc := -1
+ if result.sdilr.Response.Response != nil {
+ sc = result.sdilr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listSyncDatabaseIdsNextResults
+ req, err := client.ListSyncDatabaseIdsPreparer(ctx, locationName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSyncDatabaseIdsSender(req)
+ if err != nil {
+ result.sdilr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", resp, "Failure sending request")
+ return
+ }
+
+ result.sdilr, err = client.ListSyncDatabaseIdsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "ListSyncDatabaseIds", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListSyncDatabaseIdsPreparer prepares the ListSyncDatabaseIds request.
+func (client SyncGroupsClient) ListSyncDatabaseIdsPreparer(ctx context.Context, locationName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "locationName": autorest.Encode("path", locationName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/locations/{locationName}/syncDatabaseIds", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSyncDatabaseIdsSender sends the ListSyncDatabaseIds request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) ListSyncDatabaseIdsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListSyncDatabaseIdsResponder handles the response to the ListSyncDatabaseIds request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) ListSyncDatabaseIdsResponder(resp *http.Response) (result SyncDatabaseIDListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listSyncDatabaseIdsNextResults retrieves the next set of results, if any.
+func (client SyncGroupsClient) listSyncDatabaseIdsNextResults(ctx context.Context, lastResults SyncDatabaseIDListResult) (result SyncDatabaseIDListResult, err error) {
+ req, err := lastResults.syncDatabaseIDListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSyncDatabaseIdsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListSyncDatabaseIdsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "listSyncDatabaseIdsNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListSyncDatabaseIdsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncGroupsClient) ListSyncDatabaseIdsComplete(ctx context.Context, locationName string) (result SyncDatabaseIDListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.ListSyncDatabaseIds")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListSyncDatabaseIds(ctx, locationName)
+ return
+}
+
+// RefreshHubSchema refreshes a hub database schema.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) RefreshHubSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncGroupsRefreshHubSchemaFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.RefreshHubSchema")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.RefreshHubSchemaPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "RefreshHubSchema", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.RefreshHubSchemaSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "RefreshHubSchema", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// RefreshHubSchemaPreparer prepares the RefreshHubSchema request.
+func (client SyncGroupsClient) RefreshHubSchemaPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/refreshHubSchema", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// RefreshHubSchemaSender sends the RefreshHubSchema request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) RefreshHubSchemaSender(req *http.Request) (future SyncGroupsRefreshHubSchemaFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// RefreshHubSchemaResponder handles the response to the RefreshHubSchema request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) RefreshHubSchemaResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// TriggerSync triggers a sync group synchronization.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncGroupsClient) TriggerSync(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.TriggerSync")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.TriggerSyncPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.TriggerSyncSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.TriggerSyncResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "TriggerSync", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// TriggerSyncPreparer prepares the TriggerSync request.
+func (client SyncGroupsClient) TriggerSyncPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/triggerSync", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// TriggerSyncSender sends the TriggerSync request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) TriggerSyncSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// TriggerSyncResponder handles the response to the TriggerSync request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) TriggerSyncResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Update updates a sync group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+// parameters - the requested sync group resource state.
+func (client SyncGroupsClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (result SyncGroupsUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncGroupsClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncGroupsClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client SyncGroupsClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, parameters SyncGroup) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncGroupsClient) UpdateSender(req *http.Request) (future SyncGroupsUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client SyncGroupsClient) UpdateResponder(resp *http.Response) (result SyncGroup, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncmembers.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncmembers.go
index 0d73dde1a62a..3bf30d6226c7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncmembers.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/syncmembers.go
@@ -1,709 +1,709 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// SyncMembersClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
-// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
-// delete databases.
-type SyncMembersClient struct {
- BaseClient
-}
-
-// NewSyncMembersClient creates an instance of the SyncMembersClient client.
-func NewSyncMembersClient(subscriptionID string) SyncMembersClient {
- return NewSyncMembersClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewSyncMembersClientWithBaseURI creates an instance of the SyncMembersClient client.
-func NewSyncMembersClientWithBaseURI(baseURI string, subscriptionID string) SyncMembersClient {
- return SyncMembersClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a sync member.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-// parameters - the requested sync member resource state.
-func (client SyncMembersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (result SyncMembersCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client SyncMembersClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) CreateOrUpdateSender(req *http.Request) (future SyncMembersCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) CreateOrUpdateResponder(resp *http.Response) (result SyncMember, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes a sync member.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-func (client SyncMembersClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMembersDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client SyncMembersClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) DeleteSender(req *http.Request) (future SyncMembersDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a sync member.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-func (client SyncMembersClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMember, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client SyncMembersClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) GetResponder(resp *http.Response) (result SyncMember, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListBySyncGroup lists sync members in the given sync group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group.
-func (client SyncMembersClient) ListBySyncGroup(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncMemberListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListBySyncGroup")
- defer func() {
- sc := -1
- if result.smlr.Response.Response != nil {
- sc = result.smlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listBySyncGroupNextResults
- req, err := client.ListBySyncGroupPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListBySyncGroupSender(req)
- if err != nil {
- result.smlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", resp, "Failure sending request")
- return
- }
-
- result.smlr, err = client.ListBySyncGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListBySyncGroupPreparer prepares the ListBySyncGroup request.
-func (client SyncMembersClient) ListBySyncGroupPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListBySyncGroupSender sends the ListBySyncGroup request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) ListBySyncGroupSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListBySyncGroupResponder handles the response to the ListBySyncGroup request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) ListBySyncGroupResponder(resp *http.Response) (result SyncMemberListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listBySyncGroupNextResults retrieves the next set of results, if any.
-func (client SyncMembersClient) listBySyncGroupNextResults(ctx context.Context, lastResults SyncMemberListResult) (result SyncMemberListResult, err error) {
- req, err := lastResults.syncMemberListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListBySyncGroupSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListBySyncGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListBySyncGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncMembersClient) ListBySyncGroupComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncMemberListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListBySyncGroup")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListBySyncGroup(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
- return
-}
-
-// ListMemberSchemas gets a sync member database schema.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-func (client SyncMembersClient) ListMemberSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncFullSchemaPropertiesListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListMemberSchemas")
- defer func() {
- sc := -1
- if result.sfsplr.Response.Response != nil {
- sc = result.sfsplr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listMemberSchemasNextResults
- req, err := client.ListMemberSchemasPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListMemberSchemasSender(req)
- if err != nil {
- result.sfsplr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", resp, "Failure sending request")
- return
- }
-
- result.sfsplr, err = client.ListMemberSchemasResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListMemberSchemasPreparer prepares the ListMemberSchemas request.
-func (client SyncMembersClient) ListMemberSchemasPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}/schemas", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListMemberSchemasSender sends the ListMemberSchemas request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) ListMemberSchemasSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListMemberSchemasResponder handles the response to the ListMemberSchemas request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) ListMemberSchemasResponder(resp *http.Response) (result SyncFullSchemaPropertiesListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listMemberSchemasNextResults retrieves the next set of results, if any.
-func (client SyncMembersClient) listMemberSchemasNextResults(ctx context.Context, lastResults SyncFullSchemaPropertiesListResult) (result SyncFullSchemaPropertiesListResult, err error) {
- req, err := lastResults.syncFullSchemaPropertiesListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListMemberSchemasSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListMemberSchemasResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListMemberSchemasComplete enumerates all values, automatically crossing page boundaries as required.
-func (client SyncMembersClient) ListMemberSchemasComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncFullSchemaPropertiesListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListMemberSchemas")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListMemberSchemas(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
- return
-}
-
-// RefreshMemberSchema refreshes a sync member database schema.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-func (client SyncMembersClient) RefreshMemberSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMembersRefreshMemberSchemaFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.RefreshMemberSchema")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.RefreshMemberSchemaPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "RefreshMemberSchema", nil, "Failure preparing request")
- return
- }
-
- result, err = client.RefreshMemberSchemaSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "RefreshMemberSchema", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// RefreshMemberSchemaPreparer prepares the RefreshMemberSchema request.
-func (client SyncMembersClient) RefreshMemberSchemaPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}/refreshSchema", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// RefreshMemberSchemaSender sends the RefreshMemberSchema request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) RefreshMemberSchemaSender(req *http.Request) (future SyncMembersRefreshMemberSchemaFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// RefreshMemberSchemaResponder handles the response to the RefreshMemberSchema request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) RefreshMemberSchemaResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Update updates an existing sync member.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database on which the sync group is hosted.
-// syncGroupName - the name of the sync group on which the sync member is hosted.
-// syncMemberName - the name of the sync member.
-// parameters - the requested sync member resource state.
-func (client SyncMembersClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (result SyncMembersUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client SyncMembersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "syncGroupName": autorest.Encode("path", syncGroupName),
- "syncMemberName": autorest.Encode("path", syncMemberName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client SyncMembersClient) UpdateSender(req *http.Request) (future SyncMembersUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client SyncMembersClient) UpdateResponder(resp *http.Response) (result SyncMember, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// SyncMembersClient is the the Azure SQL Database management API provides a RESTful set of web services that interact
+// with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update, and
+// delete databases.
+type SyncMembersClient struct {
+ BaseClient
+}
+
+// NewSyncMembersClient creates an instance of the SyncMembersClient client.
+func NewSyncMembersClient(subscriptionID string) SyncMembersClient {
+ return NewSyncMembersClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewSyncMembersClientWithBaseURI creates an instance of the SyncMembersClient client.
+func NewSyncMembersClientWithBaseURI(baseURI string, subscriptionID string) SyncMembersClient {
+ return SyncMembersClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a sync member.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+// parameters - the requested sync member resource state.
+func (client SyncMembersClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (result SyncMembersCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client SyncMembersClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) CreateOrUpdateSender(req *http.Request) (future SyncMembersCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) CreateOrUpdateResponder(resp *http.Response) (result SyncMember, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes a sync member.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+func (client SyncMembersClient) Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMembersDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client SyncMembersClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) DeleteSender(req *http.Request) (future SyncMembersDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a sync member.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+func (client SyncMembersClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMember, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client SyncMembersClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) GetResponder(resp *http.Response) (result SyncMember, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListBySyncGroup lists sync members in the given sync group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group.
+func (client SyncMembersClient) ListBySyncGroup(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncMemberListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListBySyncGroup")
+ defer func() {
+ sc := -1
+ if result.smlr.Response.Response != nil {
+ sc = result.smlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listBySyncGroupNextResults
+ req, err := client.ListBySyncGroupPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListBySyncGroupSender(req)
+ if err != nil {
+ result.smlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.smlr, err = client.ListBySyncGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListBySyncGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListBySyncGroupPreparer prepares the ListBySyncGroup request.
+func (client SyncMembersClient) ListBySyncGroupPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListBySyncGroupSender sends the ListBySyncGroup request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) ListBySyncGroupSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListBySyncGroupResponder handles the response to the ListBySyncGroup request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) ListBySyncGroupResponder(resp *http.Response) (result SyncMemberListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listBySyncGroupNextResults retrieves the next set of results, if any.
+func (client SyncMembersClient) listBySyncGroupNextResults(ctx context.Context, lastResults SyncMemberListResult) (result SyncMemberListResult, err error) {
+ req, err := lastResults.syncMemberListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListBySyncGroupSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListBySyncGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listBySyncGroupNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListBySyncGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncMembersClient) ListBySyncGroupComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string) (result SyncMemberListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListBySyncGroup")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListBySyncGroup(ctx, resourceGroupName, serverName, databaseName, syncGroupName)
+ return
+}
+
+// ListMemberSchemas gets a sync member database schema.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+func (client SyncMembersClient) ListMemberSchemas(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncFullSchemaPropertiesListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListMemberSchemas")
+ defer func() {
+ sc := -1
+ if result.sfsplr.Response.Response != nil {
+ sc = result.sfsplr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listMemberSchemasNextResults
+ req, err := client.ListMemberSchemasPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListMemberSchemasSender(req)
+ if err != nil {
+ result.sfsplr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", resp, "Failure sending request")
+ return
+ }
+
+ result.sfsplr, err = client.ListMemberSchemasResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "ListMemberSchemas", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListMemberSchemasPreparer prepares the ListMemberSchemas request.
+func (client SyncMembersClient) ListMemberSchemasPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}/schemas", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListMemberSchemasSender sends the ListMemberSchemas request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) ListMemberSchemasSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListMemberSchemasResponder handles the response to the ListMemberSchemas request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) ListMemberSchemasResponder(resp *http.Response) (result SyncFullSchemaPropertiesListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listMemberSchemasNextResults retrieves the next set of results, if any.
+func (client SyncMembersClient) listMemberSchemasNextResults(ctx context.Context, lastResults SyncFullSchemaPropertiesListResult) (result SyncFullSchemaPropertiesListResult, err error) {
+ req, err := lastResults.syncFullSchemaPropertiesListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListMemberSchemasSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListMemberSchemasResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "listMemberSchemasNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListMemberSchemasComplete enumerates all values, automatically crossing page boundaries as required.
+func (client SyncMembersClient) ListMemberSchemasComplete(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncFullSchemaPropertiesListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.ListMemberSchemas")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListMemberSchemas(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
+ return
+}
+
+// RefreshMemberSchema refreshes a sync member database schema.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+func (client SyncMembersClient) RefreshMemberSchema(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (result SyncMembersRefreshMemberSchemaFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.RefreshMemberSchema")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.RefreshMemberSchemaPreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "RefreshMemberSchema", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.RefreshMemberSchemaSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "RefreshMemberSchema", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// RefreshMemberSchemaPreparer prepares the RefreshMemberSchema request.
+func (client SyncMembersClient) RefreshMemberSchemaPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}/refreshSchema", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// RefreshMemberSchemaSender sends the RefreshMemberSchema request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) RefreshMemberSchemaSender(req *http.Request) (future SyncMembersRefreshMemberSchemaFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// RefreshMemberSchemaResponder handles the response to the RefreshMemberSchema request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) RefreshMemberSchemaResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Update updates an existing sync member.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database on which the sync group is hosted.
+// syncGroupName - the name of the sync group on which the sync member is hosted.
+// syncMemberName - the name of the sync member.
+// parameters - the requested sync member resource state.
+func (client SyncMembersClient) Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (result SyncMembersUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/SyncMembersClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, serverName, databaseName, syncGroupName, syncMemberName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.SyncMembersClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client SyncMembersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, syncGroupName string, syncMemberName string, parameters SyncMember) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "syncGroupName": autorest.Encode("path", syncGroupName),
+ "syncMemberName": autorest.Encode("path", syncMemberName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/syncGroups/{syncGroupName}/syncMembers/{syncMemberName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client SyncMembersClient) UpdateSender(req *http.Request) (future SyncMembersUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client SyncMembersClient) UpdateResponder(resp *http.Response) (result SyncMember, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptionactivities.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptionactivities.go
index d8ae8dd13d1f..2c8c003fc3b7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptionactivities.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptionactivities.go
@@ -1,126 +1,126 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// TransparentDataEncryptionActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
-// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
-// retrieve, update, and delete databases.
-type TransparentDataEncryptionActivitiesClient struct {
- BaseClient
-}
-
-// NewTransparentDataEncryptionActivitiesClient creates an instance of the TransparentDataEncryptionActivitiesClient
-// client.
-func NewTransparentDataEncryptionActivitiesClient(subscriptionID string) TransparentDataEncryptionActivitiesClient {
- return NewTransparentDataEncryptionActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewTransparentDataEncryptionActivitiesClientWithBaseURI creates an instance of the
-// TransparentDataEncryptionActivitiesClient client.
-func NewTransparentDataEncryptionActivitiesClientWithBaseURI(baseURI string, subscriptionID string) TransparentDataEncryptionActivitiesClient {
- return TransparentDataEncryptionActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// ListByConfiguration returns a database's transparent data encryption operation result.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the transparent data encryption applies.
-func (client TransparentDataEncryptionActivitiesClient) ListByConfiguration(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result TransparentDataEncryptionActivityListResult, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionActivitiesClient.ListByConfiguration")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.ListByConfigurationPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByConfigurationSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", resp, "Failure sending request")
- return
- }
-
- result, err = client.ListByConfigurationResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByConfigurationPreparer prepares the ListByConfiguration request.
-func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "transparentDataEncryptionName": autorest.Encode("path", "current"),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}/operationResults", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByConfigurationSender sends the ListByConfiguration request. The method will close the
-// http.Response Body if it receives an error.
-func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByConfigurationResponder handles the response to the ListByConfiguration request. The method always
-// closes the http.Response Body.
-func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationResponder(resp *http.Response) (result TransparentDataEncryptionActivityListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// TransparentDataEncryptionActivitiesClient is the the Azure SQL Database management API provides a RESTful set of web
+// services that interact with Azure SQL Database services to manage your databases. The API enables you to create,
+// retrieve, update, and delete databases.
+type TransparentDataEncryptionActivitiesClient struct {
+ BaseClient
+}
+
+// NewTransparentDataEncryptionActivitiesClient creates an instance of the TransparentDataEncryptionActivitiesClient
+// client.
+func NewTransparentDataEncryptionActivitiesClient(subscriptionID string) TransparentDataEncryptionActivitiesClient {
+ return NewTransparentDataEncryptionActivitiesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewTransparentDataEncryptionActivitiesClientWithBaseURI creates an instance of the
+// TransparentDataEncryptionActivitiesClient client.
+func NewTransparentDataEncryptionActivitiesClientWithBaseURI(baseURI string, subscriptionID string) TransparentDataEncryptionActivitiesClient {
+ return TransparentDataEncryptionActivitiesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// ListByConfiguration returns a database's transparent data encryption operation result.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the transparent data encryption applies.
+func (client TransparentDataEncryptionActivitiesClient) ListByConfiguration(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result TransparentDataEncryptionActivityListResult, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionActivitiesClient.ListByConfiguration")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.ListByConfigurationPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByConfigurationSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListByConfigurationResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionActivitiesClient", "ListByConfiguration", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByConfigurationPreparer prepares the ListByConfiguration request.
+func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "transparentDataEncryptionName": autorest.Encode("path", "current"),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}/operationResults", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByConfigurationSender sends the ListByConfiguration request. The method will close the
+// http.Response Body if it receives an error.
+func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByConfigurationResponder handles the response to the ListByConfiguration request. The method always
+// closes the http.Response Body.
+func (client TransparentDataEncryptionActivitiesClient) ListByConfigurationResponder(resp *http.Response) (result TransparentDataEncryptionActivityListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptions.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptions.go
index 775e15164eda..7ea3bdf24a6e 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptions.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/transparentdataencryptions.go
@@ -1,209 +1,209 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// TransparentDataEncryptionsClient is the the Azure SQL Database management API provides a RESTful set of web services
-// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
-// update, and delete databases.
-type TransparentDataEncryptionsClient struct {
- BaseClient
-}
-
-// NewTransparentDataEncryptionsClient creates an instance of the TransparentDataEncryptionsClient client.
-func NewTransparentDataEncryptionsClient(subscriptionID string) TransparentDataEncryptionsClient {
- return NewTransparentDataEncryptionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewTransparentDataEncryptionsClientWithBaseURI creates an instance of the TransparentDataEncryptionsClient client.
-func NewTransparentDataEncryptionsClientWithBaseURI(baseURI string, subscriptionID string) TransparentDataEncryptionsClient {
- return TransparentDataEncryptionsClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates a database's transparent data encryption configuration.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which setting the transparent data encryption applies.
-// parameters - the required parameters for creating or updating transparent data encryption.
-func (client TransparentDataEncryptionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters TransparentDataEncryption) (result TransparentDataEncryption, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionsClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.CreateOrUpdateSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", resp, "Failure sending request")
- return
- }
-
- result, err = client.CreateOrUpdateResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", resp, "Failure responding to request")
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client TransparentDataEncryptionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters TransparentDataEncryption) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "transparentDataEncryptionName": autorest.Encode("path", "current"),
- }
-
- const APIVersion = "2014-04-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- parameters.Location = nil
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client TransparentDataEncryptionsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client TransparentDataEncryptionsClient) CreateOrUpdateResponder(resp *http.Response) (result TransparentDataEncryption, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Get gets a database's transparent data encryption configuration.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// databaseName - the name of the database for which the transparent data encryption applies.
-func (client TransparentDataEncryptionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result TransparentDataEncryption, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionsClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client TransparentDataEncryptionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "databaseName": autorest.Encode("path", databaseName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "transparentDataEncryptionName": autorest.Encode("path", "current"),
- }
-
- const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client TransparentDataEncryptionsClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client TransparentDataEncryptionsClient) GetResponder(resp *http.Response) (result TransparentDataEncryption, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// TransparentDataEncryptionsClient is the the Azure SQL Database management API provides a RESTful set of web services
+// that interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve,
+// update, and delete databases.
+type TransparentDataEncryptionsClient struct {
+ BaseClient
+}
+
+// NewTransparentDataEncryptionsClient creates an instance of the TransparentDataEncryptionsClient client.
+func NewTransparentDataEncryptionsClient(subscriptionID string) TransparentDataEncryptionsClient {
+ return NewTransparentDataEncryptionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewTransparentDataEncryptionsClientWithBaseURI creates an instance of the TransparentDataEncryptionsClient client.
+func NewTransparentDataEncryptionsClientWithBaseURI(baseURI string, subscriptionID string) TransparentDataEncryptionsClient {
+ return TransparentDataEncryptionsClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates a database's transparent data encryption configuration.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which setting the transparent data encryption applies.
+// parameters - the required parameters for creating or updating transparent data encryption.
+func (client TransparentDataEncryptionsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters TransparentDataEncryption) (result TransparentDataEncryption, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionsClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, databaseName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.CreateOrUpdateSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "CreateOrUpdate", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client TransparentDataEncryptionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters TransparentDataEncryption) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "transparentDataEncryptionName": autorest.Encode("path", "current"),
+ }
+
+ const APIVersion = "2014-04-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ parameters.Location = nil
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client TransparentDataEncryptionsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client TransparentDataEncryptionsClient) CreateOrUpdateResponder(resp *http.Response) (result TransparentDataEncryption, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Get gets a database's transparent data encryption configuration.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// databaseName - the name of the database for which the transparent data encryption applies.
+func (client TransparentDataEncryptionsClient) Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result TransparentDataEncryption, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/TransparentDataEncryptionsClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, databaseName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.TransparentDataEncryptionsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client TransparentDataEncryptionsClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "databaseName": autorest.Encode("path", databaseName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "transparentDataEncryptionName": autorest.Encode("path", "current"),
+ }
+
+ const APIVersion = "2014-04-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.Sql/servers/{serverName}/databases/{databaseName}/transparentDataEncryption/{transparentDataEncryptionName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client TransparentDataEncryptionsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client TransparentDataEncryptionsClient) GetResponder(resp *http.Response) (result TransparentDataEncryption, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/version.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/version.go
index e3bb49831790..4e1611821a6f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/version.go
@@ -1,30 +1,30 @@
-package sql
-
-import "github.com/Azure/azure-sdk-for-go/version"
-
-// 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.
-
-// UserAgent returns the UserAgent string to use when sending http.Requests.
-func UserAgent() string {
- return "Azure-SDK-For-Go/" + version.Number + " sql/2017-03-01-preview"
-}
-
-// Version returns the semantic version (see http://semver.org) of the client.
-func Version() string {
- return version.Number
-}
+package sql
+
+import "github.com/Azure/azure-sdk-for-go/version"
+
+// 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.
+
+// UserAgent returns the UserAgent string to use when sending http.Requests.
+func UserAgent() string {
+ return "Azure-SDK-For-Go/" + version.Number + " sql/2017-03-01-preview"
+}
+
+// Version returns the semantic version (see http://semver.org) of the client.
+func Version() string {
+ return version.Number
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualclusters.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualclusters.go
index ba15712e0e61..ffea75716e96 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualclusters.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualclusters.go
@@ -1,503 +1,503 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// VirtualClustersClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type VirtualClustersClient struct {
- BaseClient
-}
-
-// NewVirtualClustersClient creates an instance of the VirtualClustersClient client.
-func NewVirtualClustersClient(subscriptionID string) VirtualClustersClient {
- return NewVirtualClustersClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewVirtualClustersClientWithBaseURI creates an instance of the VirtualClustersClient client.
-func NewVirtualClustersClientWithBaseURI(baseURI string, subscriptionID string) VirtualClustersClient {
- return VirtualClustersClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// Delete deletes a virtual cluster.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// virtualClusterName - the name of the virtual cluster.
-func (client VirtualClustersClient) Delete(ctx context.Context, resourceGroupName string, virtualClusterName string) (result VirtualClustersDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, virtualClusterName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client VirtualClustersClient) DeletePreparer(ctx context.Context, resourceGroupName string, virtualClusterName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualClusterName": autorest.Encode("path", virtualClusterName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualClustersClient) DeleteSender(req *http.Request) (future VirtualClustersDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client VirtualClustersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a virtual cluster.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// virtualClusterName - the name of the virtual cluster.
-func (client VirtualClustersClient) Get(ctx context.Context, resourceGroupName string, virtualClusterName string) (result VirtualCluster, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, virtualClusterName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client VirtualClustersClient) GetPreparer(ctx context.Context, resourceGroupName string, virtualClusterName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualClusterName": autorest.Encode("path", virtualClusterName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualClustersClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client VirtualClustersClient) GetResponder(resp *http.Response) (result VirtualCluster, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// List gets a list of all virtualClusters in the subscription.
-func (client VirtualClustersClient) List(ctx context.Context) (result VirtualClusterListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.List")
- defer func() {
- sc := -1
- if result.vclr.Response.Response != nil {
- sc = result.vclr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListSender(req)
- if err != nil {
- result.vclr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", resp, "Failure sending request")
- return
- }
-
- result.vclr, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListPreparer prepares the List request.
-func (client VirtualClustersClient) ListPreparer(ctx context.Context) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/virtualClusters", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListSender sends the List request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualClustersClient) ListSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListResponder handles the response to the List request. The method always
-// closes the http.Response Body.
-func (client VirtualClustersClient) ListResponder(resp *http.Response) (result VirtualClusterListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listNextResults retrieves the next set of results, if any.
-func (client VirtualClustersClient) listNextResults(ctx context.Context, lastResults VirtualClusterListResult) (result VirtualClusterListResult, err error) {
- req, err := lastResults.virtualClusterListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client VirtualClustersClient) ListComplete(ctx context.Context) (result VirtualClusterListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
-
-// ListByResourceGroup gets a list of virtual clusters in a resource group.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-func (client VirtualClustersClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result VirtualClusterListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.vclr.Response.Response != nil {
- sc = result.vclr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByResourceGroupNextResults
- req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.vclr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", resp, "Failure sending request")
- return
- }
-
- result.vclr, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
-func (client VirtualClustersClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualClustersClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
-// closes the http.Response Body.
-func (client VirtualClustersClient) ListByResourceGroupResponder(resp *http.Response) (result VirtualClusterListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByResourceGroupNextResults retrieves the next set of results, if any.
-func (client VirtualClustersClient) listByResourceGroupNextResults(ctx context.Context, lastResults VirtualClusterListResult) (result VirtualClusterListResult, err error) {
- req, err := lastResults.virtualClusterListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByResourceGroupSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByResourceGroupResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client VirtualClustersClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result VirtualClusterListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.ListByResourceGroup")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
- return
-}
-
-// Update updates a virtual cluster.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// virtualClusterName - the name of the virtual cluster.
-// parameters - the requested managed instance resource state.
-func (client VirtualClustersClient) Update(ctx context.Context, resourceGroupName string, virtualClusterName string, parameters VirtualClusterUpdate) (result VirtualClustersUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Update")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.UpdatePreparer(ctx, resourceGroupName, virtualClusterName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Update", nil, "Failure preparing request")
- return
- }
-
- result, err = client.UpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Update", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// UpdatePreparer prepares the Update request.
-func (client VirtualClustersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, virtualClusterName string, parameters VirtualClusterUpdate) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualClusterName": autorest.Encode("path", virtualClusterName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPatch(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// UpdateSender sends the Update request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualClustersClient) UpdateSender(req *http.Request) (future VirtualClustersUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// UpdateResponder handles the response to the Update request. The method always
-// closes the http.Response Body.
-func (client VirtualClustersClient) UpdateResponder(resp *http.Response) (result VirtualCluster, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// VirtualClustersClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type VirtualClustersClient struct {
+ BaseClient
+}
+
+// NewVirtualClustersClient creates an instance of the VirtualClustersClient client.
+func NewVirtualClustersClient(subscriptionID string) VirtualClustersClient {
+ return NewVirtualClustersClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewVirtualClustersClientWithBaseURI creates an instance of the VirtualClustersClient client.
+func NewVirtualClustersClientWithBaseURI(baseURI string, subscriptionID string) VirtualClustersClient {
+ return VirtualClustersClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// Delete deletes a virtual cluster.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// virtualClusterName - the name of the virtual cluster.
+func (client VirtualClustersClient) Delete(ctx context.Context, resourceGroupName string, virtualClusterName string) (result VirtualClustersDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, virtualClusterName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client VirtualClustersClient) DeletePreparer(ctx context.Context, resourceGroupName string, virtualClusterName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualClusterName": autorest.Encode("path", virtualClusterName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualClustersClient) DeleteSender(req *http.Request) (future VirtualClustersDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client VirtualClustersClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a virtual cluster.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// virtualClusterName - the name of the virtual cluster.
+func (client VirtualClustersClient) Get(ctx context.Context, resourceGroupName string, virtualClusterName string) (result VirtualCluster, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, virtualClusterName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client VirtualClustersClient) GetPreparer(ctx context.Context, resourceGroupName string, virtualClusterName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualClusterName": autorest.Encode("path", virtualClusterName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualClustersClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client VirtualClustersClient) GetResponder(resp *http.Response) (result VirtualCluster, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List gets a list of all virtualClusters in the subscription.
+func (client VirtualClustersClient) List(ctx context.Context) (result VirtualClusterListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.List")
+ defer func() {
+ sc := -1
+ if result.vclr.Response.Response != nil {
+ sc = result.vclr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.vclr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.vclr, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client VirtualClustersClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Sql/virtualClusters", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualClustersClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client VirtualClustersClient) ListResponder(resp *http.Response) (result VirtualClusterListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client VirtualClustersClient) listNextResults(ctx context.Context, lastResults VirtualClusterListResult) (result VirtualClusterListResult, err error) {
+ req, err := lastResults.virtualClusterListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client VirtualClustersClient) ListComplete(ctx context.Context) (result VirtualClusterListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
+
+// ListByResourceGroup gets a list of virtual clusters in a resource group.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+func (client VirtualClustersClient) ListByResourceGroup(ctx context.Context, resourceGroupName string) (result VirtualClusterListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.vclr.Response.Response != nil {
+ sc = result.vclr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByResourceGroupNextResults
+ req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.vclr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.vclr, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "ListByResourceGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
+func (client VirtualClustersClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualClustersClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
+// closes the http.Response Body.
+func (client VirtualClustersClient) ListByResourceGroupResponder(resp *http.Response) (result VirtualClusterListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByResourceGroupNextResults retrieves the next set of results, if any.
+func (client VirtualClustersClient) listByResourceGroupNextResults(ctx context.Context, lastResults VirtualClusterListResult) (result VirtualClusterListResult, err error) {
+ req, err := lastResults.virtualClusterListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client VirtualClustersClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result VirtualClusterListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByResourceGroup(ctx, resourceGroupName)
+ return
+}
+
+// Update updates a virtual cluster.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// virtualClusterName - the name of the virtual cluster.
+// parameters - the requested managed instance resource state.
+func (client VirtualClustersClient) Update(ctx context.Context, resourceGroupName string, virtualClusterName string, parameters VirtualClusterUpdate) (result VirtualClustersUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualClustersClient.Update")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.UpdatePreparer(ctx, resourceGroupName, virtualClusterName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Update", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.UpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualClustersClient", "Update", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// UpdatePreparer prepares the Update request.
+func (client VirtualClustersClient) UpdatePreparer(ctx context.Context, resourceGroupName string, virtualClusterName string, parameters VirtualClusterUpdate) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualClusterName": autorest.Encode("path", virtualClusterName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPatch(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/virtualClusters/{virtualClusterName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// UpdateSender sends the Update request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualClustersClient) UpdateSender(req *http.Request) (future VirtualClustersUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// UpdateResponder handles the response to the Update request. The method always
+// closes the http.Response Body.
+func (client VirtualClustersClient) UpdateResponder(resp *http.Response) (result VirtualCluster, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualnetworkrules.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualnetworkrules.go
index f4a8ea03d576..492473c92165 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualnetworkrules.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql/virtualnetworkrules.go
@@ -1,409 +1,409 @@
-package sql
-
-// 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 (
- "context"
- "github.com/Azure/go-autorest/autorest"
- "github.com/Azure/go-autorest/autorest/azure"
- "github.com/Azure/go-autorest/autorest/validation"
- "github.com/Azure/go-autorest/tracing"
- "net/http"
-)
-
-// VirtualNetworkRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
-// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
-// and delete databases.
-type VirtualNetworkRulesClient struct {
- BaseClient
-}
-
-// NewVirtualNetworkRulesClient creates an instance of the VirtualNetworkRulesClient client.
-func NewVirtualNetworkRulesClient(subscriptionID string) VirtualNetworkRulesClient {
- return NewVirtualNetworkRulesClientWithBaseURI(DefaultBaseURI, subscriptionID)
-}
-
-// NewVirtualNetworkRulesClientWithBaseURI creates an instance of the VirtualNetworkRulesClient client.
-func NewVirtualNetworkRulesClientWithBaseURI(baseURI string, subscriptionID string) VirtualNetworkRulesClient {
- return VirtualNetworkRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
-}
-
-// CreateOrUpdate creates or updates an existing virtual network rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// virtualNetworkRuleName - the name of the virtual network rule.
-// parameters - the requested virtual Network Rule Resource state.
-func (client VirtualNetworkRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string, parameters VirtualNetworkRule) (result VirtualNetworkRulesCreateOrUpdateFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.CreateOrUpdate")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: parameters,
- Constraints: []validation.Constraint{{Target: "parameters.VirtualNetworkRuleProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "parameters.VirtualNetworkRuleProperties.VirtualNetworkSubnetID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("sql.VirtualNetworkRulesClient", "CreateOrUpdate", err.Error())
- }
-
- req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName, parameters)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
- return
- }
-
- result, err = client.CreateOrUpdateSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client VirtualNetworkRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string, parameters VirtualNetworkRule) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
- autorest.WithJSON(parameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualNetworkRulesClient) CreateOrUpdateSender(req *http.Request) (future VirtualNetworkRulesCreateOrUpdateFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
-// closes the http.Response Body.
-func (client VirtualNetworkRulesClient) CreateOrUpdateResponder(resp *http.Response) (result VirtualNetworkRule, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// Delete deletes the virtual network rule with the given name.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// virtualNetworkRuleName - the name of the virtual network rule.
-func (client VirtualNetworkRulesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result VirtualNetworkRulesDeleteFuture, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.Delete")
- defer func() {
- sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Delete", nil, "Failure preparing request")
- return
- }
-
- result, err = client.DeleteSender(req)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Delete", result.Response(), "Failure sending request")
- return
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client VirtualNetworkRulesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualNetworkRulesClient) DeleteSender(req *http.Request) (future VirtualNetworkRulesDeleteFuture, err error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client VirtualNetworkRulesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
- return
-}
-
-// Get gets a virtual network rule.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-// virtualNetworkRuleName - the name of the virtual network rule.
-func (client VirtualNetworkRulesClient) Get(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result VirtualNetworkRule, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.Get")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.GetPreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client VirtualNetworkRulesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualNetworkRulesClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client VirtualNetworkRulesClient) GetResponder(resp *http.Response) (result VirtualNetworkRule, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// ListByServer gets a list of virtual network rules in a server.
-// Parameters:
-// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
-// from the Azure Resource Manager API or the portal.
-// serverName - the name of the server.
-func (client VirtualNetworkRulesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result VirtualNetworkRuleListResultPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.ListByServer")
- defer func() {
- sc := -1
- if result.vnrlr.Response.Response != nil {
- sc = result.vnrlr.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.fn = client.listByServerNextResults
- req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.vnrlr.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", resp, "Failure sending request")
- return
- }
-
- result.vnrlr, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", resp, "Failure responding to request")
- }
-
- return
-}
-
-// ListByServerPreparer prepares the ListByServer request.
-func (client VirtualNetworkRulesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "serverName": autorest.Encode("path", serverName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2015-05-01-preview"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListByServerSender sends the ListByServer request. The method will close the
-// http.Response Body if it receives an error.
-func (client VirtualNetworkRulesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListByServerResponder handles the response to the ListByServer request. The method always
-// closes the http.Response Body.
-func (client VirtualNetworkRulesClient) ListByServerResponder(resp *http.Response) (result VirtualNetworkRuleListResult, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listByServerNextResults retrieves the next set of results, if any.
-func (client VirtualNetworkRulesClient) listByServerNextResults(ctx context.Context, lastResults VirtualNetworkRuleListResult) (result VirtualNetworkRuleListResult, err error) {
- req, err := lastResults.virtualNetworkRuleListResultPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListByServerSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListByServerResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
-func (client VirtualNetworkRulesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result VirtualNetworkRuleListResultIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.ListByServer")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
- return
-}
+package sql
+
+// 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 (
+ "context"
+ "github.com/Azure/go-autorest/autorest"
+ "github.com/Azure/go-autorest/autorest/azure"
+ "github.com/Azure/go-autorest/autorest/validation"
+ "github.com/Azure/go-autorest/tracing"
+ "net/http"
+)
+
+// VirtualNetworkRulesClient is the the Azure SQL Database management API provides a RESTful set of web services that
+// interact with Azure SQL Database services to manage your databases. The API enables you to create, retrieve, update,
+// and delete databases.
+type VirtualNetworkRulesClient struct {
+ BaseClient
+}
+
+// NewVirtualNetworkRulesClient creates an instance of the VirtualNetworkRulesClient client.
+func NewVirtualNetworkRulesClient(subscriptionID string) VirtualNetworkRulesClient {
+ return NewVirtualNetworkRulesClientWithBaseURI(DefaultBaseURI, subscriptionID)
+}
+
+// NewVirtualNetworkRulesClientWithBaseURI creates an instance of the VirtualNetworkRulesClient client.
+func NewVirtualNetworkRulesClientWithBaseURI(baseURI string, subscriptionID string) VirtualNetworkRulesClient {
+ return VirtualNetworkRulesClient{NewWithBaseURI(baseURI, subscriptionID)}
+}
+
+// CreateOrUpdate creates or updates an existing virtual network rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// virtualNetworkRuleName - the name of the virtual network rule.
+// parameters - the requested virtual Network Rule Resource state.
+func (client VirtualNetworkRulesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string, parameters VirtualNetworkRule) (result VirtualNetworkRulesCreateOrUpdateFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.CreateOrUpdate")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: parameters,
+ Constraints: []validation.Constraint{{Target: "parameters.VirtualNetworkRuleProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.VirtualNetworkRuleProperties.VirtualNetworkSubnetID", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("sql.VirtualNetworkRulesClient", "CreateOrUpdate", err.Error())
+ }
+
+ req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName, parameters)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "CreateOrUpdate", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.CreateOrUpdateSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client VirtualNetworkRulesClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string, parameters VirtualNetworkRule) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
+ autorest.WithJSON(parameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualNetworkRulesClient) CreateOrUpdateSender(req *http.Request) (future VirtualNetworkRulesCreateOrUpdateFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// closes the http.Response Body.
+func (client VirtualNetworkRulesClient) CreateOrUpdateResponder(resp *http.Response) (result VirtualNetworkRule, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// Delete deletes the virtual network rule with the given name.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// virtualNetworkRuleName - the name of the virtual network rule.
+func (client VirtualNetworkRulesClient) Delete(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result VirtualNetworkRulesDeleteFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.DeletePreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Delete", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.DeleteSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Delete", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client VirtualNetworkRulesClient) DeletePreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualNetworkRulesClient) DeleteSender(req *http.Request) (future VirtualNetworkRulesDeleteFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client VirtualNetworkRulesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
+ return
+}
+
+// Get gets a virtual network rule.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+// virtualNetworkRuleName - the name of the virtual network rule.
+func (client VirtualNetworkRulesClient) Get(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (result VirtualNetworkRule, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.Get")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ req, err := client.GetPreparer(ctx, resourceGroupName, serverName, virtualNetworkRuleName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client VirtualNetworkRulesClient) GetPreparer(ctx context.Context, resourceGroupName string, serverName string, virtualNetworkRuleName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "virtualNetworkRuleName": autorest.Encode("path", virtualNetworkRuleName),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules/{virtualNetworkRuleName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualNetworkRulesClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client VirtualNetworkRulesClient) GetResponder(resp *http.Response) (result VirtualNetworkRule, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByServer gets a list of virtual network rules in a server.
+// Parameters:
+// resourceGroupName - the name of the resource group that contains the resource. You can obtain this value
+// from the Azure Resource Manager API or the portal.
+// serverName - the name of the server.
+func (client VirtualNetworkRulesClient) ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result VirtualNetworkRuleListResultPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.vnrlr.Response.Response != nil {
+ sc = result.vnrlr.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listByServerNextResults
+ req, err := client.ListByServerPreparer(ctx, resourceGroupName, serverName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.vnrlr.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", resp, "Failure sending request")
+ return
+ }
+
+ result.vnrlr, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "ListByServer", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByServerPreparer prepares the ListByServer request.
+func (client VirtualNetworkRulesClient) ListByServerPreparer(ctx context.Context, resourceGroupName string, serverName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "serverName": autorest.Encode("path", serverName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2015-05-01-preview"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/virtualNetworkRules", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListByServerSender sends the ListByServer request. The method will close the
+// http.Response Body if it receives an error.
+func (client VirtualNetworkRulesClient) ListByServerSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListByServerResponder handles the response to the ListByServer request. The method always
+// closes the http.Response Body.
+func (client VirtualNetworkRulesClient) ListByServerResponder(resp *http.Response) (result VirtualNetworkRuleListResult, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listByServerNextResults retrieves the next set of results, if any.
+func (client VirtualNetworkRulesClient) listByServerNextResults(ctx context.Context, lastResults VirtualNetworkRuleListResult) (result VirtualNetworkRuleListResult, err error) {
+ req, err := lastResults.virtualNetworkRuleListResultPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListByServerSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListByServerResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "sql.VirtualNetworkRulesClient", "listByServerNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListByServerComplete enumerates all values, automatically crossing page boundaries as required.
+func (client VirtualNetworkRulesClient) ListByServerComplete(ctx context.Context, resourceGroupName string, serverName string) (result VirtualNetworkRuleListResultIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/VirtualNetworkRulesClient.ListByServer")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListByServer(ctx, resourceGroupName, serverName)
+ return
+}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-10-01-preview/sql/sqlapi/interfaces.go b/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-10-01-preview/sql/sqlapi/interfaces.go
deleted file mode 100644
index 9b696e175f46..000000000000
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-10-01-preview/sql/sqlapi/interfaces.go
+++ /dev/null
@@ -1,178 +0,0 @@
-package sqlapi
-
-// 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 (
- "context"
- "github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-10-01-preview/sql"
- "github.com/Azure/go-autorest/autorest"
- "github.com/satori/go.uuid"
-)
-
-// DatabaseOperationsClientAPI contains the set of methods on the DatabaseOperationsClient type.
-type DatabaseOperationsClientAPI interface {
- Cancel(ctx context.Context, resourceGroupName string, serverName string, databaseName string, operationID uuid.UUID) (result autorest.Response, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabaseOperationListResultPage, err error)
-}
-
-var _ DatabaseOperationsClientAPI = (*sql.DatabaseOperationsClient)(nil)
-
-// ElasticPoolOperationsClientAPI contains the set of methods on the ElasticPoolOperationsClient type.
-type ElasticPoolOperationsClientAPI interface {
- Cancel(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, operationID uuid.UUID) (result autorest.Response, err error)
- ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPoolOperationListResultPage, err error)
-}
-
-var _ ElasticPoolOperationsClientAPI = (*sql.ElasticPoolOperationsClient)(nil)
-
-// DatabaseVulnerabilityAssessmentScansClientAPI contains the set of methods on the DatabaseVulnerabilityAssessmentScansClient type.
-type DatabaseVulnerabilityAssessmentScansClientAPI interface {
- Export(ctx context.Context, resourceGroupName string, serverName string, databaseName string, scanID string) (result sql.DatabaseVulnerabilityAssessmentScansExport, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string, scanID string) (result sql.VulnerabilityAssessmentScanRecord, err error)
- InitiateScan(ctx context.Context, resourceGroupName string, serverName string, databaseName string, scanID string) (result sql.DatabaseVulnerabilityAssessmentScansInitiateScanFuture, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.VulnerabilityAssessmentScanRecordListResultPage, err error)
-}
-
-var _ DatabaseVulnerabilityAssessmentScansClientAPI = (*sql.DatabaseVulnerabilityAssessmentScansClient)(nil)
-
-// ManagedDatabaseVulnerabilityAssessmentRuleBaselinesClientAPI contains the set of methods on the ManagedDatabaseVulnerabilityAssessmentRuleBaselinesClient type.
-type ManagedDatabaseVulnerabilityAssessmentRuleBaselinesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName, parameters sql.DatabaseVulnerabilityAssessmentRuleBaseline) (result sql.DatabaseVulnerabilityAssessmentRuleBaseline, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, ruleID string, baselineName sql.VulnerabilityAssessmentPolicyBaselineName) (result sql.DatabaseVulnerabilityAssessmentRuleBaseline, err error)
-}
-
-var _ ManagedDatabaseVulnerabilityAssessmentRuleBaselinesClientAPI = (*sql.ManagedDatabaseVulnerabilityAssessmentRuleBaselinesClient)(nil)
-
-// ManagedDatabaseVulnerabilityAssessmentScansClientAPI contains the set of methods on the ManagedDatabaseVulnerabilityAssessmentScansClient type.
-type ManagedDatabaseVulnerabilityAssessmentScansClientAPI interface {
- Export(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, scanID string) (result sql.DatabaseVulnerabilityAssessmentScansExport, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, scanID string) (result sql.VulnerabilityAssessmentScanRecord, err error)
- InitiateScan(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, scanID string) (result sql.ManagedDatabaseVulnerabilityAssessmentScansInitiateScanFuture, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.VulnerabilityAssessmentScanRecordListResultPage, err error)
-}
-
-var _ ManagedDatabaseVulnerabilityAssessmentScansClientAPI = (*sql.ManagedDatabaseVulnerabilityAssessmentScansClient)(nil)
-
-// ManagedDatabaseVulnerabilityAssessmentsClientAPI contains the set of methods on the ManagedDatabaseVulnerabilityAssessmentsClient type.
-type ManagedDatabaseVulnerabilityAssessmentsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string, parameters sql.DatabaseVulnerabilityAssessment) (result sql.DatabaseVulnerabilityAssessment, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result autorest.Response, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.DatabaseVulnerabilityAssessment, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, managedInstanceName string, databaseName string) (result sql.DatabaseVulnerabilityAssessmentListResultPage, err error)
-}
-
-var _ ManagedDatabaseVulnerabilityAssessmentsClientAPI = (*sql.ManagedDatabaseVulnerabilityAssessmentsClient)(nil)
-
-// CapabilitiesClientAPI contains the set of methods on the CapabilitiesClient type.
-type CapabilitiesClientAPI interface {
- ListByLocation(ctx context.Context, locationName string, include sql.CapabilityGroup) (result sql.LocationCapabilities, err error)
-}
-
-var _ CapabilitiesClientAPI = (*sql.CapabilitiesClient)(nil)
-
-// DatabasesClientAPI contains the set of methods on the DatabasesClient type.
-type DatabasesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.Database) (result sql.DatabasesCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.Database, err error)
- ListByElasticPool(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.DatabaseListResultPage, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string) (result sql.DatabaseListResultPage, err error)
- Pause(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesPauseFuture, err error)
- Rename(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.ResourceMoveDefinition) (result autorest.Response, err error)
- Resume(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesResumeFuture, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.DatabaseUpdate) (result sql.DatabasesUpdateFuture, err error)
- UpgradeDataWarehouse(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.DatabasesUpgradeDataWarehouseFuture, err error)
-}
-
-var _ DatabasesClientAPI = (*sql.DatabasesClient)(nil)
-
-// ElasticPoolsClientAPI contains the set of methods on the ElasticPoolsClient type.
-type ElasticPoolsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters sql.ElasticPool) (result sql.ElasticPoolsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPoolsDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string) (result sql.ElasticPool, err error)
- ListByServer(ctx context.Context, resourceGroupName string, serverName string, skip *int32) (result sql.ElasticPoolListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, elasticPoolName string, parameters sql.ElasticPoolUpdate) (result sql.ElasticPoolsUpdateFuture, err error)
-}
-
-var _ ElasticPoolsClientAPI = (*sql.ElasticPoolsClient)(nil)
-
-// InstanceFailoverGroupsClientAPI contains the set of methods on the InstanceFailoverGroupsClient type.
-type InstanceFailoverGroupsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, locationName string, failoverGroupName string, parameters sql.InstanceFailoverGroup) (result sql.InstanceFailoverGroupsCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, locationName string, failoverGroupName string) (result sql.InstanceFailoverGroupsDeleteFuture, err error)
- Failover(ctx context.Context, resourceGroupName string, locationName string, failoverGroupName string) (result sql.InstanceFailoverGroupsFailoverFuture, err error)
- ForceFailoverAllowDataLoss(ctx context.Context, resourceGroupName string, locationName string, failoverGroupName string) (result sql.InstanceFailoverGroupsForceFailoverAllowDataLossFuture, err error)
- Get(ctx context.Context, resourceGroupName string, locationName string, failoverGroupName string) (result sql.InstanceFailoverGroup, err error)
- ListByLocation(ctx context.Context, resourceGroupName string, locationName string) (result sql.InstanceFailoverGroupListResultPage, err error)
-}
-
-var _ InstanceFailoverGroupsClientAPI = (*sql.InstanceFailoverGroupsClient)(nil)
-
-// BackupShortTermRetentionPoliciesClientAPI contains the set of methods on the BackupShortTermRetentionPoliciesClient type.
-type BackupShortTermRetentionPoliciesClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.BackupShortTermRetentionPolicy) (result sql.BackupShortTermRetentionPoliciesCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.BackupShortTermRetentionPolicy, err error)
- ListByDatabase(ctx context.Context, resourceGroupName string, serverName string, databaseName string) (result sql.BackupShortTermRetentionPolicyListResultPage, err error)
- Update(ctx context.Context, resourceGroupName string, serverName string, databaseName string, parameters sql.BackupShortTermRetentionPolicy) (result sql.BackupShortTermRetentionPoliciesUpdateFuture, err error)
-}
-
-var _ BackupShortTermRetentionPoliciesClientAPI = (*sql.BackupShortTermRetentionPoliciesClient)(nil)
-
-// TdeCertificatesClientAPI contains the set of methods on the TdeCertificatesClient type.
-type TdeCertificatesClientAPI interface {
- Create(ctx context.Context, resourceGroupName string, serverName string, parameters sql.TdeCertificate) (result sql.TdeCertificatesCreateFuture, err error)
-}
-
-var _ TdeCertificatesClientAPI = (*sql.TdeCertificatesClient)(nil)
-
-// ManagedInstanceTdeCertificatesClientAPI contains the set of methods on the ManagedInstanceTdeCertificatesClient type.
-type ManagedInstanceTdeCertificatesClientAPI interface {
- Create(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters sql.TdeCertificate) (result sql.ManagedInstanceTdeCertificatesCreateFuture, err error)
-}
-
-var _ ManagedInstanceTdeCertificatesClientAPI = (*sql.ManagedInstanceTdeCertificatesClient)(nil)
-
-// ManagedInstanceKeysClientAPI contains the set of methods on the ManagedInstanceKeysClient type.
-type ManagedInstanceKeysClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, keyName string, parameters sql.ManagedInstanceKey) (result sql.ManagedInstanceKeysCreateOrUpdateFuture, err error)
- Delete(ctx context.Context, resourceGroupName string, managedInstanceName string, keyName string) (result sql.ManagedInstanceKeysDeleteFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, keyName string) (result sql.ManagedInstanceKey, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string, filter string) (result sql.ManagedInstanceKeyListResultPage, err error)
-}
-
-var _ ManagedInstanceKeysClientAPI = (*sql.ManagedInstanceKeysClient)(nil)
-
-// ManagedInstanceEncryptionProtectorsClientAPI contains the set of methods on the ManagedInstanceEncryptionProtectorsClient type.
-type ManagedInstanceEncryptionProtectorsClientAPI interface {
- CreateOrUpdate(ctx context.Context, resourceGroupName string, managedInstanceName string, parameters sql.ManagedInstanceEncryptionProtector) (result sql.ManagedInstanceEncryptionProtectorsCreateOrUpdateFuture, err error)
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstanceEncryptionProtector, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstanceEncryptionProtectorListResultPage, err error)
- Revalidate(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.ManagedInstanceEncryptionProtectorsRevalidateFuture, err error)
-}
-
-var _ ManagedInstanceEncryptionProtectorsClientAPI = (*sql.ManagedInstanceEncryptionProtectorsClient)(nil)
-
-// RecoverableManagedDatabasesClientAPI contains the set of methods on the RecoverableManagedDatabasesClient type.
-type RecoverableManagedDatabasesClientAPI interface {
- Get(ctx context.Context, resourceGroupName string, managedInstanceName string, recoverableDatabaseName string) (result sql.RecoverableManagedDatabase, err error)
- ListByInstance(ctx context.Context, resourceGroupName string, managedInstanceName string) (result sql.RecoverableManagedDatabaseListResultPage, err error)
-}
-
-var _ RecoverableManagedDatabasesClientAPI = (*sql.RecoverableManagedDatabasesClient)(nil)
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/exportjobsoperationresults.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/exportjobsoperationresults.go
index a972227cefbb..18c3bc00319a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/exportjobsoperationresults.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/exportjobsoperationresults.go
@@ -88,7 +88,7 @@ func (client ExportJobsOperationResultsClient) GetPreparer(ctx context.Context,
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobcancellations.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobcancellations.go
index 9e6511d770f8..406e01345970 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobcancellations.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobcancellations.go
@@ -87,7 +87,7 @@ func (client JobCancellationsClient) TriggerPreparer(ctx context.Context, vaultN
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobdetails.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobdetails.go
index d6a47f8ae05d..3a1c4bb385f1 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobdetails.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobdetails.go
@@ -86,7 +86,7 @@ func (client JobDetailsClient) GetPreparer(ctx context.Context, vaultName string
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/joboperationresults.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/joboperationresults.go
index 2140da9fcca5..89b5865ac595 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/joboperationresults.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/joboperationresults.go
@@ -41,7 +41,6 @@ func NewJobOperationResultsClientWithBaseURI(baseURI string, subscriptionID stri
}
// Get fetches the result of any operation.
-// the operation.
// Parameters:
// vaultName - the name of the recovery services vault.
// resourceGroupName - the name of the resource group where the recovery services vault is present.
@@ -89,7 +88,7 @@ func (client JobOperationResultsClient) GetPreparer(ctx context.Context, vaultNa
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobs.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobs.go
index e2abb35c0938..e371ecfb1e01 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobs.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobs.go
@@ -87,7 +87,7 @@ func (client JobsClient) ListPreparer(ctx context.Context, vaultName string, res
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobsgroup.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobsgroup.go
index 36452519997b..338edb73f8e9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobsgroup.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/jobsgroup.go
@@ -85,7 +85,7 @@ func (client JobsGroupClient) ExportPreparer(ctx context.Context, vaultName stri
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/models.go
index 90427aeb46f5..5f12336f208d 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/models.go
@@ -521,6 +521,8 @@ const (
JobOperationTypeBackup JobOperationType = "Backup"
// JobOperationTypeConfigureBackup ...
JobOperationTypeConfigureBackup JobOperationType = "ConfigureBackup"
+ // JobOperationTypeCrossRegionRestore ...
+ JobOperationTypeCrossRegionRestore JobOperationType = "CrossRegionRestore"
// JobOperationTypeDeleteBackupData ...
JobOperationTypeDeleteBackupData JobOperationType = "DeleteBackupData"
// JobOperationTypeDisableBackup ...
@@ -531,13 +533,15 @@ const (
JobOperationTypeRegister JobOperationType = "Register"
// JobOperationTypeRestore ...
JobOperationTypeRestore JobOperationType = "Restore"
+ // JobOperationTypeUndelete ...
+ JobOperationTypeUndelete JobOperationType = "Undelete"
// JobOperationTypeUnRegister ...
JobOperationTypeUnRegister JobOperationType = "UnRegister"
)
// PossibleJobOperationTypeValues returns an array of possible values for the JobOperationType const type.
func PossibleJobOperationTypeValues() []JobOperationType {
- return []JobOperationType{JobOperationTypeBackup, JobOperationTypeConfigureBackup, JobOperationTypeDeleteBackupData, JobOperationTypeDisableBackup, JobOperationTypeInvalid, JobOperationTypeRegister, JobOperationTypeRestore, JobOperationTypeUnRegister}
+ return []JobOperationType{JobOperationTypeBackup, JobOperationTypeConfigureBackup, JobOperationTypeCrossRegionRestore, JobOperationTypeDeleteBackupData, JobOperationTypeDisableBackup, JobOperationTypeInvalid, JobOperationTypeRegister, JobOperationTypeRestore, JobOperationTypeUndelete, JobOperationTypeUnRegister}
}
// JobStatus enumerates the values for job status.
@@ -777,6 +781,8 @@ func PossibleObjectTypeValues() []ObjectType {
type ObjectTypeBasicILRRequest string
const (
+ // ObjectTypeAzureFileShareProvisionILRRequest ...
+ ObjectTypeAzureFileShareProvisionILRRequest ObjectTypeBasicILRRequest = "AzureFileShareProvisionILRRequest"
// ObjectTypeIaasVMILRRegistrationRequest ...
ObjectTypeIaasVMILRRegistrationRequest ObjectTypeBasicILRRequest = "IaasVMILRRegistrationRequest"
// ObjectTypeILRRequest ...
@@ -785,7 +791,7 @@ const (
// PossibleObjectTypeBasicILRRequestValues returns an array of possible values for the ObjectTypeBasicILRRequest const type.
func PossibleObjectTypeBasicILRRequestValues() []ObjectTypeBasicILRRequest {
- return []ObjectTypeBasicILRRequest{ObjectTypeIaasVMILRRegistrationRequest, ObjectTypeILRRequest}
+ return []ObjectTypeBasicILRRequest{ObjectTypeAzureFileShareProvisionILRRequest, ObjectTypeIaasVMILRRegistrationRequest, ObjectTypeILRRequest}
}
// ObjectTypeBasicOperationStatusExtendedInfo enumerates the values for object type basic operation status
@@ -1012,8 +1018,6 @@ const (
ProtectableItemTypeMicrosoftClassicComputevirtualMachines ProtectableItemType = "Microsoft.ClassicCompute/virtualMachines"
// ProtectableItemTypeMicrosoftComputevirtualMachines ...
ProtectableItemTypeMicrosoftComputevirtualMachines ProtectableItemType = "Microsoft.Compute/virtualMachines"
- // ProtectableItemTypeSAPAseDatabase ...
- ProtectableItemTypeSAPAseDatabase ProtectableItemType = "SAPAseDatabase"
// ProtectableItemTypeSAPAseSystem ...
ProtectableItemTypeSAPAseSystem ProtectableItemType = "SAPAseSystem"
// ProtectableItemTypeSAPHanaDatabase ...
@@ -1032,7 +1036,7 @@ const (
// PossibleProtectableItemTypeValues returns an array of possible values for the ProtectableItemType const type.
func PossibleProtectableItemTypeValues() []ProtectableItemType {
- return []ProtectableItemType{ProtectableItemTypeAzureFileShare, ProtectableItemTypeAzureVMWorkloadProtectableItem, ProtectableItemTypeIaaSVMProtectableItem, ProtectableItemTypeMicrosoftClassicComputevirtualMachines, ProtectableItemTypeMicrosoftComputevirtualMachines, ProtectableItemTypeSAPAseDatabase, ProtectableItemTypeSAPAseSystem, ProtectableItemTypeSAPHanaDatabase, ProtectableItemTypeSAPHanaSystem, ProtectableItemTypeSQLAvailabilityGroupContainer, ProtectableItemTypeSQLDataBase, ProtectableItemTypeSQLInstance, ProtectableItemTypeWorkloadProtectableItem}
+ return []ProtectableItemType{ProtectableItemTypeAzureFileShare, ProtectableItemTypeAzureVMWorkloadProtectableItem, ProtectableItemTypeIaaSVMProtectableItem, ProtectableItemTypeMicrosoftClassicComputevirtualMachines, ProtectableItemTypeMicrosoftComputevirtualMachines, ProtectableItemTypeSAPAseSystem, ProtectableItemTypeSAPHanaDatabase, ProtectableItemTypeSAPHanaSystem, ProtectableItemTypeSQLAvailabilityGroupContainer, ProtectableItemTypeSQLDataBase, ProtectableItemTypeSQLInstance, ProtectableItemTypeWorkloadProtectableItem}
}
// ProtectedItemHealthStatus enumerates the values for protected item health status.
@@ -1181,6 +1185,23 @@ func PossibleProtectionStatusValues() []ProtectionStatus {
return []ProtectionStatus{ProtectionStatusInvalid, ProtectionStatusNotProtected, ProtectionStatusProtected, ProtectionStatusProtecting, ProtectionStatusProtectionFailed}
}
+// RecoveryMode enumerates the values for recovery mode.
+type RecoveryMode string
+
+const (
+ // RecoveryModeFileRecovery ...
+ RecoveryModeFileRecovery RecoveryMode = "FileRecovery"
+ // RecoveryModeInvalid ...
+ RecoveryModeInvalid RecoveryMode = "Invalid"
+ // RecoveryModeWorkloadRecovery ...
+ RecoveryModeWorkloadRecovery RecoveryMode = "WorkloadRecovery"
+)
+
+// PossibleRecoveryModeValues returns an array of possible values for the RecoveryMode const type.
+func PossibleRecoveryModeValues() []RecoveryMode {
+ return []RecoveryMode{RecoveryModeFileRecovery, RecoveryModeInvalid, RecoveryModeWorkloadRecovery}
+}
+
// RecoveryPointTierStatus enumerates the values for recovery point tier status.
type RecoveryPointTierStatus string
@@ -1225,6 +1246,8 @@ const (
RecoveryTypeAlternateLocation RecoveryType = "AlternateLocation"
// RecoveryTypeInvalid ...
RecoveryTypeInvalid RecoveryType = "Invalid"
+ // RecoveryTypeOffline ...
+ RecoveryTypeOffline RecoveryType = "Offline"
// RecoveryTypeOriginalLocation ...
RecoveryTypeOriginalLocation RecoveryType = "OriginalLocation"
// RecoveryTypeRestoreDisks ...
@@ -1233,7 +1256,7 @@ const (
// PossibleRecoveryTypeValues returns an array of possible values for the RecoveryType const type.
func PossibleRecoveryTypeValues() []RecoveryType {
- return []RecoveryType{RecoveryTypeAlternateLocation, RecoveryTypeInvalid, RecoveryTypeOriginalLocation, RecoveryTypeRestoreDisks}
+ return []RecoveryType{RecoveryTypeAlternateLocation, RecoveryTypeInvalid, RecoveryTypeOffline, RecoveryTypeOriginalLocation, RecoveryTypeRestoreDisks}
}
// RestorePointQueryType enumerates the values for restore point query type.
@@ -1386,6 +1409,23 @@ func PossibleScheduleRunTypeValues() []ScheduleRunType {
return []ScheduleRunType{ScheduleRunTypeDaily, ScheduleRunTypeInvalid, ScheduleRunTypeWeekly}
}
+// SoftDeleteFeatureState enumerates the values for soft delete feature state.
+type SoftDeleteFeatureState string
+
+const (
+ // SoftDeleteFeatureStateDisabled ...
+ SoftDeleteFeatureStateDisabled SoftDeleteFeatureState = "Disabled"
+ // SoftDeleteFeatureStateEnabled ...
+ SoftDeleteFeatureStateEnabled SoftDeleteFeatureState = "Enabled"
+ // SoftDeleteFeatureStateInvalid ...
+ SoftDeleteFeatureStateInvalid SoftDeleteFeatureState = "Invalid"
+)
+
+// PossibleSoftDeleteFeatureStateValues returns an array of possible values for the SoftDeleteFeatureState const type.
+func PossibleSoftDeleteFeatureStateValues() []SoftDeleteFeatureState {
+ return []SoftDeleteFeatureState{SoftDeleteFeatureStateDisabled, SoftDeleteFeatureStateEnabled, SoftDeleteFeatureStateInvalid}
+}
+
// SQLDataDirectoryType enumerates the values for sql data directory type.
type SQLDataDirectoryType string
@@ -1873,7 +1913,7 @@ type AzureBackupServerEngine struct {
IsAzureBackupAgentUpgradeAvailable *bool `json:"isAzureBackupAgentUpgradeAvailable,omitempty"`
// IsDpmUpgradeAvailable - To check if backup engine upgrade available
IsDpmUpgradeAvailable *bool `json:"isDpmUpgradeAvailable,omitempty"`
- // ExtendedInfo - Extended info of the backup engine
+ // ExtendedInfo - Extended info of the backupengine
ExtendedInfo *EngineExtendedInfo `json:"extendedInfo,omitempty"`
// BackupEngineType - Possible values include: 'BackupEngineTypeBackupEngineBase', 'BackupEngineTypeAzureBackupServerEngine', 'BackupEngineTypeDpmBackupEngine'
BackupEngineType EngineType `json:"backupEngineType,omitempty"`
@@ -2007,7 +2047,7 @@ type AzureFileShareProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -2067,11 +2107,6 @@ func (afspi AzureFileShareProtectableItem) AsBasicAzureVMWorkloadProtectableItem
return nil, false
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureFileShareProtectableItem.
-func (afspi AzureFileShareProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureFileShareProtectableItem.
func (afspi AzureFileShareProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -2326,6 +2361,10 @@ type AzureFileshareProtectedItemExtendedInfo struct {
RecoveryPointCount *int32 `json:"recoveryPointCount,omitempty"`
// PolicyState - Indicates consistency of policy object and policy applied to this backup item.
PolicyState *string `json:"policyState,omitempty"`
+ // ResourceState - READ-ONLY; Indicates the state of this resource. Possible values are from enum ResourceState {Invalid, Active, SoftDeleted, Deleted}
+ ResourceState *string `json:"resourceState,omitempty"`
+ // ResourceStateSyncTime - READ-ONLY; The resource state sync time for this backup item.
+ ResourceStateSyncTime *date.Time `json:"resourceStateSyncTime,omitempty"`
}
// AzureFileShareProtectionPolicy azureStorage backup policy.
@@ -2340,7 +2379,7 @@ type AzureFileShareProtectionPolicy struct {
TimeZone *string `json:"timeZone,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -2365,6 +2404,11 @@ func (afspp AzureFileShareProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureFileShareProtectionPolicy.
+func (afspp AzureFileShareProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for AzureFileShareProtectionPolicy.
func (afspp AzureFileShareProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return &afspp, true
@@ -2380,11 +2424,6 @@ func (afspp AzureFileShareProtectionPolicy) AsAzureSQLProtectionPolicy() (*Azure
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureFileShareProtectionPolicy.
-func (afspp AzureFileShareProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for AzureFileShareProtectionPolicy.
func (afspp AzureFileShareProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -2472,14 +2511,63 @@ func (afspp *AzureFileShareProtectionPolicy) UnmarshalJSON(body []byte) error {
return nil
}
+// AzureFileShareProvisionILRRequest update snapshot Uri with the correct friendly Name of the source Azure
+// file share.
+type AzureFileShareProvisionILRRequest struct {
+ // RecoveryPointID - Recovery point ID.
+ RecoveryPointID *string `json:"recoveryPointId,omitempty"`
+ // SourceResourceID - Source Storage account ARM Id
+ SourceResourceID *string `json:"sourceResourceId,omitempty"`
+ // ObjectType - Possible values include: 'ObjectTypeILRRequest', 'ObjectTypeAzureFileShareProvisionILRRequest', 'ObjectTypeIaasVMILRRegistrationRequest'
+ ObjectType ObjectTypeBasicILRRequest `json:"objectType,omitempty"`
+}
+
+// MarshalJSON is the custom marshaler for AzureFileShareProvisionILRRequest.
+func (afspir AzureFileShareProvisionILRRequest) MarshalJSON() ([]byte, error) {
+ afspir.ObjectType = ObjectTypeAzureFileShareProvisionILRRequest
+ objectMap := make(map[string]interface{})
+ if afspir.RecoveryPointID != nil {
+ objectMap["recoveryPointId"] = afspir.RecoveryPointID
+ }
+ if afspir.SourceResourceID != nil {
+ objectMap["sourceResourceId"] = afspir.SourceResourceID
+ }
+ if afspir.ObjectType != "" {
+ objectMap["objectType"] = afspir.ObjectType
+ }
+ return json.Marshal(objectMap)
+}
+
+// AsAzureFileShareProvisionILRRequest is the BasicILRRequest implementation for AzureFileShareProvisionILRRequest.
+func (afspir AzureFileShareProvisionILRRequest) AsAzureFileShareProvisionILRRequest() (*AzureFileShareProvisionILRRequest, bool) {
+ return &afspir, true
+}
+
+// AsIaasVMILRRegistrationRequest is the BasicILRRequest implementation for AzureFileShareProvisionILRRequest.
+func (afspir AzureFileShareProvisionILRRequest) AsIaasVMILRRegistrationRequest() (*IaasVMILRRegistrationRequest, bool) {
+ return nil, false
+}
+
+// AsILRRequest is the BasicILRRequest implementation for AzureFileShareProvisionILRRequest.
+func (afspir AzureFileShareProvisionILRRequest) AsILRRequest() (*ILRRequest, bool) {
+ return nil, false
+}
+
+// AsBasicILRRequest is the BasicILRRequest implementation for AzureFileShareProvisionILRRequest.
+func (afspir AzureFileShareProvisionILRRequest) AsBasicILRRequest() (BasicILRRequest, bool) {
+ return &afspir, true
+}
+
// AzureFileShareRecoveryPoint azure File Share workload specific backup copy.
type AzureFileShareRecoveryPoint struct {
- // RecoveryPointType - Type of the backup copy. Specifies whether it is a crash consistent backup or app consistent.
+ // RecoveryPointType - READ-ONLY; Type of the backup copy. Specifies whether it is a crash consistent backup or app consistent.
RecoveryPointType *string `json:"recoveryPointType,omitempty"`
- // RecoveryPointTime - Time at which this backup copy was created.
+ // RecoveryPointTime - READ-ONLY; Time at which this backup copy was created.
RecoveryPointTime *date.Time `json:"recoveryPointTime,omitempty"`
- // FileShareSnapshotURI - Contains Url to the snapshot of fileshare, if applicable
+ // FileShareSnapshotURI - READ-ONLY; Contains Url to the snapshot of fileshare, if applicable
FileShareSnapshotURI *string `json:"fileShareSnapshotUri,omitempty"`
+ // RecoveryPointSizeInGB - READ-ONLY; Contains recovery point size
+ RecoveryPointSizeInGB *int32 `json:"recoveryPointSizeInGB,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
}
@@ -2488,15 +2576,6 @@ type AzureFileShareRecoveryPoint struct {
func (afsrp AzureFileShareRecoveryPoint) MarshalJSON() ([]byte, error) {
afsrp.ObjectType = ObjectTypeAzureFileShareRecoveryPoint
objectMap := make(map[string]interface{})
- if afsrp.RecoveryPointType != nil {
- objectMap["recoveryPointType"] = afsrp.RecoveryPointType
- }
- if afsrp.RecoveryPointTime != nil {
- objectMap["recoveryPointTime"] = afsrp.RecoveryPointTime
- }
- if afsrp.FileShareSnapshotURI != nil {
- objectMap["fileShareSnapshotUri"] = afsrp.FileShareSnapshotURI
- }
if afsrp.ObjectType != "" {
objectMap["objectType"] = afsrp.ObjectType
}
@@ -2575,7 +2654,7 @@ func (afsrp AzureFileShareRecoveryPoint) AsBasicRecoveryPoint() (BasicRecoveryPo
// AzureFileShareRestoreRequest azureFileShare Restore Request
type AzureFileShareRestoreRequest struct {
- // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Source storage account ARM Id
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -2834,7 +2913,7 @@ type AzureIaaSClassicComputeVMProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -2888,11 +2967,6 @@ func (aisccvpi AzureIaaSClassicComputeVMProtectableItem) AsBasicAzureVMWorkloadP
return nil, false
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureIaaSClassicComputeVMProtectableItem.
-func (aisccvpi AzureIaaSClassicComputeVMProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureIaaSClassicComputeVMProtectableItem.
func (aisccvpi AzureIaaSClassicComputeVMProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -2965,7 +3039,8 @@ type AzureIaaSClassicComputeVMProtectedItem struct {
// ProtectedItemDataID - Data ID of the protected item.
ProtectedItemDataID *string `json:"protectedItemDataId,omitempty"`
// ExtendedInfo - Additional information for this backup item.
- ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedProperties *ExtendedProperties `json:"extendedProperties,omitempty"`
// BackupManagementType - Type of backup management for the backed up item. Possible values include: 'ManagementTypeInvalid', 'ManagementTypeAzureIaasVM', 'ManagementTypeMAB', 'ManagementTypeDPM', 'ManagementTypeAzureBackupServer', 'ManagementTypeAzureSQL', 'ManagementTypeAzureStorage', 'ManagementTypeAzureWorkload', 'ManagementTypeDefaultBackup'
BackupManagementType ManagementType `json:"backupManagementType,omitempty"`
// WorkloadType - Type of workload this item represents. Possible values include: 'DataSourceTypeInvalid', 'DataSourceTypeVM', 'DataSourceTypeFileFolder', 'DataSourceTypeAzureSQLDb', 'DataSourceTypeSQLDB', 'DataSourceTypeExchange', 'DataSourceTypeSharepoint', 'DataSourceTypeVMwareVM', 'DataSourceTypeSystemState', 'DataSourceTypeClient', 'DataSourceTypeGenericDataSource', 'DataSourceTypeSQLDataBase', 'DataSourceTypeAzureFileShare', 'DataSourceTypeSAPHanaDatabase', 'DataSourceTypeSAPAseDatabase'
@@ -3030,6 +3105,9 @@ func (aisccvpi AzureIaaSClassicComputeVMProtectedItem) MarshalJSON() ([]byte, er
if aisccvpi.ExtendedInfo != nil {
objectMap["extendedInfo"] = aisccvpi.ExtendedInfo
}
+ if aisccvpi.ExtendedProperties != nil {
+ objectMap["extendedProperties"] = aisccvpi.ExtendedProperties
+ }
if aisccvpi.BackupManagementType != "" {
objectMap["backupManagementType"] = aisccvpi.BackupManagementType
}
@@ -3305,7 +3383,7 @@ type AzureIaaSComputeVMProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -3359,11 +3437,6 @@ func (aiscvpi AzureIaaSComputeVMProtectableItem) AsBasicAzureVMWorkloadProtectab
return nil, false
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureIaaSComputeVMProtectableItem.
-func (aiscvpi AzureIaaSComputeVMProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureIaaSComputeVMProtectableItem.
func (aiscvpi AzureIaaSComputeVMProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -3436,7 +3509,8 @@ type AzureIaaSComputeVMProtectedItem struct {
// ProtectedItemDataID - Data ID of the protected item.
ProtectedItemDataID *string `json:"protectedItemDataId,omitempty"`
// ExtendedInfo - Additional information for this backup item.
- ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedProperties *ExtendedProperties `json:"extendedProperties,omitempty"`
// BackupManagementType - Type of backup management for the backed up item. Possible values include: 'ManagementTypeInvalid', 'ManagementTypeAzureIaasVM', 'ManagementTypeMAB', 'ManagementTypeDPM', 'ManagementTypeAzureBackupServer', 'ManagementTypeAzureSQL', 'ManagementTypeAzureStorage', 'ManagementTypeAzureWorkload', 'ManagementTypeDefaultBackup'
BackupManagementType ManagementType `json:"backupManagementType,omitempty"`
// WorkloadType - Type of workload this item represents. Possible values include: 'DataSourceTypeInvalid', 'DataSourceTypeVM', 'DataSourceTypeFileFolder', 'DataSourceTypeAzureSQLDb', 'DataSourceTypeSQLDB', 'DataSourceTypeExchange', 'DataSourceTypeSharepoint', 'DataSourceTypeVMwareVM', 'DataSourceTypeSystemState', 'DataSourceTypeClient', 'DataSourceTypeGenericDataSource', 'DataSourceTypeSQLDataBase', 'DataSourceTypeAzureFileShare', 'DataSourceTypeSAPHanaDatabase', 'DataSourceTypeSAPAseDatabase'
@@ -3501,6 +3575,9 @@ func (aiscvpi AzureIaaSComputeVMProtectedItem) MarshalJSON() ([]byte, error) {
if aiscvpi.ExtendedInfo != nil {
objectMap["extendedInfo"] = aiscvpi.ExtendedInfo
}
+ if aiscvpi.ExtendedProperties != nil {
+ objectMap["extendedProperties"] = aiscvpi.ExtendedProperties
+ }
if aiscvpi.BackupManagementType != "" {
objectMap["backupManagementType"] = aiscvpi.BackupManagementType
}
@@ -3628,25 +3705,25 @@ func (aiscvpi AzureIaaSComputeVMProtectedItem) AsBasicProtectedItem() (BasicProt
// AzureIaaSVMErrorInfo azure IaaS VM workload-specific error information.
type AzureIaaSVMErrorInfo struct {
- // ErrorCode - Error code.
+ // ErrorCode - READ-ONLY; Error code.
ErrorCode *int32 `json:"errorCode,omitempty"`
- // ErrorTitle - Title: Typically, the entity that the error pertains to.
+ // ErrorTitle - READ-ONLY; Title: Typically, the entity that the error pertains to.
ErrorTitle *string `json:"errorTitle,omitempty"`
- // ErrorString - Localized error string.
+ // ErrorString - READ-ONLY; Localized error string.
ErrorString *string `json:"errorString,omitempty"`
- // Recommendations - List of localized recommendations for above error code.
+ // Recommendations - READ-ONLY; List of localized recommendations for above error code.
Recommendations *[]string `json:"recommendations,omitempty"`
}
// AzureIaaSVMHealthDetails azure IaaS VM workload-specific Health Details.
type AzureIaaSVMHealthDetails struct {
- // Code - Health Code
+ // Code - READ-ONLY; Health Code
Code *int32 `json:"code,omitempty"`
- // Title - Health Title
+ // Title - READ-ONLY; Health Title
Title *string `json:"title,omitempty"`
- // Message - Health Message
+ // Message - READ-ONLY; Health Message
Message *string `json:"message,omitempty"`
- // Recommendations - Health Recommended Actions
+ // Recommendations - READ-ONLY; Health Recommended Actions
Recommendations *[]string `json:"recommendations,omitempty"`
}
@@ -3850,7 +3927,8 @@ type AzureIaaSVMProtectedItem struct {
// ProtectedItemDataID - Data ID of the protected item.
ProtectedItemDataID *string `json:"protectedItemDataId,omitempty"`
// ExtendedInfo - Additional information for this backup item.
- ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedInfo *AzureIaaSVMProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
+ ExtendedProperties *ExtendedProperties `json:"extendedProperties,omitempty"`
// BackupManagementType - Type of backup management for the backed up item. Possible values include: 'ManagementTypeInvalid', 'ManagementTypeAzureIaasVM', 'ManagementTypeMAB', 'ManagementTypeDPM', 'ManagementTypeAzureBackupServer', 'ManagementTypeAzureSQL', 'ManagementTypeAzureStorage', 'ManagementTypeAzureWorkload', 'ManagementTypeDefaultBackup'
BackupManagementType ManagementType `json:"backupManagementType,omitempty"`
// WorkloadType - Type of workload this item represents. Possible values include: 'DataSourceTypeInvalid', 'DataSourceTypeVM', 'DataSourceTypeFileFolder', 'DataSourceTypeAzureSQLDb', 'DataSourceTypeSQLDB', 'DataSourceTypeExchange', 'DataSourceTypeSharepoint', 'DataSourceTypeVMwareVM', 'DataSourceTypeSystemState', 'DataSourceTypeClient', 'DataSourceTypeGenericDataSource', 'DataSourceTypeSQLDataBase', 'DataSourceTypeAzureFileShare', 'DataSourceTypeSAPHanaDatabase', 'DataSourceTypeSAPAseDatabase'
@@ -3956,6 +4034,9 @@ func (aispi AzureIaaSVMProtectedItem) MarshalJSON() ([]byte, error) {
if aispi.ExtendedInfo != nil {
objectMap["extendedInfo"] = aispi.ExtendedInfo
}
+ if aispi.ExtendedProperties != nil {
+ objectMap["extendedProperties"] = aispi.ExtendedProperties
+ }
if aispi.BackupManagementType != "" {
objectMap["backupManagementType"] = aispi.BackupManagementType
}
@@ -4103,7 +4184,7 @@ type AzureIaaSVMProtectionPolicy struct {
TimeZone *string `json:"timeZone,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -4128,6 +4209,11 @@ func (aispp AzureIaaSVMProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureIaaSVMProtectionPolicy.
+func (aispp AzureIaaSVMProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for AzureIaaSVMProtectionPolicy.
func (aispp AzureIaaSVMProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -4143,11 +4229,6 @@ func (aispp AzureIaaSVMProtectionPolicy) AsAzureSQLProtectionPolicy() (*AzureSQL
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureIaaSVMProtectionPolicy.
-func (aispp AzureIaaSVMProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for AzureIaaSVMProtectionPolicy.
func (aispp AzureIaaSVMProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -4910,7 +4991,7 @@ type AzureSQLProtectionPolicy struct {
RetentionPolicy BasicRetentionPolicy `json:"retentionPolicy,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -4928,6 +5009,11 @@ func (aspp AzureSQLProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureSQLProtectionPolicy.
+func (aspp AzureSQLProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for AzureSQLProtectionPolicy.
func (aspp AzureSQLProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -4943,11 +5029,6 @@ func (aspp AzureSQLProtectionPolicy) AsAzureSQLProtectionPolicy() (*AzureSQLProt
return &aspp, true
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureSQLProtectionPolicy.
-func (aspp AzureSQLProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for AzureSQLProtectionPolicy.
func (aspp AzureSQLProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -5639,9 +5720,9 @@ type AzureVMWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -5801,7 +5882,6 @@ func (avwi AzureVMWorkloadItem) AsBasicWorkloadItem() (BasicWorkloadItem, bool)
// BasicAzureVMWorkloadProtectableItem azure VM workload-specific protectable item.
type BasicAzureVMWorkloadProtectableItem interface {
- AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool)
AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool)
AsAzureVMWorkloadSAPHanaDatabaseProtectableItem() (*AzureVMWorkloadSAPHanaDatabaseProtectableItem, bool)
AsAzureVMWorkloadSAPHanaSystemProtectableItem() (*AzureVMWorkloadSAPHanaSystemProtectableItem, bool)
@@ -5824,9 +5904,9 @@ type AzureVMWorkloadProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -5838,7 +5918,7 @@ type AzureVMWorkloadProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -5850,10 +5930,6 @@ func unmarshalBasicAzureVMWorkloadProtectableItem(body []byte) (BasicAzureVMWork
}
switch m["protectableItemType"] {
- case string(ProtectableItemTypeSAPAseDatabase):
- var avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem
- err := json.Unmarshal(body, &avwsadpi)
- return avwsadpi, err
case string(ProtectableItemTypeSAPAseSystem):
var avwsaspi AzureVMWorkloadSAPAseSystemProtectableItem
err := json.Unmarshal(body, &avwsaspi)
@@ -5974,11 +6050,6 @@ func (avwpi AzureVMWorkloadProtectableItem) AsBasicAzureVMWorkloadProtectableIte
return &avwpi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadProtectableItem.
-func (avwpi AzureVMWorkloadProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadProtectableItem.
func (avwpi AzureVMWorkloadProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -6322,9 +6393,11 @@ type AzureVMWorkloadProtectionPolicy struct {
Settings *Settings `json:"settings,omitempty"`
// SubProtectionPolicy - List of sub-protection policies which includes schedule and retention
SubProtectionPolicy *[]SubProtectionPolicy `json:"subProtectionPolicy,omitempty"`
+ // MakePolicyConsistent - Fix the policy inconsistency
+ MakePolicyConsistent *bool `json:"makePolicyConsistent,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -6341,6 +6414,9 @@ func (avwpp AzureVMWorkloadProtectionPolicy) MarshalJSON() ([]byte, error) {
if avwpp.SubProtectionPolicy != nil {
objectMap["subProtectionPolicy"] = avwpp.SubProtectionPolicy
}
+ if avwpp.MakePolicyConsistent != nil {
+ objectMap["makePolicyConsistent"] = avwpp.MakePolicyConsistent
+ }
if avwpp.ProtectedItemsCount != nil {
objectMap["protectedItemsCount"] = avwpp.ProtectedItemsCount
}
@@ -6350,6 +6426,11 @@ func (avwpp AzureVMWorkloadProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureVMWorkloadProtectionPolicy.
+func (avwpp AzureVMWorkloadProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return &avwpp, true
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for AzureVMWorkloadProtectionPolicy.
func (avwpp AzureVMWorkloadProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -6365,11 +6446,6 @@ func (avwpp AzureVMWorkloadProtectionPolicy) AsAzureSQLProtectionPolicy() (*Azur
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for AzureVMWorkloadProtectionPolicy.
-func (avwpp AzureVMWorkloadProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return &avwpp, true
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for AzureVMWorkloadProtectionPolicy.
func (avwpp AzureVMWorkloadProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -6390,164 +6466,6 @@ func (avwpp AzureVMWorkloadProtectionPolicy) AsBasicProtectionPolicy() (BasicPro
return &avwpp, true
}
-// AzureVMWorkloadSAPAseDatabaseProtectableItem azure VM workload-specific protectable item representing
-// SAP ASE Database.
-type AzureVMWorkloadSAPAseDatabaseProtectableItem struct {
- // ParentName - Name for instance or AG
- ParentName *string `json:"parentName,omitempty"`
- // ParentUniqueName - Parent Unique Name is added to provide the service formatted URI Name of the Parent
- // Only Applicable for data bases where the parent would be either Instance or a SQL AG.
- ParentUniqueName *string `json:"parentUniqueName,omitempty"`
- // ServerName - Host/Cluster Name for instance or AG
- ServerName *string `json:"serverName,omitempty"`
- // IsAutoProtectable - Indicates if protectable item is auto-protectable
- IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // IsAutoProtected - Indicates if protectable item is auto-protected
- IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
- Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
- Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
- // Prebackupvalidation - Pre-backup validation for protectable objects
- Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
- // BackupManagementType - Type of backup management to backup an item.
- BackupManagementType *string `json:"backupManagementType,omitempty"`
- // WorkloadType - Type of workload for the backup management
- WorkloadType *string `json:"workloadType,omitempty"`
- // FriendlyName - Friendly name of the backup item.
- FriendlyName *string `json:"friendlyName,omitempty"`
- // ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
- ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
- ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) MarshalJSON() ([]byte, error) {
- avwsadpi.ProtectableItemType = ProtectableItemTypeSAPAseDatabase
- objectMap := make(map[string]interface{})
- if avwsadpi.ParentName != nil {
- objectMap["parentName"] = avwsadpi.ParentName
- }
- if avwsadpi.ParentUniqueName != nil {
- objectMap["parentUniqueName"] = avwsadpi.ParentUniqueName
- }
- if avwsadpi.ServerName != nil {
- objectMap["serverName"] = avwsadpi.ServerName
- }
- if avwsadpi.IsAutoProtectable != nil {
- objectMap["isAutoProtectable"] = avwsadpi.IsAutoProtectable
- }
- if avwsadpi.IsAutoProtected != nil {
- objectMap["isAutoProtected"] = avwsadpi.IsAutoProtected
- }
- if avwsadpi.Subinquireditemcount != nil {
- objectMap["subinquireditemcount"] = avwsadpi.Subinquireditemcount
- }
- if avwsadpi.Subprotectableitemcount != nil {
- objectMap["subprotectableitemcount"] = avwsadpi.Subprotectableitemcount
- }
- if avwsadpi.Prebackupvalidation != nil {
- objectMap["prebackupvalidation"] = avwsadpi.Prebackupvalidation
- }
- if avwsadpi.BackupManagementType != nil {
- objectMap["backupManagementType"] = avwsadpi.BackupManagementType
- }
- if avwsadpi.WorkloadType != nil {
- objectMap["workloadType"] = avwsadpi.WorkloadType
- }
- if avwsadpi.FriendlyName != nil {
- objectMap["friendlyName"] = avwsadpi.FriendlyName
- }
- if avwsadpi.ProtectionState != "" {
- objectMap["protectionState"] = avwsadpi.ProtectionState
- }
- if avwsadpi.ProtectableItemType != "" {
- objectMap["protectableItemType"] = avwsadpi.ProtectableItemType
- }
- return json.Marshal(objectMap)
-}
-
-// AsAzureFileShareProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureFileShareProtectableItem() (*AzureFileShareProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureIaaSClassicComputeVMProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureIaaSClassicComputeVMProtectableItem() (*AzureIaaSClassicComputeVMProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureIaaSComputeVMProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureIaaSComputeVMProtectableItem() (*AzureIaaSComputeVMProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadProtectableItem() (*AzureVMWorkloadProtectableItem, bool) {
- return nil, false
-}
-
-// AsBasicAzureVMWorkloadProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsBasicAzureVMWorkloadProtectableItem() (BasicAzureVMWorkloadProtectableItem, bool) {
- return &avwsadpi, true
-}
-
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return &avwsadpi, true
-}
-
-// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadSAPHanaDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSAPHanaDatabaseProtectableItem() (*AzureVMWorkloadSAPHanaDatabaseProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadSAPHanaSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSAPHanaSystemProtectableItem() (*AzureVMWorkloadSAPHanaSystemProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadSQLAvailabilityGroupProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSQLAvailabilityGroupProtectableItem() (*AzureVMWorkloadSQLAvailabilityGroupProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadSQLDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSQLDatabaseProtectableItem() (*AzureVMWorkloadSQLDatabaseProtectableItem, bool) {
- return nil, false
-}
-
-// AsAzureVMWorkloadSQLInstanceProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsAzureVMWorkloadSQLInstanceProtectableItem() (*AzureVMWorkloadSQLInstanceProtectableItem, bool) {
- return nil, false
-}
-
-// AsIaaSVMProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsIaaSVMProtectableItem() (*IaaSVMProtectableItem, bool) {
- return nil, false
-}
-
-// AsBasicIaaSVMProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsBasicIaaSVMProtectableItem() (BasicIaaSVMProtectableItem, bool) {
- return nil, false
-}
-
-// AsWorkloadProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsWorkloadProtectableItem() (*WorkloadProtectableItem, bool) {
- return nil, false
-}
-
-// AsBasicWorkloadProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseDatabaseProtectableItem.
-func (avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem) AsBasicWorkloadProtectableItem() (BasicWorkloadProtectableItem, bool) {
- return &avwsadpi, true
-}
-
// AzureVMWorkloadSAPAseDatabaseProtectedItem azure VM workload-specific protected item representing SAP
// ASE Database.
type AzureVMWorkloadSAPAseDatabaseProtectedItem struct {
@@ -6779,9 +6697,9 @@ type AzureVMWorkloadSAPAseDatabaseWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -6896,9 +6814,9 @@ type AzureVMWorkloadSAPAseSystemProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -6910,7 +6828,7 @@ type AzureVMWorkloadSAPAseSystemProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -6985,11 +6903,6 @@ func (avwsaspi AzureVMWorkloadSAPAseSystemProtectableItem) AsBasicAzureVMWorkloa
return &avwsaspi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseSystemProtectableItem.
-func (avwsaspi AzureVMWorkloadSAPAseSystemProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPAseSystemProtectableItem.
func (avwsaspi AzureVMWorkloadSAPAseSystemProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return &avwsaspi, true
@@ -7049,9 +6962,9 @@ type AzureVMWorkloadSAPAseSystemWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -7166,9 +7079,9 @@ type AzureVMWorkloadSAPHanaDatabaseProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -7180,7 +7093,7 @@ type AzureVMWorkloadSAPHanaDatabaseProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -7255,11 +7168,6 @@ func (avwshdpi AzureVMWorkloadSAPHanaDatabaseProtectableItem) AsBasicAzureVMWork
return &avwshdpi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPHanaDatabaseProtectableItem.
-func (avwshdpi AzureVMWorkloadSAPHanaDatabaseProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPHanaDatabaseProtectableItem.
func (avwshdpi AzureVMWorkloadSAPHanaDatabaseProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -7541,9 +7449,9 @@ type AzureVMWorkloadSAPHanaDatabaseWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -7658,9 +7566,9 @@ type AzureVMWorkloadSAPHanaSystemProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -7672,7 +7580,7 @@ type AzureVMWorkloadSAPHanaSystemProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -7747,11 +7655,6 @@ func (avwshspi AzureVMWorkloadSAPHanaSystemProtectableItem) AsBasicAzureVMWorklo
return &avwshspi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPHanaSystemProtectableItem.
-func (avwshspi AzureVMWorkloadSAPHanaSystemProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSAPHanaSystemProtectableItem.
func (avwshspi AzureVMWorkloadSAPHanaSystemProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -7811,9 +7714,9 @@ type AzureVMWorkloadSAPHanaSystemWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -7928,9 +7831,9 @@ type AzureVMWorkloadSQLAvailabilityGroupProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -7942,7 +7845,7 @@ type AzureVMWorkloadSQLAvailabilityGroupProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -8017,11 +7920,6 @@ func (avwsagpi AzureVMWorkloadSQLAvailabilityGroupProtectableItem) AsBasicAzureV
return &avwsagpi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLAvailabilityGroupProtectableItem.
-func (avwsagpi AzureVMWorkloadSQLAvailabilityGroupProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLAvailabilityGroupProtectableItem.
func (avwsagpi AzureVMWorkloadSQLAvailabilityGroupProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -8086,9 +7984,9 @@ type AzureVMWorkloadSQLDatabaseProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -8100,7 +7998,7 @@ type AzureVMWorkloadSQLDatabaseProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -8175,11 +8073,6 @@ func (avwsdpi AzureVMWorkloadSQLDatabaseProtectableItem) AsBasicAzureVMWorkloadP
return &avwsdpi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLDatabaseProtectableItem.
-func (avwsdpi AzureVMWorkloadSQLDatabaseProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLDatabaseProtectableItem.
func (avwsdpi AzureVMWorkloadSQLDatabaseProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -8461,9 +8354,9 @@ type AzureVMWorkloadSQLDatabaseWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -8578,9 +8471,9 @@ type AzureVMWorkloadSQLInstanceProtectableItem struct {
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
// IsAutoProtected - Indicates if protectable item is auto-protected
IsAutoProtected *bool `json:"isAutoProtected,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // Subprotectableitemcount - For instance or AG, indicates number of DBs to be protected
+ // Subprotectableitemcount - For instance or AG, indicates number of DB's to be protected
Subprotectableitemcount *int32 `json:"subprotectableitemcount,omitempty"`
// Prebackupvalidation - Pre-backup validation for protectable objects
Prebackupvalidation *PreBackupValidation `json:"prebackupvalidation,omitempty"`
@@ -8592,7 +8485,7 @@ type AzureVMWorkloadSQLInstanceProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -8667,11 +8560,6 @@ func (avwsipi AzureVMWorkloadSQLInstanceProtectableItem) AsBasicAzureVMWorkloadP
return &avwsipi, true
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLInstanceProtectableItem.
-func (avwsipi AzureVMWorkloadSQLInstanceProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for AzureVMWorkloadSQLInstanceProtectableItem.
func (avwsipi AzureVMWorkloadSQLInstanceProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -8733,9 +8621,9 @@ type AzureVMWorkloadSQLInstanceWorkloadItem struct {
ServerName *string `json:"serverName,omitempty"`
// IsAutoProtectable - Indicates if workload item is auto-protectable
IsAutoProtectable *bool `json:"isAutoProtectable,omitempty"`
- // Subinquireditemcount - For instance or AG, indicates number of DBs present
+ // Subinquireditemcount - For instance or AG, indicates number of DB's present
Subinquireditemcount *int32 `json:"subinquireditemcount,omitempty"`
- // SubWorkloadItemCount - For instance or AG, indicates number of DBs to be protected
+ // SubWorkloadItemCount - For instance or AG, indicates number of DB's to be protected
SubWorkloadItemCount *int32 `json:"subWorkloadItemCount,omitempty"`
// BackupManagementType - Type of backup management to backup an item.
BackupManagementType *string `json:"backupManagementType,omitempty"`
@@ -9391,9 +9279,9 @@ type BasicAzureWorkloadPointInTimeRecoveryPoint interface {
type AzureWorkloadPointInTimeRecoveryPoint struct {
// TimeRanges - List of log ranges
TimeRanges *[]PointInTimeRange `json:"timeRanges,omitempty"`
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -9443,12 +9331,6 @@ func (awpitrp AzureWorkloadPointInTimeRecoveryPoint) MarshalJSON() ([]byte, erro
if awpitrp.TimeRanges != nil {
objectMap["timeRanges"] = awpitrp.TimeRanges
}
- if awpitrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awpitrp.RecoveryPointTimeInUTC
- }
- if awpitrp.Type != "" {
- objectMap["type"] = awpitrp.Type
- }
if awpitrp.ObjectType != "" {
objectMap["objectType"] = awpitrp.ObjectType
}
@@ -9530,7 +9412,7 @@ func (awpitrp AzureWorkloadPointInTimeRecoveryPoint) AsBasicRecoveryPoint() (Bas
type AzureWorkloadPointInTimeRestoreRequest struct {
// PointInTime - PointInTime value
PointInTime *date.Time `json:"pointInTime,omitempty"`
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -9538,6 +9420,8 @@ type AzureWorkloadPointInTimeRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -9561,6 +9445,9 @@ func (awpitrr AzureWorkloadPointInTimeRestoreRequest) MarshalJSON() ([]byte, err
if awpitrr.TargetInfo != nil {
objectMap["targetInfo"] = awpitrr.TargetInfo
}
+ if awpitrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awpitrr.RecoveryMode
+ }
if awpitrr.ObjectType != "" {
objectMap["objectType"] = awpitrr.ObjectType
}
@@ -9647,9 +9534,9 @@ type BasicAzureWorkloadRecoveryPoint interface {
// AzureWorkloadRecoveryPoint workload specific recovery point, specifically encapsulates full/diff recovery
// point
type AzureWorkloadRecoveryPoint struct {
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -9712,12 +9599,6 @@ func unmarshalBasicAzureWorkloadRecoveryPointArray(body []byte) ([]BasicAzureWor
func (awrp AzureWorkloadRecoveryPoint) MarshalJSON() ([]byte, error) {
awrp.ObjectType = ObjectTypeAzureWorkloadRecoveryPoint
objectMap := make(map[string]interface{})
- if awrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awrp.RecoveryPointTimeInUTC
- }
- if awrp.Type != "" {
- objectMap["type"] = awrp.Type
- }
if awrp.ObjectType != "" {
objectMap["objectType"] = awrp.ObjectType
}
@@ -9808,7 +9689,7 @@ type BasicAzureWorkloadRestoreRequest interface {
// AzureWorkloadRestoreRequest azureWorkload-specific restore.
type AzureWorkloadRestoreRequest struct {
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -9816,6 +9697,8 @@ type AzureWorkloadRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -9889,6 +9772,9 @@ func (awrr AzureWorkloadRestoreRequest) MarshalJSON() ([]byte, error) {
if awrr.TargetInfo != nil {
objectMap["targetInfo"] = awrr.TargetInfo
}
+ if awrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awrr.RecoveryMode
+ }
if awrr.ObjectType != "" {
objectMap["objectType"] = awrr.ObjectType
}
@@ -9964,9 +9850,9 @@ func (awrr AzureWorkloadRestoreRequest) AsBasicRestoreRequest() (BasicRestoreReq
type AzureWorkloadSAPHanaPointInTimeRecoveryPoint struct {
// TimeRanges - List of log ranges
TimeRanges *[]PointInTimeRange `json:"timeRanges,omitempty"`
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -9979,12 +9865,6 @@ func (awshpitrp AzureWorkloadSAPHanaPointInTimeRecoveryPoint) MarshalJSON() ([]b
if awshpitrp.TimeRanges != nil {
objectMap["timeRanges"] = awshpitrp.TimeRanges
}
- if awshpitrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awshpitrp.RecoveryPointTimeInUTC
- }
- if awshpitrp.Type != "" {
- objectMap["type"] = awshpitrp.Type
- }
if awshpitrp.ObjectType != "" {
objectMap["objectType"] = awshpitrp.ObjectType
}
@@ -10066,7 +9946,7 @@ func (awshpitrp AzureWorkloadSAPHanaPointInTimeRecoveryPoint) AsBasicRecoveryPoi
type AzureWorkloadSAPHanaPointInTimeRestoreRequest struct {
// PointInTime - PointInTime value
PointInTime *date.Time `json:"pointInTime,omitempty"`
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -10074,6 +9954,8 @@ type AzureWorkloadSAPHanaPointInTimeRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -10097,6 +9979,9 @@ func (awshpitrr AzureWorkloadSAPHanaPointInTimeRestoreRequest) MarshalJSON() ([]
if awshpitrr.TargetInfo != nil {
objectMap["targetInfo"] = awshpitrr.TargetInfo
}
+ if awshpitrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awshpitrr.RecoveryMode
+ }
if awshpitrr.ObjectType != "" {
objectMap["objectType"] = awshpitrr.ObjectType
}
@@ -10168,12 +10053,12 @@ func (awshpitrr AzureWorkloadSAPHanaPointInTimeRestoreRequest) AsBasicRestoreReq
return &awshpitrr, true
}
-// AzureWorkloadSAPHanaRecoveryPoint sAPHana specific recovery point, specifically encapsulates full/diff
-// recovery points
+// AzureWorkloadSAPHanaRecoveryPoint sAPHana specific recoverypoint, specifically encapsulates full/diff
+// recoverypoints
type AzureWorkloadSAPHanaRecoveryPoint struct {
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -10183,12 +10068,6 @@ type AzureWorkloadSAPHanaRecoveryPoint struct {
func (awshrp AzureWorkloadSAPHanaRecoveryPoint) MarshalJSON() ([]byte, error) {
awshrp.ObjectType = ObjectTypeAzureWorkloadSAPHanaRecoveryPoint
objectMap := make(map[string]interface{})
- if awshrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awshrp.RecoveryPointTimeInUTC
- }
- if awshrp.Type != "" {
- objectMap["type"] = awshrp.Type
- }
if awshrp.ObjectType != "" {
objectMap["objectType"] = awshrp.ObjectType
}
@@ -10273,7 +10152,7 @@ type BasicAzureWorkloadSAPHanaRestoreRequest interface {
// AzureWorkloadSAPHanaRestoreRequest azureWorkload SAP Hana-specific restore.
type AzureWorkloadSAPHanaRestoreRequest struct {
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -10281,6 +10160,8 @@ type AzureWorkloadSAPHanaRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -10338,6 +10219,9 @@ func (awshrr AzureWorkloadSAPHanaRestoreRequest) MarshalJSON() ([]byte, error) {
if awshrr.TargetInfo != nil {
objectMap["targetInfo"] = awshrr.TargetInfo
}
+ if awshrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awshrr.RecoveryMode
+ }
if awshrr.ObjectType != "" {
objectMap["objectType"] = awshrr.ObjectType
}
@@ -10503,9 +10387,9 @@ type AzureWorkloadSQLPointInTimeRecoveryPoint struct {
// When a specific recovery point is accessed using GetRecoveryPoint
// Or when ListRecoveryPoints is called for Log RP only with ExtendedInfo query filter
ExtendedInfo *AzureWorkloadSQLRecoveryPointExtendedInfo `json:"extendedInfo,omitempty"`
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -10521,12 +10405,6 @@ func (awspitrp AzureWorkloadSQLPointInTimeRecoveryPoint) MarshalJSON() ([]byte,
if awspitrp.ExtendedInfo != nil {
objectMap["extendedInfo"] = awspitrp.ExtendedInfo
}
- if awspitrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awspitrp.RecoveryPointTimeInUTC
- }
- if awspitrp.Type != "" {
- objectMap["type"] = awspitrp.Type
- }
if awspitrp.ObjectType != "" {
objectMap["objectType"] = awspitrp.ObjectType
}
@@ -10614,7 +10492,7 @@ type AzureWorkloadSQLPointInTimeRestoreRequest struct {
IsNonRecoverable *bool `json:"isNonRecoverable,omitempty"`
// AlternateDirectoryPaths - Data directory details
AlternateDirectoryPaths *[]SQLDataDirectoryMapping `json:"alternateDirectoryPaths,omitempty"`
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -10622,6 +10500,8 @@ type AzureWorkloadSQLPointInTimeRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -10654,6 +10534,9 @@ func (awspitrr AzureWorkloadSQLPointInTimeRestoreRequest) MarshalJSON() ([]byte,
if awspitrr.TargetInfo != nil {
objectMap["targetInfo"] = awspitrr.TargetInfo
}
+ if awspitrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awspitrr.RecoveryMode
+ }
if awspitrr.ObjectType != "" {
objectMap["objectType"] = awspitrr.ObjectType
}
@@ -10725,23 +10608,23 @@ func (awspitrr AzureWorkloadSQLPointInTimeRestoreRequest) AsBasicRestoreRequest(
return &awspitrr, true
}
-// BasicAzureWorkloadSQLRecoveryPoint SQL specific recovery point, specifically encapsulates full/diff recovery point
+// BasicAzureWorkloadSQLRecoveryPoint SQL specific recoverypoint, specifically encapsulates full/diff recoverypoint
// along with extended info
type BasicAzureWorkloadSQLRecoveryPoint interface {
AsAzureWorkloadSQLPointInTimeRecoveryPoint() (*AzureWorkloadSQLPointInTimeRecoveryPoint, bool)
AsAzureWorkloadSQLRecoveryPoint() (*AzureWorkloadSQLRecoveryPoint, bool)
}
-// AzureWorkloadSQLRecoveryPoint SQL specific recovery point, specifically encapsulates full/diff recovery
-// point along with extended info
+// AzureWorkloadSQLRecoveryPoint SQL specific recoverypoint, specifically encapsulates full/diff recoverypoint
+// along with extended info
type AzureWorkloadSQLRecoveryPoint struct {
// ExtendedInfo - Extended Info that provides data directory details. Will be populated in two cases:
// When a specific recovery point is accessed using GetRecoveryPoint
// Or when ListRecoveryPoints is called for Log RP only with ExtendedInfo query filter
ExtendedInfo *AzureWorkloadSQLRecoveryPointExtendedInfo `json:"extendedInfo,omitempty"`
- // RecoveryPointTimeInUTC - UTC time at which recovery point was created
+ // RecoveryPointTimeInUTC - READ-ONLY; UTC time at which recovery point was created
RecoveryPointTimeInUTC *date.Time `json:"recoveryPointTimeInUTC,omitempty"`
- // Type - Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
+ // Type - READ-ONLY; Type of restore point. Possible values include: 'RestorePointTypeInvalid', 'RestorePointTypeFull', 'RestorePointTypeLog', 'RestorePointTypeDifferential'
Type RestorePointType `json:"type,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
@@ -10791,12 +10674,6 @@ func (awsrp AzureWorkloadSQLRecoveryPoint) MarshalJSON() ([]byte, error) {
if awsrp.ExtendedInfo != nil {
objectMap["extendedInfo"] = awsrp.ExtendedInfo
}
- if awsrp.RecoveryPointTimeInUTC != nil {
- objectMap["recoveryPointTimeInUTC"] = awsrp.RecoveryPointTimeInUTC
- }
- if awsrp.Type != "" {
- objectMap["type"] = awsrp.Type
- }
if awsrp.ObjectType != "" {
objectMap["objectType"] = awsrp.ObjectType
}
@@ -10875,9 +10752,9 @@ func (awsrp AzureWorkloadSQLRecoveryPoint) AsBasicRecoveryPoint() (BasicRecovery
// AzureWorkloadSQLRecoveryPointExtendedInfo extended info class details
type AzureWorkloadSQLRecoveryPointExtendedInfo struct {
- // DataDirectoryTimeInUTC - UTC time at which data directory info was captured
+ // DataDirectoryTimeInUTC - READ-ONLY; UTC time at which data directory info was captured
DataDirectoryTimeInUTC *date.Time `json:"dataDirectoryTimeInUTC,omitempty"`
- // DataDirectoryPaths - List of data directory paths during restore operation.
+ // DataDirectoryPaths - READ-ONLY; List of data directory paths during restore operation.
DataDirectoryPaths *[]SQLDataDirectory `json:"dataDirectoryPaths,omitempty"`
}
@@ -10895,7 +10772,7 @@ type AzureWorkloadSQLRestoreRequest struct {
IsNonRecoverable *bool `json:"isNonRecoverable,omitempty"`
// AlternateDirectoryPaths - Data directory details
AlternateDirectoryPaths *[]SQLDataDirectoryMapping `json:"alternateDirectoryPaths,omitempty"`
- // RecoveryType - OLR/ALR, RestoreDisks is invalid option. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM on which workload that was running is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -10903,6 +10780,8 @@ type AzureWorkloadSQLRestoreRequest struct {
PropertyBag map[string]*string `json:"propertyBag"`
// TargetInfo - Details of target database
TargetInfo *TargetRestoreInfo `json:"targetInfo,omitempty"`
+ // RecoveryMode - Defines whether the current recovery mode is file restore or database restore. Possible values include: 'RecoveryModeInvalid', 'RecoveryModeFileRecovery', 'RecoveryModeWorkloadRecovery'
+ RecoveryMode RecoveryMode `json:"recoveryMode,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -10969,6 +10848,9 @@ func (awsrr AzureWorkloadSQLRestoreRequest) MarshalJSON() ([]byte, error) {
if awsrr.TargetInfo != nil {
objectMap["targetInfo"] = awsrr.TargetInfo
}
+ if awsrr.RecoveryMode != "" {
+ objectMap["recoveryMode"] = awsrr.RecoveryMode
+ }
if awsrr.ObjectType != "" {
objectMap["objectType"] = awsrr.ObjectType
}
@@ -11384,6 +11266,20 @@ type Day struct {
IsLast *bool `json:"isLast,omitempty"`
}
+// DiskExclusionProperties ...
+type DiskExclusionProperties struct {
+ // DiskLunList - List of Disks' Logical Unit Numbers (LUN) to be used for VM Protection.
+ DiskLunList *[]int32 `json:"diskLunList,omitempty"`
+ // IsInclusionList - Flag to indicate whether DiskLunList is to be included/ excluded from backup.
+ IsInclusionList *bool `json:"isInclusionList,omitempty"`
+}
+
+// DiskInformation disk information
+type DiskInformation struct {
+ Lun *int32 `json:"lun,omitempty"`
+ Name *string `json:"name,omitempty"`
+}
+
// DistributedNodesInfo this is used to represent the various nodes of the distributed container.
type DistributedNodesInfo struct {
// NodeName - Name of the node under a distributed container.
@@ -11419,7 +11315,7 @@ type DpmBackupEngine struct {
IsAzureBackupAgentUpgradeAvailable *bool `json:"isAzureBackupAgentUpgradeAvailable,omitempty"`
// IsDpmUpgradeAvailable - To check if backup engine upgrade available
IsDpmUpgradeAvailable *bool `json:"isDpmUpgradeAvailable,omitempty"`
- // ExtendedInfo - Extended info of the backup engine
+ // ExtendedInfo - Extended info of the backupengine
ExtendedInfo *EngineExtendedInfo `json:"extendedInfo,omitempty"`
// BackupEngineType - Possible values include: 'BackupEngineTypeBackupEngineBase', 'BackupEngineTypeAzureBackupServerEngine', 'BackupEngineTypeDpmBackupEngine'
BackupEngineType EngineType `json:"backupEngineType,omitempty"`
@@ -12180,7 +12076,7 @@ type EngineBase struct {
IsAzureBackupAgentUpgradeAvailable *bool `json:"isAzureBackupAgentUpgradeAvailable,omitempty"`
// IsDpmUpgradeAvailable - To check if backup engine upgrade available
IsDpmUpgradeAvailable *bool `json:"isDpmUpgradeAvailable,omitempty"`
- // ExtendedInfo - Extended info of the backup engine
+ // ExtendedInfo - Extended info of the backupengine
ExtendedInfo *EngineExtendedInfo `json:"extendedInfo,omitempty"`
// BackupEngineType - Possible values include: 'BackupEngineTypeBackupEngineBase', 'BackupEngineTypeAzureBackupServerEngine', 'BackupEngineTypeDpmBackupEngine'
BackupEngineType EngineType `json:"backupEngineType,omitempty"`
@@ -12574,11 +12470,11 @@ type EngineExtendedInfo struct {
// ErrorDetail error Detail class which encapsulates Code, Message and Recommendations.
type ErrorDetail struct {
- // Code - Error code.
+ // Code - READ-ONLY; Error code.
Code *string `json:"code,omitempty"`
- // Message - Error Message related to the Code.
+ // Message - READ-ONLY; Error Message related to the Code.
Message *string `json:"message,omitempty"`
- // Recommendations - List of recommendation strings.
+ // Recommendations - READ-ONLY; List of recommendation strings.
Recommendations *[]string `json:"recommendations,omitempty"`
}
@@ -12588,6 +12484,10 @@ type ExportJobsOperationResultInfo struct {
BlobURL *string `json:"blobUrl,omitempty"`
// BlobSasKey - SAS key to access the blob. It expires in 15 mins.
BlobSasKey *string `json:"blobSasKey,omitempty"`
+ // ExcelFileBlobURL - URL of the blob into which the ExcelFile is uploaded.
+ ExcelFileBlobURL *string `json:"excelFileBlobUrl,omitempty"`
+ // ExcelFileBlobSasKey - SAS key to access the blob. It expires in 15 mins.
+ ExcelFileBlobSasKey *string `json:"excelFileBlobSasKey,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeOperationResultInfoBase', 'ObjectTypeExportJobsOperationResultInfo', 'ObjectTypeOperationResultInfo'
ObjectType ObjectType `json:"objectType,omitempty"`
}
@@ -12602,6 +12502,12 @@ func (ejori ExportJobsOperationResultInfo) MarshalJSON() ([]byte, error) {
if ejori.BlobSasKey != nil {
objectMap["blobSasKey"] = ejori.BlobSasKey
}
+ if ejori.ExcelFileBlobURL != nil {
+ objectMap["excelFileBlobUrl"] = ejori.ExcelFileBlobURL
+ }
+ if ejori.ExcelFileBlobSasKey != nil {
+ objectMap["excelFileBlobSasKey"] = ejori.ExcelFileBlobSasKey
+ }
if ejori.ObjectType != "" {
objectMap["objectType"] = ejori.ObjectType
}
@@ -12628,6 +12534,12 @@ func (ejori ExportJobsOperationResultInfo) AsBasicOperationResultInfoBase() (Bas
return &ejori, true
}
+// ExtendedProperties extended Properties for Azure IaasVM Backup.
+type ExtendedProperties struct {
+ // DiskExclusionProperties - Extended Properties for Disk Exclusion.
+ DiskExclusionProperties *DiskExclusionProperties `json:"diskExclusionProperties,omitempty"`
+}
+
// BasicFeatureSupportRequest base class for feature request
type BasicFeatureSupportRequest interface {
AsAzureBackupGoalFeatureSupportRequest() (*AzureBackupGoalFeatureSupportRequest, bool)
@@ -13069,7 +12981,7 @@ type GenericProtectionPolicy struct {
FabricName *string `json:"fabricName,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -13095,6 +13007,11 @@ func (gpp GenericProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for GenericProtectionPolicy.
+func (gpp GenericProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for GenericProtectionPolicy.
func (gpp GenericProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -13110,11 +13027,6 @@ func (gpp GenericProtectionPolicy) AsAzureSQLProtectionPolicy() (*AzureSQLProtec
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for GenericProtectionPolicy.
-func (gpp GenericProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for GenericProtectionPolicy.
func (gpp GenericProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return &gpp, true
@@ -13487,7 +13399,7 @@ type IaasVMILRRegistrationRequest struct {
InitiatorName *string `json:"initiatorName,omitempty"`
// RenewExistingRegistration - Whether to renew existing registration with the iSCSI server.
RenewExistingRegistration *bool `json:"renewExistingRegistration,omitempty"`
- // ObjectType - Possible values include: 'ObjectTypeILRRequest', 'ObjectTypeIaasVMILRRegistrationRequest'
+ // ObjectType - Possible values include: 'ObjectTypeILRRequest', 'ObjectTypeAzureFileShareProvisionILRRequest', 'ObjectTypeIaasVMILRRegistrationRequest'
ObjectType ObjectTypeBasicILRRequest `json:"objectType,omitempty"`
}
@@ -13513,6 +13425,11 @@ func (ivrr IaasVMILRRegistrationRequest) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureFileShareProvisionILRRequest is the BasicILRRequest implementation for IaasVMILRRegistrationRequest.
+func (ivrr IaasVMILRRegistrationRequest) AsAzureFileShareProvisionILRRequest() (*AzureFileShareProvisionILRRequest, bool) {
+ return nil, false
+}
+
// AsIaasVMILRRegistrationRequest is the BasicILRRequest implementation for IaasVMILRRegistrationRequest.
func (ivrr IaasVMILRRegistrationRequest) AsIaasVMILRRegistrationRequest() (*IaasVMILRRegistrationRequest, bool) {
return &ivrr, true
@@ -13547,7 +13464,7 @@ type IaaSVMProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -13642,11 +13559,6 @@ func (ispi IaaSVMProtectableItem) AsBasicAzureVMWorkloadProtectableItem() (Basic
return nil, false
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for IaaSVMProtectableItem.
-func (ispi IaaSVMProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for IaaSVMProtectableItem.
func (ispi IaaSVMProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
@@ -13699,15 +13611,15 @@ func (ispi IaaSVMProtectableItem) AsBasicWorkloadProtectableItem() (BasicWorkloa
// IaasVMRecoveryPoint iaaS VM workload specific backup copy.
type IaasVMRecoveryPoint struct {
- // RecoveryPointType - Type of the backup copy.
+ // RecoveryPointType - READ-ONLY; Type of the backup copy.
RecoveryPointType *string `json:"recoveryPointType,omitempty"`
- // RecoveryPointTime - Time at which this backup copy was created.
+ // RecoveryPointTime - READ-ONLY; Time at which this backup copy was created.
RecoveryPointTime *date.Time `json:"recoveryPointTime,omitempty"`
- // RecoveryPointAdditionalInfo - Additional information associated with this backup copy.
+ // RecoveryPointAdditionalInfo - READ-ONLY; Additional information associated with this backup copy.
RecoveryPointAdditionalInfo *string `json:"recoveryPointAdditionalInfo,omitempty"`
- // SourceVMStorageType - Storage type of the VM whose backup copy is created.
+ // SourceVMStorageType - READ-ONLY; Storage type of the VM whose backup copy is created.
SourceVMStorageType *string `json:"sourceVMStorageType,omitempty"`
- // IsSourceVMEncrypted - Identifies whether the VM was encrypted when the backup copy is created.
+ // IsSourceVMEncrypted - READ-ONLY; Identifies whether the VM was encrypted when the backup copy is created.
IsSourceVMEncrypted *bool `json:"isSourceVMEncrypted,omitempty"`
// KeyAndSecret - Required details for recovering an encrypted VM. Applicable only when IsSourceVMEncrypted is true.
KeyAndSecret *KeyAndSecretDetails `json:"keyAndSecret,omitempty"`
@@ -13723,6 +13635,8 @@ type IaasVMRecoveryPoint struct {
OriginalStorageAccountOption *bool `json:"originalStorageAccountOption,omitempty"`
// OsType - OS type
OsType *string `json:"osType,omitempty"`
+ // RecoveryPointDiskConfiguration - Disk configuration
+ RecoveryPointDiskConfiguration *RecoveryPointDiskConfiguration `json:"recoveryPointDiskConfiguration,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRecoveryPoint', 'ObjectTypeAzureFileShareRecoveryPoint', 'ObjectTypeAzureWorkloadPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSAPHanaRecoveryPoint', 'ObjectTypeAzureWorkloadSQLPointInTimeRecoveryPoint', 'ObjectTypeAzureWorkloadSQLRecoveryPoint', 'ObjectTypeGenericRecoveryPoint', 'ObjectTypeIaasVMRecoveryPoint'
ObjectType ObjectTypeBasicRecoveryPoint `json:"objectType,omitempty"`
}
@@ -13731,21 +13645,6 @@ type IaasVMRecoveryPoint struct {
func (ivrp IaasVMRecoveryPoint) MarshalJSON() ([]byte, error) {
ivrp.ObjectType = ObjectTypeIaasVMRecoveryPoint
objectMap := make(map[string]interface{})
- if ivrp.RecoveryPointType != nil {
- objectMap["recoveryPointType"] = ivrp.RecoveryPointType
- }
- if ivrp.RecoveryPointTime != nil {
- objectMap["recoveryPointTime"] = ivrp.RecoveryPointTime
- }
- if ivrp.RecoveryPointAdditionalInfo != nil {
- objectMap["recoveryPointAdditionalInfo"] = ivrp.RecoveryPointAdditionalInfo
- }
- if ivrp.SourceVMStorageType != nil {
- objectMap["sourceVMStorageType"] = ivrp.SourceVMStorageType
- }
- if ivrp.IsSourceVMEncrypted != nil {
- objectMap["isSourceVMEncrypted"] = ivrp.IsSourceVMEncrypted
- }
if ivrp.KeyAndSecret != nil {
objectMap["keyAndSecret"] = ivrp.KeyAndSecret
}
@@ -13767,6 +13666,9 @@ func (ivrp IaasVMRecoveryPoint) MarshalJSON() ([]byte, error) {
if ivrp.OsType != nil {
objectMap["osType"] = ivrp.OsType
}
+ if ivrp.RecoveryPointDiskConfiguration != nil {
+ objectMap["recoveryPointDiskConfiguration"] = ivrp.RecoveryPointDiskConfiguration
+ }
if ivrp.ObjectType != "" {
objectMap["objectType"] = ivrp.ObjectType
}
@@ -13847,7 +13749,7 @@ func (ivrp IaasVMRecoveryPoint) AsBasicRecoveryPoint() (BasicRecoveryPoint, bool
type IaasVMRestoreRequest struct {
// RecoveryPointID - ID of the backup copy to be recovered.
RecoveryPointID *string `json:"recoveryPointId,omitempty"`
- // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks'
+ // RecoveryType - Type of this recovery. Possible values include: 'RecoveryTypeInvalid', 'RecoveryTypeOriginalLocation', 'RecoveryTypeAlternateLocation', 'RecoveryTypeRestoreDisks', 'RecoveryTypeOffline'
RecoveryType RecoveryType `json:"recoveryType,omitempty"`
// SourceResourceID - Fully qualified ARM ID of the VM which is being recovered.
SourceResourceID *string `json:"sourceResourceId,omitempty"`
@@ -13880,6 +13782,8 @@ type IaasVMRestoreRequest struct {
OriginalStorageAccountOption *bool `json:"originalStorageAccountOption,omitempty"`
// EncryptionDetails - Details needed if the VM was encrypted at the time of backup.
EncryptionDetails *EncryptionDetails `json:"encryptionDetails,omitempty"`
+ // RestoreDiskLunList - List of Disk LUNs for partial restore
+ RestoreDiskLunList *[]int32 `json:"restoreDiskLunList,omitempty"`
// ObjectType - Possible values include: 'ObjectTypeRestoreRequest', 'ObjectTypeAzureFileShareRestoreRequest', 'ObjectTypeAzureWorkloadPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSAPHanaRestoreRequest', 'ObjectTypeAzureWorkloadSQLPointInTimeRestoreRequest', 'ObjectTypeAzureWorkloadSQLRestoreRequest', 'ObjectTypeIaasVMRestoreRequest'
ObjectType ObjectTypeBasicRestoreRequest `json:"objectType,omitempty"`
}
@@ -13930,6 +13834,9 @@ func (ivrr IaasVMRestoreRequest) MarshalJSON() ([]byte, error) {
if ivrr.EncryptionDetails != nil {
objectMap["encryptionDetails"] = ivrr.EncryptionDetails
}
+ if ivrr.RestoreDiskLunList != nil {
+ objectMap["restoreDiskLunList"] = ivrr.RestoreDiskLunList
+ }
if ivrr.ObjectType != "" {
objectMap["objectType"] = ivrr.ObjectType
}
@@ -14001,15 +13908,16 @@ func (ivrr IaasVMRestoreRequest) AsBasicRestoreRequest() (BasicRestoreRequest, b
return &ivrr, true
}
-// BasicILRRequest parameters to restore file/folders API.
+// BasicILRRequest parameters to Provision ILR API.
type BasicILRRequest interface {
+ AsAzureFileShareProvisionILRRequest() (*AzureFileShareProvisionILRRequest, bool)
AsIaasVMILRRegistrationRequest() (*IaasVMILRRegistrationRequest, bool)
AsILRRequest() (*ILRRequest, bool)
}
-// ILRRequest parameters to restore file/folders API.
+// ILRRequest parameters to Provision ILR API.
type ILRRequest struct {
- // ObjectType - Possible values include: 'ObjectTypeILRRequest', 'ObjectTypeIaasVMILRRegistrationRequest'
+ // ObjectType - Possible values include: 'ObjectTypeILRRequest', 'ObjectTypeAzureFileShareProvisionILRRequest', 'ObjectTypeIaasVMILRRegistrationRequest'
ObjectType ObjectTypeBasicILRRequest `json:"objectType,omitempty"`
}
@@ -14021,6 +13929,10 @@ func unmarshalBasicILRRequest(body []byte) (BasicILRRequest, error) {
}
switch m["objectType"] {
+ case string(ObjectTypeAzureFileShareProvisionILRRequest):
+ var afspir AzureFileShareProvisionILRRequest
+ err := json.Unmarshal(body, &afspir)
+ return afspir, err
case string(ObjectTypeIaasVMILRRegistrationRequest):
var ivrr IaasVMILRRegistrationRequest
err := json.Unmarshal(body, &ivrr)
@@ -14060,6 +13972,11 @@ func (ir ILRRequest) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureFileShareProvisionILRRequest is the BasicILRRequest implementation for ILRRequest.
+func (ir ILRRequest) AsAzureFileShareProvisionILRRequest() (*AzureFileShareProvisionILRRequest, bool) {
+ return nil, false
+}
+
// AsIaasVMILRRegistrationRequest is the BasicILRRequest implementation for ILRRequest.
func (ir ILRRequest) AsIaasVMILRRegistrationRequest() (*IaasVMILRRegistrationRequest, bool) {
return nil, false
@@ -14075,7 +13992,7 @@ func (ir ILRRequest) AsBasicILRRequest() (BasicILRRequest, bool) {
return &ir, true
}
-// ILRRequestResource parameters to restore file/folders API.
+// ILRRequestResource parameters to Provision ILR API.
type ILRRequestResource struct {
// Properties - ILRRequestResource properties
Properties BasicILRRequest `json:"properties,omitempty"`
@@ -14204,6 +14121,8 @@ type InquiryValidation struct {
Status *string `json:"status,omitempty"`
// ErrorDetail - Error Detail in case the status is non-success.
ErrorDetail *ErrorDetail `json:"errorDetail,omitempty"`
+ // AdditionalDetail - READ-ONLY; Error Additional Detail in case the status is non-success.
+ AdditionalDetail *string `json:"additionalDetail,omitempty"`
}
// InstantItemRecoveryTarget target details for file / folder restore.
@@ -14212,6 +14131,12 @@ type InstantItemRecoveryTarget struct {
ClientScripts *[]ClientScriptForConnect `json:"clientScripts,omitempty"`
}
+// InstantRPAdditionalDetails ...
+type InstantRPAdditionalDetails struct {
+ AzureBackupRGNamePrefix *string `json:"azureBackupRGNamePrefix,omitempty"`
+ AzureBackupRGNameSuffix *string `json:"azureBackupRGNameSuffix,omitempty"`
+}
+
// BasicJob defines workload agnostic properties for a job.
type BasicJob interface {
AsAzureIaaSVMJob() (*AzureIaaSVMJob, bool)
@@ -14367,7 +14292,7 @@ type JobQueryObject struct {
Status JobStatus `json:"status,omitempty"`
// BackupManagementType - Type of backup management for the job. Possible values include: 'ManagementTypeInvalid', 'ManagementTypeAzureIaasVM', 'ManagementTypeMAB', 'ManagementTypeDPM', 'ManagementTypeAzureBackupServer', 'ManagementTypeAzureSQL', 'ManagementTypeAzureStorage', 'ManagementTypeAzureWorkload', 'ManagementTypeDefaultBackup'
BackupManagementType ManagementType `json:"backupManagementType,omitempty"`
- // Operation - Type of operation. Possible values include: 'JobOperationTypeInvalid', 'JobOperationTypeRegister', 'JobOperationTypeUnRegister', 'JobOperationTypeConfigureBackup', 'JobOperationTypeBackup', 'JobOperationTypeRestore', 'JobOperationTypeDisableBackup', 'JobOperationTypeDeleteBackupData'
+ // Operation - Type of operation. Possible values include: 'JobOperationTypeInvalid', 'JobOperationTypeRegister', 'JobOperationTypeUnRegister', 'JobOperationTypeConfigureBackup', 'JobOperationTypeBackup', 'JobOperationTypeRestore', 'JobOperationTypeDisableBackup', 'JobOperationTypeDeleteBackupData', 'JobOperationTypeCrossRegionRestore', 'JobOperationTypeUndelete'
Operation JobOperationType `json:"operation,omitempty"`
// JobID - JobID represents the job uniquely.
JobID *string `json:"jobId,omitempty"`
@@ -14988,9 +14913,9 @@ type MABContainerHealthDetails struct {
// MabErrorInfo MAB workload-specific error information.
type MabErrorInfo struct {
- // ErrorString - Localized error string.
+ // ErrorString - READ-ONLY; Localized error string.
ErrorString *string `json:"errorString,omitempty"`
- // Recommendations - List of localized recommendations.
+ // Recommendations - READ-ONLY; List of localized recommendations.
Recommendations *[]string `json:"recommendations,omitempty"`
}
@@ -15002,9 +14927,11 @@ type MabFileFolderProtectedItem struct {
ComputerName *string `json:"computerName,omitempty"`
// LastBackupStatus - Status of last backup operation.
LastBackupStatus *string `json:"lastBackupStatus,omitempty"`
+ // LastBackupTime - Timestamp of the last backup operation on this backup item.
+ LastBackupTime *date.Time `json:"lastBackupTime,omitempty"`
// ProtectionState - Protected, ProtectionStopped, IRPending or ProtectionError
ProtectionState *string `json:"protectionState,omitempty"`
- // DeferredDeleteSyncTimeInUTC - Sync time for deferred deletion.
+ // DeferredDeleteSyncTimeInUTC - Sync time for deferred deletion in UTC
DeferredDeleteSyncTimeInUTC *int64 `json:"deferredDeleteSyncTimeInUTC,omitempty"`
// ExtendedInfo - Additional information with this backup item.
ExtendedInfo *MabFileFolderProtectedItemExtendedInfo `json:"extendedInfo,omitempty"`
@@ -15051,6 +14978,9 @@ func (mffpi MabFileFolderProtectedItem) MarshalJSON() ([]byte, error) {
if mffpi.LastBackupStatus != nil {
objectMap["lastBackupStatus"] = mffpi.LastBackupStatus
}
+ if mffpi.LastBackupTime != nil {
+ objectMap["lastBackupTime"] = mffpi.LastBackupTime
+ }
if mffpi.ProtectionState != nil {
objectMap["protectionState"] = mffpi.ProtectionState
}
@@ -15363,7 +15293,7 @@ type MabProtectionPolicy struct {
RetentionPolicy BasicRetentionPolicy `json:"retentionPolicy,omitempty"`
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -15382,6 +15312,11 @@ func (mpp MabProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for MabProtectionPolicy.
+func (mpp MabProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for MabProtectionPolicy.
func (mpp MabProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -15397,11 +15332,6 @@ func (mpp MabProtectionPolicy) AsAzureSQLProtectionPolicy() (*AzureSQLProtection
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for MabProtectionPolicy.
-func (mpp MabProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for MabProtectionPolicy.
func (mpp MabProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -16096,7 +16026,7 @@ type PreValidateEnableBackupRequest struct {
ResourceType DataSourceType `json:"resourceType,omitempty"`
// ResourceID - ARM Virtual Machine Id
ResourceID *string `json:"resourceId,omitempty"`
- // VaultID - Specifies the arm resource id of the vault
+ // VaultID - ARM id of the Recovery Services Vault
VaultID *string `json:"vaultId,omitempty"`
// Properties - Configuration of VM if any needs to be validated like OS type etc
Properties *string `json:"properties,omitempty"`
@@ -17921,10 +17851,10 @@ func NewProtectionIntentResourceListPage(getNextPage func(context.Context, Prote
// BasicProtectionPolicy base class for backup policy. Workload-specific backup policies are derived from this class.
type BasicProtectionPolicy interface {
+ AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool)
AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool)
AsAzureIaaSVMProtectionPolicy() (*AzureIaaSVMProtectionPolicy, bool)
AsAzureSQLProtectionPolicy() (*AzureSQLProtectionPolicy, bool)
- AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool)
AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool)
AsMabProtectionPolicy() (*MabProtectionPolicy, bool)
AsProtectionPolicy() (*ProtectionPolicy, bool)
@@ -17935,7 +17865,7 @@ type BasicProtectionPolicy interface {
type ProtectionPolicy struct {
// ProtectedItemsCount - Number of items associated with this policy.
ProtectedItemsCount *int32 `json:"protectedItemsCount,omitempty"`
- // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
+ // BackupManagementType - Possible values include: 'BackupManagementTypeProtectionPolicy', 'BackupManagementTypeAzureWorkload', 'BackupManagementTypeAzureStorage', 'BackupManagementTypeAzureIaasVM', 'BackupManagementTypeAzureSQL', 'BackupManagementTypeGenericProtectionPolicy', 'BackupManagementTypeMAB'
BackupManagementType ManagementTypeBasicProtectionPolicy `json:"backupManagementType,omitempty"`
}
@@ -17947,6 +17877,10 @@ func unmarshalBasicProtectionPolicy(body []byte) (BasicProtectionPolicy, error)
}
switch m["backupManagementType"] {
+ case string(BackupManagementTypeAzureWorkload):
+ var avwpp AzureVMWorkloadProtectionPolicy
+ err := json.Unmarshal(body, &avwpp)
+ return avwpp, err
case string(BackupManagementTypeAzureStorage):
var afspp AzureFileShareProtectionPolicy
err := json.Unmarshal(body, &afspp)
@@ -17959,10 +17893,6 @@ func unmarshalBasicProtectionPolicy(body []byte) (BasicProtectionPolicy, error)
var aspp AzureSQLProtectionPolicy
err := json.Unmarshal(body, &aspp)
return aspp, err
- case string(BackupManagementTypeAzureWorkload):
- var avwpp AzureVMWorkloadProtectionPolicy
- err := json.Unmarshal(body, &avwpp)
- return avwpp, err
case string(BackupManagementTypeGenericProtectionPolicy):
var gpp GenericProtectionPolicy
err := json.Unmarshal(body, &gpp)
@@ -18009,6 +17939,11 @@ func (pp ProtectionPolicy) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for ProtectionPolicy.
+func (pp ProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
+ return nil, false
+}
+
// AsAzureFileShareProtectionPolicy is the BasicProtectionPolicy implementation for ProtectionPolicy.
func (pp ProtectionPolicy) AsAzureFileShareProtectionPolicy() (*AzureFileShareProtectionPolicy, bool) {
return nil, false
@@ -18024,11 +17959,6 @@ func (pp ProtectionPolicy) AsAzureSQLProtectionPolicy() (*AzureSQLProtectionPoli
return nil, false
}
-// AsAzureVMWorkloadProtectionPolicy is the BasicProtectionPolicy implementation for ProtectionPolicy.
-func (pp ProtectionPolicy) AsAzureVMWorkloadProtectionPolicy() (*AzureVMWorkloadProtectionPolicy, bool) {
- return nil, false
-}
-
// AsGenericProtectionPolicy is the BasicProtectionPolicy implementation for ProtectionPolicy.
func (pp ProtectionPolicy) AsGenericProtectionPolicy() (*GenericProtectionPolicy, bool) {
return nil, false
@@ -18491,6 +18421,18 @@ func (rp RecoveryPoint) AsBasicRecoveryPoint() (BasicRecoveryPoint, bool) {
return &rp, true
}
+// RecoveryPointDiskConfiguration disk configuration
+type RecoveryPointDiskConfiguration struct {
+ // NumberOfDisksIncludedInBackup - Number of disks included in backup
+ NumberOfDisksIncludedInBackup *int32 `json:"numberOfDisksIncludedInBackup,omitempty"`
+ // NumberOfDisksAttachedToVM - Number of disks attached to the VM
+ NumberOfDisksAttachedToVM *int32 `json:"numberOfDisksAttachedToVm,omitempty"`
+ // IncludedDiskList - Information of disks included in backup
+ IncludedDiskList *[]DiskInformation `json:"includedDiskList,omitempty"`
+ // ExcludedDiskList - Information of disks excluded from backup
+ ExcludedDiskList *[]DiskInformation `json:"excludedDiskList,omitempty"`
+}
+
// RecoveryPointResource base class for backup copies. Workload-specific backup copies are derived from
// this class.
type RecoveryPointResource struct {
@@ -19058,6 +19000,8 @@ type ResourceVaultConfig struct {
StorageTypeState StorageTypeState `json:"storageTypeState,omitempty"`
// EnhancedSecurityState - Enabled or Disabled. Possible values include: 'EnhancedSecurityStateInvalid', 'EnhancedSecurityStateEnabled', 'EnhancedSecurityStateDisabled'
EnhancedSecurityState EnhancedSecurityState `json:"enhancedSecurityState,omitempty"`
+ // SoftDeleteFeatureState - Soft Delete feature state. Possible values include: 'SoftDeleteFeatureStateInvalid', 'SoftDeleteFeatureStateEnabled', 'SoftDeleteFeatureStateDisabled'
+ SoftDeleteFeatureState SoftDeleteFeatureState `json:"softDeleteFeatureState,omitempty"`
}
// ResourceVaultConfigResource backup resource vault config details.
@@ -20566,7 +20510,6 @@ type BasicWorkloadProtectableItem interface {
AsAzureIaaSComputeVMProtectableItem() (*AzureIaaSComputeVMProtectableItem, bool)
AsAzureVMWorkloadProtectableItem() (*AzureVMWorkloadProtectableItem, bool)
AsBasicAzureVMWorkloadProtectableItem() (BasicAzureVMWorkloadProtectableItem, bool)
- AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool)
AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool)
AsAzureVMWorkloadSAPHanaDatabaseProtectableItem() (*AzureVMWorkloadSAPHanaDatabaseProtectableItem, bool)
AsAzureVMWorkloadSAPHanaSystemProtectableItem() (*AzureVMWorkloadSAPHanaSystemProtectableItem, bool)
@@ -20589,7 +20532,7 @@ type WorkloadProtectableItem struct {
FriendlyName *string `json:"friendlyName,omitempty"`
// ProtectionState - State of the back up item. Possible values include: 'ProtectionStatusInvalid', 'ProtectionStatusNotProtected', 'ProtectionStatusProtecting', 'ProtectionStatusProtected', 'ProtectionStatusProtectionFailed'
ProtectionState ProtectionStatus `json:"protectionState,omitempty"`
- // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseDatabase', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
+ // ProtectableItemType - Possible values include: 'ProtectableItemTypeWorkloadProtectableItem', 'ProtectableItemTypeAzureFileShare', 'ProtectableItemTypeMicrosoftClassicComputevirtualMachines', 'ProtectableItemTypeMicrosoftComputevirtualMachines', 'ProtectableItemTypeAzureVMWorkloadProtectableItem', 'ProtectableItemTypeSAPAseSystem', 'ProtectableItemTypeSAPHanaDatabase', 'ProtectableItemTypeSAPHanaSystem', 'ProtectableItemTypeSQLAvailabilityGroupContainer', 'ProtectableItemTypeSQLDataBase', 'ProtectableItemTypeSQLInstance', 'ProtectableItemTypeIaaSVMProtectableItem'
ProtectableItemType ProtectableItemType `json:"protectableItemType,omitempty"`
}
@@ -20617,10 +20560,6 @@ func unmarshalBasicWorkloadProtectableItem(body []byte) (BasicWorkloadProtectabl
var avwpi AzureVMWorkloadProtectableItem
err := json.Unmarshal(body, &avwpi)
return avwpi, err
- case string(ProtectableItemTypeSAPAseDatabase):
- var avwsadpi AzureVMWorkloadSAPAseDatabaseProtectableItem
- err := json.Unmarshal(body, &avwsadpi)
- return avwsadpi, err
case string(ProtectableItemTypeSAPAseSystem):
var avwsaspi AzureVMWorkloadSAPAseSystemProtectableItem
err := json.Unmarshal(body, &avwsaspi)
@@ -20721,11 +20660,6 @@ func (wpi WorkloadProtectableItem) AsBasicAzureVMWorkloadProtectableItem() (Basi
return nil, false
}
-// AsAzureVMWorkloadSAPAseDatabaseProtectableItem is the BasicWorkloadProtectableItem implementation for WorkloadProtectableItem.
-func (wpi WorkloadProtectableItem) AsAzureVMWorkloadSAPAseDatabaseProtectableItem() (*AzureVMWorkloadSAPAseDatabaseProtectableItem, bool) {
- return nil, false
-}
-
// AsAzureVMWorkloadSAPAseSystemProtectableItem is the BasicWorkloadProtectableItem implementation for WorkloadProtectableItem.
func (wpi WorkloadProtectableItem) AsAzureVMWorkloadSAPAseSystemProtectableItem() (*AzureVMWorkloadSAPAseSystemProtectableItem, bool) {
return nil, false
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/operation.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/operation.go
index e1de4e1c8923..dc66321c1f6c 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/operation.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/operation.go
@@ -85,7 +85,7 @@ func (client OperationClient) ValidatePreparer(ctx context.Context, vaultName st
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/policies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/policies.go
index 126c37efcf12..ac93925c96c9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/policies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/policies.go
@@ -87,7 +87,7 @@ func (client PoliciesClient) ListPreparer(ctx context.Context, vaultName string,
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemoperationresults.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemoperationresults.go
index 36e8a5f7a368..956a7ccb55e4 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemoperationresults.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemoperationresults.go
@@ -93,7 +93,7 @@ func (client ProtectedItemOperationResultsClient) GetPreparer(ctx context.Contex
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditems.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditems.go
index 7cb9eb51598c..9c50fa811d38 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditems.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditems.go
@@ -40,125 +40,263 @@ func NewProtectedItemsClientWithBaseURI(baseURI string, subscriptionID string) P
return ProtectedItemsClient{NewWithBaseURI(baseURI, subscriptionID)}
}
-// List provides a pageable list of all items that are backed up within a vault.
+// CreateOrUpdate enables backup of an item or to modifies the backup policy information of an already backed up item.
+// This is an
+// asynchronous operation. To know the status of the operation, call the GetItemOperationResult API.
// Parameters:
// vaultName - the name of the recovery services vault.
// resourceGroupName - the name of the resource group where the recovery services vault is present.
-// filter - oData filter options.
-// skipToken - skipToken Filter.
-func (client ProtectedItemsClient) List(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (result ProtectedItemResourceListPage, err error) {
+// fabricName - fabric name associated with the backup item.
+// containerName - container name associated with the backup item.
+// protectedItemName - item name to be backed up.
+// parameters - resource backed up item
+func (client ProtectedItemsClient) CreateOrUpdate(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, parameters ProtectedItemResource) (result ProtectedItemResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsClient.List")
+ ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsClient.CreateOrUpdate")
defer func() {
sc := -1
- if result.pirl.Response.Response != nil {
- sc = result.pirl.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx, vaultName, resourceGroupName, filter, skipToken)
+ req, err := client.CreateOrUpdatePreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName, parameters)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "List", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "CreateOrUpdate", nil, "Failure preparing request")
return
}
- resp, err := client.ListSender(req)
+ resp, err := client.CreateOrUpdateSender(req)
if err != nil {
- result.pirl.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "List", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "CreateOrUpdate", resp, "Failure sending request")
return
}
- result.pirl, err = client.ListResponder(resp)
+ result, err = client.CreateOrUpdateResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "List", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "CreateOrUpdate", resp, "Failure responding to request")
}
return
}
-// ListPreparer prepares the List request.
-func (client ProtectedItemsClient) ListPreparer(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (*http.Request, error) {
+// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
+func (client ProtectedItemsClient) CreateOrUpdatePreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, parameters ProtectedItemResource) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "containerName": autorest.Encode("path", containerName),
+ "fabricName": autorest.Encode("path", fabricName),
+ "protectedItemName": autorest.Encode("path", protectedItemName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2017-07-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
- if len(skipToken) > 0 {
- queryParameters["$skipToken"] = autorest.Encode("query", skipToken)
- }
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectedItems", pathParameters),
+ autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
+ autorest.WithJSON(parameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListSender sends the List request. The method will close the
+// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
// http.Response Body if it receives an error.
-func (client ProtectedItemsClient) ListSender(req *http.Request) (*http.Response, error) {
+func (client ProtectedItemsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListResponder handles the response to the List request. The method always
+// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
// closes the http.Response Body.
-func (client ProtectedItemsClient) ListResponder(resp *http.Response) (result ProtectedItemResourceList, err error) {
+func (client ProtectedItemsClient) CreateOrUpdateResponder(resp *http.Response) (result ProtectedItemResource, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// listNextResults retrieves the next set of results, if any.
-func (client ProtectedItemsClient) listNextResults(ctx context.Context, lastResults ProtectedItemResourceList) (result ProtectedItemResourceList, err error) {
- req, err := lastResults.protectedItemResourceListPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "listNextResults", nil, "Failure preparing next results request")
+// Delete used to disable backup of an item within a container. This is an asynchronous operation. To know the status
+// of the
+// request, call the GetItemOperationResult API.
+// Parameters:
+// vaultName - the name of the recovery services vault.
+// resourceGroupName - the name of the resource group where the recovery services vault is present.
+// fabricName - fabric name associated with the backed up item.
+// containerName - container name associated with the backed up item.
+// protectedItemName - backed up item to be deleted.
+func (client ProtectedItemsClient) Delete(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsClient.Delete")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
}
- if req == nil {
+ req, err := client.DeletePreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Delete", nil, "Failure preparing request")
return
}
- resp, err := client.ListSender(req)
+
+ resp, err := client.DeleteSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "listNextResults", resp, "Failure sending next results request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Delete", resp, "Failure sending request")
+ return
}
- result, err = client.ListResponder(resp)
+
+ result, err = client.DeleteResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "listNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Delete", resp, "Failure responding to request")
}
+
+ return
+}
+
+// DeletePreparer prepares the Delete request.
+func (client ProtectedItemsClient) DeletePreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "containerName": autorest.Encode("path", containerName),
+ "fabricName": autorest.Encode("path", fabricName),
+ "protectedItemName": autorest.Encode("path", protectedItemName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vaultName": autorest.Encode("path", vaultName),
+ }
+
+ const APIVersion = "2019-05-13"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsDelete(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// DeleteSender sends the Delete request. The method will close the
+// http.Response Body if it receives an error.
+func (client ProtectedItemsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// DeleteResponder handles the response to the Delete request. The method always
+// closes the http.Response Body.
+func (client ProtectedItemsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
+ autorest.ByClosing())
+ result.Response = resp
return
}
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client ProtectedItemsClient) ListComplete(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (result ProtectedItemResourceListIterator, err error) {
+// Get provides the details of the backed up item. This is an asynchronous operation. To know the status of the
+// operation,
+// call the GetItemOperationResult API.
+// Parameters:
+// vaultName - the name of the recovery services vault.
+// resourceGroupName - the name of the resource group where the recovery services vault is present.
+// fabricName - fabric name associated with the backed up item.
+// containerName - container name associated with the backed up item.
+// protectedItemName - backed up item name whose details are to be fetched.
+// filter - oData filter options.
+func (client ProtectedItemsClient) Get(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, filter string) (result ProtectedItemResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsClient.List")
+ ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsClient.Get")
defer func() {
sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.List(ctx, vaultName, resourceGroupName, filter, skipToken)
+ req, err := client.GetPreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName, filter)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Get", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.GetSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Get", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.GetResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsClient", "Get", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// GetPreparer prepares the Get request.
+func (client ProtectedItemsClient) GetPreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, filter string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "containerName": autorest.Encode("path", containerName),
+ "fabricName": autorest.Encode("path", fabricName),
+ "protectedItemName": autorest.Encode("path", protectedItemName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vaultName": autorest.Encode("path", vaultName),
+ }
+
+ const APIVersion = "2019-05-13"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// GetSender sends the Get request. The method will close the
+// http.Response Body if it receives an error.
+func (client ProtectedItemsClient) GetSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// GetResponder handles the response to the Get request. The method always
+// closes the http.Response Body.
+func (client ProtectedItemsClient) GetResponder(resp *http.Response) (result ProtectedItemResource, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
return
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemsgroup.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemsgroup.go
index 155c709de2ba..0003d05eb5ed 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemsgroup.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protecteditemsgroup.go
@@ -40,263 +40,125 @@ func NewProtectedItemsGroupClientWithBaseURI(baseURI string, subscriptionID stri
return ProtectedItemsGroupClient{NewWithBaseURI(baseURI, subscriptionID)}
}
-// CreateOrUpdate enables backup of an item or to modifies the backup policy information of an already backed up item.
-// This is an
-// asynchronous operation. To know the status of the operation, call the GetItemOperationResult API.
+// List provides a pageable list of all items that are backed up within a vault.
// Parameters:
// vaultName - the name of the recovery services vault.
// resourceGroupName - the name of the resource group where the recovery services vault is present.
-// fabricName - fabric name associated with the backup item.
-// containerName - container name associated with the backup item.
-// protectedItemName - item name to be backed up.
-// parameters - resource backed up item
-func (client ProtectedItemsGroupClient) CreateOrUpdate(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, parameters ProtectedItemResource) (result ProtectedItemResource, err error) {
+// filter - oData filter options.
+// skipToken - skipToken Filter.
+func (client ProtectedItemsGroupClient) List(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (result ProtectedItemResourceListPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsGroupClient.CreateOrUpdate")
+ ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsGroupClient.List")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.pirl.Response.Response != nil {
+ sc = result.pirl.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
- req, err := client.CreateOrUpdatePreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName, parameters)
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx, vaultName, resourceGroupName, filter, skipToken)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "CreateOrUpdate", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "List", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateSender(req)
+ resp, err := client.ListSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "CreateOrUpdate", resp, "Failure sending request")
+ result.pirl.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "List", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateResponder(resp)
+ result.pirl, err = client.ListResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "CreateOrUpdate", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "List", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
-func (client ProtectedItemsGroupClient) CreateOrUpdatePreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, parameters ProtectedItemResource) (*http.Request, error) {
+// ListPreparer prepares the List request.
+func (client ProtectedItemsGroupClient) ListPreparer(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "containerName": autorest.Encode("path", containerName),
- "fabricName": autorest.Encode("path", fabricName),
- "protectedItemName": autorest.Encode("path", protectedItemName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if len(filter) > 0 {
+ queryParameters["$filter"] = autorest.Encode("query", filter)
+ }
+ if len(skipToken) > 0 {
+ queryParameters["$skipToken"] = autorest.Encode("query", skipToken)
+ }
preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPut(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
- autorest.WithJSON(parameters),
+ autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupProtectedItems", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
+// ListSender sends the List request. The method will close the
// http.Response Body if it receives an error.
-func (client ProtectedItemsGroupClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
+func (client ProtectedItemsGroupClient) ListSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
+// ListResponder handles the response to the List request. The method always
// closes the http.Response Body.
-func (client ProtectedItemsGroupClient) CreateOrUpdateResponder(resp *http.Response) (result ProtectedItemResource, err error) {
+func (client ProtectedItemsGroupClient) ListResponder(resp *http.Response) (result ProtectedItemResourceList, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// Delete used to disable backup of an item within a container. This is an asynchronous operation. To know the status
-// of the
-// request, call the GetItemOperationResult API.
-// Parameters:
-// vaultName - the name of the recovery services vault.
-// resourceGroupName - the name of the resource group where the recovery services vault is present.
-// fabricName - fabric name associated with the backed up item.
-// containerName - container name associated with the backed up item.
-// protectedItemName - backed up item to be deleted.
-func (client ProtectedItemsGroupClient) Delete(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string) (result autorest.Response, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsGroupClient.Delete")
- defer func() {
- sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- req, err := client.DeletePreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName)
+// listNextResults retrieves the next set of results, if any.
+func (client ProtectedItemsGroupClient) listNextResults(ctx context.Context, lastResults ProtectedItemResourceList) (result ProtectedItemResourceList, err error) {
+ req, err := lastResults.protectedItemResourceListPreparer(ctx)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Delete", nil, "Failure preparing request")
- return
+ return result, autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "listNextResults", nil, "Failure preparing next results request")
}
-
- resp, err := client.DeleteSender(req)
- if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Delete", resp, "Failure sending request")
+ if req == nil {
return
}
-
- result, err = client.DeleteResponder(resp)
+ resp, err := client.ListSender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Delete", resp, "Failure responding to request")
- }
-
- return
-}
-
-// DeletePreparer prepares the Delete request.
-func (client ProtectedItemsGroupClient) DeletePreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "containerName": autorest.Encode("path", containerName),
- "fabricName": autorest.Encode("path", fabricName),
- "protectedItemName": autorest.Encode("path", protectedItemName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vaultName": autorest.Encode("path", vaultName),
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "listNextResults", resp, "Failure sending next results request")
}
-
- const APIVersion = "2016-12-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "listNextResults", resp, "Failure responding to next results request")
}
-
- preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// DeleteSender sends the Delete request. The method will close the
-// http.Response Body if it receives an error.
-func (client ProtectedItemsGroupClient) DeleteSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// DeleteResponder handles the response to the Delete request. The method always
-// closes the http.Response Body.
-func (client ProtectedItemsGroupClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent),
- autorest.ByClosing())
- result.Response = resp
return
}
-// Get provides the details of the backed up item. This is an asynchronous operation. To know the status of the
-// operation,
-// call the GetItemOperationResult API.
-// Parameters:
-// vaultName - the name of the recovery services vault.
-// resourceGroupName - the name of the resource group where the recovery services vault is present.
-// fabricName - fabric name associated with the backed up item.
-// containerName - container name associated with the backed up item.
-// protectedItemName - backed up item name whose details are to be fetched.
-// filter - oData filter options.
-func (client ProtectedItemsGroupClient) Get(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, filter string) (result ProtectedItemResource, err error) {
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client ProtectedItemsGroupClient) ListComplete(ctx context.Context, vaultName string, resourceGroupName string, filter string, skipToken string) (result ProtectedItemResourceListIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsGroupClient.Get")
+ ctx = tracing.StartSpan(ctx, fqdn+"/ProtectedItemsGroupClient.List")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
- req, err := client.GetPreparer(ctx, vaultName, resourceGroupName, fabricName, containerName, protectedItemName, filter)
- if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Get", nil, "Failure preparing request")
- return
- }
-
- resp, err := client.GetSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Get", resp, "Failure sending request")
- return
- }
-
- result, err = client.GetResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "backup.ProtectedItemsGroupClient", "Get", resp, "Failure responding to request")
- }
-
- return
-}
-
-// GetPreparer prepares the Get request.
-func (client ProtectedItemsGroupClient) GetPreparer(ctx context.Context, vaultName string, resourceGroupName string, fabricName string, containerName string, protectedItemName string, filter string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "containerName": autorest.Encode("path", containerName),
- "fabricName": autorest.Encode("path", fabricName),
- "protectedItemName": autorest.Encode("path", protectedItemName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vaultName": autorest.Encode("path", vaultName),
- }
-
- const APIVersion = "2016-12-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
- if len(filter) > 0 {
- queryParameters["$filter"] = autorest.Encode("query", filter)
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsGet(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/Subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}/protectedItems/{protectedItemName}", pathParameters),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// GetSender sends the Get request. The method will close the
-// http.Response Body if it receives an error.
-func (client ProtectedItemsGroupClient) GetSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// GetResponder handles the response to the Get request. The method always
-// closes the http.Response Body.
-func (client ProtectedItemsGroupClient) GetResponder(resp *http.Response) (result ProtectedItemResource, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.page, err = client.List(ctx, vaultName, resourceGroupName, filter, skipToken)
return
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicies.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicies.go
index 7b3f596249a3..83f2afa24f43 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicies.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicies.go
@@ -89,7 +89,7 @@ func (client ProtectionPoliciesClient) CreateOrUpdatePreparer(ctx context.Contex
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -251,7 +251,7 @@ func (client ProtectionPoliciesClient) GetPreparer(ctx context.Context, vaultNam
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicyoperationresults.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicyoperationresults.go
index 2f5240a8235d..4f004b44d86f 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicyoperationresults.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/protectionpolicyoperationresults.go
@@ -89,7 +89,7 @@ func (client ProtectionPolicyOperationResultsClient) GetPreparer(ctx context.Con
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/recoverypoints.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/recoverypoints.go
index d0ad1506b4e5..52e2f8698015 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/recoverypoints.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/recoverypoints.go
@@ -94,7 +94,7 @@ func (client RecoveryPointsClient) GetPreparer(ctx context.Context, vaultName st
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -179,7 +179,7 @@ func (client RecoveryPointsClient) ListPreparer(ctx context.Context, vaultName s
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/resourcevaultconfigs.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/resourcevaultconfigs.go
index 3cb36b898367..be1d140227b9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/resourcevaultconfigs.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/resourcevaultconfigs.go
@@ -84,7 +84,7 @@ func (client ResourceVaultConfigsClient) GetPreparer(ctx context.Context, vaultN
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -162,7 +162,7 @@ func (client ResourceVaultConfigsClient) UpdatePreparer(ctx context.Context, vau
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/restores.go b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/restores.go
index 211714201e84..ae81caf616b1 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/restores.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/recoveryservices/mgmt/2017-07-01/backup/restores.go
@@ -95,7 +95,7 @@ func (client RestoresClient) TriggerPreparer(ctx context.Context, vaultName stri
"vaultName": autorest.Encode("path", vaultName),
}
- const APIVersion = "2016-12-01"
+ const APIVersion = "2019-05-13"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/client.go b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/client.go
index 8b5883bddb99..014a36f64ae9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/client.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/client.go
@@ -29,7 +29,6 @@ const (
DefaultBaseURI = "https://management.azure.com"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// BaseClient is the base client for Scheduler.
type BaseClient struct {
autorest.Client
@@ -37,13 +36,11 @@ type BaseClient struct {
SubscriptionID string
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// New creates an instance of the BaseClient client.
func New(subscriptionID string) BaseClient {
return NewWithBaseURI(DefaultBaseURI, subscriptionID)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// NewWithBaseURI creates an instance of the BaseClient client.
func NewWithBaseURI(baseURI string, subscriptionID string) BaseClient {
return BaseClient{
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobcollections.go b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobcollections.go
index 23564fe7a4a9..9f72059704c9 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobcollections.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobcollections.go
@@ -25,25 +25,21 @@ import (
"net/http"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionsClient is the client for the JobCollections methods of the Scheduler service.
type JobCollectionsClient struct {
BaseClient
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// NewJobCollectionsClient creates an instance of the JobCollectionsClient client.
func NewJobCollectionsClient(subscriptionID string) JobCollectionsClient {
return NewJobCollectionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// NewJobCollectionsClientWithBaseURI creates an instance of the JobCollectionsClient client.
func NewJobCollectionsClientWithBaseURI(baseURI string, subscriptionID string) JobCollectionsClient {
return JobCollectionsClient{NewWithBaseURI(baseURI, subscriptionID)}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdate provisions a new job collection or updates an existing job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -81,7 +77,6 @@ func (client JobCollectionsClient) CreateOrUpdate(ctx context.Context, resourceG
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
func (client JobCollectionsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobCollection JobCollectionDefinition) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -107,7 +102,6 @@ func (client JobCollectionsClient) CreateOrUpdatePreparer(ctx context.Context, r
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
@@ -115,7 +109,6 @@ func (client JobCollectionsClient) CreateOrUpdateSender(req *http.Request) (*htt
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) CreateOrUpdateResponder(resp *http.Response) (result JobCollectionDefinition, err error) {
@@ -129,7 +122,6 @@ func (client JobCollectionsClient) CreateOrUpdateResponder(resp *http.Response)
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Delete deletes a job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -160,7 +152,6 @@ func (client JobCollectionsClient) Delete(ctx context.Context, resourceGroupName
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeletePreparer prepares the Delete request.
func (client JobCollectionsClient) DeletePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -182,7 +173,6 @@ func (client JobCollectionsClient) DeletePreparer(ctx context.Context, resourceG
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeleteSender sends the Delete request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) DeleteSender(req *http.Request) (future JobCollectionsDeleteFuture, err error) {
@@ -196,7 +186,6 @@ func (client JobCollectionsClient) DeleteSender(req *http.Request) (future JobCo
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeleteResponder handles the response to the Delete request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
@@ -209,7 +198,6 @@ func (client JobCollectionsClient) DeleteResponder(resp *http.Response) (result
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Disable disables all of the jobs in the job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -240,7 +228,6 @@ func (client JobCollectionsClient) Disable(ctx context.Context, resourceGroupNam
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DisablePreparer prepares the Disable request.
func (client JobCollectionsClient) DisablePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -262,7 +249,6 @@ func (client JobCollectionsClient) DisablePreparer(ctx context.Context, resource
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DisableSender sends the Disable request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) DisableSender(req *http.Request) (future JobCollectionsDisableFuture, err error) {
@@ -276,7 +262,6 @@ func (client JobCollectionsClient) DisableSender(req *http.Request) (future JobC
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DisableResponder handles the response to the Disable request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) DisableResponder(resp *http.Response) (result autorest.Response, err error) {
@@ -289,7 +274,6 @@ func (client JobCollectionsClient) DisableResponder(resp *http.Response) (result
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Enable enables all of the jobs in the job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -320,7 +304,6 @@ func (client JobCollectionsClient) Enable(ctx context.Context, resourceGroupName
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// EnablePreparer prepares the Enable request.
func (client JobCollectionsClient) EnablePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -342,7 +325,6 @@ func (client JobCollectionsClient) EnablePreparer(ctx context.Context, resourceG
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// EnableSender sends the Enable request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) EnableSender(req *http.Request) (future JobCollectionsEnableFuture, err error) {
@@ -356,7 +338,6 @@ func (client JobCollectionsClient) EnableSender(req *http.Request) (future JobCo
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// EnableResponder handles the response to the Enable request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) EnableResponder(resp *http.Response) (result autorest.Response, err error) {
@@ -369,7 +350,6 @@ func (client JobCollectionsClient) EnableResponder(resp *http.Response) (result
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Get gets a job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -406,7 +386,6 @@ func (client JobCollectionsClient) Get(ctx context.Context, resourceGroupName st
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetPreparer prepares the Get request.
func (client JobCollectionsClient) GetPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -428,7 +407,6 @@ func (client JobCollectionsClient) GetPreparer(ctx context.Context, resourceGrou
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetSender sends the Get request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) GetSender(req *http.Request) (*http.Response, error) {
@@ -436,7 +414,6 @@ func (client JobCollectionsClient) GetSender(req *http.Request) (*http.Response,
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetResponder handles the response to the Get request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) GetResponder(resp *http.Response) (result JobCollectionDefinition, err error) {
@@ -450,7 +427,6 @@ func (client JobCollectionsClient) GetResponder(resp *http.Response) (result Job
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListByResourceGroup gets all job collections under specified resource group.
// Parameters:
// resourceGroupName - the resource group name.
@@ -487,7 +463,6 @@ func (client JobCollectionsClient) ListByResourceGroup(ctx context.Context, reso
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
func (client JobCollectionsClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -508,7 +483,6 @@ func (client JobCollectionsClient) ListByResourceGroupPreparer(ctx context.Conte
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
@@ -516,7 +490,6 @@ func (client JobCollectionsClient) ListByResourceGroupSender(req *http.Request)
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) ListByResourceGroupResponder(resp *http.Response) (result JobCollectionListResult, err error) {
@@ -551,7 +524,6 @@ func (client JobCollectionsClient) listByResourceGroupNextResults(ctx context.Co
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
func (client JobCollectionsClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string) (result JobCollectionListResultIterator, err error) {
if tracing.IsEnabled() {
@@ -568,7 +540,6 @@ func (client JobCollectionsClient) ListByResourceGroupComplete(ctx context.Conte
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListBySubscription gets all job collections under specified subscription.
func (client JobCollectionsClient) ListBySubscription(ctx context.Context) (result JobCollectionListResultPage, err error) {
if tracing.IsEnabled() {
@@ -603,7 +574,6 @@ func (client JobCollectionsClient) ListBySubscription(ctx context.Context) (resu
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListBySubscriptionPreparer prepares the ListBySubscription request.
func (client JobCollectionsClient) ListBySubscriptionPreparer(ctx context.Context) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -623,7 +593,6 @@ func (client JobCollectionsClient) ListBySubscriptionPreparer(ctx context.Contex
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListBySubscriptionSender sends the ListBySubscription request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) ListBySubscriptionSender(req *http.Request) (*http.Response, error) {
@@ -631,7 +600,6 @@ func (client JobCollectionsClient) ListBySubscriptionSender(req *http.Request) (
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListBySubscriptionResponder handles the response to the ListBySubscription request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) ListBySubscriptionResponder(resp *http.Response) (result JobCollectionListResult, err error) {
@@ -666,7 +634,6 @@ func (client JobCollectionsClient) listBySubscriptionNextResults(ctx context.Con
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListBySubscriptionComplete enumerates all values, automatically crossing page boundaries as required.
func (client JobCollectionsClient) ListBySubscriptionComplete(ctx context.Context) (result JobCollectionListResultIterator, err error) {
if tracing.IsEnabled() {
@@ -683,7 +650,6 @@ func (client JobCollectionsClient) ListBySubscriptionComplete(ctx context.Contex
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Patch patches an existing job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -721,7 +687,6 @@ func (client JobCollectionsClient) Patch(ctx context.Context, resourceGroupName
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchPreparer prepares the Patch request.
func (client JobCollectionsClient) PatchPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobCollection JobCollectionDefinition) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -747,7 +712,6 @@ func (client JobCollectionsClient) PatchPreparer(ctx context.Context, resourceGr
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchSender sends the Patch request. The method will close the
// http.Response Body if it receives an error.
func (client JobCollectionsClient) PatchSender(req *http.Request) (*http.Response, error) {
@@ -755,7 +719,6 @@ func (client JobCollectionsClient) PatchSender(req *http.Request) (*http.Respons
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchResponder handles the response to the Patch request. The method always
// closes the http.Response Body.
func (client JobCollectionsClient) PatchResponder(resp *http.Response) (result JobCollectionDefinition, err error) {
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobs.go b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobs.go
index 8066cef82b47..1942cd84b0de 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobs.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/jobs.go
@@ -26,25 +26,21 @@ import (
"net/http"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobsClient is the client for the Jobs methods of the Scheduler service.
type JobsClient struct {
BaseClient
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// NewJobsClient creates an instance of the JobsClient client.
func NewJobsClient(subscriptionID string) JobsClient {
return NewJobsClientWithBaseURI(DefaultBaseURI, subscriptionID)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// NewJobsClientWithBaseURI creates an instance of the JobsClient client.
func NewJobsClientWithBaseURI(baseURI string, subscriptionID string) JobsClient {
return JobsClient{NewWithBaseURI(baseURI, subscriptionID)}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdate provisions a new job or updates an existing job.
// Parameters:
// resourceGroupName - the resource group name.
@@ -83,7 +79,6 @@ func (client JobsClient) CreateOrUpdate(ctx context.Context, resourceGroupName s
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
func (client JobsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string, job JobDefinition) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -111,7 +106,6 @@ func (client JobsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGro
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
@@ -119,7 +113,6 @@ func (client JobsClient) CreateOrUpdateSender(req *http.Request) (*http.Response
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
// closes the http.Response Body.
func (client JobsClient) CreateOrUpdateResponder(resp *http.Response) (result JobDefinition, err error) {
@@ -133,7 +126,6 @@ func (client JobsClient) CreateOrUpdateResponder(resp *http.Response) (result Jo
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Delete deletes a job.
// Parameters:
// resourceGroupName - the resource group name.
@@ -171,7 +163,6 @@ func (client JobsClient) Delete(ctx context.Context, resourceGroupName string, j
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeletePreparer prepares the Delete request.
func (client JobsClient) DeletePreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -194,7 +185,6 @@ func (client JobsClient) DeletePreparer(ctx context.Context, resourceGroupName s
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeleteSender sends the Delete request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) DeleteSender(req *http.Request) (*http.Response, error) {
@@ -202,7 +192,6 @@ func (client JobsClient) DeleteSender(req *http.Request) (*http.Response, error)
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// DeleteResponder handles the response to the Delete request. The method always
// closes the http.Response Body.
func (client JobsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
@@ -215,7 +204,6 @@ func (client JobsClient) DeleteResponder(resp *http.Response) (result autorest.R
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Get gets a job.
// Parameters:
// resourceGroupName - the resource group name.
@@ -253,7 +241,6 @@ func (client JobsClient) Get(ctx context.Context, resourceGroupName string, jobC
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetPreparer prepares the Get request.
func (client JobsClient) GetPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -276,7 +263,6 @@ func (client JobsClient) GetPreparer(ctx context.Context, resourceGroupName stri
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetSender sends the Get request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) GetSender(req *http.Request) (*http.Response, error) {
@@ -284,7 +270,6 @@ func (client JobsClient) GetSender(req *http.Request) (*http.Response, error) {
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// GetResponder handles the response to the Get request. The method always
// closes the http.Response Body.
func (client JobsClient) GetResponder(resp *http.Response) (result JobDefinition, err error) {
@@ -298,7 +283,6 @@ func (client JobsClient) GetResponder(resp *http.Response) (result JobDefinition
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// List lists all jobs under the specified job collection.
// Parameters:
// resourceGroupName - the resource group name.
@@ -348,7 +332,6 @@ func (client JobsClient) List(ctx context.Context, resourceGroupName string, job
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListPreparer prepares the List request.
func (client JobsClient) ListPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, top *int32, skip *int32, filter string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -379,7 +362,6 @@ func (client JobsClient) ListPreparer(ctx context.Context, resourceGroupName str
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListSender sends the List request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) ListSender(req *http.Request) (*http.Response, error) {
@@ -387,7 +369,6 @@ func (client JobsClient) ListSender(req *http.Request) (*http.Response, error) {
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListResponder handles the response to the List request. The method always
// closes the http.Response Body.
func (client JobsClient) ListResponder(resp *http.Response) (result JobListResult, err error) {
@@ -422,7 +403,6 @@ func (client JobsClient) listNextResults(ctx context.Context, lastResults JobLis
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListComplete enumerates all values, automatically crossing page boundaries as required.
func (client JobsClient) ListComplete(ctx context.Context, resourceGroupName string, jobCollectionName string, top *int32, skip *int32, filter string) (result JobListResultIterator, err error) {
if tracing.IsEnabled() {
@@ -439,7 +419,6 @@ func (client JobsClient) ListComplete(ctx context.Context, resourceGroupName str
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListJobHistory lists job history.
// Parameters:
// resourceGroupName - the resource group name.
@@ -490,7 +469,6 @@ func (client JobsClient) ListJobHistory(ctx context.Context, resourceGroupName s
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListJobHistoryPreparer prepares the ListJobHistory request.
func (client JobsClient) ListJobHistoryPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string, top *int32, skip *int32, filter string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -522,7 +500,6 @@ func (client JobsClient) ListJobHistoryPreparer(ctx context.Context, resourceGro
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListJobHistorySender sends the ListJobHistory request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) ListJobHistorySender(req *http.Request) (*http.Response, error) {
@@ -530,7 +507,6 @@ func (client JobsClient) ListJobHistorySender(req *http.Request) (*http.Response
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListJobHistoryResponder handles the response to the ListJobHistory request. The method always
// closes the http.Response Body.
func (client JobsClient) ListJobHistoryResponder(resp *http.Response) (result JobHistoryListResult, err error) {
@@ -565,7 +541,6 @@ func (client JobsClient) listJobHistoryNextResults(ctx context.Context, lastResu
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ListJobHistoryComplete enumerates all values, automatically crossing page boundaries as required.
func (client JobsClient) ListJobHistoryComplete(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string, top *int32, skip *int32, filter string) (result JobHistoryListResultIterator, err error) {
if tracing.IsEnabled() {
@@ -582,7 +557,6 @@ func (client JobsClient) ListJobHistoryComplete(ctx context.Context, resourceGro
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Patch patches an existing job.
// Parameters:
// resourceGroupName - the resource group name.
@@ -621,7 +595,6 @@ func (client JobsClient) Patch(ctx context.Context, resourceGroupName string, jo
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchPreparer prepares the Patch request.
func (client JobsClient) PatchPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string, job JobDefinition) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -649,7 +622,6 @@ func (client JobsClient) PatchPreparer(ctx context.Context, resourceGroupName st
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchSender sends the Patch request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) PatchSender(req *http.Request) (*http.Response, error) {
@@ -657,7 +629,6 @@ func (client JobsClient) PatchSender(req *http.Request) (*http.Response, error)
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PatchResponder handles the response to the Patch request. The method always
// closes the http.Response Body.
func (client JobsClient) PatchResponder(resp *http.Response) (result JobDefinition, err error) {
@@ -671,7 +642,6 @@ func (client JobsClient) PatchResponder(resp *http.Response) (result JobDefiniti
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Run runs a job.
// Parameters:
// resourceGroupName - the resource group name.
@@ -709,7 +679,6 @@ func (client JobsClient) Run(ctx context.Context, resourceGroupName string, jobC
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RunPreparer prepares the Run request.
func (client JobsClient) RunPreparer(ctx context.Context, resourceGroupName string, jobCollectionName string, jobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
@@ -732,7 +701,6 @@ func (client JobsClient) RunPreparer(ctx context.Context, resourceGroupName stri
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RunSender sends the Run request. The method will close the
// http.Response Body if it receives an error.
func (client JobsClient) RunSender(req *http.Request) (*http.Response, error) {
@@ -740,7 +708,6 @@ func (client JobsClient) RunSender(req *http.Request) (*http.Response, error) {
return autorest.SendWithSender(client, req, sd...)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RunResponder handles the response to the Run request. The method always
// closes the http.Response Body.
func (client JobsClient) RunResponder(resp *http.Response) (result autorest.Response, err error) {
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/models.go
index 7f79963bba05..00aba5f9bc56 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/models.go
@@ -51,13 +51,11 @@ const (
Wednesday DayOfWeek = "Wednesday"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleDayOfWeekValues returns an array of possible values for the DayOfWeek const type.
func PossibleDayOfWeekValues() []DayOfWeek {
return []DayOfWeek{Friday, Monday, Saturday, Sunday, Thursday, Tuesday, Wednesday}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobActionType enumerates the values for job action type.
type JobActionType string
@@ -74,13 +72,11 @@ const (
StorageQueue JobActionType = "StorageQueue"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobActionTypeValues returns an array of possible values for the JobActionType const type.
func PossibleJobActionTypeValues() []JobActionType {
return []JobActionType{HTTP, HTTPS, ServiceBusQueue, ServiceBusTopic, StorageQueue}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionState enumerates the values for job collection state.
type JobCollectionState string
@@ -95,13 +91,11 @@ const (
Suspended JobCollectionState = "Suspended"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobCollectionStateValues returns an array of possible values for the JobCollectionState const type.
func PossibleJobCollectionStateValues() []JobCollectionState {
return []JobCollectionState{Deleted, Disabled, Enabled, Suspended}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobExecutionStatus enumerates the values for job execution status.
type JobExecutionStatus string
@@ -114,13 +108,11 @@ const (
Postponed JobExecutionStatus = "Postponed"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobExecutionStatusValues returns an array of possible values for the JobExecutionStatus const type.
func PossibleJobExecutionStatusValues() []JobExecutionStatus {
return []JobExecutionStatus{Completed, Failed, Postponed}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryActionName enumerates the values for job history action name.
type JobHistoryActionName string
@@ -131,13 +123,11 @@ const (
MainAction JobHistoryActionName = "MainAction"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobHistoryActionNameValues returns an array of possible values for the JobHistoryActionName const type.
func PossibleJobHistoryActionNameValues() []JobHistoryActionName {
return []JobHistoryActionName{ErrorAction, MainAction}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobScheduleDay enumerates the values for job schedule day.
type JobScheduleDay string
@@ -158,13 +148,11 @@ const (
JobScheduleDayWednesday JobScheduleDay = "Wednesday"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobScheduleDayValues returns an array of possible values for the JobScheduleDay const type.
func PossibleJobScheduleDayValues() []JobScheduleDay {
return []JobScheduleDay{JobScheduleDayFriday, JobScheduleDayMonday, JobScheduleDaySaturday, JobScheduleDaySunday, JobScheduleDayThursday, JobScheduleDayTuesday, JobScheduleDayWednesday}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobState enumerates the values for job state.
type JobState string
@@ -179,13 +167,11 @@ const (
JobStateFaulted JobState = "Faulted"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleJobStateValues returns an array of possible values for the JobState const type.
func PossibleJobStateValues() []JobState {
return []JobState{JobStateCompleted, JobStateDisabled, JobStateEnabled, JobStateFaulted}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RecurrenceFrequency enumerates the values for recurrence frequency.
type RecurrenceFrequency string
@@ -202,13 +188,11 @@ const (
Week RecurrenceFrequency = "Week"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleRecurrenceFrequencyValues returns an array of possible values for the RecurrenceFrequency const type.
func PossibleRecurrenceFrequencyValues() []RecurrenceFrequency {
return []RecurrenceFrequency{Day, Hour, Minute, Month, Week}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RetryType enumerates the values for retry type.
type RetryType string
@@ -219,13 +203,11 @@ const (
None RetryType = "None"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleRetryTypeValues returns an array of possible values for the RetryType const type.
func PossibleRetryTypeValues() []RetryType {
return []RetryType{Fixed, None}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusAuthenticationType enumerates the values for service bus authentication type.
type ServiceBusAuthenticationType string
@@ -236,13 +218,11 @@ const (
SharedAccessKey ServiceBusAuthenticationType = "SharedAccessKey"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleServiceBusAuthenticationTypeValues returns an array of possible values for the ServiceBusAuthenticationType const type.
func PossibleServiceBusAuthenticationTypeValues() []ServiceBusAuthenticationType {
return []ServiceBusAuthenticationType{NotSpecified, SharedAccessKey}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusTransportType enumerates the values for service bus transport type.
type ServiceBusTransportType string
@@ -255,13 +235,11 @@ const (
ServiceBusTransportTypeNotSpecified ServiceBusTransportType = "NotSpecified"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleServiceBusTransportTypeValues returns an array of possible values for the ServiceBusTransportType const type.
func PossibleServiceBusTransportTypeValues() []ServiceBusTransportType {
return []ServiceBusTransportType{ServiceBusTransportTypeAMQP, ServiceBusTransportTypeNetMessaging, ServiceBusTransportTypeNotSpecified}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// SkuDefinition enumerates the values for sku definition.
type SkuDefinition string
@@ -276,13 +254,11 @@ const (
Standard SkuDefinition = "Standard"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleSkuDefinitionValues returns an array of possible values for the SkuDefinition const type.
func PossibleSkuDefinitionValues() []SkuDefinition {
return []SkuDefinition{Free, P10Premium, P20Premium, Standard}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Type enumerates the values for type.
type Type string
@@ -297,13 +273,11 @@ const (
TypeHTTPAuthentication Type = "HttpAuthentication"
)
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// PossibleTypeValues returns an array of possible values for the Type const type.
func PossibleTypeValues() []Type {
return []Type{TypeActiveDirectoryOAuth, TypeBasic, TypeClientCertificate, TypeHTTPAuthentication}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// BasicAuthentication ...
type BasicAuthentication struct {
// Username - Gets or sets the username.
@@ -314,7 +288,6 @@ type BasicAuthentication struct {
Type Type `json:"type,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for BasicAuthentication.
func (ba BasicAuthentication) MarshalJSON() ([]byte, error) {
ba.Type = TypeBasic
@@ -331,37 +304,31 @@ func (ba BasicAuthentication) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsClientCertAuthentication is the BasicHTTPAuthentication implementation for BasicAuthentication.
func (ba BasicAuthentication) AsClientCertAuthentication() (*ClientCertAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicAuthentication is the BasicHTTPAuthentication implementation for BasicAuthentication.
func (ba BasicAuthentication) AsBasicAuthentication() (*BasicAuthentication, bool) {
return &ba, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsOAuthAuthentication is the BasicHTTPAuthentication implementation for BasicAuthentication.
func (ba BasicAuthentication) AsOAuthAuthentication() (*OAuthAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsHTTPAuthentication is the BasicHTTPAuthentication implementation for BasicAuthentication.
func (ba BasicAuthentication) AsHTTPAuthentication() (*HTTPAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicHTTPAuthentication is the BasicHTTPAuthentication implementation for BasicAuthentication.
func (ba BasicAuthentication) AsBasicHTTPAuthentication() (BasicHTTPAuthentication, bool) {
return &ba, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ClientCertAuthentication ...
type ClientCertAuthentication struct {
// Password - Gets or sets the certificate password, return value will always be empty.
@@ -378,7 +345,6 @@ type ClientCertAuthentication struct {
Type Type `json:"type,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for ClientCertAuthentication.
func (cca ClientCertAuthentication) MarshalJSON() ([]byte, error) {
cca.Type = TypeClientCertificate
@@ -404,37 +370,31 @@ func (cca ClientCertAuthentication) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsClientCertAuthentication is the BasicHTTPAuthentication implementation for ClientCertAuthentication.
func (cca ClientCertAuthentication) AsClientCertAuthentication() (*ClientCertAuthentication, bool) {
return &cca, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicAuthentication is the BasicHTTPAuthentication implementation for ClientCertAuthentication.
func (cca ClientCertAuthentication) AsBasicAuthentication() (*BasicAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsOAuthAuthentication is the BasicHTTPAuthentication implementation for ClientCertAuthentication.
func (cca ClientCertAuthentication) AsOAuthAuthentication() (*OAuthAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsHTTPAuthentication is the BasicHTTPAuthentication implementation for ClientCertAuthentication.
func (cca ClientCertAuthentication) AsHTTPAuthentication() (*HTTPAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicHTTPAuthentication is the BasicHTTPAuthentication implementation for ClientCertAuthentication.
func (cca ClientCertAuthentication) AsBasicHTTPAuthentication() (BasicHTTPAuthentication, bool) {
return &cca, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// BasicHTTPAuthentication ...
type BasicHTTPAuthentication interface {
AsClientCertAuthentication() (*ClientCertAuthentication, bool)
@@ -443,7 +403,6 @@ type BasicHTTPAuthentication interface {
AsHTTPAuthentication() (*HTTPAuthentication, bool)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// HTTPAuthentication ...
type HTTPAuthentication struct {
// Type - Possible values include: 'TypeHTTPAuthentication', 'TypeClientCertificate', 'TypeBasic', 'TypeActiveDirectoryOAuth'
@@ -495,7 +454,6 @@ func unmarshalBasicHTTPAuthenticationArray(body []byte) ([]BasicHTTPAuthenticati
return haArray, nil
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for HTTPAuthentication.
func (ha HTTPAuthentication) MarshalJSON() ([]byte, error) {
ha.Type = TypeHTTPAuthentication
@@ -506,37 +464,31 @@ func (ha HTTPAuthentication) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsClientCertAuthentication is the BasicHTTPAuthentication implementation for HTTPAuthentication.
func (ha HTTPAuthentication) AsClientCertAuthentication() (*ClientCertAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicAuthentication is the BasicHTTPAuthentication implementation for HTTPAuthentication.
func (ha HTTPAuthentication) AsBasicAuthentication() (*BasicAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsOAuthAuthentication is the BasicHTTPAuthentication implementation for HTTPAuthentication.
func (ha HTTPAuthentication) AsOAuthAuthentication() (*OAuthAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsHTTPAuthentication is the BasicHTTPAuthentication implementation for HTTPAuthentication.
func (ha HTTPAuthentication) AsHTTPAuthentication() (*HTTPAuthentication, bool) {
return &ha, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicHTTPAuthentication is the BasicHTTPAuthentication implementation for HTTPAuthentication.
func (ha HTTPAuthentication) AsBasicHTTPAuthentication() (BasicHTTPAuthentication, bool) {
return &ha, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// HTTPRequest ...
type HTTPRequest struct {
// Authentication - Gets or sets the authentication method of the request.
@@ -551,7 +503,6 @@ type HTTPRequest struct {
Headers map[string]*string `json:"headers"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for HTTPRequest.
func (hr HTTPRequest) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
@@ -571,7 +522,6 @@ func (hr HTTPRequest) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// UnmarshalJSON is the custom unmarshaler for HTTPRequest struct.
func (hr *HTTPRequest) UnmarshalJSON(body []byte) error {
var m map[string]*json.RawMessage
@@ -631,7 +581,6 @@ func (hr *HTTPRequest) UnmarshalJSON(body []byte) error {
return nil
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobAction ...
type JobAction struct {
// Type - Gets or sets the job action type. Possible values include: 'HTTP', 'HTTPS', 'StorageQueue', 'ServiceBusQueue', 'ServiceBusTopic'
@@ -650,7 +599,6 @@ type JobAction struct {
ErrorAction *JobErrorAction `json:"errorAction,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionDefinition ...
type JobCollectionDefinition struct {
autorest.Response `json:"-"`
@@ -668,7 +616,6 @@ type JobCollectionDefinition struct {
Properties *JobCollectionProperties `json:"properties,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for JobCollectionDefinition.
func (jcd JobCollectionDefinition) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
@@ -687,7 +634,6 @@ func (jcd JobCollectionDefinition) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionListResult ...
type JobCollectionListResult struct {
autorest.Response `json:"-"`
@@ -697,7 +643,6 @@ type JobCollectionListResult struct {
NextLink *string `json:"nextLink,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionListResultIterator provides access to a complete listing of JobCollectionDefinition values.
type JobCollectionListResultIterator struct {
i int
@@ -742,13 +687,11 @@ func (iter JobCollectionListResultIterator) NotDone() bool {
return iter.page.NotDone() && iter.i < len(iter.page.Values())
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (iter JobCollectionListResultIterator) Response() JobCollectionListResult {
return iter.page.Response()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Value returns the current value or a zero-initialized value if the
// iterator has advanced beyond the end of the collection.
func (iter JobCollectionListResultIterator) Value() JobCollectionDefinition {
@@ -758,13 +701,11 @@ func (iter JobCollectionListResultIterator) Value() JobCollectionDefinition {
return iter.page.Values()[iter.i]
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobCollectionListResultIterator type.
func NewJobCollectionListResultIterator(page JobCollectionListResultPage) JobCollectionListResultIterator {
return JobCollectionListResultIterator{page: page}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// IsEmpty returns true if the ListResult contains no values.
func (jclr JobCollectionListResult) IsEmpty() bool {
return jclr.Value == nil || len(*jclr.Value) == 0
@@ -782,7 +723,6 @@ func (jclr JobCollectionListResult) jobCollectionListResultPreparer(ctx context.
autorest.WithBaseURL(to.String(jclr.NextLink)))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionListResultPage contains a page of JobCollectionDefinition values.
type JobCollectionListResultPage struct {
fn func(context.Context, JobCollectionListResult) (JobCollectionListResult, error)
@@ -822,13 +762,11 @@ func (page JobCollectionListResultPage) NotDone() bool {
return !page.jclr.IsEmpty()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (page JobCollectionListResultPage) Response() JobCollectionListResult {
return page.jclr
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Values returns the slice of values for the current page or nil if there are no values.
func (page JobCollectionListResultPage) Values() []JobCollectionDefinition {
if page.jclr.IsEmpty() {
@@ -837,13 +775,11 @@ func (page JobCollectionListResultPage) Values() []JobCollectionDefinition {
return *page.jclr.Value
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobCollectionListResultPage type.
func NewJobCollectionListResultPage(getNextPage func(context.Context, JobCollectionListResult) (JobCollectionListResult, error)) JobCollectionListResultPage {
return JobCollectionListResultPage{fn: getNextPage}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionProperties ...
type JobCollectionProperties struct {
// Sku - Gets or sets the SKU.
@@ -854,7 +790,6 @@ type JobCollectionProperties struct {
Quota *JobCollectionQuota `json:"quota,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionQuota ...
type JobCollectionQuota struct {
// MaxJobCount - Gets or set the maximum job count.
@@ -871,7 +806,6 @@ type JobCollectionsDeleteFuture struct {
azure.Future
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Result returns the result of the asynchronous operation.
// If the operation has not completed it will return an error.
func (future *JobCollectionsDeleteFuture) Result(client JobCollectionsClient) (ar autorest.Response, err error) {
@@ -889,14 +823,12 @@ func (future *JobCollectionsDeleteFuture) Result(client JobCollectionsClient) (a
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobCollectionsDisableFuture an abstraction for monitoring and retrieving the results of a long-running
// operation.
type JobCollectionsDisableFuture struct {
azure.Future
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Result returns the result of the asynchronous operation.
// If the operation has not completed it will return an error.
func (future *JobCollectionsDisableFuture) Result(client JobCollectionsClient) (ar autorest.Response, err error) {
@@ -920,7 +852,6 @@ type JobCollectionsEnableFuture struct {
azure.Future
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Result returns the result of the asynchronous operation.
// If the operation has not completed it will return an error.
func (future *JobCollectionsEnableFuture) Result(client JobCollectionsClient) (ar autorest.Response, err error) {
@@ -938,7 +869,6 @@ func (future *JobCollectionsEnableFuture) Result(client JobCollectionsClient) (a
return
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobDefinition ...
type JobDefinition struct {
autorest.Response `json:"-"`
@@ -952,7 +882,6 @@ type JobDefinition struct {
Properties *JobProperties `json:"properties,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobErrorAction ...
type JobErrorAction struct {
// Type - Gets or sets the job error action type. Possible values include: 'HTTP', 'HTTPS', 'StorageQueue', 'ServiceBusQueue', 'ServiceBusTopic'
@@ -969,7 +898,6 @@ type JobErrorAction struct {
RetryPolicy *RetryPolicy `json:"retryPolicy,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryDefinition ...
type JobHistoryDefinition struct {
// ID - READ-ONLY; Gets the job history identifier.
@@ -982,7 +910,6 @@ type JobHistoryDefinition struct {
Properties *JobHistoryDefinitionProperties `json:"properties,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryDefinitionProperties ...
type JobHistoryDefinitionProperties struct {
// StartTime - READ-ONLY; Gets the start time for this job.
@@ -1003,14 +930,12 @@ type JobHistoryDefinitionProperties struct {
RepeatCount *int32 `json:"repeatCount,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryFilter ...
type JobHistoryFilter struct {
// Status - Gets or sets the job execution status. Possible values include: 'Completed', 'Failed', 'Postponed'
Status JobExecutionStatus `json:"status,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryListResult ...
type JobHistoryListResult struct {
autorest.Response `json:"-"`
@@ -1020,7 +945,6 @@ type JobHistoryListResult struct {
NextLink *string `json:"nextLink,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryListResultIterator provides access to a complete listing of JobHistoryDefinition values.
type JobHistoryListResultIterator struct {
i int
@@ -1065,13 +989,11 @@ func (iter JobHistoryListResultIterator) NotDone() bool {
return iter.page.NotDone() && iter.i < len(iter.page.Values())
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (iter JobHistoryListResultIterator) Response() JobHistoryListResult {
return iter.page.Response()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Value returns the current value or a zero-initialized value if the
// iterator has advanced beyond the end of the collection.
func (iter JobHistoryListResultIterator) Value() JobHistoryDefinition {
@@ -1081,13 +1003,11 @@ func (iter JobHistoryListResultIterator) Value() JobHistoryDefinition {
return iter.page.Values()[iter.i]
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobHistoryListResultIterator type.
func NewJobHistoryListResultIterator(page JobHistoryListResultPage) JobHistoryListResultIterator {
return JobHistoryListResultIterator{page: page}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// IsEmpty returns true if the ListResult contains no values.
func (jhlr JobHistoryListResult) IsEmpty() bool {
return jhlr.Value == nil || len(*jhlr.Value) == 0
@@ -1105,7 +1025,6 @@ func (jhlr JobHistoryListResult) jobHistoryListResultPreparer(ctx context.Contex
autorest.WithBaseURL(to.String(jhlr.NextLink)))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobHistoryListResultPage contains a page of JobHistoryDefinition values.
type JobHistoryListResultPage struct {
fn func(context.Context, JobHistoryListResult) (JobHistoryListResult, error)
@@ -1145,13 +1064,11 @@ func (page JobHistoryListResultPage) NotDone() bool {
return !page.jhlr.IsEmpty()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (page JobHistoryListResultPage) Response() JobHistoryListResult {
return page.jhlr
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Values returns the slice of values for the current page or nil if there are no values.
func (page JobHistoryListResultPage) Values() []JobHistoryDefinition {
if page.jhlr.IsEmpty() {
@@ -1160,13 +1077,11 @@ func (page JobHistoryListResultPage) Values() []JobHistoryDefinition {
return *page.jhlr.Value
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobHistoryListResultPage type.
func NewJobHistoryListResultPage(getNextPage func(context.Context, JobHistoryListResult) (JobHistoryListResult, error)) JobHistoryListResultPage {
return JobHistoryListResultPage{fn: getNextPage}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobListResult ...
type JobListResult struct {
autorest.Response `json:"-"`
@@ -1176,7 +1091,6 @@ type JobListResult struct {
NextLink *string `json:"nextLink,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobListResultIterator provides access to a complete listing of JobDefinition values.
type JobListResultIterator struct {
i int
@@ -1221,13 +1135,11 @@ func (iter JobListResultIterator) NotDone() bool {
return iter.page.NotDone() && iter.i < len(iter.page.Values())
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (iter JobListResultIterator) Response() JobListResult {
return iter.page.Response()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Value returns the current value or a zero-initialized value if the
// iterator has advanced beyond the end of the collection.
func (iter JobListResultIterator) Value() JobDefinition {
@@ -1237,13 +1149,11 @@ func (iter JobListResultIterator) Value() JobDefinition {
return iter.page.Values()[iter.i]
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobListResultIterator type.
func NewJobListResultIterator(page JobListResultPage) JobListResultIterator {
return JobListResultIterator{page: page}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// IsEmpty returns true if the ListResult contains no values.
func (jlr JobListResult) IsEmpty() bool {
return jlr.Value == nil || len(*jlr.Value) == 0
@@ -1261,7 +1171,6 @@ func (jlr JobListResult) jobListResultPreparer(ctx context.Context) (*http.Reque
autorest.WithBaseURL(to.String(jlr.NextLink)))
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobListResultPage contains a page of JobDefinition values.
type JobListResultPage struct {
fn func(context.Context, JobListResult) (JobListResult, error)
@@ -1301,13 +1210,11 @@ func (page JobListResultPage) NotDone() bool {
return !page.jlr.IsEmpty()
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Response returns the raw server response from the last page request.
func (page JobListResultPage) Response() JobListResult {
return page.jlr
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Values returns the slice of values for the current page or nil if there are no values.
func (page JobListResultPage) Values() []JobDefinition {
if page.jlr.IsEmpty() {
@@ -1316,13 +1223,11 @@ func (page JobListResultPage) Values() []JobDefinition {
return *page.jlr.Value
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Creates a new instance of the JobListResultPage type.
func NewJobListResultPage(getNextPage func(context.Context, JobListResult) (JobListResult, error)) JobListResultPage {
return JobListResultPage{fn: getNextPage}
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobMaxRecurrence ...
type JobMaxRecurrence struct {
// Frequency - Gets or sets the frequency of recurrence (second, minute, hour, day, week, month). Possible values include: 'Minute', 'Hour', 'Day', 'Week', 'Month'
@@ -1331,7 +1236,6 @@ type JobMaxRecurrence struct {
Interval *int32 `json:"interval,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobProperties ...
type JobProperties struct {
// StartTime - Gets or sets the job start time.
@@ -1346,7 +1250,6 @@ type JobProperties struct {
Status *JobStatus `json:"status,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobRecurrence ...
type JobRecurrence struct {
// Frequency - Gets or sets the frequency of recurrence (second, minute, hour, day, week, month). Possible values include: 'Minute', 'Hour', 'Day', 'Week', 'Month'
@@ -1360,7 +1263,6 @@ type JobRecurrence struct {
Schedule *JobRecurrenceSchedule `json:"schedule,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobRecurrenceSchedule ...
type JobRecurrenceSchedule struct {
// WeekDays - Gets or sets the days of the week that the job should execute on.
@@ -1375,7 +1277,6 @@ type JobRecurrenceSchedule struct {
MonthlyOccurrences *[]JobRecurrenceScheduleMonthlyOccurrence `json:"monthlyOccurrences,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobRecurrenceScheduleMonthlyOccurrence ...
type JobRecurrenceScheduleMonthlyOccurrence struct {
// Day - Gets or sets the day. Must be one of monday, tuesday, wednesday, thursday, friday, saturday, sunday. Possible values include: 'JobScheduleDayMonday', 'JobScheduleDayTuesday', 'JobScheduleDayWednesday', 'JobScheduleDayThursday', 'JobScheduleDayFriday', 'JobScheduleDaySaturday', 'JobScheduleDaySunday'
@@ -1384,14 +1285,12 @@ type JobRecurrenceScheduleMonthlyOccurrence struct {
Occurrence *int32 `json:"Occurrence,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobStateFilter ...
type JobStateFilter struct {
// State - Gets or sets the job state. Possible values include: 'JobStateEnabled', 'JobStateDisabled', 'JobStateFaulted', 'JobStateCompleted'
State JobState `json:"state,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// JobStatus ...
type JobStatus struct {
// ExecutionCount - READ-ONLY; Gets the number of times this job has executed.
@@ -1406,7 +1305,6 @@ type JobStatus struct {
NextExecutionTime *date.Time `json:"nextExecutionTime,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// OAuthAuthentication ...
type OAuthAuthentication struct {
// Secret - Gets or sets the secret, return value will always be empty.
@@ -1421,7 +1319,6 @@ type OAuthAuthentication struct {
Type Type `json:"type,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for OAuthAuthentication.
func (oaa OAuthAuthentication) MarshalJSON() ([]byte, error) {
oaa.Type = TypeActiveDirectoryOAuth
@@ -1444,37 +1341,31 @@ func (oaa OAuthAuthentication) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsClientCertAuthentication is the BasicHTTPAuthentication implementation for OAuthAuthentication.
func (oaa OAuthAuthentication) AsClientCertAuthentication() (*ClientCertAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicAuthentication is the BasicHTTPAuthentication implementation for OAuthAuthentication.
func (oaa OAuthAuthentication) AsBasicAuthentication() (*BasicAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsOAuthAuthentication is the BasicHTTPAuthentication implementation for OAuthAuthentication.
func (oaa OAuthAuthentication) AsOAuthAuthentication() (*OAuthAuthentication, bool) {
return &oaa, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsHTTPAuthentication is the BasicHTTPAuthentication implementation for OAuthAuthentication.
func (oaa OAuthAuthentication) AsHTTPAuthentication() (*HTTPAuthentication, bool) {
return nil, false
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// AsBasicHTTPAuthentication is the BasicHTTPAuthentication implementation for OAuthAuthentication.
func (oaa OAuthAuthentication) AsBasicHTTPAuthentication() (BasicHTTPAuthentication, bool) {
return &oaa, true
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// RetryPolicy ...
type RetryPolicy struct {
// RetryType - Gets or sets the retry strategy to be used. Possible values include: 'None', 'Fixed'
@@ -1485,7 +1376,6 @@ type RetryPolicy struct {
RetryCount *int32 `json:"retryCount,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusAuthentication ...
type ServiceBusAuthentication struct {
// SasKey - Gets or sets the SAS key.
@@ -1496,7 +1386,6 @@ type ServiceBusAuthentication struct {
Type ServiceBusAuthenticationType `json:"type,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusBrokeredMessageProperties ...
type ServiceBusBrokeredMessageProperties struct {
// ContentType - Gets or sets the content type.
@@ -1527,7 +1416,6 @@ type ServiceBusBrokeredMessageProperties struct {
ViaPartitionKey *string `json:"viaPartitionKey,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusMessage ...
type ServiceBusMessage struct {
// Authentication - Gets or sets the Service Bus authentication.
@@ -1544,7 +1432,6 @@ type ServiceBusMessage struct {
TransportType ServiceBusTransportType `json:"transportType,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for ServiceBusMessage.
func (sbm ServiceBusMessage) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
@@ -1569,7 +1456,6 @@ func (sbm ServiceBusMessage) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusQueueMessage ...
type ServiceBusQueueMessage struct {
// QueueName - Gets or sets the queue name.
@@ -1588,7 +1474,6 @@ type ServiceBusQueueMessage struct {
TransportType ServiceBusTransportType `json:"transportType,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for ServiceBusQueueMessage.
func (sbqm ServiceBusQueueMessage) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
@@ -1616,7 +1501,6 @@ func (sbqm ServiceBusQueueMessage) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// ServiceBusTopicMessage ...
type ServiceBusTopicMessage struct {
// TopicPath - Gets or sets the topic path.
@@ -1635,7 +1519,6 @@ type ServiceBusTopicMessage struct {
TransportType ServiceBusTransportType `json:"transportType,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// MarshalJSON is the custom marshaler for ServiceBusTopicMessage.
func (sbtm ServiceBusTopicMessage) MarshalJSON() ([]byte, error) {
objectMap := make(map[string]interface{})
@@ -1663,14 +1546,12 @@ func (sbtm ServiceBusTopicMessage) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Sku ...
type Sku struct {
// Name - Gets or set the SKU. Possible values include: 'Standard', 'Free', 'P10Premium', 'P20Premium'
Name SkuDefinition `json:"name,omitempty"`
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// StorageQueueMessage ...
type StorageQueueMessage struct {
// StorageAccount - Gets or sets the storage account name.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/version.go b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/version.go
index 4409ef618edd..6fcf2020c240 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler/version.go
@@ -18,13 +18,12 @@ import "github.com/Azure/azure-sdk-for-go/version"
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
+
// UserAgent returns the UserAgent string to use when sending http.Requests.
func UserAgent() string {
return "Azure-SDK-For-Go/" + version.Number + " scheduler/2016-03-01"
}
-// Deprecated: Please use github.com/Azure/azure-sdk-for-go/services/logic/mgmt/2016-06-01/logic instead.
// Version returns the semantic version (see http://semver.org) of the client.
func Version() string {
return version.Number
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/servicebus/mgmt/2017-04-01/servicebus/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/servicebus/mgmt/2017-04-01/servicebus/models.go
index d651f9ac1eb6..f737cf2ea88a 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/servicebus/mgmt/2017-04-01/servicebus/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/servicebus/mgmt/2017-04-01/servicebus/models.go
@@ -122,21 +122,6 @@ func PossibleFilterTypeValues() []FilterType {
return []FilterType{FilterTypeCorrelationFilter, FilterTypeSQLFilter}
}
-// IPAction enumerates the values for ip action.
-type IPAction string
-
-const (
- // Accept ...
- Accept IPAction = "Accept"
- // Reject ...
- Reject IPAction = "Reject"
-)
-
-// PossibleIPActionValues returns an array of possible values for the IPAction const type.
-func PossibleIPActionValues() []IPAction {
- return []IPAction{Accept, Reject}
-}
-
// KeyType enumerates the values for key type.
type KeyType string
@@ -948,200 +933,6 @@ type EventhubProperties struct {
CaptureDescription *CaptureDescription `json:"captureDescription,omitempty"`
}
-// IPFilterRule single item in a List or Get IpFilterRules operation
-type IPFilterRule struct {
- autorest.Response `json:"-"`
- // IPFilterRuleProperties - Properties supplied to create or update IpFilterRules
- *IPFilterRuleProperties `json:"properties,omitempty"`
- // ID - Resource Id
- ID *string `json:"id,omitempty"`
- // Name - Resource name
- Name *string `json:"name,omitempty"`
- // Type - Resource type
- Type *string `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for IPFilterRule.
-func (ifr IPFilterRule) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if ifr.IPFilterRuleProperties != nil {
- objectMap["properties"] = ifr.IPFilterRuleProperties
- }
- if ifr.ID != nil {
- objectMap["id"] = ifr.ID
- }
- if ifr.Name != nil {
- objectMap["name"] = ifr.Name
- }
- if ifr.Type != nil {
- objectMap["type"] = ifr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for IPFilterRule struct.
-func (ifr *IPFilterRule) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "properties":
- if v != nil {
- var IPFilterRuleProperties IPFilterRuleProperties
- err = json.Unmarshal(*v, &IPFilterRuleProperties)
- if err != nil {
- return err
- }
- ifr.IPFilterRuleProperties = &IPFilterRuleProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- ifr.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- ifr.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- ifr.Type = &typeVar
- }
- }
- }
-
- return nil
-}
-
-// IPFilterRuleListResult the response from the List namespace operation.
-type IPFilterRuleListResult struct {
- autorest.Response `json:"-"`
- // Value - Result of the List IpFilter Rules operation.
- Value *[]IPFilterRule `json:"value,omitempty"`
- // NextLink - Link to the next set of results. Not empty if Value contains an incomplete list of IpFilter Rules
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// IPFilterRuleListResultIterator provides access to a complete listing of IPFilterRule values.
-type IPFilterRuleListResultIterator struct {
- i int
- page IPFilterRuleListResultPage
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *IPFilterRuleListResultIterator) Next() error {
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err := iter.page.Next()
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter IPFilterRuleListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter IPFilterRuleListResultIterator) Response() IPFilterRuleListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter IPFilterRuleListResultIterator) Value() IPFilterRule {
- if !iter.page.NotDone() {
- return IPFilterRule{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (ifrlr IPFilterRuleListResult) IsEmpty() bool {
- return ifrlr.Value == nil || len(*ifrlr.Value) == 0
-}
-
-// iPFilterRuleListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (ifrlr IPFilterRuleListResult) iPFilterRuleListResultPreparer() (*http.Request, error) {
- if ifrlr.NextLink == nil || len(to.String(ifrlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare(&http.Request{},
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(ifrlr.NextLink)))
-}
-
-// IPFilterRuleListResultPage contains a page of IPFilterRule values.
-type IPFilterRuleListResultPage struct {
- fn func(IPFilterRuleListResult) (IPFilterRuleListResult, error)
- ifrlr IPFilterRuleListResult
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *IPFilterRuleListResultPage) Next() error {
- next, err := page.fn(page.ifrlr)
- if err != nil {
- return err
- }
- page.ifrlr = next
- return nil
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page IPFilterRuleListResultPage) NotDone() bool {
- return !page.ifrlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page IPFilterRuleListResultPage) Response() IPFilterRuleListResult {
- return page.ifrlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page IPFilterRuleListResultPage) Values() []IPFilterRule {
- if page.ifrlr.IsEmpty() {
- return nil
- }
- return *page.ifrlr.Value
-}
-
-// IPFilterRuleProperties properties supplied to create or update IpFilterRules
-type IPFilterRuleProperties struct {
- // IPMask - IP Mask
- IPMask *string `json:"ipMask,omitempty"`
- // Action - The IP Filter Action. Possible values include: 'Accept', 'Reject'
- Action IPAction `json:"action,omitempty"`
- // FilterName - IP Filter name
- FilterName *string `json:"filterName,omitempty"`
-}
-
// MessageCountDetails message Count Details.
type MessageCountDetails struct {
// ActiveMessageCount - READ-ONLY; Number of active messages in the queue, topic, or subscription.
@@ -3803,193 +3594,3 @@ func (tr TrackedResource) MarshalJSON() ([]byte, error) {
}
return json.Marshal(objectMap)
}
-
-// VirtualNetworkRule single item in a List or Get VirtualNetworkRules operation
-type VirtualNetworkRule struct {
- autorest.Response `json:"-"`
- // VirtualNetworkRuleProperties - Properties supplied to create or update VirtualNetworkRules
- *VirtualNetworkRuleProperties `json:"properties,omitempty"`
- // ID - Resource Id
- ID *string `json:"id,omitempty"`
- // Name - Resource name
- Name *string `json:"name,omitempty"`
- // Type - Resource type
- Type *string `json:"type,omitempty"`
-}
-
-// MarshalJSON is the custom marshaler for VirtualNetworkRule.
-func (vnr VirtualNetworkRule) MarshalJSON() ([]byte, error) {
- objectMap := make(map[string]interface{})
- if vnr.VirtualNetworkRuleProperties != nil {
- objectMap["properties"] = vnr.VirtualNetworkRuleProperties
- }
- if vnr.ID != nil {
- objectMap["id"] = vnr.ID
- }
- if vnr.Name != nil {
- objectMap["name"] = vnr.Name
- }
- if vnr.Type != nil {
- objectMap["type"] = vnr.Type
- }
- return json.Marshal(objectMap)
-}
-
-// UnmarshalJSON is the custom unmarshaler for VirtualNetworkRule struct.
-func (vnr *VirtualNetworkRule) UnmarshalJSON(body []byte) error {
- var m map[string]*json.RawMessage
- err := json.Unmarshal(body, &m)
- if err != nil {
- return err
- }
- for k, v := range m {
- switch k {
- case "properties":
- if v != nil {
- var virtualNetworkRuleProperties VirtualNetworkRuleProperties
- err = json.Unmarshal(*v, &virtualNetworkRuleProperties)
- if err != nil {
- return err
- }
- vnr.VirtualNetworkRuleProperties = &virtualNetworkRuleProperties
- }
- case "id":
- if v != nil {
- var ID string
- err = json.Unmarshal(*v, &ID)
- if err != nil {
- return err
- }
- vnr.ID = &ID
- }
- case "name":
- if v != nil {
- var name string
- err = json.Unmarshal(*v, &name)
- if err != nil {
- return err
- }
- vnr.Name = &name
- }
- case "type":
- if v != nil {
- var typeVar string
- err = json.Unmarshal(*v, &typeVar)
- if err != nil {
- return err
- }
- vnr.Type = &typeVar
- }
- }
- }
-
- return nil
-}
-
-// VirtualNetworkRuleListResult the response from the List namespace operation.
-type VirtualNetworkRuleListResult struct {
- autorest.Response `json:"-"`
- // Value - Result of the List VirtualNetwork Rules operation.
- Value *[]VirtualNetworkRule `json:"value,omitempty"`
- // NextLink - Link to the next set of results. Not empty if Value contains an incomplete list of VirtualNetwork Rules
- NextLink *string `json:"nextLink,omitempty"`
-}
-
-// VirtualNetworkRuleListResultIterator provides access to a complete listing of VirtualNetworkRule values.
-type VirtualNetworkRuleListResultIterator struct {
- i int
- page VirtualNetworkRuleListResultPage
-}
-
-// Next advances to the next value. If there was an error making
-// the request the iterator does not advance and the error is returned.
-func (iter *VirtualNetworkRuleListResultIterator) Next() error {
- iter.i++
- if iter.i < len(iter.page.Values()) {
- return nil
- }
- err := iter.page.Next()
- if err != nil {
- iter.i--
- return err
- }
- iter.i = 0
- return nil
-}
-
-// NotDone returns true if the enumeration should be started or is not yet complete.
-func (iter VirtualNetworkRuleListResultIterator) NotDone() bool {
- return iter.page.NotDone() && iter.i < len(iter.page.Values())
-}
-
-// Response returns the raw server response from the last page request.
-func (iter VirtualNetworkRuleListResultIterator) Response() VirtualNetworkRuleListResult {
- return iter.page.Response()
-}
-
-// Value returns the current value or a zero-initialized value if the
-// iterator has advanced beyond the end of the collection.
-func (iter VirtualNetworkRuleListResultIterator) Value() VirtualNetworkRule {
- if !iter.page.NotDone() {
- return VirtualNetworkRule{}
- }
- return iter.page.Values()[iter.i]
-}
-
-// IsEmpty returns true if the ListResult contains no values.
-func (vnrlr VirtualNetworkRuleListResult) IsEmpty() bool {
- return vnrlr.Value == nil || len(*vnrlr.Value) == 0
-}
-
-// virtualNetworkRuleListResultPreparer prepares a request to retrieve the next set of results.
-// It returns nil if no more results exist.
-func (vnrlr VirtualNetworkRuleListResult) virtualNetworkRuleListResultPreparer() (*http.Request, error) {
- if vnrlr.NextLink == nil || len(to.String(vnrlr.NextLink)) < 1 {
- return nil, nil
- }
- return autorest.Prepare(&http.Request{},
- autorest.AsJSON(),
- autorest.AsGet(),
- autorest.WithBaseURL(to.String(vnrlr.NextLink)))
-}
-
-// VirtualNetworkRuleListResultPage contains a page of VirtualNetworkRule values.
-type VirtualNetworkRuleListResultPage struct {
- fn func(VirtualNetworkRuleListResult) (VirtualNetworkRuleListResult, error)
- vnrlr VirtualNetworkRuleListResult
-}
-
-// Next advances to the next page of values. If there was an error making
-// the request the page does not advance and the error is returned.
-func (page *VirtualNetworkRuleListResultPage) Next() error {
- next, err := page.fn(page.vnrlr)
- if err != nil {
- return err
- }
- page.vnrlr = next
- return nil
-}
-
-// NotDone returns true if the page enumeration should be started or is not yet complete.
-func (page VirtualNetworkRuleListResultPage) NotDone() bool {
- return !page.vnrlr.IsEmpty()
-}
-
-// Response returns the raw server response from the last page request.
-func (page VirtualNetworkRuleListResultPage) Response() VirtualNetworkRuleListResult {
- return page.vnrlr
-}
-
-// Values returns the slice of values for the current page or nil if there are no values.
-func (page VirtualNetworkRuleListResultPage) Values() []VirtualNetworkRule {
- if page.vnrlr.IsEmpty() {
- return nil
- }
- return *page.vnrlr.Value
-}
-
-// VirtualNetworkRuleProperties properties supplied to create or update VirtualNetworkRules
-type VirtualNetworkRuleProperties struct {
- // VirtualNetworkSubnetID - Resource ID of Virtual Network Subnet
- VirtualNetworkSubnetID *string `json:"virtualNetworkSubnetId,omitempty"`
-}
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/accounts.go b/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/accounts.go
index 4ca8db150dec..9b5daba19e50 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/accounts.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/accounts.go
@@ -164,6 +164,16 @@ func (client AccountsClient) Create(ctx context.Context, resourceGroupName strin
{Target: "parameters.AccountPropertiesCreateParameters", Name: validation.Null, Rule: false,
Chain: []validation.Constraint{{Target: "parameters.AccountPropertiesCreateParameters.CustomDomain", Name: validation.Null, Rule: false,
Chain: []validation.Constraint{{Target: "parameters.AccountPropertiesCreateParameters.CustomDomain.Name", Name: validation.Null, Rule: true, Chain: nil}}},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.DomainName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.NetBiosDomainName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.ForestName", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.DomainGUID", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.DomainSid", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "parameters.AccountPropertiesCreateParameters.AzureFilesIdentityBasedAuthentication.ActiveDirectoryProperties.AzureStorageSid", Name: validation.Null, Rule: true, Chain: nil},
+ }},
+ }},
}}}},
{TargetValue: client.SubscriptionID,
Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
@@ -817,13 +827,14 @@ func (client AccountsClient) ListByResourceGroupResponder(resp *http.Response) (
return
}
-// ListKeys lists the access keys for the specified storage account.
+// ListKeys lists the access keys or Kerberos keys (if active directory enabled) for the specified storage account.
// Parameters:
// resourceGroupName - the name of the resource group within the user's subscription. The name is case
// insensitive.
// accountName - the name of the storage account within the specified resource group. Storage account names
// must be between 3 and 24 characters in length and use numbers and lower-case letters only.
-func (client AccountsClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string) (result AccountListKeysResult, err error) {
+// expand - specifies type of the key to be listed. Possible value is kerb.
+func (client AccountsClient) ListKeys(ctx context.Context, resourceGroupName string, accountName string, expand ListKeyExpand) (result AccountListKeysResult, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AccountsClient.ListKeys")
defer func() {
@@ -847,7 +858,7 @@ func (client AccountsClient) ListKeys(ctx context.Context, resourceGroupName str
return result, validation.NewError("storage.AccountsClient", "ListKeys", err.Error())
}
- req, err := client.ListKeysPreparer(ctx, resourceGroupName, accountName)
+ req, err := client.ListKeysPreparer(ctx, resourceGroupName, accountName, expand)
if err != nil {
err = autorest.NewErrorWithError(err, "storage.AccountsClient", "ListKeys", nil, "Failure preparing request")
return
@@ -869,7 +880,7 @@ func (client AccountsClient) ListKeys(ctx context.Context, resourceGroupName str
}
// ListKeysPreparer prepares the ListKeys request.
-func (client AccountsClient) ListKeysPreparer(ctx context.Context, resourceGroupName string, accountName string) (*http.Request, error) {
+func (client AccountsClient) ListKeysPreparer(ctx context.Context, resourceGroupName string, accountName string, expand ListKeyExpand) (*http.Request, error) {
pathParameters := map[string]interface{}{
"accountName": autorest.Encode("path", accountName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -880,6 +891,9 @@ func (client AccountsClient) ListKeysPreparer(ctx context.Context, resourceGroup
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if len(string(expand)) > 0 {
+ queryParameters["$expand"] = autorest.Encode("query", expand)
+ }
preparer := autorest.CreatePreparer(
autorest.AsPost(),
@@ -1008,13 +1022,13 @@ func (client AccountsClient) ListServiceSASResponder(resp *http.Response) (resul
return
}
-// RegenerateKey regenerates one of the access keys for the specified storage account.
+// RegenerateKey regenerates one of the access keys or Kerberos keys for the specified storage account.
// Parameters:
// resourceGroupName - the name of the resource group within the user's subscription. The name is case
// insensitive.
// accountName - the name of the storage account within the specified resource group. Storage account names
// must be between 3 and 24 characters in length and use numbers and lower-case letters only.
-// regenerateKey - specifies name of the key which should be regenerated -- key1 or key2.
+// regenerateKey - specifies name of the key which should be regenerated -- key1, key2, kerb1, kerb2.
func (client AccountsClient) RegenerateKey(ctx context.Context, resourceGroupName string, accountName string, regenerateKey AccountRegenerateKeyParameters) (result AccountListKeysResult, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AccountsClient.RegenerateKey")
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/models.go
index 8cba20da6e24..b6326d0faba7 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage/models.go
@@ -148,13 +148,15 @@ type DirectoryServiceOptions string
const (
// DirectoryServiceOptionsAADDS ...
DirectoryServiceOptionsAADDS DirectoryServiceOptions = "AADDS"
+ // DirectoryServiceOptionsAD ...
+ DirectoryServiceOptionsAD DirectoryServiceOptions = "AD"
// DirectoryServiceOptionsNone ...
DirectoryServiceOptionsNone DirectoryServiceOptions = "None"
)
// PossibleDirectoryServiceOptionsValues returns an array of possible values for the DirectoryServiceOptions const type.
func PossibleDirectoryServiceOptionsValues() []DirectoryServiceOptions {
- return []DirectoryServiceOptions{DirectoryServiceOptionsAADDS, DirectoryServiceOptionsNone}
+ return []DirectoryServiceOptions{DirectoryServiceOptionsAADDS, DirectoryServiceOptionsAD, DirectoryServiceOptionsNone}
}
// GeoReplicationStatus enumerates the values for geo replication status.
@@ -338,6 +340,19 @@ func PossibleLeaseStatusValues() []LeaseStatus {
return []LeaseStatus{LeaseStatusLocked, LeaseStatusUnlocked}
}
+// ListKeyExpand enumerates the values for list key expand.
+type ListKeyExpand string
+
+const (
+ // Kerb ...
+ Kerb ListKeyExpand = "kerb"
+)
+
+// PossibleListKeyExpandValues returns an array of possible values for the ListKeyExpand const type.
+func PossibleListKeyExpandValues() []ListKeyExpand {
+ return []ListKeyExpand{Kerb}
+}
+
// Permissions enumerates the values for permissions.
type Permissions string
@@ -1070,7 +1085,7 @@ type AccountPropertiesUpdateParameters struct {
// AccountRegenerateKeyParameters the parameters used to regenerate the storage account key.
type AccountRegenerateKeyParameters struct {
- // KeyName - The name of storage keys that want to be regenerated, possible values are key1, key2.
+ // KeyName - The name of storage keys that want to be regenerated, possible values are key1, key2, kerb1, kerb2.
KeyName *string `json:"keyName,omitempty"`
}
@@ -1242,6 +1257,22 @@ func (aup *AccountUpdateParameters) UnmarshalJSON(body []byte) error {
return nil
}
+// ActiveDirectoryProperties settings properties for Active Directory (AD).
+type ActiveDirectoryProperties struct {
+ // DomainName - Specifies the primary domain that the AD DNS server is authoritative for.
+ DomainName *string `json:"domainName,omitempty"`
+ // NetBiosDomainName - Specifies the NetBIOS domain name.
+ NetBiosDomainName *string `json:"netBiosDomainName,omitempty"`
+ // ForestName - Specifies the Active Directory forest to get.
+ ForestName *string `json:"forestName,omitempty"`
+ // DomainGUID - Specifies the domain GUID.
+ DomainGUID *string `json:"domainGuid,omitempty"`
+ // DomainSid - Specifies the security identifier (SID).
+ DomainSid *string `json:"domainSid,omitempty"`
+ // AzureStorageSid - Specifies the security identifier (SID) for Azure Storage.
+ AzureStorageSid *string `json:"azureStorageSid,omitempty"`
+}
+
// AzureEntityResource the resource model definition for a Azure Resource Manager resource with an etag.
type AzureEntityResource struct {
// Etag - READ-ONLY; Resource Etag.
@@ -1256,8 +1287,10 @@ type AzureEntityResource struct {
// AzureFilesIdentityBasedAuthentication settings for Azure Files identity based authentication.
type AzureFilesIdentityBasedAuthentication struct {
- // DirectoryServiceOptions - Indicates the directory service used. Possible values include: 'DirectoryServiceOptionsNone', 'DirectoryServiceOptionsAADDS'
+ // DirectoryServiceOptions - Indicates the directory service used. Possible values include: 'DirectoryServiceOptionsNone', 'DirectoryServiceOptionsAADDS', 'DirectoryServiceOptionsAD'
DirectoryServiceOptions DirectoryServiceOptions `json:"directoryServiceOptions,omitempty"`
+ // ActiveDirectoryProperties - Required if choose AD.
+ ActiveDirectoryProperties *ActiveDirectoryProperties `json:"activeDirectoryProperties,omitempty"`
}
// BlobContainer properties of the blob container, including Id, resource name, resource type, Etag.
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/apps.go b/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/apps.go
index 6a7668705ff9..8f6ca74fe918 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/apps.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/apps.go
@@ -1061,8 +1061,7 @@ func (client AppsClient) CreateFunctionResponder(resp *http.Response) (result Fu
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
// functionName - function name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
+// slot - name of the deployment slot.
// functionEnvelope - function details.
func (client AppsClient) CreateInstanceFunctionSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string, functionEnvelope FunctionEnvelope) (result AppsCreateInstanceFunctionSlotFuture, err error) {
if tracing.IsEnabled() {
@@ -1999,15 +1998,16 @@ func (client AppsClient) CreateOrUpdateDomainOwnershipIdentifierSlotResponder(re
return
}
-// CreateOrUpdateHostNameBinding creates a hostname binding for an app.
+// CreateOrUpdateFunctionSecret add or update a function secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// hostName - hostname in the hostname binding.
-// hostNameBinding - binding details. This is the JSON representation of a HostNameBinding object.
-func (client AppsClient) CreateOrUpdateHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding) (result HostNameBinding, err error) {
+// name - site name.
+// functionName - the name of the function.
+// keyName - the name of the key.
+// key - the key to create or update
+func (client AppsClient) CreateOrUpdateFunctionSecret(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, key KeyInfo) (result KeyInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostNameBinding")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateFunctionSecret")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2021,34 +2021,35 @@ func (client AppsClient) CreateOrUpdateHostNameBinding(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostNameBinding", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateFunctionSecret", err.Error())
}
- req, err := client.CreateOrUpdateHostNameBindingPreparer(ctx, resourceGroupName, name, hostName, hostNameBinding)
+ req, err := client.CreateOrUpdateFunctionSecretPreparer(ctx, resourceGroupName, name, functionName, keyName, key)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecret", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateHostNameBindingSender(req)
+ resp, err := client.CreateOrUpdateFunctionSecretSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecret", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateHostNameBindingResponder(resp)
+ result, err = client.CreateOrUpdateFunctionSecretResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecret", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateHostNameBindingPreparer prepares the CreateOrUpdateHostNameBinding request.
-func (client AppsClient) CreateOrUpdateHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding) (*http.Request, error) {
+// CreateOrUpdateFunctionSecretPreparer prepares the CreateOrUpdateFunctionSecret request.
+func (client AppsClient) CreateOrUpdateFunctionSecretPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, key KeyInfo) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
+ "functionName": autorest.Encode("path", functionName),
+ "keyName": autorest.Encode("path", keyName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -2063,43 +2064,43 @@ func (client AppsClient) CreateOrUpdateHostNameBindingPreparer(ctx context.Conte
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
- autorest.WithJSON(hostNameBinding),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}/keys/{keyName}", pathParameters),
+ autorest.WithJSON(key),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateHostNameBindingSender sends the CreateOrUpdateHostNameBinding request. The method will close the
+// CreateOrUpdateFunctionSecretSender sends the CreateOrUpdateFunctionSecret request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateHostNameBindingSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateFunctionSecretSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateHostNameBindingResponder handles the response to the CreateOrUpdateHostNameBinding request. The method always
+// CreateOrUpdateFunctionSecretResponder handles the response to the CreateOrUpdateFunctionSecret request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateHostNameBindingResponder(resp *http.Response) (result HostNameBinding, err error) {
+func (client AppsClient) CreateOrUpdateFunctionSecretResponder(resp *http.Response) (result KeyInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateHostNameBindingSlot creates a hostname binding for an app.
+// CreateOrUpdateFunctionSecretSlot add or update a function secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// hostName - hostname in the hostname binding.
-// hostNameBinding - binding details. This is the JSON representation of a HostNameBinding object.
-// slot - name of the deployment slot. If a slot is not specified, the API will create a binding for the
-// production slot.
-func (client AppsClient) CreateOrUpdateHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding, slot string) (result HostNameBinding, err error) {
+// name - site name.
+// functionName - the name of the function.
+// keyName - the name of the key.
+// slot - name of the deployment slot.
+// key - the key to create or update
+func (client AppsClient) CreateOrUpdateFunctionSecretSlot(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, slot string, key KeyInfo) (result KeyInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostNameBindingSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateFunctionSecretSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2113,34 +2114,35 @@ func (client AppsClient) CreateOrUpdateHostNameBindingSlot(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostNameBindingSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateFunctionSecretSlot", err.Error())
}
- req, err := client.CreateOrUpdateHostNameBindingSlotPreparer(ctx, resourceGroupName, name, hostName, hostNameBinding, slot)
+ req, err := client.CreateOrUpdateFunctionSecretSlotPreparer(ctx, resourceGroupName, name, functionName, keyName, slot, key)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecretSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateHostNameBindingSlotSender(req)
+ resp, err := client.CreateOrUpdateFunctionSecretSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecretSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateHostNameBindingSlotResponder(resp)
+ result, err = client.CreateOrUpdateFunctionSecretSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateFunctionSecretSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateHostNameBindingSlotPreparer prepares the CreateOrUpdateHostNameBindingSlot request.
-func (client AppsClient) CreateOrUpdateHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding, slot string) (*http.Request, error) {
+// CreateOrUpdateFunctionSecretSlotPreparer prepares the CreateOrUpdateFunctionSecretSlot request.
+func (client AppsClient) CreateOrUpdateFunctionSecretSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, slot string, key KeyInfo) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
+ "functionName": autorest.Encode("path", functionName),
+ "keyName": autorest.Encode("path", keyName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
@@ -2156,42 +2158,41 @@ func (client AppsClient) CreateOrUpdateHostNameBindingSlotPreparer(ctx context.C
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
- autorest.WithJSON(hostNameBinding),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}/keys/{keyName}", pathParameters),
+ autorest.WithJSON(key),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateHostNameBindingSlotSender sends the CreateOrUpdateHostNameBindingSlot request. The method will close the
+// CreateOrUpdateFunctionSecretSlotSender sends the CreateOrUpdateFunctionSecretSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateFunctionSecretSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateHostNameBindingSlotResponder handles the response to the CreateOrUpdateHostNameBindingSlot request. The method always
+// CreateOrUpdateFunctionSecretSlotResponder handles the response to the CreateOrUpdateFunctionSecretSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateHostNameBindingSlotResponder(resp *http.Response) (result HostNameBinding, err error) {
+func (client AppsClient) CreateOrUpdateFunctionSecretSlotResponder(resp *http.Response) (result KeyInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateHybridConnection creates a new Hybrid Connection using a Service Bus relay.
+// CreateOrUpdateHostNameBinding creates a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-// connectionEnvelope - the details of the hybrid connection.
-func (client AppsClient) CreateOrUpdateHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection) (result HybridConnection, err error) {
+// name - name of the app.
+// hostName - hostname in the hostname binding.
+// hostNameBinding - binding details. This is the JSON representation of a HostNameBinding object.
+func (client AppsClient) CreateOrUpdateHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding) (result HostNameBinding, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHybridConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostNameBinding")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2205,36 +2206,35 @@ func (client AppsClient) CreateOrUpdateHybridConnection(ctx context.Context, res
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateHybridConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostNameBinding", err.Error())
}
- req, err := client.CreateOrUpdateHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName, connectionEnvelope)
+ req, err := client.CreateOrUpdateHostNameBindingPreparer(ctx, resourceGroupName, name, hostName, hostNameBinding)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateHybridConnectionSender(req)
+ resp, err := client.CreateOrUpdateHostNameBindingSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateHybridConnectionResponder(resp)
+ result, err = client.CreateOrUpdateHostNameBindingResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBinding", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateHybridConnectionPreparer prepares the CreateOrUpdateHybridConnection request.
-func (client AppsClient) CreateOrUpdateHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection) (*http.Request, error) {
+// CreateOrUpdateHostNameBindingPreparer prepares the CreateOrUpdateHostNameBinding request.
+func (client AppsClient) CreateOrUpdateHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -2248,22 +2248,22 @@ func (client AppsClient) CreateOrUpdateHybridConnectionPreparer(ctx context.Cont
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
- autorest.WithJSON(connectionEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithJSON(hostNameBinding),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateHybridConnectionSender sends the CreateOrUpdateHybridConnection request. The method will close the
+// CreateOrUpdateHostNameBindingSender sends the CreateOrUpdateHostNameBinding request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateHybridConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHostNameBindingSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateHybridConnectionResponder handles the response to the CreateOrUpdateHybridConnection request. The method always
+// CreateOrUpdateHostNameBindingResponder handles the response to the CreateOrUpdateHostNameBinding request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateHybridConnectionResponder(resp *http.Response) (result HybridConnection, err error) {
+func (client AppsClient) CreateOrUpdateHostNameBindingResponder(resp *http.Response) (result HostNameBinding, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -2274,17 +2274,17 @@ func (client AppsClient) CreateOrUpdateHybridConnectionResponder(resp *http.Resp
return
}
-// CreateOrUpdateHybridConnectionSlot creates a new Hybrid Connection using a Service Bus relay.
+// CreateOrUpdateHostNameBindingSlot creates a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-// connectionEnvelope - the details of the hybrid connection.
-// slot - the name of the slot for the web app.
-func (client AppsClient) CreateOrUpdateHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection, slot string) (result HybridConnection, err error) {
+// name - name of the app.
+// hostName - hostname in the hostname binding.
+// hostNameBinding - binding details. This is the JSON representation of a HostNameBinding object.
+// slot - name of the deployment slot. If a slot is not specified, the API will create a binding for the
+// production slot.
+func (client AppsClient) CreateOrUpdateHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding, slot string) (result HostNameBinding, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHybridConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostNameBindingSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2298,36 +2298,35 @@ func (client AppsClient) CreateOrUpdateHybridConnectionSlot(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateHybridConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostNameBindingSlot", err.Error())
}
- req, err := client.CreateOrUpdateHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, connectionEnvelope, slot)
+ req, err := client.CreateOrUpdateHostNameBindingSlotPreparer(ctx, resourceGroupName, name, hostName, hostNameBinding, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateHybridConnectionSlotSender(req)
+ resp, err := client.CreateOrUpdateHostNameBindingSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateHybridConnectionSlotResponder(resp)
+ result, err = client.CreateOrUpdateHostNameBindingSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostNameBindingSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateHybridConnectionSlotPreparer prepares the CreateOrUpdateHybridConnectionSlot request.
-func (client AppsClient) CreateOrUpdateHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection, slot string) (*http.Request, error) {
+// CreateOrUpdateHostNameBindingSlotPreparer prepares the CreateOrUpdateHostNameBindingSlot request.
+func (client AppsClient) CreateOrUpdateHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, hostName string, hostNameBinding HostNameBinding, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -2342,22 +2341,22 @@ func (client AppsClient) CreateOrUpdateHybridConnectionSlotPreparer(ctx context.
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
- autorest.WithJSON(connectionEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithJSON(hostNameBinding),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateHybridConnectionSlotSender sends the CreateOrUpdateHybridConnectionSlot request. The method will close the
+// CreateOrUpdateHostNameBindingSlotSender sends the CreateOrUpdateHostNameBindingSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateHybridConnectionSlotResponder handles the response to the CreateOrUpdateHybridConnectionSlot request. The method always
+// CreateOrUpdateHostNameBindingSlotResponder handles the response to the CreateOrUpdateHostNameBindingSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateHybridConnectionSlotResponder(resp *http.Response) (result HybridConnection, err error) {
+func (client AppsClient) CreateOrUpdateHostNameBindingSlotResponder(resp *http.Response) (result HostNameBinding, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -2368,16 +2367,16 @@ func (client AppsClient) CreateOrUpdateHybridConnectionSlotResponder(resp *http.
return
}
-// CreateOrUpdatePublicCertificate creates a hostname binding for an app.
+// CreateOrUpdateHostSecret add or update a host level secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// publicCertificateName - public certificate name.
-// publicCertificate - public certificate details. This is the JSON representation of a PublicCertificate
-// object.
-func (client AppsClient) CreateOrUpdatePublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate) (result PublicCertificate, err error) {
+// name - site name.
+// keyType - the type of host key.
+// keyName - the name of the key.
+// key - the key to create or update
+func (client AppsClient) CreateOrUpdateHostSecret(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, key KeyInfo) (result KeyInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdatePublicCertificate")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostSecret")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2391,37 +2390,38 @@ func (client AppsClient) CreateOrUpdatePublicCertificate(ctx context.Context, re
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdatePublicCertificate", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostSecret", err.Error())
}
- req, err := client.CreateOrUpdatePublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName, publicCertificate)
+ req, err := client.CreateOrUpdateHostSecretPreparer(ctx, resourceGroupName, name, keyType, keyName, key)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecret", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdatePublicCertificateSender(req)
+ resp, err := client.CreateOrUpdateHostSecretSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecret", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdatePublicCertificateResponder(resp)
+ result, err = client.CreateOrUpdateHostSecretResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecret", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdatePublicCertificatePreparer prepares the CreateOrUpdatePublicCertificate request.
-func (client AppsClient) CreateOrUpdatePublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate) (*http.Request, error) {
+// CreateOrUpdateHostSecretPreparer prepares the CreateOrUpdateHostSecret request.
+func (client AppsClient) CreateOrUpdateHostSecretPreparer(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, key KeyInfo) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "keyName": autorest.Encode("path", keyName),
+ "keyType": autorest.Encode("path", keyType),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -2433,44 +2433,43 @@ func (client AppsClient) CreateOrUpdatePublicCertificatePreparer(ctx context.Con
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
- autorest.WithJSON(publicCertificate),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/host/default/{keyType}/{keyName}", pathParameters),
+ autorest.WithJSON(key),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdatePublicCertificateSender sends the CreateOrUpdatePublicCertificate request. The method will close the
+// CreateOrUpdateHostSecretSender sends the CreateOrUpdateHostSecret request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdatePublicCertificateSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHostSecretSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdatePublicCertificateResponder handles the response to the CreateOrUpdatePublicCertificate request. The method always
+// CreateOrUpdateHostSecretResponder handles the response to the CreateOrUpdateHostSecret request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdatePublicCertificateResponder(resp *http.Response) (result PublicCertificate, err error) {
+func (client AppsClient) CreateOrUpdateHostSecretResponder(resp *http.Response) (result KeyInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdatePublicCertificateSlot creates a hostname binding for an app.
+// CreateOrUpdateHostSecretSlot add or update a host level secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// publicCertificateName - public certificate name.
-// publicCertificate - public certificate details. This is the JSON representation of a PublicCertificate
-// object.
-// slot - name of the deployment slot. If a slot is not specified, the API will create a binding for the
-// production slot.
-func (client AppsClient) CreateOrUpdatePublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate, slot string) (result PublicCertificate, err error) {
+// name - site name.
+// keyType - the type of host key.
+// keyName - the name of the key.
+// slot - name of the deployment slot.
+// key - the key to create or update
+func (client AppsClient) CreateOrUpdateHostSecretSlot(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, slot string, key KeyInfo) (result KeyInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdatePublicCertificateSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHostSecretSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2484,38 +2483,39 @@ func (client AppsClient) CreateOrUpdatePublicCertificateSlot(ctx context.Context
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdatePublicCertificateSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHostSecretSlot", err.Error())
}
- req, err := client.CreateOrUpdatePublicCertificateSlotPreparer(ctx, resourceGroupName, name, publicCertificateName, publicCertificate, slot)
+ req, err := client.CreateOrUpdateHostSecretSlotPreparer(ctx, resourceGroupName, name, keyType, keyName, slot, key)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecretSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdatePublicCertificateSlotSender(req)
+ resp, err := client.CreateOrUpdateHostSecretSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecretSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdatePublicCertificateSlotResponder(resp)
+ result, err = client.CreateOrUpdateHostSecretSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHostSecretSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdatePublicCertificateSlotPreparer prepares the CreateOrUpdatePublicCertificateSlot request.
-func (client AppsClient) CreateOrUpdatePublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate, slot string) (*http.Request, error) {
+// CreateOrUpdateHostSecretSlotPreparer prepares the CreateOrUpdateHostSecretSlot request.
+func (client AppsClient) CreateOrUpdateHostSecretSlotPreparer(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, slot string, key KeyInfo) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "keyName": autorest.Encode("path", keyName),
+ "keyType": autorest.Encode("path", keyType),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -2527,42 +2527,42 @@ func (client AppsClient) CreateOrUpdatePublicCertificateSlotPreparer(ctx context
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
- autorest.WithJSON(publicCertificate),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/host/default/{keyType}/{keyName}", pathParameters),
+ autorest.WithJSON(key),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdatePublicCertificateSlotSender sends the CreateOrUpdatePublicCertificateSlot request. The method will close the
+// CreateOrUpdateHostSecretSlotSender sends the CreateOrUpdateHostSecretSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdatePublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHostSecretSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdatePublicCertificateSlotResponder handles the response to the CreateOrUpdatePublicCertificateSlot request. The method always
+// CreateOrUpdateHostSecretSlotResponder handles the response to the CreateOrUpdateHostSecretSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdatePublicCertificateSlotResponder(resp *http.Response) (result PublicCertificate, err error) {
+func (client AppsClient) CreateOrUpdateHostSecretSlotResponder(resp *http.Response) (result KeyInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateRelayServiceConnection creates a new hybrid connection configuration (PUT), or updates an existing one
-// (PATCH).
+// CreateOrUpdateHybridConnection creates a new Hybrid Connection using a Service Bus relay.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection configuration.
-// connectionEnvelope - details of the hybrid connection configuration.
-func (client AppsClient) CreateOrUpdateRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity) (result RelayServiceConnectionEntity, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+// connectionEnvelope - the details of the hybrid connection.
+func (client AppsClient) CreateOrUpdateHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection) (result HybridConnection, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateRelayServiceConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHybridConnection")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2576,36 +2576,37 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnection(ctx context.Contex
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateRelayServiceConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHybridConnection", err.Error())
}
- req, err := client.CreateOrUpdateRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName, connectionEnvelope)
+ req, err := client.CreateOrUpdateHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName, connectionEnvelope)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateRelayServiceConnectionSender(req)
+ resp, err := client.CreateOrUpdateHybridConnectionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateRelayServiceConnectionResponder(resp)
+ result, err = client.CreateOrUpdateHybridConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnection", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateRelayServiceConnectionPreparer prepares the CreateOrUpdateRelayServiceConnection request.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity) (*http.Request, error) {
+// CreateOrUpdateHybridConnectionPreparer prepares the CreateOrUpdateHybridConnection request.
+func (client AppsClient) CreateOrUpdateHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -2618,22 +2619,22 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnectionPreparer(ctx contex
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateRelayServiceConnectionSender sends the CreateOrUpdateRelayServiceConnection request. The method will close the
+// CreateOrUpdateHybridConnectionSender sends the CreateOrUpdateHybridConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHybridConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateRelayServiceConnectionResponder handles the response to the CreateOrUpdateRelayServiceConnection request. The method always
+// CreateOrUpdateHybridConnectionResponder handles the response to the CreateOrUpdateHybridConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
+func (client AppsClient) CreateOrUpdateHybridConnectionResponder(resp *http.Response) (result HybridConnection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -2644,18 +2645,17 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnectionResponder(resp *htt
return
}
-// CreateOrUpdateRelayServiceConnectionSlot creates a new hybrid connection configuration (PUT), or updates an existing
-// one (PATCH).
+// CreateOrUpdateHybridConnectionSlot creates a new Hybrid Connection using a Service Bus relay.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection configuration.
-// connectionEnvelope - details of the hybrid connection configuration.
-// slot - name of the deployment slot. If a slot is not specified, the API will create or update a hybrid
-// connection for the production slot.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity, slot string) (result RelayServiceConnectionEntity, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+// connectionEnvelope - the details of the hybrid connection.
+// slot - the name of the slot for the web app.
+func (client AppsClient) CreateOrUpdateHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection, slot string) (result HybridConnection, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateRelayServiceConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateHybridConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -2669,35 +2669,36 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlot(ctx context.Co
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateHybridConnectionSlot", err.Error())
}
- req, err := client.CreateOrUpdateRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, connectionEnvelope, slot)
+ req, err := client.CreateOrUpdateHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, connectionEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateRelayServiceConnectionSlotSender(req)
+ resp, err := client.CreateOrUpdateHybridConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateRelayServiceConnectionSlotResponder(resp)
+ result, err = client.CreateOrUpdateHybridConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateHybridConnectionSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateRelayServiceConnectionSlotPreparer prepares the CreateOrUpdateRelayServiceConnectionSlot request.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity, slot string) (*http.Request, error) {
+// CreateOrUpdateHybridConnectionSlotPreparer prepares the CreateOrUpdateHybridConnectionSlot request.
+func (client AppsClient) CreateOrUpdateHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, connectionEnvelope HybridConnection, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -2712,22 +2713,22 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotPreparer(ctx co
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateRelayServiceConnectionSlotSender sends the CreateOrUpdateRelayServiceConnectionSlot request. The method will close the
+// CreateOrUpdateHybridConnectionSlotSender sends the CreateOrUpdateHybridConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateRelayServiceConnectionSlotResponder handles the response to the CreateOrUpdateRelayServiceConnectionSlot request. The method always
+// CreateOrUpdateHybridConnectionSlotResponder handles the response to the CreateOrUpdateHybridConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
+func (client AppsClient) CreateOrUpdateHybridConnectionSlotResponder(resp *http.Response) (result HybridConnection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -2738,21 +2739,20 @@ func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotResponder(resp
return
}
-// CreateOrUpdateSlot creates a new web, mobile, or API app in an existing resource group, or updates an existing app.
+// CreateOrUpdatePublicCertificate creates a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - unique name of the app to create or update. To create or update a deployment slot, use the {slot}
-// parameter.
-// siteEnvelope - a JSON representation of the app properties. See example.
-// slot - name of the deployment slot to create or update. By default, this API attempts to create or modify
-// the production slot.
-func (client AppsClient) CreateOrUpdateSlot(ctx context.Context, resourceGroupName string, name string, siteEnvelope Site, slot string) (result AppsCreateOrUpdateSlotFuture, err error) {
+// name - name of the app.
+// publicCertificateName - public certificate name.
+// publicCertificate - public certificate details. This is the JSON representation of a PublicCertificate
+// object.
+func (client AppsClient) CreateOrUpdatePublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate) (result PublicCertificate, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdatePublicCertificate")
defer func() {
sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -2761,47 +2761,38 @@ func (client AppsClient) CreateOrUpdateSlot(ctx context.Context, resourceGroupNa
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: siteEnvelope,
- Constraints: []validation.Constraint{{Target: "siteEnvelope.SiteProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push.PushSettingsProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push.PushSettingsProperties.IsPushEnabled", Name: validation.Null, Rule: true, Chain: nil}}},
- }},
- {Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.InclusiveMaximum, Rule: int64(10), Chain: nil},
- {Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.InclusiveMinimum, Rule: 0, Chain: nil},
- }},
- }},
- {Target: "siteEnvelope.SiteProperties.CloningInfo", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.CloningInfo.SourceWebAppID", Name: validation.Null, Rule: true, Chain: nil}}},
- }}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateSlot", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdatePublicCertificate", err.Error())
}
- req, err := client.CreateOrUpdateSlotPreparer(ctx, resourceGroupName, name, siteEnvelope, slot)
+ req, err := client.CreateOrUpdatePublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName, publicCertificate)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", nil, "Failure preparing request")
return
}
- result, err = client.CreateOrUpdateSlotSender(req)
+ resp, err := client.CreateOrUpdatePublicCertificateSender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSlot", result.Response(), "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", resp, "Failure sending request")
return
}
+ result, err = client.CreateOrUpdatePublicCertificateResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificate", resp, "Failure responding to request")
+ }
+
return
}
-// CreateOrUpdateSlotPreparer prepares the CreateOrUpdateSlot request.
-func (client AppsClient) CreateOrUpdateSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteEnvelope Site, slot string) (*http.Request, error) {
+// CreateOrUpdatePublicCertificatePreparer prepares the CreateOrUpdatePublicCertificate request.
+func (client AppsClient) CreateOrUpdatePublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -2813,50 +2804,48 @@ func (client AppsClient) CreateOrUpdateSlotPreparer(ctx context.Context, resourc
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
- autorest.WithJSON(siteEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithJSON(publicCertificate),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSlotSender sends the CreateOrUpdateSlot request. The method will close the
+// CreateOrUpdatePublicCertificateSender sends the CreateOrUpdatePublicCertificate request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateSlotSender(req *http.Request) (future AppsCreateOrUpdateSlotFuture, err error) {
+func (client AppsClient) CreateOrUpdatePublicCertificateSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
+ return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateSlotResponder handles the response to the CreateOrUpdateSlot request. The method always
+// CreateOrUpdatePublicCertificateResponder handles the response to the CreateOrUpdatePublicCertificate request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateSlotResponder(resp *http.Response) (result Site, err error) {
+func (client AppsClient) CreateOrUpdatePublicCertificateResponder(resp *http.Response) (result PublicCertificate, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateSourceControl updates the source control configuration of an app.
+// CreateOrUpdatePublicCertificateSlot creates a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// siteSourceControl - JSON representation of a SiteSourceControl object. See example.
-func (client AppsClient) CreateOrUpdateSourceControl(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl) (result AppsCreateOrUpdateSourceControlFuture, err error) {
+// publicCertificateName - public certificate name.
+// publicCertificate - public certificate details. This is the JSON representation of a PublicCertificate
+// object.
+// slot - name of the deployment slot. If a slot is not specified, the API will create a binding for the
+// production slot.
+func (client AppsClient) CreateOrUpdatePublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate, slot string) (result PublicCertificate, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSourceControl")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdatePublicCertificateSlot")
defer func() {
sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -2866,30 +2855,38 @@ func (client AppsClient) CreateOrUpdateSourceControl(ctx context.Context, resour
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateSourceControl", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdatePublicCertificateSlot", err.Error())
}
- req, err := client.CreateOrUpdateSourceControlPreparer(ctx, resourceGroupName, name, siteSourceControl)
+ req, err := client.CreateOrUpdatePublicCertificateSlotPreparer(ctx, resourceGroupName, name, publicCertificateName, publicCertificate, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControl", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", nil, "Failure preparing request")
return
}
- result, err = client.CreateOrUpdateSourceControlSender(req)
+ resp, err := client.CreateOrUpdatePublicCertificateSlotSender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControl", result.Response(), "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", resp, "Failure sending request")
return
}
+ result, err = client.CreateOrUpdatePublicCertificateSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdatePublicCertificateSlot", resp, "Failure responding to request")
+ }
+
return
}
-// CreateOrUpdateSourceControlPreparer prepares the CreateOrUpdateSourceControl request.
-func (client AppsClient) CreateOrUpdateSourceControlPreparer(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl) (*http.Request, error) {
+// CreateOrUpdatePublicCertificateSlotPreparer prepares the CreateOrUpdatePublicCertificateSlot request.
+func (client AppsClient) CreateOrUpdatePublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string, publicCertificate PublicCertificate, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -2901,52 +2898,46 @@ func (client AppsClient) CreateOrUpdateSourceControlPreparer(ctx context.Context
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
- autorest.WithJSON(siteSourceControl),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithJSON(publicCertificate),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSourceControlSender sends the CreateOrUpdateSourceControl request. The method will close the
+// CreateOrUpdatePublicCertificateSlotSender sends the CreateOrUpdatePublicCertificateSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateSourceControlSender(req *http.Request) (future AppsCreateOrUpdateSourceControlFuture, err error) {
+func (client AppsClient) CreateOrUpdatePublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
+ return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateSourceControlResponder handles the response to the CreateOrUpdateSourceControl request. The method always
+// CreateOrUpdatePublicCertificateSlotResponder handles the response to the CreateOrUpdatePublicCertificateSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateSourceControlResponder(resp *http.Response) (result SiteSourceControl, err error) {
+func (client AppsClient) CreateOrUpdatePublicCertificateSlotResponder(resp *http.Response) (result PublicCertificate, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateSourceControlSlot updates the source control configuration of an app.
+// CreateOrUpdateRelayServiceConnection creates a new hybrid connection configuration (PUT), or updates an existing one
+// (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// siteSourceControl - JSON representation of a SiteSourceControl object. See example.
-// slot - name of the deployment slot. If a slot is not specified, the API will update the source control
-// configuration for the production slot.
-func (client AppsClient) CreateOrUpdateSourceControlSlot(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl, slot string) (result AppsCreateOrUpdateSourceControlSlotFuture, err error) {
+// entityName - name of the hybrid connection configuration.
+// connectionEnvelope - details of the hybrid connection configuration.
+func (client AppsClient) CreateOrUpdateRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity) (result RelayServiceConnectionEntity, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSourceControlSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateRelayServiceConnection")
defer func() {
sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -2956,30 +2947,36 @@ func (client AppsClient) CreateOrUpdateSourceControlSlot(ctx context.Context, re
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateSourceControlSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateRelayServiceConnection", err.Error())
}
- req, err := client.CreateOrUpdateSourceControlSlotPreparer(ctx, resourceGroupName, name, siteSourceControl, slot)
+ req, err := client.CreateOrUpdateRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName, connectionEnvelope)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControlSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", nil, "Failure preparing request")
return
}
- result, err = client.CreateOrUpdateSourceControlSlotSender(req)
+ resp, err := client.CreateOrUpdateRelayServiceConnectionSender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControlSlot", result.Response(), "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", resp, "Failure sending request")
return
}
+ result, err = client.CreateOrUpdateRelayServiceConnectionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnection", resp, "Failure responding to request")
+ }
+
return
}
-// CreateOrUpdateSourceControlSlotPreparer prepares the CreateOrUpdateSourceControlSlot request.
-func (client AppsClient) CreateOrUpdateSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl, slot string) (*http.Request, error) {
+// CreateOrUpdateRelayServiceConnectionPreparer prepares the CreateOrUpdateRelayServiceConnection request.
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -2992,49 +2989,44 @@ func (client AppsClient) CreateOrUpdateSourceControlSlotPreparer(ctx context.Con
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
- autorest.WithJSON(siteSourceControl),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSourceControlSlotSender sends the CreateOrUpdateSourceControlSlot request. The method will close the
+// CreateOrUpdateRelayServiceConnectionSender sends the CreateOrUpdateRelayServiceConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateSourceControlSlotSender(req *http.Request) (future AppsCreateOrUpdateSourceControlSlotFuture, err error) {
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
+ return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateSourceControlSlotResponder handles the response to the CreateOrUpdateSourceControlSlot request. The method always
+// CreateOrUpdateRelayServiceConnectionResponder handles the response to the CreateOrUpdateRelayServiceConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateSourceControlSlotResponder(resp *http.Response) (result SiteSourceControl, err error) {
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateSwiftVirtualNetworkConnection integrates this Web App with a Virtual Network. This requires that 1)
-// "swiftSupported" is true when doing a GET against this resource, and 2) that the target Subnet has already been
-// delegated, and is not
-// in use by another App Service Plan other than the one this App is in.
+// CreateOrUpdateRelayServiceConnectionSlot creates a new hybrid connection configuration (PUT), or updates an existing
+// one (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// connectionEnvelope - properties of the Virtual Network connection. See example.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnection(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork) (result SwiftVirtualNetwork, err error) {
+// entityName - name of the hybrid connection configuration.
+// connectionEnvelope - details of the hybrid connection configuration.
+// slot - name of the deployment slot. If a slot is not specified, the API will create or update a hybrid
+// connection for the production slot.
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity, slot string) (result RelayServiceConnectionEntity, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSwiftVirtualNetworkConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateRelayServiceConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -3048,35 +3040,37 @@ func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnection(ctx context
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", err.Error())
}
- req, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionPreparer(ctx, resourceGroupName, name, connectionEnvelope)
+ req, err := client.CreateOrUpdateRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, connectionEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSender(req)
+ resp, err := client.CreateOrUpdateRelayServiceConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateSwiftVirtualNetworkConnectionResponder(resp)
+ result, err = client.CreateOrUpdateRelayServiceConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateRelayServiceConnectionSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionPreparer prepares the CreateOrUpdateSwiftVirtualNetworkConnection request.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionPreparer(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork) (*http.Request, error) {
+// CreateOrUpdateRelayServiceConnectionSlotPreparer prepares the CreateOrUpdateRelayServiceConnectionSlot request.
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, connectionEnvelope RelayServiceConnectionEntity, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -3089,22 +3083,22 @@ func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionPreparer(ctx
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionSender sends the CreateOrUpdateSwiftVirtualNetworkConnection request. The method will close the
+// CreateOrUpdateRelayServiceConnectionSlotSender sends the CreateOrUpdateRelayServiceConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionResponder handles the response to the CreateOrUpdateSwiftVirtualNetworkConnection request. The method always
+// CreateOrUpdateRelayServiceConnectionSlotResponder handles the response to the CreateOrUpdateRelayServiceConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
+func (client AppsClient) CreateOrUpdateRelayServiceConnectionSlotResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -3115,23 +3109,21 @@ func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionResponder(re
return
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionSlot integrates this Web App with a Virtual Network. This requires that
-// 1) "swiftSupported" is true when doing a GET against this resource, and 2) that the target Subnet has already been
-// delegated, and is not
-// in use by another App Service Plan other than the one this App is in.
+// CreateOrUpdateSlot creates a new web, mobile, or API app in an existing resource group, or updates an existing app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// connectionEnvelope - properties of the Virtual Network connection. See example.
-// slot - name of the deployment slot. If a slot is not specified, the API will add or update connections for
+// name - unique name of the app to create or update. To create or update a deployment slot, use the {slot}
+// parameter.
+// siteEnvelope - a JSON representation of the app properties. See example.
+// slot - name of the deployment slot to create or update. By default, this API attempts to create or modify
// the production slot.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlot(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork, slot string) (result SwiftVirtualNetwork, err error) {
+func (client AppsClient) CreateOrUpdateSlot(ctx context.Context, resourceGroupName string, name string, siteEnvelope Site, slot string) (result AppsCreateOrUpdateSlotFuture, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSwiftVirtualNetworkConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3140,33 +3132,42 @@ func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlot(ctx con
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: siteEnvelope,
+ Constraints: []validation.Constraint{{Target: "siteEnvelope.SiteProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push.PushSettingsProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.Push.PushSettingsProperties.IsPushEnabled", Name: validation.Null, Rule: true, Chain: nil}}},
+ }},
+ {Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.InclusiveMaximum, Rule: int64(10), Chain: nil},
+ {Target: "siteEnvelope.SiteProperties.SiteConfig.ReservedInstanceCount", Name: validation.InclusiveMinimum, Rule: 0, Chain: nil},
+ }},
+ }},
+ {Target: "siteEnvelope.SiteProperties.CloningInfo", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "siteEnvelope.SiteProperties.CloningInfo.SourceWebAppID", Name: validation.Null, Rule: true, Chain: nil}}},
+ }}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateSlot", err.Error())
}
- req, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer(ctx, resourceGroupName, name, connectionEnvelope, slot)
+ req, err := client.CreateOrUpdateSlotPreparer(ctx, resourceGroupName, name, siteEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender(req)
+ result, err = client.CreateOrUpdateSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSlot", result.Response(), "Failure sending request")
return
}
- result, err = client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", resp, "Failure responding to request")
- }
-
return
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer prepares the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork, slot string) (*http.Request, error) {
+// CreateOrUpdateSlotPreparer prepares the CreateOrUpdateSlot request.
+func (client AppsClient) CreateOrUpdateSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteEnvelope Site, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -3183,46 +3184,50 @@ func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
- autorest.WithJSON(connectionEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
+ autorest.WithJSON(siteEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender sends the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request. The method will close the
+// CreateOrUpdateSlotSender sends the CreateOrUpdateSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateSlotSender(req *http.Request) (future AppsCreateOrUpdateSlotFuture, err error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
}
-// CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder handles the response to the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request. The method always
+// CreateOrUpdateSlotResponder handles the response to the CreateOrUpdateSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
+func (client AppsClient) CreateOrUpdateSlotResponder(resp *http.Response) (result Site, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateVnetConnection adds a Virtual Network connection to an app or slot (PUT) or updates the connection
-// properties (PATCH).
+// CreateOrUpdateSourceControl updates the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of an existing Virtual Network.
-// connectionEnvelope - properties of the Virtual Network connection. See example.
-func (client AppsClient) CreateOrUpdateVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo) (result VnetInfo, err error) {
+// siteSourceControl - JSON representation of a SiteSourceControl object. See example.
+func (client AppsClient) CreateOrUpdateSourceControl(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl) (result AppsCreateOrUpdateSourceControlFuture, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSourceControl")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3232,37 +3237,30 @@ func (client AppsClient) CreateOrUpdateVnetConnection(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateSourceControl", err.Error())
}
- req, err := client.CreateOrUpdateVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName, connectionEnvelope)
+ req, err := client.CreateOrUpdateSourceControlPreparer(ctx, resourceGroupName, name, siteSourceControl)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControl", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateVnetConnectionSender(req)
+ result, err = client.CreateOrUpdateSourceControlSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControl", result.Response(), "Failure sending request")
return
}
- result, err = client.CreateOrUpdateVnetConnectionResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", resp, "Failure responding to request")
- }
-
return
}
-// CreateOrUpdateVnetConnectionPreparer prepares the CreateOrUpdateVnetConnection request.
-func (client AppsClient) CreateOrUpdateVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo) (*http.Request, error) {
+// CreateOrUpdateSourceControlPreparer prepares the CreateOrUpdateSourceControl request.
+func (client AppsClient) CreateOrUpdateSourceControlPreparer(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3274,46 +3272,52 @@ func (client AppsClient) CreateOrUpdateVnetConnectionPreparer(ctx context.Contex
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
- autorest.WithJSON(connectionEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
+ autorest.WithJSON(siteSourceControl),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateVnetConnectionSender sends the CreateOrUpdateVnetConnection request. The method will close the
+// CreateOrUpdateSourceControlSender sends the CreateOrUpdateSourceControl request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateVnetConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateSourceControlSender(req *http.Request) (future AppsCreateOrUpdateSourceControlFuture, err error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
}
-// CreateOrUpdateVnetConnectionResponder handles the response to the CreateOrUpdateVnetConnection request. The method always
+// CreateOrUpdateSourceControlResponder handles the response to the CreateOrUpdateSourceControl request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateVnetConnectionResponder(resp *http.Response) (result VnetInfo, err error) {
+func (client AppsClient) CreateOrUpdateSourceControlResponder(resp *http.Response) (result SiteSourceControl, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateVnetConnectionGateway adds a gateway to a connected Virtual Network (PUT) or updates it (PATCH).
+// CreateOrUpdateSourceControlSlot updates the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the Virtual Network.
-// gatewayName - name of the gateway. Currently, the only supported string is "primary".
-// connectionEnvelope - the properties to update this gateway with.
-func (client AppsClient) CreateOrUpdateVnetConnectionGateway(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway) (result VnetGateway, err error) {
+// siteSourceControl - JSON representation of a SiteSourceControl object. See example.
+// slot - name of the deployment slot. If a slot is not specified, the API will update the source control
+// configuration for the production slot.
+func (client AppsClient) CreateOrUpdateSourceControlSlot(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl, slot string) (result AppsCreateOrUpdateSourceControlSlotFuture, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionGateway")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSourceControlSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3322,42 +3326,32 @@ func (client AppsClient) CreateOrUpdateVnetConnectionGateway(ctx context.Context
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: connectionEnvelope,
- Constraints: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties.VpnPackageURI", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionGateway", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateSourceControlSlot", err.Error())
}
- req, err := client.CreateOrUpdateVnetConnectionGatewayPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, connectionEnvelope)
+ req, err := client.CreateOrUpdateSourceControlSlotPreparer(ctx, resourceGroupName, name, siteSourceControl, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControlSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateVnetConnectionGatewaySender(req)
+ result, err = client.CreateOrUpdateSourceControlSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSourceControlSlot", result.Response(), "Failure sending request")
return
}
- result, err = client.CreateOrUpdateVnetConnectionGatewayResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", resp, "Failure responding to request")
- }
-
return
}
-// CreateOrUpdateVnetConnectionGatewayPreparer prepares the CreateOrUpdateVnetConnectionGateway request.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewayPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway) (*http.Request, error) {
+// CreateOrUpdateSourceControlSlotPreparer prepares the CreateOrUpdateSourceControlSlot request.
+func (client AppsClient) CreateOrUpdateSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteSourceControl SiteSourceControl, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3369,44 +3363,49 @@ func (client AppsClient) CreateOrUpdateVnetConnectionGatewayPreparer(ctx context
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
- autorest.WithJSON(connectionEnvelope),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
+ autorest.WithJSON(siteSourceControl),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateVnetConnectionGatewaySender sends the CreateOrUpdateVnetConnectionGateway request. The method will close the
+// CreateOrUpdateSourceControlSlotSender sends the CreateOrUpdateSourceControlSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateSourceControlSlotSender(req *http.Request) (future AppsCreateOrUpdateSourceControlSlotFuture, err error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// CreateOrUpdateVnetConnectionGatewayResponder handles the response to the CreateOrUpdateVnetConnectionGateway request. The method always
-// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewayResponder(resp *http.Response) (result VnetGateway, err error) {
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// CreateOrUpdateSourceControlSlotResponder handles the response to the CreateOrUpdateSourceControlSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) CreateOrUpdateSourceControlSlotResponder(resp *http.Response) (result SiteSourceControl, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// CreateOrUpdateVnetConnectionGatewaySlot adds a gateway to a connected Virtual Network (PUT) or updates it (PATCH).
+// CreateOrUpdateSwiftVirtualNetworkConnection integrates this Web App with a Virtual Network. This requires that 1)
+// "swiftSupported" is true when doing a GET against this resource, and 2) that the target Subnet has already been
+// delegated, and is not
+// in use by another App Service Plan other than the one this App is in.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the Virtual Network.
-// gatewayName - name of the gateway. Currently, the only supported string is "primary".
-// connectionEnvelope - the properties to update this gateway with.
-// slot - name of the deployment slot. If a slot is not specified, the API will add or update a gateway for the
-// production slot's Virtual Network.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlot(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway, slot string) (result VnetGateway, err error) {
+// connectionEnvelope - properties of the Virtual Network connection. See example.
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnection(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork) (result SwiftVirtualNetwork, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionGatewaySlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSwiftVirtualNetworkConnection")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -3419,43 +3418,37 @@ func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlot(ctx context.Con
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: connectionEnvelope,
- Constraints: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties.VpnPackageURI", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", err.Error())
}
- req, err := client.CreateOrUpdateVnetConnectionGatewaySlotPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, connectionEnvelope, slot)
+ req, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionPreparer(ctx, resourceGroupName, name, connectionEnvelope)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateVnetConnectionGatewaySlotSender(req)
+ resp, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateVnetConnectionGatewaySlotResponder(resp)
+ result, err = client.CreateOrUpdateSwiftVirtualNetworkConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnection", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateVnetConnectionGatewaySlotPreparer prepares the CreateOrUpdateVnetConnectionGatewaySlot request.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway, slot string) (*http.Request, error) {
+// CreateOrUpdateSwiftVirtualNetworkConnectionPreparer prepares the CreateOrUpdateSwiftVirtualNetworkConnection request.
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionPreparer(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3467,22 +3460,22 @@ func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotPreparer(ctx con
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateVnetConnectionGatewaySlotSender sends the CreateOrUpdateVnetConnectionGatewaySlot request. The method will close the
+// CreateOrUpdateSwiftVirtualNetworkConnectionSender sends the CreateOrUpdateSwiftVirtualNetworkConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateVnetConnectionGatewaySlotResponder handles the response to the CreateOrUpdateVnetConnectionGatewaySlot request. The method always
+// CreateOrUpdateSwiftVirtualNetworkConnectionResponder handles the response to the CreateOrUpdateSwiftVirtualNetworkConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotResponder(resp *http.Response) (result VnetGateway, err error) {
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -3493,18 +3486,19 @@ func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotResponder(resp *
return
}
-// CreateOrUpdateVnetConnectionSlot adds a Virtual Network connection to an app or slot (PUT) or updates the connection
-// properties (PATCH).
+// CreateOrUpdateSwiftVirtualNetworkConnectionSlot integrates this Web App with a Virtual Network. This requires that
+// 1) "swiftSupported" is true when doing a GET against this resource, and 2) that the target Subnet has already been
+// delegated, and is not
+// in use by another App Service Plan other than the one this App is in.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of an existing Virtual Network.
// connectionEnvelope - properties of the Virtual Network connection. See example.
// slot - name of the deployment slot. If a slot is not specified, the API will add or update connections for
// the production slot.
-func (client AppsClient) CreateOrUpdateVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo, slot string) (result VnetInfo, err error) {
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlot(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork, slot string) (result SwiftVirtualNetwork, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateSwiftVirtualNetworkConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -3518,38 +3512,37 @@ func (client AppsClient) CreateOrUpdateVnetConnectionSlot(ctx context.Context, r
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", err.Error())
}
- req, err := client.CreateOrUpdateVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, connectionEnvelope, slot)
+ req, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer(ctx, resourceGroupName, name, connectionEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.CreateOrUpdateVnetConnectionSlotSender(req)
+ resp, err := client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.CreateOrUpdateVnetConnectionSlotResponder(resp)
+ result, err = client.CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateSwiftVirtualNetworkConnectionSlot", resp, "Failure responding to request")
}
return
}
-// CreateOrUpdateVnetConnectionSlotPreparer prepares the CreateOrUpdateVnetConnectionSlot request.
-func (client AppsClient) CreateOrUpdateVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo, slot string) (*http.Request, error) {
+// CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer prepares the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request.
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, connectionEnvelope SwiftVirtualNetwork, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3561,22 +3554,22 @@ func (client AppsClient) CreateOrUpdateVnetConnectionSlotPreparer(ctx context.Co
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// CreateOrUpdateVnetConnectionSlotSender sends the CreateOrUpdateVnetConnectionSlot request. The method will close the
+// CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender sends the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) CreateOrUpdateVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// CreateOrUpdateVnetConnectionSlotResponder handles the response to the CreateOrUpdateVnetConnectionSlot request. The method always
+// CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder handles the response to the CreateOrUpdateSwiftVirtualNetworkConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) CreateOrUpdateVnetConnectionSlotResponder(resp *http.Response) (result VnetInfo, err error) {
+func (client AppsClient) CreateOrUpdateSwiftVirtualNetworkConnectionSlotResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -3587,20 +3580,20 @@ func (client AppsClient) CreateOrUpdateVnetConnectionSlotResponder(resp *http.Re
return
}
-// Delete deletes a web, mobile, or API app, or one of the deployment slots.
+// CreateOrUpdateVnetConnection adds a Virtual Network connection to an app or slot (PUT) or updates the connection
+// properties (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app to delete.
-// deleteMetrics - if true, web app metrics are also deleted.
-// deleteEmptyServerFarm - specify true if the App Service plan will be empty after app deletion and you want
-// to delete the empty App Service plan. By default, the empty App Service plan is not deleted.
-func (client AppsClient) Delete(ctx context.Context, resourceGroupName string, name string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (result autorest.Response, err error) {
+// name - name of the app.
+// vnetName - name of an existing Virtual Network.
+// connectionEnvelope - properties of the Virtual Network connection. See example.
+func (client AppsClient) CreateOrUpdateVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo) (result VnetInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.Delete")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnection")
defer func() {
sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3610,88 +3603,88 @@ func (client AppsClient) Delete(ctx context.Context, resourceGroupName string, n
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "Delete", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnection", err.Error())
}
- req, err := client.DeletePreparer(ctx, resourceGroupName, name, deleteMetrics, deleteEmptyServerFarm)
+ req, err := client.CreateOrUpdateVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName, connectionEnvelope)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSender(req)
+ resp, err := client.CreateOrUpdateVnetConnectionSender(req)
if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", resp, "Failure sending request")
return
}
- result, err = client.DeleteResponder(resp)
+ result, err = client.CreateOrUpdateVnetConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnection", resp, "Failure responding to request")
}
return
}
-// DeletePreparer prepares the Delete request.
-func (client AppsClient) DeletePreparer(ctx context.Context, resourceGroupName string, name string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (*http.Request, error) {
+// CreateOrUpdateVnetConnectionPreparer prepares the CreateOrUpdateVnetConnection request.
+func (client AppsClient) CreateOrUpdateVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
- if deleteMetrics != nil {
- queryParameters["deleteMetrics"] = autorest.Encode("query", *deleteMetrics)
- }
- if deleteEmptyServerFarm != nil {
- queryParameters["deleteEmptyServerFarm"] = autorest.Encode("query", *deleteEmptyServerFarm)
- }
preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSender sends the Delete request. The method will close the
+// CreateOrUpdateVnetConnectionSender sends the CreateOrUpdateVnetConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteResponder handles the response to the Delete request. The method always
+// CreateOrUpdateVnetConnectionResponder handles the response to the CreateOrUpdateVnetConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionResponder(resp *http.Response) (result VnetInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
- result.Response = resp
+ result.Response = autorest.Response{Response: resp}
return
}
-// DeleteBackup deletes a backup of an app by its ID.
+// CreateOrUpdateVnetConnectionGateway adds a gateway to a connected Virtual Network (PUT) or updates it (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// backupID - ID of the backup.
-func (client AppsClient) DeleteBackup(ctx context.Context, resourceGroupName string, name string, backupID string) (result autorest.Response, err error) {
+// vnetName - name of the Virtual Network.
+// gatewayName - name of the gateway. Currently, the only supported string is "primary".
+// connectionEnvelope - the properties to update this gateway with.
+func (client AppsClient) CreateOrUpdateVnetConnectionGateway(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway) (result VnetGateway, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackup")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionGateway")
defer func() {
sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3700,38 +3693,42 @@ func (client AppsClient) DeleteBackup(ctx context.Context, resourceGroupName str
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteBackup", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: connectionEnvelope,
+ Constraints: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties.VpnPackageURI", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionGateway", err.Error())
}
- req, err := client.DeleteBackupPreparer(ctx, resourceGroupName, name, backupID)
+ req, err := client.CreateOrUpdateVnetConnectionGatewayPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, connectionEnvelope)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteBackupSender(req)
+ resp, err := client.CreateOrUpdateVnetConnectionGatewaySender(req)
if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", resp, "Failure sending request")
return
}
- result, err = client.DeleteBackupResponder(resp)
+ result, err = client.CreateOrUpdateVnetConnectionGatewayResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGateway", resp, "Failure responding to request")
}
return
}
-// DeleteBackupPreparer prepares the DeleteBackup request.
-func (client AppsClient) DeleteBackupPreparer(ctx context.Context, resourceGroupName string, name string, backupID string) (*http.Request, error) {
+// CreateOrUpdateVnetConnectionGatewayPreparer prepares the CreateOrUpdateVnetConnectionGateway request.
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewayPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
+ "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3740,43 +3737,51 @@ func (client AppsClient) DeleteBackupPreparer(ctx context.Context, resourceGroup
}
preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
+ autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteBackupSender sends the DeleteBackup request. The method will close the
+// CreateOrUpdateVnetConnectionGatewaySender sends the CreateOrUpdateVnetConnectionGateway request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteBackupSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteBackupResponder handles the response to the DeleteBackup request. The method always
+// CreateOrUpdateVnetConnectionGatewayResponder handles the response to the CreateOrUpdateVnetConnectionGateway request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteBackupResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewayResponder(resp *http.Response) (result VnetGateway, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
- result.Response = resp
+ result.Response = autorest.Response{Response: resp}
return
}
-// DeleteBackupConfiguration deletes the backup configuration of an app.
+// CreateOrUpdateVnetConnectionGatewaySlot adds a gateway to a connected Virtual Network (PUT) or updates it (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) DeleteBackupConfiguration(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
+// vnetName - name of the Virtual Network.
+// gatewayName - name of the gateway. Currently, the only supported string is "primary".
+// connectionEnvelope - the properties to update this gateway with.
+// slot - name of the deployment slot. If a slot is not specified, the API will add or update a gateway for the
+// production slot's Virtual Network.
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlot(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway, slot string) (result VnetGateway, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupConfiguration")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionGatewaySlot")
defer func() {
sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3785,37 +3790,43 @@ func (client AppsClient) DeleteBackupConfiguration(ctx context.Context, resource
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteBackupConfiguration", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: connectionEnvelope,
+ Constraints: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "connectionEnvelope.VnetGatewayProperties.VpnPackageURI", Name: validation.Null, Rule: true, Chain: nil}}}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", err.Error())
}
- req, err := client.DeleteBackupConfigurationPreparer(ctx, resourceGroupName, name)
+ req, err := client.CreateOrUpdateVnetConnectionGatewaySlotPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, connectionEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteBackupConfigurationSender(req)
+ resp, err := client.CreateOrUpdateVnetConnectionGatewaySlotSender(req)
if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteBackupConfigurationResponder(resp)
+ result, err = client.CreateOrUpdateVnetConnectionGatewaySlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionGatewaySlot", resp, "Failure responding to request")
}
return
}
-// DeleteBackupConfigurationPreparer prepares the DeleteBackupConfiguration request.
-func (client AppsClient) DeleteBackupConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// CreateOrUpdateVnetConnectionGatewaySlotPreparer prepares the CreateOrUpdateVnetConnectionGatewaySlot request.
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, connectionEnvelope VnetGateway, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3824,45 +3835,51 @@ func (client AppsClient) DeleteBackupConfigurationPreparer(ctx context.Context,
}
preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/backup", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
+ autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteBackupConfigurationSender sends the DeleteBackupConfiguration request. The method will close the
+// CreateOrUpdateVnetConnectionGatewaySlotSender sends the CreateOrUpdateVnetConnectionGatewaySlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteBackupConfigurationSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteBackupConfigurationResponder handles the response to the DeleteBackupConfiguration request. The method always
+// CreateOrUpdateVnetConnectionGatewaySlotResponder handles the response to the CreateOrUpdateVnetConnectionGatewaySlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteBackupConfigurationResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionGatewaySlotResponder(resp *http.Response) (result VnetGateway, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
- result.Response = resp
+ result.Response = autorest.Response{Response: resp}
return
}
-// DeleteBackupConfigurationSlot deletes the backup configuration of an app.
+// CreateOrUpdateVnetConnectionSlot adds a Virtual Network connection to an app or slot (PUT) or updates the connection
+// properties (PATCH).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the backup configuration
-// for the production slot.
-func (client AppsClient) DeleteBackupConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
+// vnetName - name of an existing Virtual Network.
+// connectionEnvelope - properties of the Virtual Network connection. See example.
+// slot - name of the deployment slot. If a slot is not specified, the API will add or update connections for
+// the production slot.
+func (client AppsClient) CreateOrUpdateVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo, slot string) (result VnetInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupConfigurationSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.CreateOrUpdateVnetConnectionSlot")
defer func() {
sc := -1
- if result.Response != nil {
- sc = result.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -3872,37 +3889,38 @@ func (client AppsClient) DeleteBackupConfigurationSlot(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteBackupConfigurationSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "CreateOrUpdateVnetConnectionSlot", err.Error())
}
- req, err := client.DeleteBackupConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.CreateOrUpdateVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, connectionEnvelope, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteBackupConfigurationSlotSender(req)
+ resp, err := client.CreateOrUpdateVnetConnectionSlotSender(req)
if err != nil {
- result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteBackupConfigurationSlotResponder(resp)
+ result, err = client.CreateOrUpdateVnetConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "CreateOrUpdateVnetConnectionSlot", resp, "Failure responding to request")
}
return
}
-// DeleteBackupConfigurationSlotPreparer prepares the DeleteBackupConfigurationSlot request.
-func (client AppsClient) DeleteBackupConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// CreateOrUpdateVnetConnectionSlotPreparer prepares the CreateOrUpdateVnetConnectionSlot request.
+func (client AppsClient) CreateOrUpdateVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, connectionEnvelope VnetInfo, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -3911,42 +3929,45 @@ func (client AppsClient) DeleteBackupConfigurationSlotPreparer(ctx context.Conte
}
preparer := autorest.CreatePreparer(
- autorest.AsDelete(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithJSON(connectionEnvelope),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteBackupConfigurationSlotSender sends the DeleteBackupConfigurationSlot request. The method will close the
+// CreateOrUpdateVnetConnectionSlotSender sends the CreateOrUpdateVnetConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteBackupConfigurationSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteBackupConfigurationSlotResponder handles the response to the DeleteBackupConfigurationSlot request. The method always
+// CreateOrUpdateVnetConnectionSlotResponder handles the response to the CreateOrUpdateVnetConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteBackupConfigurationSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) CreateOrUpdateVnetConnectionSlotResponder(resp *http.Response) (result VnetInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
- result.Response = resp
+ result.Response = autorest.Response{Response: resp}
return
}
-// DeleteBackupSlot deletes a backup of an app by its ID.
+// Delete deletes a web, mobile, or API app, or one of the deployment slots.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// backupID - ID of the backup.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete a backup of the
-// production slot.
-func (client AppsClient) DeleteBackupSlot(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (result autorest.Response, err error) {
+// name - name of the app to delete.
+// deleteMetrics - if true, web app metrics are also deleted.
+// deleteEmptyServerFarm - specify true if the App Service plan will be empty after app deletion and you want
+// to delete the empty App Service plan. By default, the empty App Service plan is not deleted.
+func (client AppsClient) Delete(ctx context.Context, resourceGroupName string, name string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.Delete")
defer func() {
sc := -1
if result.Response != nil {
@@ -3960,37 +3981,35 @@ func (client AppsClient) DeleteBackupSlot(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteBackupSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "Delete", err.Error())
}
- req, err := client.DeleteBackupSlotPreparer(ctx, resourceGroupName, name, backupID, slot)
+ req, err := client.DeletePreparer(ctx, resourceGroupName, name, deleteMetrics, deleteEmptyServerFarm)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteBackupSlotSender(req)
+ resp, err := client.DeleteSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", resp, "Failure sending request")
return
}
- result, err = client.DeleteBackupSlotResponder(resp)
+ result, err = client.DeleteResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Delete", resp, "Failure responding to request")
}
return
}
-// DeleteBackupSlotPreparer prepares the DeleteBackupSlot request.
-func (client AppsClient) DeleteBackupSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (*http.Request, error) {
+// DeletePreparer prepares the Delete request.
+func (client AppsClient) DeletePreparer(ctx context.Context, resourceGroupName string, name string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -3998,42 +4017,48 @@ func (client AppsClient) DeleteBackupSlotPreparer(ctx context.Context, resourceG
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if deleteMetrics != nil {
+ queryParameters["deleteMetrics"] = autorest.Encode("query", *deleteMetrics)
+ }
+ if deleteEmptyServerFarm != nil {
+ queryParameters["deleteEmptyServerFarm"] = autorest.Encode("query", *deleteEmptyServerFarm)
+ }
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteBackupSlotSender sends the DeleteBackupSlot request. The method will close the
+// DeleteSender sends the Delete request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteBackupSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteBackupSlotResponder handles the response to the DeleteBackupSlot request. The method always
+// DeleteResponder handles the response to the Delete request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteBackupSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteContinuousWebJob delete a continuous web job by its ID for an app, or a deployment slot.
+// DeleteBackup deletes a backup of an app by its ID.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-func (client AppsClient) DeleteContinuousWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result autorest.Response, err error) {
+// name - name of the app.
+// backupID - ID of the backup.
+func (client AppsClient) DeleteBackup(ctx context.Context, resourceGroupName string, name string, backupID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteContinuousWebJob")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackup")
defer func() {
sc := -1
if result.Response != nil {
@@ -4047,37 +4072,37 @@ func (client AppsClient) DeleteContinuousWebJob(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteContinuousWebJob", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteBackup", err.Error())
}
- req, err := client.DeleteContinuousWebJobPreparer(ctx, resourceGroupName, name, webJobName)
+ req, err := client.DeleteBackupPreparer(ctx, resourceGroupName, name, backupID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteContinuousWebJobSender(req)
+ resp, err := client.DeleteBackupSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", resp, "Failure sending request")
return
}
- result, err = client.DeleteContinuousWebJobResponder(resp)
+ result, err = client.DeleteBackupResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackup", resp, "Failure responding to request")
}
return
}
-// DeleteContinuousWebJobPreparer prepares the DeleteContinuousWebJob request.
-func (client AppsClient) DeleteContinuousWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
+// DeleteBackupPreparer prepares the DeleteBackup request.
+func (client AppsClient) DeleteBackupPreparer(ctx context.Context, resourceGroupName string, name string, backupID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -4088,40 +4113,37 @@ func (client AppsClient) DeleteContinuousWebJobPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteContinuousWebJobSender sends the DeleteContinuousWebJob request. The method will close the
+// DeleteBackupSender sends the DeleteBackup request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteContinuousWebJobSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteBackupSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteContinuousWebJobResponder handles the response to the DeleteContinuousWebJob request. The method always
+// DeleteBackupResponder handles the response to the DeleteBackup request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteContinuousWebJobResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteBackupResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteContinuousWebJobSlot delete a continuous web job by its ID for an app, or a deployment slot.
+// DeleteBackupConfiguration deletes the backup configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) DeleteContinuousWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result autorest.Response, err error) {
+// name - name of the app.
+func (client AppsClient) DeleteBackupConfiguration(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteContinuousWebJobSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupConfiguration")
defer func() {
sc := -1
if result.Response != nil {
@@ -4135,38 +4157,36 @@ func (client AppsClient) DeleteContinuousWebJobSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteContinuousWebJobSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteBackupConfiguration", err.Error())
}
- req, err := client.DeleteContinuousWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
+ req, err := client.DeleteBackupConfigurationPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteContinuousWebJobSlotSender(req)
+ resp, err := client.DeleteBackupConfigurationSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", resp, "Failure sending request")
return
}
- result, err = client.DeleteContinuousWebJobSlotResponder(resp)
+ result, err = client.DeleteBackupConfigurationResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfiguration", resp, "Failure responding to request")
}
return
}
-// DeleteContinuousWebJobSlotPreparer prepares the DeleteContinuousWebJobSlot request.
-func (client AppsClient) DeleteContinuousWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
+// DeleteBackupConfigurationPreparer prepares the DeleteBackupConfiguration request.
+func (client AppsClient) DeleteBackupConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -4177,38 +4197,39 @@ func (client AppsClient) DeleteContinuousWebJobSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/backup", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteContinuousWebJobSlotSender sends the DeleteContinuousWebJobSlot request. The method will close the
+// DeleteBackupConfigurationSender sends the DeleteBackupConfiguration request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteContinuousWebJobSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteBackupConfigurationSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteContinuousWebJobSlotResponder handles the response to the DeleteContinuousWebJobSlot request. The method always
+// DeleteBackupConfigurationResponder handles the response to the DeleteBackupConfiguration request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteContinuousWebJobSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteBackupConfigurationResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteDeployment delete a deployment by its ID for an app, or a deployment slot.
+// DeleteBackupConfigurationSlot deletes the backup configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - deployment ID.
-func (client AppsClient) DeleteDeployment(ctx context.Context, resourceGroupName string, name string, ID string) (result autorest.Response, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the backup configuration
+// for the production slot.
+func (client AppsClient) DeleteBackupConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDeployment")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupConfigurationSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -4222,36 +4243,36 @@ func (client AppsClient) DeleteDeployment(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteDeployment", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteBackupConfigurationSlot", err.Error())
}
- req, err := client.DeleteDeploymentPreparer(ctx, resourceGroupName, name, ID)
+ req, err := client.DeleteBackupConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteDeploymentSender(req)
+ resp, err := client.DeleteBackupConfigurationSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteDeploymentResponder(resp)
+ result, err = client.DeleteBackupConfigurationSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupConfigurationSlot", resp, "Failure responding to request")
}
return
}
-// DeleteDeploymentPreparer prepares the DeleteDeployment request.
-func (client AppsClient) DeleteDeploymentPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
+// DeleteBackupConfigurationSlotPreparer prepares the DeleteBackupConfigurationSlot request.
+func (client AppsClient) DeleteBackupConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -4263,40 +4284,40 @@ func (client AppsClient) DeleteDeploymentPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteDeploymentSender sends the DeleteDeployment request. The method will close the
+// DeleteBackupConfigurationSlotSender sends the DeleteBackupConfigurationSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteDeploymentSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteBackupConfigurationSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteDeploymentResponder handles the response to the DeleteDeployment request. The method always
+// DeleteBackupConfigurationSlotResponder handles the response to the DeleteBackupConfigurationSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteDeploymentResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteBackupConfigurationSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteDeploymentSlot delete a deployment by its ID for an app, or a deployment slot.
+// DeleteBackupSlot deletes a backup of an app by its ID.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - deployment ID.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// backupID - ID of the backup.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete a backup of the
// production slot.
-func (client AppsClient) DeleteDeploymentSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result autorest.Response, err error) {
+func (client AppsClient) DeleteBackupSlot(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDeploymentSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteBackupSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -4310,34 +4331,34 @@ func (client AppsClient) DeleteDeploymentSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteDeploymentSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteBackupSlot", err.Error())
}
- req, err := client.DeleteDeploymentSlotPreparer(ctx, resourceGroupName, name, ID, slot)
+ req, err := client.DeleteBackupSlotPreparer(ctx, resourceGroupName, name, backupID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteDeploymentSlotSender(req)
+ resp, err := client.DeleteBackupSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteDeploymentSlotResponder(resp)
+ result, err = client.DeleteBackupSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteBackupSlot", resp, "Failure responding to request")
}
return
}
-// DeleteDeploymentSlotPreparer prepares the DeleteDeploymentSlot request.
-func (client AppsClient) DeleteDeploymentSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
+// DeleteBackupSlotPreparer prepares the DeleteBackupSlot request.
+func (client AppsClient) DeleteBackupSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
+ "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
@@ -4352,38 +4373,38 @@ func (client AppsClient) DeleteDeploymentSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteDeploymentSlotSender sends the DeleteDeploymentSlot request. The method will close the
+// DeleteBackupSlotSender sends the DeleteBackupSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteDeploymentSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteBackupSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteDeploymentSlotResponder handles the response to the DeleteDeploymentSlot request. The method always
+// DeleteBackupSlotResponder handles the response to the DeleteBackupSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteDeploymentSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteBackupSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteDomainOwnershipIdentifier deletes a domain ownership identifier for a web app.
+// DeleteContinuousWebJob delete a continuous web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// domainOwnershipIdentifierName - name of domain ownership identifier.
-func (client AppsClient) DeleteDomainOwnershipIdentifier(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (result autorest.Response, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+func (client AppsClient) DeleteContinuousWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDomainOwnershipIdentifier")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteContinuousWebJob")
defer func() {
sc := -1
if result.Response != nil {
@@ -4397,37 +4418,37 @@ func (client AppsClient) DeleteDomainOwnershipIdentifier(ctx context.Context, re
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteDomainOwnershipIdentifier", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteContinuousWebJob", err.Error())
}
- req, err := client.DeleteDomainOwnershipIdentifierPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName)
+ req, err := client.DeleteContinuousWebJobPreparer(ctx, resourceGroupName, name, webJobName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteDomainOwnershipIdentifierSender(req)
+ resp, err := client.DeleteContinuousWebJobSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", resp, "Failure sending request")
return
}
- result, err = client.DeleteDomainOwnershipIdentifierResponder(resp)
+ result, err = client.DeleteContinuousWebJobResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJob", resp, "Failure responding to request")
}
return
}
-// DeleteDomainOwnershipIdentifierPreparer prepares the DeleteDomainOwnershipIdentifier request.
-func (client AppsClient) DeleteDomainOwnershipIdentifierPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (*http.Request, error) {
+// DeleteContinuousWebJobPreparer prepares the DeleteContinuousWebJob request.
+func (client AppsClient) DeleteContinuousWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -4438,21 +4459,21 @@ func (client AppsClient) DeleteDomainOwnershipIdentifierPreparer(ctx context.Con
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteDomainOwnershipIdentifierSender sends the DeleteDomainOwnershipIdentifier request. The method will close the
+// DeleteContinuousWebJobSender sends the DeleteContinuousWebJob request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteDomainOwnershipIdentifierSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteContinuousWebJobSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteDomainOwnershipIdentifierResponder handles the response to the DeleteDomainOwnershipIdentifier request. The method always
+// DeleteContinuousWebJobResponder handles the response to the DeleteContinuousWebJob request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteDomainOwnershipIdentifierResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteContinuousWebJobResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -4462,16 +4483,16 @@ func (client AppsClient) DeleteDomainOwnershipIdentifierResponder(resp *http.Res
return
}
-// DeleteDomainOwnershipIdentifierSlot deletes a domain ownership identifier for a web app.
+// DeleteContinuousWebJobSlot delete a continuous web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// domainOwnershipIdentifierName - name of domain ownership identifier.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
+// name - site name.
+// webJobName - name of Web Job.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
// production slot.
-func (client AppsClient) DeleteDomainOwnershipIdentifierSlot(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (result autorest.Response, err error) {
+func (client AppsClient) DeleteContinuousWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDomainOwnershipIdentifierSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteContinuousWebJobSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -4485,38 +4506,38 @@ func (client AppsClient) DeleteDomainOwnershipIdentifierSlot(ctx context.Context
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteContinuousWebJobSlot", err.Error())
}
- req, err := client.DeleteDomainOwnershipIdentifierSlotPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName, slot)
+ req, err := client.DeleteContinuousWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteDomainOwnershipIdentifierSlotSender(req)
+ resp, err := client.DeleteContinuousWebJobSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteDomainOwnershipIdentifierSlotResponder(resp)
+ result, err = client.DeleteContinuousWebJobSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteContinuousWebJobSlot", resp, "Failure responding to request")
}
return
}
-// DeleteDomainOwnershipIdentifierSlotPreparer prepares the DeleteDomainOwnershipIdentifierSlot request.
-func (client AppsClient) DeleteDomainOwnershipIdentifierSlotPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (*http.Request, error) {
+// DeleteContinuousWebJobSlotPreparer prepares the DeleteContinuousWebJobSlot request.
+func (client AppsClient) DeleteContinuousWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -4527,21 +4548,21 @@ func (client AppsClient) DeleteDomainOwnershipIdentifierSlotPreparer(ctx context
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteDomainOwnershipIdentifierSlotSender sends the DeleteDomainOwnershipIdentifierSlot request. The method will close the
+// DeleteContinuousWebJobSlotSender sends the DeleteContinuousWebJobSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteDomainOwnershipIdentifierSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteContinuousWebJobSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteDomainOwnershipIdentifierSlotResponder handles the response to the DeleteDomainOwnershipIdentifierSlot request. The method always
+// DeleteContinuousWebJobSlotResponder handles the response to the DeleteContinuousWebJobSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteDomainOwnershipIdentifierSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteContinuousWebJobSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -4551,14 +4572,14 @@ func (client AppsClient) DeleteDomainOwnershipIdentifierSlotResponder(resp *http
return
}
-// DeleteFunction delete a function for web site, or a deployment slot.
+// DeleteDeployment delete a deployment by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// functionName - function name.
-func (client AppsClient) DeleteFunction(ctx context.Context, resourceGroupName string, name string, functionName string) (result autorest.Response, err error) {
+// name - name of the app.
+// ID - deployment ID.
+func (client AppsClient) DeleteDeployment(ctx context.Context, resourceGroupName string, name string, ID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteFunction")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDeployment")
defer func() {
sc := -1
if result.Response != nil {
@@ -4572,34 +4593,34 @@ func (client AppsClient) DeleteFunction(ctx context.Context, resourceGroupName s
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteFunction", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteDeployment", err.Error())
}
- req, err := client.DeleteFunctionPreparer(ctx, resourceGroupName, name, functionName)
+ req, err := client.DeleteDeploymentPreparer(ctx, resourceGroupName, name, ID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteFunctionSender(req)
+ resp, err := client.DeleteDeploymentSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", resp, "Failure sending request")
return
}
- result, err = client.DeleteFunctionResponder(resp)
+ result, err = client.DeleteDeploymentResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeployment", resp, "Failure responding to request")
}
return
}
-// DeleteFunctionPreparer prepares the DeleteFunction request.
-func (client AppsClient) DeleteFunctionPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
+// DeleteDeploymentPreparer prepares the DeleteDeployment request.
+func (client AppsClient) DeleteDeploymentPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "functionName": autorest.Encode("path", functionName),
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -4613,38 +4634,40 @@ func (client AppsClient) DeleteFunctionPreparer(ctx context.Context, resourceGro
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteFunctionSender sends the DeleteFunction request. The method will close the
+// DeleteDeploymentSender sends the DeleteDeployment request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteFunctionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteDeploymentSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteFunctionResponder handles the response to the DeleteFunction request. The method always
+// DeleteDeploymentResponder handles the response to the DeleteDeployment request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteFunctionResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteDeploymentResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteHostNameBinding deletes a hostname binding for an app.
+// DeleteDeploymentSlot delete a deployment by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// hostName - hostname in the hostname binding.
-func (client AppsClient) DeleteHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string) (result autorest.Response, err error) {
+// ID - deployment ID.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) DeleteDeploymentSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostNameBinding")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDeploymentSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -4658,36 +4681,37 @@ func (client AppsClient) DeleteHostNameBinding(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteHostNameBinding", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteDeploymentSlot", err.Error())
}
- req, err := client.DeleteHostNameBindingPreparer(ctx, resourceGroupName, name, hostName)
+ req, err := client.DeleteDeploymentSlotPreparer(ctx, resourceGroupName, name, ID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteHostNameBindingSender(req)
+ resp, err := client.DeleteDeploymentSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteHostNameBindingResponder(resp)
+ result, err = client.DeleteDeploymentSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDeploymentSlot", resp, "Failure responding to request")
}
return
}
-// DeleteHostNameBindingPreparer prepares the DeleteHostNameBinding request.
-func (client AppsClient) DeleteHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string) (*http.Request, error) {
+// DeleteDeploymentSlotPreparer prepares the DeleteDeploymentSlot request.
+func (client AppsClient) DeleteDeploymentSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -4699,21 +4723,21 @@ func (client AppsClient) DeleteHostNameBindingPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteHostNameBindingSender sends the DeleteHostNameBinding request. The method will close the
+// DeleteDeploymentSlotSender sends the DeleteDeploymentSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteHostNameBindingSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteDeploymentSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteHostNameBindingResponder handles the response to the DeleteHostNameBinding request. The method always
+// DeleteDeploymentSlotResponder handles the response to the DeleteDeploymentSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteHostNameBindingResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteDeploymentSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -4723,16 +4747,14 @@ func (client AppsClient) DeleteHostNameBindingResponder(resp *http.Response) (re
return
}
-// DeleteHostNameBindingSlot deletes a hostname binding for an app.
+// DeleteDomainOwnershipIdentifier deletes a domain ownership identifier for a web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
-// production slot.
-// hostName - hostname in the hostname binding.
-func (client AppsClient) DeleteHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (result autorest.Response, err error) {
+// domainOwnershipIdentifierName - name of domain ownership identifier.
+func (client AppsClient) DeleteDomainOwnershipIdentifier(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostNameBindingSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDomainOwnershipIdentifier")
defer func() {
sc := -1
if result.Response != nil {
@@ -4746,38 +4768,37 @@ func (client AppsClient) DeleteHostNameBindingSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteHostNameBindingSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteDomainOwnershipIdentifier", err.Error())
}
- req, err := client.DeleteHostNameBindingSlotPreparer(ctx, resourceGroupName, name, slot, hostName)
+ req, err := client.DeleteDomainOwnershipIdentifierPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteHostNameBindingSlotSender(req)
+ resp, err := client.DeleteDomainOwnershipIdentifierSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", resp, "Failure sending request")
return
}
- result, err = client.DeleteHostNameBindingSlotResponder(resp)
+ result, err = client.DeleteDomainOwnershipIdentifierResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifier", resp, "Failure responding to request")
}
return
}
-// DeleteHostNameBindingSlotPreparer prepares the DeleteHostNameBindingSlot request.
-func (client AppsClient) DeleteHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (*http.Request, error) {
+// DeleteDomainOwnershipIdentifierPreparer prepares the DeleteDomainOwnershipIdentifier request.
+func (client AppsClient) DeleteDomainOwnershipIdentifierPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -4788,21 +4809,21 @@ func (client AppsClient) DeleteHostNameBindingSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteHostNameBindingSlotSender sends the DeleteHostNameBindingSlot request. The method will close the
+// DeleteDomainOwnershipIdentifierSender sends the DeleteDomainOwnershipIdentifier request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteDomainOwnershipIdentifierSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteHostNameBindingSlotResponder handles the response to the DeleteHostNameBindingSlot request. The method always
+// DeleteDomainOwnershipIdentifierResponder handles the response to the DeleteDomainOwnershipIdentifier request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteHostNameBindingSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteDomainOwnershipIdentifierResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -4812,15 +4833,16 @@ func (client AppsClient) DeleteHostNameBindingSlotResponder(resp *http.Response)
return
}
-// DeleteHybridConnection removes a Hybrid Connection from this site.
+// DeleteDomainOwnershipIdentifierSlot deletes a domain ownership identifier for a web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-func (client AppsClient) DeleteHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (result autorest.Response, err error) {
+// name - name of the app.
+// domainOwnershipIdentifierName - name of domain ownership identifier.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
+// production slot.
+func (client AppsClient) DeleteDomainOwnershipIdentifierSlot(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHybridConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteDomainOwnershipIdentifierSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -4834,38 +4856,38 @@ func (client AppsClient) DeleteHybridConnection(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteHybridConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", err.Error())
}
- req, err := client.DeleteHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName)
+ req, err := client.DeleteDomainOwnershipIdentifierSlotPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteHybridConnectionSender(req)
+ resp, err := client.DeleteDomainOwnershipIdentifierSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteHybridConnectionResponder(resp)
+ result, err = client.DeleteDomainOwnershipIdentifierSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteDomainOwnershipIdentifierSlot", resp, "Failure responding to request")
}
return
}
-// DeleteHybridConnectionPreparer prepares the DeleteHybridConnection request.
-func (client AppsClient) DeleteHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (*http.Request, error) {
+// DeleteDomainOwnershipIdentifierSlotPreparer prepares the DeleteDomainOwnershipIdentifierSlot request.
+func (client AppsClient) DeleteDomainOwnershipIdentifierSlotPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -4876,40 +4898,38 @@ func (client AppsClient) DeleteHybridConnectionPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteHybridConnectionSender sends the DeleteHybridConnection request. The method will close the
+// DeleteDomainOwnershipIdentifierSlotSender sends the DeleteDomainOwnershipIdentifierSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteHybridConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteDomainOwnershipIdentifierSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteHybridConnectionResponder handles the response to the DeleteHybridConnection request. The method always
+// DeleteDomainOwnershipIdentifierSlotResponder handles the response to the DeleteDomainOwnershipIdentifierSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteHybridConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteDomainOwnershipIdentifierSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteHybridConnectionSlot removes a Hybrid Connection from this site.
+// DeleteFunction delete a function for web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-// slot - the name of the slot for the web app.
-func (client AppsClient) DeleteHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (result autorest.Response, err error) {
+// name - site name.
+// functionName - function name.
+func (client AppsClient) DeleteFunction(ctx context.Context, resourceGroupName string, name string, functionName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHybridConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteFunction")
defer func() {
sc := -1
if result.Response != nil {
@@ -4923,38 +4943,36 @@ func (client AppsClient) DeleteHybridConnectionSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteHybridConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteFunction", err.Error())
}
- req, err := client.DeleteHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, slot)
+ req, err := client.DeleteFunctionPreparer(ctx, resourceGroupName, name, functionName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteHybridConnectionSlotSender(req)
+ resp, err := client.DeleteFunctionSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", resp, "Failure sending request")
return
}
- result, err = client.DeleteHybridConnectionSlotResponder(resp)
+ result, err = client.DeleteFunctionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunction", resp, "Failure responding to request")
}
return
}
-// DeleteHybridConnectionSlotPreparer prepares the DeleteHybridConnectionSlot request.
-func (client AppsClient) DeleteHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (*http.Request, error) {
+// DeleteFunctionPreparer prepares the DeleteFunction request.
+func (client AppsClient) DeleteFunctionPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -4966,40 +4984,39 @@ func (client AppsClient) DeleteHybridConnectionSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteHybridConnectionSlotSender sends the DeleteHybridConnectionSlot request. The method will close the
+// DeleteFunctionSender sends the DeleteFunction request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteFunctionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteHybridConnectionSlotResponder handles the response to the DeleteHybridConnectionSlot request. The method always
+// DeleteFunctionResponder handles the response to the DeleteFunction request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteHybridConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteFunctionResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteInstanceFunctionSlot delete a function for web site, or a deployment slot.
+// DeleteFunctionSecret delete a function secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// functionName - function name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) DeleteInstanceFunctionSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result autorest.Response, err error) {
+// functionName - the name of the function.
+// keyName - the name of the key.
+func (client AppsClient) DeleteFunctionSecret(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceFunctionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteFunctionSecret")
defer func() {
sc := -1
if result.Response != nil {
@@ -5013,37 +5030,37 @@ func (client AppsClient) DeleteInstanceFunctionSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteInstanceFunctionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteFunctionSecret", err.Error())
}
- req, err := client.DeleteInstanceFunctionSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
+ req, err := client.DeleteFunctionSecretPreparer(ctx, resourceGroupName, name, functionName, keyName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecret", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteInstanceFunctionSlotSender(req)
+ resp, err := client.DeleteFunctionSecretSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecret", resp, "Failure sending request")
return
}
- result, err = client.DeleteInstanceFunctionSlotResponder(resp)
+ result, err = client.DeleteFunctionSecretResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecret", resp, "Failure responding to request")
}
return
}
-// DeleteInstanceFunctionSlotPreparer prepares the DeleteInstanceFunctionSlot request.
-func (client AppsClient) DeleteInstanceFunctionSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
+// DeleteFunctionSecretPreparer prepares the DeleteFunctionSecret request.
+func (client AppsClient) DeleteFunctionSecretPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"functionName": autorest.Encode("path", functionName),
+ "keyName": autorest.Encode("path", keyName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5055,21 +5072,21 @@ func (client AppsClient) DeleteInstanceFunctionSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}/keys/{keyName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteInstanceFunctionSlotSender sends the DeleteInstanceFunctionSlot request. The method will close the
+// DeleteFunctionSecretSender sends the DeleteFunctionSecret request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteInstanceFunctionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteFunctionSecretSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteInstanceFunctionSlotResponder handles the response to the DeleteInstanceFunctionSlot request. The method always
+// DeleteFunctionSecretResponder handles the response to the DeleteFunctionSecret request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteInstanceFunctionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteFunctionSecretResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -5079,17 +5096,16 @@ func (client AppsClient) DeleteInstanceFunctionSlotResponder(resp *http.Response
return
}
-// DeleteInstanceProcess terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
-// instance in a web site.
+// DeleteFunctionSecretSlot delete a function secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// processID - pID.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) DeleteInstanceProcess(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result autorest.Response, err error) {
+// functionName - the name of the function.
+// keyName - the name of the key.
+// slot - name of the deployment slot.
+func (client AppsClient) DeleteFunctionSecretSlot(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceProcess")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteFunctionSecretSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5103,37 +5119,38 @@ func (client AppsClient) DeleteInstanceProcess(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteInstanceProcess", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteFunctionSecretSlot", err.Error())
}
- req, err := client.DeleteInstanceProcessPreparer(ctx, resourceGroupName, name, processID, instanceID)
+ req, err := client.DeleteFunctionSecretSlotPreparer(ctx, resourceGroupName, name, functionName, keyName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecretSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteInstanceProcessSender(req)
+ resp, err := client.DeleteFunctionSecretSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecretSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteInstanceProcessResponder(resp)
+ result, err = client.DeleteFunctionSecretSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteFunctionSecretSlot", resp, "Failure responding to request")
}
return
}
-// DeleteInstanceProcessPreparer prepares the DeleteInstanceProcess request.
-func (client AppsClient) DeleteInstanceProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
+// DeleteFunctionSecretSlotPreparer prepares the DeleteFunctionSecretSlot request.
+func (client AppsClient) DeleteFunctionSecretSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, keyName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
+ "functionName": autorest.Encode("path", functionName),
+ "keyName": autorest.Encode("path", keyName),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5145,21 +5162,21 @@ func (client AppsClient) DeleteInstanceProcessPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}/keys/{keyName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteInstanceProcessSender sends the DeleteInstanceProcess request. The method will close the
+// DeleteFunctionSecretSlotSender sends the DeleteFunctionSecretSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteInstanceProcessSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteFunctionSecretSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteInstanceProcessResponder handles the response to the DeleteInstanceProcess request. The method always
+// DeleteFunctionSecretSlotResponder handles the response to the DeleteFunctionSecretSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteInstanceProcessResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteFunctionSecretSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -5169,19 +5186,14 @@ func (client AppsClient) DeleteInstanceProcessResponder(resp *http.Response) (re
return
}
-// DeleteInstanceProcessSlot terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
-// instance in a web site.
+// DeleteHostNameBinding deletes a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) DeleteInstanceProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result autorest.Response, err error) {
+// name - name of the app.
+// hostName - hostname in the hostname binding.
+func (client AppsClient) DeleteHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceProcessSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostNameBinding")
defer func() {
sc := -1
if result.Response != nil {
@@ -5195,38 +5207,36 @@ func (client AppsClient) DeleteInstanceProcessSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteInstanceProcessSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHostNameBinding", err.Error())
}
- req, err := client.DeleteInstanceProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
+ req, err := client.DeleteHostNameBindingPreparer(ctx, resourceGroupName, name, hostName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteInstanceProcessSlotSender(req)
+ resp, err := client.DeleteHostNameBindingSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", resp, "Failure sending request")
return
}
- result, err = client.DeleteInstanceProcessSlotResponder(resp)
+ result, err = client.DeleteHostNameBindingResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBinding", resp, "Failure responding to request")
}
return
}
-// DeleteInstanceProcessSlotPreparer prepares the DeleteInstanceProcessSlot request.
-func (client AppsClient) DeleteInstanceProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
+// DeleteHostNameBindingPreparer prepares the DeleteHostNameBinding request.
+func (client AppsClient) DeleteHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5238,38 +5248,40 @@ func (client AppsClient) DeleteInstanceProcessSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteInstanceProcessSlotSender sends the DeleteInstanceProcessSlot request. The method will close the
+// DeleteHostNameBindingSender sends the DeleteHostNameBinding request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteInstanceProcessSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHostNameBindingSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteInstanceProcessSlotResponder handles the response to the DeleteInstanceProcessSlot request. The method always
+// DeleteHostNameBindingResponder handles the response to the DeleteHostNameBinding request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteInstanceProcessSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHostNameBindingResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeletePremierAddOn delete a premier add-on from an app.
+// DeleteHostNameBindingSlot deletes a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// premierAddOnName - add-on name.
-func (client AppsClient) DeletePremierAddOn(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (result autorest.Response, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
+// production slot.
+// hostName - hostname in the hostname binding.
+func (client AppsClient) DeleteHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePremierAddOn")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostNameBindingSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5283,36 +5295,37 @@ func (client AppsClient) DeletePremierAddOn(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeletePremierAddOn", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHostNameBindingSlot", err.Error())
}
- req, err := client.DeletePremierAddOnPreparer(ctx, resourceGroupName, name, premierAddOnName)
+ req, err := client.DeleteHostNameBindingSlotPreparer(ctx, resourceGroupName, name, slot, hostName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeletePremierAddOnSender(req)
+ resp, err := client.DeleteHostNameBindingSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", resp, "Failure sending request")
return
}
- result, err = client.DeletePremierAddOnResponder(resp)
+ result, err = client.DeleteHostNameBindingSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostNameBindingSlot", resp, "Failure responding to request")
}
return
}
-// DeletePremierAddOnPreparer prepares the DeletePremierAddOn request.
-func (client AppsClient) DeletePremierAddOnPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (*http.Request, error) {
+// DeleteHostNameBindingSlotPreparer prepares the DeleteHostNameBindingSlot request.
+func (client AppsClient) DeleteHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
- "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5324,40 +5337,39 @@ func (client AppsClient) DeletePremierAddOnPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeletePremierAddOnSender sends the DeletePremierAddOn request. The method will close the
+// DeleteHostNameBindingSlotSender sends the DeleteHostNameBindingSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeletePremierAddOnSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeletePremierAddOnResponder handles the response to the DeletePremierAddOn request. The method always
+// DeleteHostNameBindingSlotResponder handles the response to the DeleteHostNameBindingSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeletePremierAddOnResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHostNameBindingSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeletePremierAddOnSlot delete a premier add-on from an app.
+// DeleteHostSecret delete a host level secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// premierAddOnName - add-on name.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the named add-on for the
-// production slot.
-func (client AppsClient) DeletePremierAddOnSlot(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (result autorest.Response, err error) {
+// name - site name.
+// keyType - the type of host key.
+// keyName - the name of the key.
+func (client AppsClient) DeleteHostSecret(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePremierAddOnSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostSecret")
defer func() {
sc := -1
if result.Response != nil {
@@ -5371,37 +5383,37 @@ func (client AppsClient) DeletePremierAddOnSlot(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeletePremierAddOnSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHostSecret", err.Error())
}
- req, err := client.DeletePremierAddOnSlotPreparer(ctx, resourceGroupName, name, premierAddOnName, slot)
+ req, err := client.DeleteHostSecretPreparer(ctx, resourceGroupName, name, keyType, keyName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecret", nil, "Failure preparing request")
return
}
- resp, err := client.DeletePremierAddOnSlotSender(req)
+ resp, err := client.DeleteHostSecretSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecret", resp, "Failure sending request")
return
}
- result, err = client.DeletePremierAddOnSlotResponder(resp)
+ result, err = client.DeleteHostSecretResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecret", resp, "Failure responding to request")
}
return
}
-// DeletePremierAddOnSlotPreparer prepares the DeletePremierAddOnSlot request.
-func (client AppsClient) DeletePremierAddOnSlotPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (*http.Request, error) {
+// DeleteHostSecretPreparer prepares the DeleteHostSecret request.
+func (client AppsClient) DeleteHostSecretPreparer(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "keyName": autorest.Encode("path", keyName),
+ "keyType": autorest.Encode("path", keyType),
"name": autorest.Encode("path", name),
- "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5413,39 +5425,40 @@ func (client AppsClient) DeletePremierAddOnSlotPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/host/default/{keyType}/{keyName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeletePremierAddOnSlotSender sends the DeletePremierAddOnSlot request. The method will close the
+// DeleteHostSecretSender sends the DeleteHostSecret request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeletePremierAddOnSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHostSecretSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeletePremierAddOnSlotResponder handles the response to the DeletePremierAddOnSlot request. The method always
+// DeleteHostSecretResponder handles the response to the DeleteHostSecret request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeletePremierAddOnSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHostSecretResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteProcess terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out instance in
-// a web site.
+// DeleteHostSecretSlot delete a host level secret.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// processID - pID.
-func (client AppsClient) DeleteProcess(ctx context.Context, resourceGroupName string, name string, processID string) (result autorest.Response, err error) {
+// keyType - the type of host key.
+// keyName - the name of the key.
+// slot - name of the deployment slot.
+func (client AppsClient) DeleteHostSecretSlot(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteProcess")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHostSecretSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5459,36 +5472,38 @@ func (client AppsClient) DeleteProcess(ctx context.Context, resourceGroupName st
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteProcess", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHostSecretSlot", err.Error())
}
- req, err := client.DeleteProcessPreparer(ctx, resourceGroupName, name, processID)
+ req, err := client.DeleteHostSecretSlotPreparer(ctx, resourceGroupName, name, keyType, keyName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecretSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteProcessSender(req)
+ resp, err := client.DeleteHostSecretSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecretSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteProcessResponder(resp)
+ result, err = client.DeleteHostSecretSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHostSecretSlot", resp, "Failure responding to request")
}
return
}
-// DeleteProcessPreparer prepares the DeleteProcess request.
-func (client AppsClient) DeleteProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
+// DeleteHostSecretSlotPreparer prepares the DeleteHostSecretSlot request.
+func (client AppsClient) DeleteHostSecretSlotPreparer(ctx context.Context, resourceGroupName string, name string, keyType string, keyName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "keyName": autorest.Encode("path", keyName),
+ "keyType": autorest.Encode("path", keyType),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5500,21 +5515,21 @@ func (client AppsClient) DeleteProcessPreparer(ctx context.Context, resourceGrou
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/host/default/{keyType}/{keyName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteProcessSender sends the DeleteProcess request. The method will close the
+// DeleteHostSecretSlotSender sends the DeleteHostSecretSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteProcessSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHostSecretSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteProcessResponder handles the response to the DeleteProcess request. The method always
+// DeleteHostSecretSlotResponder handles the response to the DeleteHostSecretSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteProcessResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHostSecretSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -5524,17 +5539,15 @@ func (client AppsClient) DeleteProcessResponder(resp *http.Response) (result aut
return
}
-// DeleteProcessSlot terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
-// instance in a web site.
+// DeleteHybridConnection removes a Hybrid Connection from this site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) DeleteProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result autorest.Response, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+func (client AppsClient) DeleteHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteProcessSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHybridConnection")
defer func() {
sc := -1
if result.Response != nil {
@@ -5548,37 +5561,37 @@ func (client AppsClient) DeleteProcessSlot(ctx context.Context, resourceGroupNam
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteProcessSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHybridConnection", err.Error())
}
- req, err := client.DeleteProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot)
+ req, err := client.DeleteHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteProcessSlotSender(req)
+ resp, err := client.DeleteHybridConnectionSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", resp, "Failure sending request")
return
}
- result, err = client.DeleteProcessSlotResponder(resp)
+ result, err = client.DeleteHybridConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnection", resp, "Failure responding to request")
}
return
}
-// DeleteProcessSlotPreparer prepares the DeleteProcessSlot request.
-func (client AppsClient) DeleteProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
+// DeleteHybridConnectionPreparer prepares the DeleteHybridConnection request.
+func (client AppsClient) DeleteHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5590,38 +5603,40 @@ func (client AppsClient) DeleteProcessSlotPreparer(ctx context.Context, resource
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteProcessSlotSender sends the DeleteProcessSlot request. The method will close the
+// DeleteHybridConnectionSender sends the DeleteHybridConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteProcessSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHybridConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteProcessSlotResponder handles the response to the DeleteProcessSlot request. The method always
+// DeleteHybridConnectionResponder handles the response to the DeleteHybridConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteProcessSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHybridConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeletePublicCertificate deletes a hostname binding for an app.
+// DeleteHybridConnectionSlot removes a Hybrid Connection from this site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// publicCertificateName - public certificate name.
-func (client AppsClient) DeletePublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (result autorest.Response, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+// slot - the name of the slot for the web app.
+func (client AppsClient) DeleteHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePublicCertificate")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteHybridConnectionSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5635,37 +5650,39 @@ func (client AppsClient) DeletePublicCertificate(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeletePublicCertificate", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteHybridConnectionSlot", err.Error())
}
- req, err := client.DeletePublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName)
+ req, err := client.DeleteHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeletePublicCertificateSender(req)
+ resp, err := client.DeleteHybridConnectionSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.DeletePublicCertificateResponder(resp)
+ result, err = client.DeleteHybridConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteHybridConnectionSlot", resp, "Failure responding to request")
}
return
}
-// DeletePublicCertificatePreparer prepares the DeletePublicCertificate request.
-func (client AppsClient) DeletePublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (*http.Request, error) {
+// DeleteHybridConnectionSlotPreparer prepares the DeleteHybridConnectionSlot request.
+func (client AppsClient) DeleteHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -5676,40 +5693,39 @@ func (client AppsClient) DeletePublicCertificatePreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeletePublicCertificateSender sends the DeletePublicCertificate request. The method will close the
+// DeleteHybridConnectionSlotSender sends the DeleteHybridConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeletePublicCertificateSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeletePublicCertificateResponder handles the response to the DeletePublicCertificate request. The method always
+// DeleteHybridConnectionSlotResponder handles the response to the DeleteHybridConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeletePublicCertificateResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteHybridConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeletePublicCertificateSlot deletes a hostname binding for an app.
+// DeleteInstanceFunctionSlot delete a function for web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
-// production slot.
-// publicCertificateName - public certificate name.
-func (client AppsClient) DeletePublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (result autorest.Response, err error) {
+// name - site name.
+// functionName - function name.
+// slot - name of the deployment slot.
+func (client AppsClient) DeleteInstanceFunctionSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePublicCertificateSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceFunctionSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5723,38 +5739,38 @@ func (client AppsClient) DeletePublicCertificateSlot(ctx context.Context, resour
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeletePublicCertificateSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteInstanceFunctionSlot", err.Error())
}
- req, err := client.DeletePublicCertificateSlotPreparer(ctx, resourceGroupName, name, slot, publicCertificateName)
+ req, err := client.DeleteInstanceFunctionSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeletePublicCertificateSlotSender(req)
+ resp, err := client.DeleteInstanceFunctionSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", resp, "Failure sending request")
return
}
- result, err = client.DeletePublicCertificateSlotResponder(resp)
+ result, err = client.DeleteInstanceFunctionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceFunctionSlot", resp, "Failure responding to request")
}
return
}
-// DeletePublicCertificateSlotPreparer prepares the DeletePublicCertificateSlot request.
-func (client AppsClient) DeletePublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (*http.Request, error) {
+// DeleteInstanceFunctionSlotPreparer prepares the DeleteInstanceFunctionSlot request.
+func (client AppsClient) DeleteInstanceFunctionSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "functionName": autorest.Encode("path", functionName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -5765,38 +5781,41 @@ func (client AppsClient) DeletePublicCertificateSlotPreparer(ctx context.Context
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeletePublicCertificateSlotSender sends the DeletePublicCertificateSlot request. The method will close the
+// DeleteInstanceFunctionSlotSender sends the DeleteInstanceFunctionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeletePublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteInstanceFunctionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeletePublicCertificateSlotResponder handles the response to the DeletePublicCertificateSlot request. The method always
+// DeleteInstanceFunctionSlotResponder handles the response to the DeleteInstanceFunctionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeletePublicCertificateSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteInstanceFunctionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteRelayServiceConnection deletes a relay service connection by its name.
+// DeleteInstanceProcess terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
+// instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection configuration.
-func (client AppsClient) DeleteRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string) (result autorest.Response, err error) {
+// name - site name.
+// processID - pID.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) DeleteInstanceProcess(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteRelayServiceConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceProcess")
defer func() {
sc := -1
if result.Response != nil {
@@ -5810,35 +5829,36 @@ func (client AppsClient) DeleteRelayServiceConnection(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteRelayServiceConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteInstanceProcess", err.Error())
}
- req, err := client.DeleteRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName)
+ req, err := client.DeleteInstanceProcessPreparer(ctx, resourceGroupName, name, processID, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteRelayServiceConnectionSender(req)
+ resp, err := client.DeleteInstanceProcessSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", resp, "Failure sending request")
return
}
- result, err = client.DeleteRelayServiceConnectionResponder(resp)
+ result, err = client.DeleteInstanceProcessResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcess", resp, "Failure responding to request")
}
return
}
-// DeleteRelayServiceConnectionPreparer prepares the DeleteRelayServiceConnection request.
-func (client AppsClient) DeleteRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string) (*http.Request, error) {
+// DeleteInstanceProcessPreparer prepares the DeleteInstanceProcess request.
+func (client AppsClient) DeleteInstanceProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -5851,40 +5871,43 @@ func (client AppsClient) DeleteRelayServiceConnectionPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteRelayServiceConnectionSender sends the DeleteRelayServiceConnection request. The method will close the
+// DeleteInstanceProcessSender sends the DeleteInstanceProcess request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteInstanceProcessSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteRelayServiceConnectionResponder handles the response to the DeleteRelayServiceConnection request. The method always
+// DeleteInstanceProcessResponder handles the response to the DeleteInstanceProcess request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteRelayServiceConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteInstanceProcessResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteRelayServiceConnectionSlot deletes a relay service connection by its name.
+// DeleteInstanceProcessSlot terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
+// instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection configuration.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete a hybrid connection for
-// the production slot.
-func (client AppsClient) DeleteRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (result autorest.Response, err error) {
+// name - site name.
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) DeleteInstanceProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteRelayServiceConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteInstanceProcessSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -5898,35 +5921,36 @@ func (client AppsClient) DeleteRelayServiceConnectionSlot(ctx context.Context, r
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteRelayServiceConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteInstanceProcessSlot", err.Error())
}
- req, err := client.DeleteRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, slot)
+ req, err := client.DeleteInstanceProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteRelayServiceConnectionSlotSender(req)
+ resp, err := client.DeleteInstanceProcessSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteRelayServiceConnectionSlotResponder(resp)
+ result, err = client.DeleteInstanceProcessSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteInstanceProcessSlot", resp, "Failure responding to request")
}
return
}
-// DeleteRelayServiceConnectionSlotPreparer prepares the DeleteRelayServiceConnectionSlot request.
-func (client AppsClient) DeleteRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (*http.Request, error) {
+// DeleteInstanceProcessSlotPreparer prepares the DeleteInstanceProcessSlot request.
+func (client AppsClient) DeleteInstanceProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -5940,38 +5964,38 @@ func (client AppsClient) DeleteRelayServiceConnectionSlotPreparer(ctx context.Co
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteRelayServiceConnectionSlotSender sends the DeleteRelayServiceConnectionSlot request. The method will close the
+// DeleteInstanceProcessSlotSender sends the DeleteInstanceProcessSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteInstanceProcessSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteRelayServiceConnectionSlotResponder handles the response to the DeleteRelayServiceConnectionSlot request. The method always
+// DeleteInstanceProcessSlotResponder handles the response to the DeleteInstanceProcessSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteRelayServiceConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteInstanceProcessSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSiteExtension remove a site extension from a web site, or a deployment slot.
+// DeletePremierAddOn delete a premier add-on from an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// siteExtensionID - site extension name.
-func (client AppsClient) DeleteSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result autorest.Response, err error) {
+// name - name of the app.
+// premierAddOnName - add-on name.
+func (client AppsClient) DeletePremierAddOn(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSiteExtension")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePremierAddOn")
defer func() {
sc := -1
if result.Response != nil {
@@ -5985,36 +6009,36 @@ func (client AppsClient) DeleteSiteExtension(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSiteExtension", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeletePremierAddOn", err.Error())
}
- req, err := client.DeleteSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
+ req, err := client.DeletePremierAddOnPreparer(ctx, resourceGroupName, name, premierAddOnName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSiteExtensionSender(req)
+ resp, err := client.DeletePremierAddOnSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", resp, "Failure sending request")
return
}
- result, err = client.DeleteSiteExtensionResponder(resp)
+ result, err = client.DeletePremierAddOnResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOn", resp, "Failure responding to request")
}
return
}
-// DeleteSiteExtensionPreparer prepares the DeleteSiteExtension request.
-func (client AppsClient) DeleteSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
+// DeletePremierAddOnPreparer prepares the DeletePremierAddOn request.
+func (client AppsClient) DeletePremierAddOnPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -6026,40 +6050,40 @@ func (client AppsClient) DeleteSiteExtensionPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSiteExtensionSender sends the DeleteSiteExtension request. The method will close the
+// DeletePremierAddOnSender sends the DeletePremierAddOn request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSiteExtensionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeletePremierAddOnSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSiteExtensionResponder handles the response to the DeleteSiteExtension request. The method always
+// DeletePremierAddOnResponder handles the response to the DeletePremierAddOn request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSiteExtensionResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeletePremierAddOnResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSiteExtensionSlot remove a site extension from a web site, or a deployment slot.
+// DeletePremierAddOnSlot delete a premier add-on from an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// siteExtensionID - site extension name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// name - name of the app.
+// premierAddOnName - add-on name.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the named add-on for the
// production slot.
-func (client AppsClient) DeleteSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result autorest.Response, err error) {
+func (client AppsClient) DeletePremierAddOnSlot(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSiteExtensionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePremierAddOnSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6073,36 +6097,36 @@ func (client AppsClient) DeleteSiteExtensionSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSiteExtensionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeletePremierAddOnSlot", err.Error())
}
- req, err := client.DeleteSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
+ req, err := client.DeletePremierAddOnSlotPreparer(ctx, resourceGroupName, name, premierAddOnName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSiteExtensionSlotSender(req)
+ resp, err := client.DeletePremierAddOnSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteSiteExtensionSlotResponder(resp)
+ result, err = client.DeletePremierAddOnSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePremierAddOnSlot", resp, "Failure responding to request")
}
return
}
-// DeleteSiteExtensionSlotPreparer prepares the DeleteSiteExtensionSlot request.
-func (client AppsClient) DeleteSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
+// DeletePremierAddOnSlotPreparer prepares the DeletePremierAddOnSlot request.
+func (client AppsClient) DeletePremierAddOnSlotPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -6115,41 +6139,39 @@ func (client AppsClient) DeleteSiteExtensionSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSiteExtensionSlotSender sends the DeleteSiteExtensionSlot request. The method will close the
+// DeletePremierAddOnSlotSender sends the DeletePremierAddOnSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSiteExtensionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeletePremierAddOnSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSiteExtensionSlotResponder handles the response to the DeleteSiteExtensionSlot request. The method always
+// DeletePremierAddOnSlotResponder handles the response to the DeletePremierAddOnSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSiteExtensionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeletePremierAddOnSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSlot deletes a web, mobile, or API app, or one of the deployment slots.
+// DeleteProcess terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out instance in
+// a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app to delete.
-// slot - name of the deployment slot to delete. By default, the API deletes the production slot.
-// deleteMetrics - if true, web app metrics are also deleted.
-// deleteEmptyServerFarm - specify true if the App Service plan will be empty after app deletion and you want
-// to delete the empty App Service plan. By default, the empty App Service plan is not deleted.
-func (client AppsClient) DeleteSlot(ctx context.Context, resourceGroupName string, name string, slot string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (result autorest.Response, err error) {
+// name - site name.
+// processID - pID.
+func (client AppsClient) DeleteProcess(ctx context.Context, resourceGroupName string, name string, processID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteProcess")
defer func() {
sc := -1
if result.Response != nil {
@@ -6163,36 +6185,36 @@ func (client AppsClient) DeleteSlot(ctx context.Context, resourceGroupName strin
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteProcess", err.Error())
}
- req, err := client.DeleteSlotPreparer(ctx, resourceGroupName, name, slot, deleteMetrics, deleteEmptyServerFarm)
+ req, err := client.DeleteProcessPreparer(ctx, resourceGroupName, name, processID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSlotSender(req)
+ resp, err := client.DeleteProcessSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", resp, "Failure sending request")
return
}
- result, err = client.DeleteSlotResponder(resp)
+ result, err = client.DeleteProcessResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcess", resp, "Failure responding to request")
}
return
}
-// DeleteSlotPreparer prepares the DeleteSlot request.
-func (client AppsClient) DeleteSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (*http.Request, error) {
+// DeleteProcessPreparer prepares the DeleteProcess request.
+func (client AppsClient) DeleteProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -6200,31 +6222,25 @@ func (client AppsClient) DeleteSlotPreparer(ctx context.Context, resourceGroupNa
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
- if deleteMetrics != nil {
- queryParameters["deleteMetrics"] = autorest.Encode("query", *deleteMetrics)
- }
- if deleteEmptyServerFarm != nil {
- queryParameters["deleteEmptyServerFarm"] = autorest.Encode("query", *deleteEmptyServerFarm)
- }
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSlotSender sends the DeleteSlot request. The method will close the
+// DeleteProcessSender sends the DeleteProcess request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteProcessSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSlotResponder handles the response to the DeleteSlot request. The method always
+// DeleteProcessResponder handles the response to the DeleteProcess request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteProcessResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -6234,13 +6250,17 @@ func (client AppsClient) DeleteSlotResponder(resp *http.Response) (result autore
return
}
-// DeleteSourceControl deletes the source control configuration of an app.
+// DeleteProcessSlot terminate a process by its ID for a web site, or a deployment slot, or specific scaled-out
+// instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) DeleteSourceControl(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
+// name - site name.
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) DeleteProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSourceControl")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteProcessSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6254,35 +6274,37 @@ func (client AppsClient) DeleteSourceControl(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSourceControl", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteProcessSlot", err.Error())
}
- req, err := client.DeleteSourceControlPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeleteProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSourceControlSender(req)
+ resp, err := client.DeleteProcessSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteSourceControlResponder(resp)
+ result, err = client.DeleteProcessSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteProcessSlot", resp, "Failure responding to request")
}
return
}
-// DeleteSourceControlPreparer prepares the DeleteSourceControl request.
-func (client AppsClient) DeleteSourceControlPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeleteProcessSlotPreparer prepares the DeleteProcessSlot request.
+func (client AppsClient) DeleteProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -6294,39 +6316,38 @@ func (client AppsClient) DeleteSourceControlPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSourceControlSender sends the DeleteSourceControl request. The method will close the
+// DeleteProcessSlotSender sends the DeleteProcessSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSourceControlSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteProcessSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSourceControlResponder handles the response to the DeleteSourceControl request. The method always
+// DeleteProcessSlotResponder handles the response to the DeleteProcessSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSourceControlResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteProcessSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSourceControlSlot deletes the source control configuration of an app.
+// DeletePublicCertificate deletes a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the source control
-// configuration for the production slot.
-func (client AppsClient) DeleteSourceControlSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
+// publicCertificateName - public certificate name.
+func (client AppsClient) DeletePublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSourceControlSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePublicCertificate")
defer func() {
sc := -1
if result.Response != nil {
@@ -6340,37 +6361,37 @@ func (client AppsClient) DeleteSourceControlSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSourceControlSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeletePublicCertificate", err.Error())
}
- req, err := client.DeleteSourceControlSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.DeletePublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSourceControlSlotSender(req)
+ resp, err := client.DeletePublicCertificateSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", resp, "Failure sending request")
return
}
- result, err = client.DeleteSourceControlSlotResponder(resp)
+ result, err = client.DeletePublicCertificateResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificate", resp, "Failure responding to request")
}
return
}
-// DeleteSourceControlSlotPreparer prepares the DeleteSourceControlSlot request.
-func (client AppsClient) DeleteSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// DeletePublicCertificatePreparer prepares the DeletePublicCertificate request.
+func (client AppsClient) DeletePublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -6381,37 +6402,40 @@ func (client AppsClient) DeleteSourceControlSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSourceControlSlotSender sends the DeleteSourceControlSlot request. The method will close the
+// DeletePublicCertificateSender sends the DeletePublicCertificate request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSourceControlSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeletePublicCertificateSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSourceControlSlotResponder handles the response to the DeleteSourceControlSlot request. The method always
+// DeletePublicCertificateResponder handles the response to the DeletePublicCertificate request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSourceControlSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeletePublicCertificateResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSwiftVirtualNetwork deletes a Swift Virtual Network connection from an app (or deployment slot).
+// DeletePublicCertificateSlot deletes a hostname binding for an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) DeleteSwiftVirtualNetwork(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
+// production slot.
+// publicCertificateName - public certificate name.
+func (client AppsClient) DeletePublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSwiftVirtualNetwork")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeletePublicCertificateSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6425,36 +6449,38 @@ func (client AppsClient) DeleteSwiftVirtualNetwork(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSwiftVirtualNetwork", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeletePublicCertificateSlot", err.Error())
}
- req, err := client.DeleteSwiftVirtualNetworkPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeletePublicCertificateSlotPreparer(ctx, resourceGroupName, name, slot, publicCertificateName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSwiftVirtualNetworkSender(req)
+ resp, err := client.DeletePublicCertificateSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteSwiftVirtualNetworkResponder(resp)
+ result, err = client.DeletePublicCertificateSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeletePublicCertificateSlot", resp, "Failure responding to request")
}
return
}
-// DeleteSwiftVirtualNetworkPreparer prepares the DeleteSwiftVirtualNetwork request.
-func (client AppsClient) DeleteSwiftVirtualNetworkPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeletePublicCertificateSlotPreparer prepares the DeletePublicCertificateSlot request.
+func (client AppsClient) DeletePublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -6465,39 +6491,38 @@ func (client AppsClient) DeleteSwiftVirtualNetworkPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSwiftVirtualNetworkSender sends the DeleteSwiftVirtualNetwork request. The method will close the
+// DeletePublicCertificateSlotSender sends the DeletePublicCertificateSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSwiftVirtualNetworkSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeletePublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSwiftVirtualNetworkResponder handles the response to the DeleteSwiftVirtualNetwork request. The method always
+// DeletePublicCertificateSlotResponder handles the response to the DeletePublicCertificateSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSwiftVirtualNetworkResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeletePublicCertificateSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteSwiftVirtualNetworkSlot deletes a Swift Virtual Network connection from an app (or deployment slot).
+// DeleteRelayServiceConnection deletes a relay service connection by its name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the connection for the
-// production slot.
-func (client AppsClient) DeleteSwiftVirtualNetworkSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
+// entityName - name of the hybrid connection configuration.
+func (client AppsClient) DeleteRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSwiftVirtualNetworkSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteRelayServiceConnection")
defer func() {
sc := -1
if result.Response != nil {
@@ -6511,36 +6536,36 @@ func (client AppsClient) DeleteSwiftVirtualNetworkSlot(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteSwiftVirtualNetworkSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteRelayServiceConnection", err.Error())
}
- req, err := client.DeleteSwiftVirtualNetworkSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.DeleteRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteSwiftVirtualNetworkSlotSender(req)
+ resp, err := client.DeleteRelayServiceConnectionSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", resp, "Failure sending request")
return
}
- result, err = client.DeleteSwiftVirtualNetworkSlotResponder(resp)
+ result, err = client.DeleteRelayServiceConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnection", resp, "Failure responding to request")
}
return
}
-// DeleteSwiftVirtualNetworkSlotPreparer prepares the DeleteSwiftVirtualNetworkSlot request.
-func (client AppsClient) DeleteSwiftVirtualNetworkSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// DeleteRelayServiceConnectionPreparer prepares the DeleteRelayServiceConnection request.
+func (client AppsClient) DeleteRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -6552,21 +6577,21 @@ func (client AppsClient) DeleteSwiftVirtualNetworkSlotPreparer(ctx context.Conte
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteSwiftVirtualNetworkSlotSender sends the DeleteSwiftVirtualNetworkSlot request. The method will close the
+// DeleteRelayServiceConnectionSender sends the DeleteRelayServiceConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteSwiftVirtualNetworkSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteSwiftVirtualNetworkSlotResponder handles the response to the DeleteSwiftVirtualNetworkSlot request. The method always
+// DeleteRelayServiceConnectionResponder handles the response to the DeleteRelayServiceConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteSwiftVirtualNetworkSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteRelayServiceConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -6576,14 +6601,16 @@ func (client AppsClient) DeleteSwiftVirtualNetworkSlotResponder(resp *http.Respo
return
}
-// DeleteTriggeredWebJob delete a triggered web job by its ID for an app, or a deployment slot.
+// DeleteRelayServiceConnectionSlot deletes a relay service connection by its name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-func (client AppsClient) DeleteTriggeredWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result autorest.Response, err error) {
+// name - name of the app.
+// entityName - name of the hybrid connection configuration.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete a hybrid connection for
+// the production slot.
+func (client AppsClient) DeleteRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteTriggeredWebJob")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteRelayServiceConnectionSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6597,37 +6624,38 @@ func (client AppsClient) DeleteTriggeredWebJob(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteTriggeredWebJob", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteRelayServiceConnectionSlot", err.Error())
}
- req, err := client.DeleteTriggeredWebJobPreparer(ctx, resourceGroupName, name, webJobName)
+ req, err := client.DeleteRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteTriggeredWebJobSender(req)
+ resp, err := client.DeleteRelayServiceConnectionSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteTriggeredWebJobResponder(resp)
+ result, err = client.DeleteRelayServiceConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteRelayServiceConnectionSlot", resp, "Failure responding to request")
}
return
}
-// DeleteTriggeredWebJobPreparer prepares the DeleteTriggeredWebJob request.
-func (client AppsClient) DeleteTriggeredWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
+// DeleteRelayServiceConnectionSlotPreparer prepares the DeleteRelayServiceConnectionSlot request.
+func (client AppsClient) DeleteRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -6638,40 +6666,38 @@ func (client AppsClient) DeleteTriggeredWebJobPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteTriggeredWebJobSender sends the DeleteTriggeredWebJob request. The method will close the
+// DeleteRelayServiceConnectionSlotSender sends the DeleteRelayServiceConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteTriggeredWebJobSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteTriggeredWebJobResponder handles the response to the DeleteTriggeredWebJob request. The method always
+// DeleteRelayServiceConnectionSlotResponder handles the response to the DeleteRelayServiceConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteTriggeredWebJobResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteRelayServiceConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteTriggeredWebJobSlot delete a triggered web job by its ID for an app, or a deployment slot.
+// DeleteSiteExtension remove a site extension from a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// webJobName - name of Web Job.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) DeleteTriggeredWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result autorest.Response, err error) {
+// siteExtensionID - site extension name.
+func (client AppsClient) DeleteSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteTriggeredWebJobSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSiteExtension")
defer func() {
sc := -1
if result.Response != nil {
@@ -6685,38 +6711,37 @@ func (client AppsClient) DeleteTriggeredWebJobSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteTriggeredWebJobSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteSiteExtension", err.Error())
}
- req, err := client.DeleteTriggeredWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
+ req, err := client.DeleteSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteTriggeredWebJobSlotSender(req)
+ resp, err := client.DeleteSiteExtensionSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", resp, "Failure sending request")
return
}
- result, err = client.DeleteTriggeredWebJobSlotResponder(resp)
+ result, err = client.DeleteSiteExtensionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtension", resp, "Failure responding to request")
}
return
}
-// DeleteTriggeredWebJobSlotPreparer prepares the DeleteTriggeredWebJobSlot request.
-func (client AppsClient) DeleteTriggeredWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
+// DeleteSiteExtensionPreparer prepares the DeleteSiteExtension request.
+func (client AppsClient) DeleteSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -6727,38 +6752,40 @@ func (client AppsClient) DeleteTriggeredWebJobSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteTriggeredWebJobSlotSender sends the DeleteTriggeredWebJobSlot request. The method will close the
+// DeleteSiteExtensionSender sends the DeleteSiteExtension request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteTriggeredWebJobSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSiteExtensionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteTriggeredWebJobSlotResponder handles the response to the DeleteTriggeredWebJobSlot request. The method always
+// DeleteSiteExtensionResponder handles the response to the DeleteSiteExtension request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteTriggeredWebJobSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSiteExtensionResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteVnetConnection deletes a connection from an app (or deployment slot to a named virtual network.
+// DeleteSiteExtensionSlot remove a site extension from a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// vnetName - name of the virtual network.
-func (client AppsClient) DeleteVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string) (result autorest.Response, err error) {
+// name - site name.
+// siteExtensionID - site extension name.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) DeleteSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteVnetConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSiteExtensionSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6772,37 +6799,38 @@ func (client AppsClient) DeleteVnetConnection(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteVnetConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteSiteExtensionSlot", err.Error())
}
- req, err := client.DeleteVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName)
+ req, err := client.DeleteSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteVnetConnectionSender(req)
+ resp, err := client.DeleteSiteExtensionSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteVnetConnectionResponder(resp)
+ result, err = client.DeleteSiteExtensionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSiteExtensionSlot", resp, "Failure responding to request")
}
return
}
-// DeleteVnetConnectionPreparer prepares the DeleteVnetConnection request.
-func (client AppsClient) DeleteVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string) (*http.Request, error) {
+// DeleteSiteExtensionSlotPreparer prepares the DeleteSiteExtensionSlot request.
+func (client AppsClient) DeleteSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -6813,40 +6841,41 @@ func (client AppsClient) DeleteVnetConnectionPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteVnetConnectionSender sends the DeleteVnetConnection request. The method will close the
+// DeleteSiteExtensionSlotSender sends the DeleteSiteExtensionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteVnetConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSiteExtensionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteVnetConnectionResponder handles the response to the DeleteVnetConnection request. The method always
+// DeleteSiteExtensionSlotResponder handles the response to the DeleteSiteExtensionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteVnetConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSiteExtensionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DeleteVnetConnectionSlot deletes a connection from an app (or deployment slot to a named virtual network.
+// DeleteSlot deletes a web, mobile, or API app, or one of the deployment slots.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// vnetName - name of the virtual network.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the connection for the
-// production slot.
-func (client AppsClient) DeleteVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (result autorest.Response, err error) {
+// name - name of the app to delete.
+// slot - name of the deployment slot to delete. By default, the API deletes the production slot.
+// deleteMetrics - if true, web app metrics are also deleted.
+// deleteEmptyServerFarm - specify true if the App Service plan will be empty after app deletion and you want
+// to delete the empty App Service plan. By default, the empty App Service plan is not deleted.
+func (client AppsClient) DeleteSlot(ctx context.Context, resourceGroupName string, name string, slot string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteVnetConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -6860,85 +6889,88 @@ func (client AppsClient) DeleteVnetConnectionSlot(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DeleteVnetConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteSlot", err.Error())
}
- req, err := client.DeleteVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, slot)
+ req, err := client.DeleteSlotPreparer(ctx, resourceGroupName, name, slot, deleteMetrics, deleteEmptyServerFarm)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DeleteVnetConnectionSlotSender(req)
+ resp, err := client.DeleteSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", resp, "Failure sending request")
return
}
- result, err = client.DeleteVnetConnectionSlotResponder(resp)
+ result, err = client.DeleteSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSlot", resp, "Failure responding to request")
}
return
}
-// DeleteVnetConnectionSlotPreparer prepares the DeleteVnetConnectionSlot request.
-func (client AppsClient) DeleteVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (*http.Request, error) {
+// DeleteSlotPreparer prepares the DeleteSlot request.
+func (client AppsClient) DeleteSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, deleteMetrics *bool, deleteEmptyServerFarm *bool) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
+ if deleteMetrics != nil {
+ queryParameters["deleteMetrics"] = autorest.Encode("query", *deleteMetrics)
+ }
+ if deleteEmptyServerFarm != nil {
+ queryParameters["deleteEmptyServerFarm"] = autorest.Encode("query", *deleteEmptyServerFarm)
+ }
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DeleteVnetConnectionSlotSender sends the DeleteVnetConnectionSlot request. The method will close the
+// DeleteSlotSender sends the DeleteSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DeleteVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DeleteVnetConnectionSlotResponder handles the response to the DeleteVnetConnectionSlot request. The method always
+// DeleteSlotResponder handles the response to the DeleteSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DeleteVnetConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// DiscoverBackup discovers an existing app backup that can be restored from a blob in Azure storage. Use this to get
-// information about the databases stored in a backup.
+// DeleteSourceControl deletes the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// request - a RestoreRequest object that includes Azure storage URL and blog name for discovery of backup.
-func (client AppsClient) DiscoverBackup(ctx context.Context, resourceGroupName string, name string, request RestoreRequest) (result RestoreRequest, err error) {
+func (client AppsClient) DeleteSourceControl(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DiscoverBackup")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSourceControl")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -6947,38 +6979,33 @@ func (client AppsClient) DiscoverBackup(ctx context.Context, resourceGroupName s
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: request,
- Constraints: []validation.Constraint{{Target: "request.RestoreRequestProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.RestoreRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.RestoreRequestProperties.Overwrite", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DiscoverBackup", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "DeleteSourceControl", err.Error())
}
- req, err := client.DiscoverBackupPreparer(ctx, resourceGroupName, name, request)
+ req, err := client.DeleteSourceControlPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", nil, "Failure preparing request")
return
}
- resp, err := client.DiscoverBackupSender(req)
+ resp, err := client.DeleteSourceControlSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", resp, "Failure sending request")
return
}
- result, err = client.DiscoverBackupResponder(resp)
+ result, err = client.DeleteSourceControlResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControl", resp, "Failure responding to request")
}
return
}
-// DiscoverBackupPreparer prepares the DiscoverBackup request.
-func (client AppsClient) DiscoverBackupPreparer(ctx context.Context, resourceGroupName string, name string, request RestoreRequest) (*http.Request, error) {
+// DeleteSourceControlPreparer prepares the DeleteSourceControl request.
+func (client AppsClient) DeleteSourceControlPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -6991,50 +7018,45 @@ func (client AppsClient) DiscoverBackupPreparer(ctx context.Context, resourceGro
}
preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/discoverbackup", pathParameters),
- autorest.WithJSON(request),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DiscoverBackupSender sends the DiscoverBackup request. The method will close the
+// DeleteSourceControlSender sends the DeleteSourceControl request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DiscoverBackupSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSourceControlSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DiscoverBackupResponder handles the response to the DiscoverBackup request. The method always
+// DeleteSourceControlResponder handles the response to the DeleteSourceControl request. The method always
// closes the http.Response Body.
-func (client AppsClient) DiscoverBackupResponder(resp *http.Response) (result RestoreRequest, err error) {
+func (client AppsClient) DeleteSourceControlResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNotFound),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// DiscoverBackupSlot discovers an existing app backup that can be restored from a blob in Azure storage. Use this to
-// get information about the databases stored in a backup.
+// DeleteSourceControlSlot deletes the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// request - a RestoreRequest object that includes Azure storage URL and blog name for discovery of backup.
-// slot - name of the deployment slot. If a slot is not specified, the API will perform discovery for the
-// production slot.
-func (client AppsClient) DiscoverBackupSlot(ctx context.Context, resourceGroupName string, name string, request RestoreRequest, slot string) (result RestoreRequest, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the source control
+// configuration for the production slot.
+func (client AppsClient) DeleteSourceControlSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DiscoverBackupSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSourceControlSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7043,38 +7065,33 @@ func (client AppsClient) DiscoverBackupSlot(ctx context.Context, resourceGroupNa
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: request,
- Constraints: []validation.Constraint{{Target: "request.RestoreRequestProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.RestoreRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.RestoreRequestProperties.Overwrite", Name: validation.Null, Rule: true, Chain: nil},
- }}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "DiscoverBackupSlot", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "DeleteSourceControlSlot", err.Error())
}
- req, err := client.DiscoverBackupSlotPreparer(ctx, resourceGroupName, name, request, slot)
+ req, err := client.DeleteSourceControlSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", nil, "Failure preparing request")
return
}
- resp, err := client.DiscoverBackupSlotSender(req)
+ resp, err := client.DeleteSourceControlSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", resp, "Failure sending request")
return
}
- result, err = client.DiscoverBackupSlotResponder(resp)
+ result, err = client.DeleteSourceControlSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSourceControlSlot", resp, "Failure responding to request")
}
return
}
-// DiscoverBackupSlotPreparer prepares the DiscoverBackupSlot request.
-func (client AppsClient) DiscoverBackupSlotPreparer(ctx context.Context, resourceGroupName string, name string, request RestoreRequest, slot string) (*http.Request, error) {
+// DeleteSourceControlSlotPreparer prepares the DeleteSourceControlSlot request.
+func (client AppsClient) DeleteSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -7088,42 +7105,39 @@ func (client AppsClient) DiscoverBackupSlotPreparer(ctx context.Context, resourc
}
preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/discoverbackup", pathParameters),
- autorest.WithJSON(request),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// DiscoverBackupSlotSender sends the DiscoverBackupSlot request. The method will close the
+// DeleteSourceControlSlotSender sends the DeleteSourceControlSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) DiscoverBackupSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSourceControlSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// DiscoverBackupSlotResponder handles the response to the DiscoverBackupSlot request. The method always
+// DeleteSourceControlSlotResponder handles the response to the DeleteSourceControlSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) DiscoverBackupSlotResponder(resp *http.Response) (result RestoreRequest, err error) {
+func (client AppsClient) DeleteSourceControlSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNotFound),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GenerateNewSitePublishingPassword generates a new publishing password for an app (or deployment slot, if specified).
+// DeleteSwiftVirtualNetwork deletes a Swift Virtual Network connection from an app (or deployment slot).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GenerateNewSitePublishingPassword(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSwiftVirtualNetwork(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GenerateNewSitePublishingPassword")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSwiftVirtualNetwork")
defer func() {
sc := -1
if result.Response != nil {
@@ -7137,32 +7151,32 @@ func (client AppsClient) GenerateNewSitePublishingPassword(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GenerateNewSitePublishingPassword", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteSwiftVirtualNetwork", err.Error())
}
- req, err := client.GenerateNewSitePublishingPasswordPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeleteSwiftVirtualNetworkPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", nil, "Failure preparing request")
return
}
- resp, err := client.GenerateNewSitePublishingPasswordSender(req)
+ resp, err := client.DeleteSwiftVirtualNetworkSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", resp, "Failure sending request")
return
}
- result, err = client.GenerateNewSitePublishingPasswordResponder(resp)
+ result, err = client.DeleteSwiftVirtualNetworkResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetwork", resp, "Failure responding to request")
}
return
}
-// GenerateNewSitePublishingPasswordPreparer prepares the GenerateNewSitePublishingPassword request.
-func (client AppsClient) GenerateNewSitePublishingPasswordPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeleteSwiftVirtualNetworkPreparer prepares the DeleteSwiftVirtualNetwork request.
+func (client AppsClient) DeleteSwiftVirtualNetworkPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -7175,42 +7189,41 @@ func (client AppsClient) GenerateNewSitePublishingPasswordPreparer(ctx context.C
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/newpassword", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GenerateNewSitePublishingPasswordSender sends the GenerateNewSitePublishingPassword request. The method will close the
+// DeleteSwiftVirtualNetworkSender sends the DeleteSwiftVirtualNetwork request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GenerateNewSitePublishingPasswordSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSwiftVirtualNetworkSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GenerateNewSitePublishingPasswordResponder handles the response to the GenerateNewSitePublishingPassword request. The method always
+// DeleteSwiftVirtualNetworkResponder handles the response to the DeleteSwiftVirtualNetwork request. The method always
// closes the http.Response Body.
-func (client AppsClient) GenerateNewSitePublishingPasswordResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSwiftVirtualNetworkResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// GenerateNewSitePublishingPasswordSlot generates a new publishing password for an app (or deployment slot, if
-// specified).
+// DeleteSwiftVirtualNetworkSlot deletes a Swift Virtual Network connection from an app (or deployment slot).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API generate a new publishing password
-// for the production slot.
-func (client AppsClient) GenerateNewSitePublishingPasswordSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the connection for the
+// production slot.
+func (client AppsClient) DeleteSwiftVirtualNetworkSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GenerateNewSitePublishingPasswordSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteSwiftVirtualNetworkSlot")
defer func() {
sc := -1
if result.Response != nil {
@@ -7224,32 +7237,32 @@ func (client AppsClient) GenerateNewSitePublishingPasswordSlot(ctx context.Conte
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GenerateNewSitePublishingPasswordSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteSwiftVirtualNetworkSlot", err.Error())
}
- req, err := client.GenerateNewSitePublishingPasswordSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.DeleteSwiftVirtualNetworkSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GenerateNewSitePublishingPasswordSlotSender(req)
+ resp, err := client.DeleteSwiftVirtualNetworkSlotSender(req)
if err != nil {
result.Response = resp
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", resp, "Failure sending request")
return
}
- result, err = client.GenerateNewSitePublishingPasswordSlotResponder(resp)
+ result, err = client.DeleteSwiftVirtualNetworkSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteSwiftVirtualNetworkSlot", resp, "Failure responding to request")
}
return
}
-// GenerateNewSitePublishingPasswordSlotPreparer prepares the GenerateNewSitePublishingPasswordSlot request.
-func (client AppsClient) GenerateNewSitePublishingPasswordSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// DeleteSwiftVirtualNetworkSlotPreparer prepares the DeleteSwiftVirtualNetworkSlot request.
+func (client AppsClient) DeleteSwiftVirtualNetworkSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -7263,43 +7276,44 @@ func (client AppsClient) GenerateNewSitePublishingPasswordSlotPreparer(ctx conte
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/newpassword", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GenerateNewSitePublishingPasswordSlotSender sends the GenerateNewSitePublishingPasswordSlot request. The method will close the
+// DeleteSwiftVirtualNetworkSlotSender sends the DeleteSwiftVirtualNetworkSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GenerateNewSitePublishingPasswordSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteSwiftVirtualNetworkSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GenerateNewSitePublishingPasswordSlotResponder handles the response to the GenerateNewSitePublishingPasswordSlot request. The method always
+// DeleteSwiftVirtualNetworkSlotResponder handles the response to the DeleteSwiftVirtualNetworkSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GenerateNewSitePublishingPasswordSlotResponder(resp *http.Response) (result autorest.Response, err error) {
+func (client AppsClient) DeleteSwiftVirtualNetworkSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
result.Response = resp
return
}
-// Get gets the details of a web, mobile, or API app.
+// DeleteTriggeredWebJob delete a triggered web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) Get(ctx context.Context, resourceGroupName string, name string) (result Site, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+func (client AppsClient) DeleteTriggeredWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.Get")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteTriggeredWebJob")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7309,36 +7323,37 @@ func (client AppsClient) Get(ctx context.Context, resourceGroupName string, name
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "Get", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteTriggeredWebJob", err.Error())
}
- req, err := client.GetPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeleteTriggeredWebJobPreparer(ctx, resourceGroupName, name, webJobName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", nil, "Failure preparing request")
return
}
- resp, err := client.GetSender(req)
+ resp, err := client.DeleteTriggeredWebJobSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", resp, "Failure sending request")
return
}
- result, err = client.GetResponder(resp)
+ result, err = client.DeleteTriggeredWebJobResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJob", resp, "Failure responding to request")
}
return
}
-// GetPreparer prepares the Get request.
-func (client AppsClient) GetPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeleteTriggeredWebJobPreparer prepares the DeleteTriggeredWebJob request.
+func (client AppsClient) DeleteTriggeredWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -7347,44 +7362,46 @@ func (client AppsClient) GetPreparer(ctx context.Context, resourceGroupName stri
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSender sends the Get request. The method will close the
+// DeleteTriggeredWebJobSender sends the DeleteTriggeredWebJob request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteTriggeredWebJobSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetResponder handles the response to the Get request. The method always
+// DeleteTriggeredWebJobResponder handles the response to the DeleteTriggeredWebJob request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetResponder(resp *http.Response) (result Site, err error) {
+func (client AppsClient) DeleteTriggeredWebJobResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetAuthSettings gets the Authentication/Authorization settings of an app.
+// DeleteTriggeredWebJobSlot delete a triggered web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) GetAuthSettings(ctx context.Context, resourceGroupName string, name string) (result SiteAuthSettings, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) DeleteTriggeredWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetAuthSettings")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteTriggeredWebJobSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7394,36 +7411,38 @@ func (client AppsClient) GetAuthSettings(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetAuthSettings", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteTriggeredWebJobSlot", err.Error())
}
- req, err := client.GetAuthSettingsPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeleteTriggeredWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetAuthSettingsSender(req)
+ resp, err := client.DeleteTriggeredWebJobSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", resp, "Failure sending request")
return
}
- result, err = client.GetAuthSettingsResponder(resp)
+ result, err = client.DeleteTriggeredWebJobSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteTriggeredWebJobSlot", resp, "Failure responding to request")
}
return
}
-// GetAuthSettingsPreparer prepares the GetAuthSettings request.
-func (client AppsClient) GetAuthSettingsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeleteTriggeredWebJobSlotPreparer prepares the DeleteTriggeredWebJobSlot request.
+func (client AppsClient) DeleteTriggeredWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -7432,46 +7451,44 @@ func (client AppsClient) GetAuthSettingsPreparer(ctx context.Context, resourceGr
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/authsettings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetAuthSettingsSender sends the GetAuthSettings request. The method will close the
+// DeleteTriggeredWebJobSlotSender sends the DeleteTriggeredWebJobSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetAuthSettingsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteTriggeredWebJobSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetAuthSettingsResponder handles the response to the GetAuthSettings request. The method always
+// DeleteTriggeredWebJobSlotResponder handles the response to the DeleteTriggeredWebJobSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetAuthSettingsResponder(resp *http.Response) (result SiteAuthSettings, err error) {
+func (client AppsClient) DeleteTriggeredWebJobSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetAuthSettingsSlot gets the Authentication/Authorization settings of an app.
+// DeleteVnetConnection deletes a connection from an app (or deployment slot to a named virtual network.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the settings for the
-// production slot.
-func (client AppsClient) GetAuthSettingsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteAuthSettings, err error) {
+// vnetName - name of the virtual network.
+func (client AppsClient) DeleteVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetAuthSettingsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteVnetConnection")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7481,37 +7498,37 @@ func (client AppsClient) GetAuthSettingsSlot(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetAuthSettingsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteVnetConnection", err.Error())
}
- req, err := client.GetAuthSettingsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.DeleteVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", nil, "Failure preparing request")
return
}
- resp, err := client.GetAuthSettingsSlotSender(req)
+ resp, err := client.DeleteVnetConnectionSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", resp, "Failure sending request")
return
}
- result, err = client.GetAuthSettingsSlotResponder(resp)
+ result, err = client.DeleteVnetConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnection", resp, "Failure responding to request")
}
return
}
-// GetAuthSettingsSlotPreparer prepares the GetAuthSettingsSlot request.
-func (client AppsClient) GetAuthSettingsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// DeleteVnetConnectionPreparer prepares the DeleteVnetConnection request.
+func (client AppsClient) DeleteVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -7520,44 +7537,46 @@ func (client AppsClient) GetAuthSettingsSlotPreparer(ctx context.Context, resour
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetAuthSettingsSlotSender sends the GetAuthSettingsSlot request. The method will close the
+// DeleteVnetConnectionSender sends the DeleteVnetConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetAuthSettingsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteVnetConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetAuthSettingsSlotResponder handles the response to the GetAuthSettingsSlot request. The method always
+// DeleteVnetConnectionResponder handles the response to the DeleteVnetConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetAuthSettingsSlotResponder(resp *http.Response) (result SiteAuthSettings, err error) {
+func (client AppsClient) DeleteVnetConnectionResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetBackupConfiguration gets the backup configuration of an app.
+// DeleteVnetConnectionSlot deletes a connection from an app (or deployment slot to a named virtual network.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GetBackupConfiguration(ctx context.Context, resourceGroupName string, name string) (result BackupRequest, err error) {
+// vnetName - name of the virtual network.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the connection for the
+// production slot.
+func (client AppsClient) DeleteVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupConfiguration")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DeleteVnetConnectionSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7567,36 +7586,38 @@ func (client AppsClient) GetBackupConfiguration(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetBackupConfiguration", err.Error())
+ return result, validation.NewError("web.AppsClient", "DeleteVnetConnectionSlot", err.Error())
}
- req, err := client.GetBackupConfigurationPreparer(ctx, resourceGroupName, name)
+ req, err := client.DeleteVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetBackupConfigurationSender(req)
+ resp, err := client.DeleteVnetConnectionSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetBackupConfigurationResponder(resp)
+ result, err = client.DeleteVnetConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DeleteVnetConnectionSlot", resp, "Failure responding to request")
}
return
}
-// GetBackupConfigurationPreparer prepares the GetBackupConfiguration request.
-func (client AppsClient) GetBackupConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// DeleteVnetConnectionSlotPreparer prepares the DeleteVnetConnectionSlot request.
+func (client AppsClient) DeleteVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -7605,42 +7626,41 @@ func (client AppsClient) GetBackupConfigurationPreparer(ctx context.Context, res
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/backup/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetBackupConfigurationSender sends the GetBackupConfiguration request. The method will close the
+// DeleteVnetConnectionSlotSender sends the DeleteVnetConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetBackupConfigurationSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DeleteVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetBackupConfigurationResponder handles the response to the GetBackupConfiguration request. The method always
+// DeleteVnetConnectionSlotResponder handles the response to the DeleteVnetConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetBackupConfigurationResponder(resp *http.Response) (result BackupRequest, err error) {
+func (client AppsClient) DeleteVnetConnectionSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetBackupConfigurationSlot gets the backup configuration of an app.
+// DiscoverBackup discovers an existing app backup that can be restored from a blob in Azure storage. Use this to get
+// information about the databases stored in a backup.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the backup configuration
-// for the production slot.
-func (client AppsClient) GetBackupConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupRequest, err error) {
+// request - a RestoreRequest object that includes Azure storage URL and blog name for discovery of backup.
+func (client AppsClient) DiscoverBackup(ctx context.Context, resourceGroupName string, name string, request RestoreRequest) (result RestoreRequest, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupConfigurationSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DiscoverBackup")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -7653,37 +7673,41 @@ func (client AppsClient) GetBackupConfigurationSlot(ctx context.Context, resourc
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetBackupConfigurationSlot", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: request,
+ Constraints: []validation.Constraint{{Target: "request.RestoreRequestProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.RestoreRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.RestoreRequestProperties.Overwrite", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "DiscoverBackup", err.Error())
}
- req, err := client.GetBackupConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.DiscoverBackupPreparer(ctx, resourceGroupName, name, request)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", nil, "Failure preparing request")
return
}
- resp, err := client.GetBackupConfigurationSlotSender(req)
+ resp, err := client.DiscoverBackupSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", resp, "Failure sending request")
return
}
- result, err = client.GetBackupConfigurationSlotResponder(resp)
+ result, err = client.DiscoverBackupResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackup", resp, "Failure responding to request")
}
return
}
-// GetBackupConfigurationSlotPreparer prepares the GetBackupConfigurationSlot request.
-func (client AppsClient) GetBackupConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// DiscoverBackupPreparer prepares the DiscoverBackup request.
+func (client AppsClient) DiscoverBackupPreparer(ctx context.Context, resourceGroupName string, name string, request RestoreRequest) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -7693,23 +7717,25 @@ func (client AppsClient) GetBackupConfigurationSlotPreparer(ctx context.Context,
}
preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/discoverbackup", pathParameters),
+ autorest.WithJSON(request),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetBackupConfigurationSlotSender sends the GetBackupConfigurationSlot request. The method will close the
+// DiscoverBackupSender sends the DiscoverBackup request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetBackupConfigurationSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DiscoverBackupSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetBackupConfigurationSlotResponder handles the response to the GetBackupConfigurationSlot request. The method always
+// DiscoverBackupResponder handles the response to the DiscoverBackup request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetBackupConfigurationSlotResponder(resp *http.Response) (result BackupRequest, err error) {
+func (client AppsClient) DiscoverBackupResponder(resp *http.Response) (result RestoreRequest, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -7720,14 +7746,17 @@ func (client AppsClient) GetBackupConfigurationSlotResponder(resp *http.Response
return
}
-// GetBackupStatus gets a backup of an app by its ID.
+// DiscoverBackupSlot discovers an existing app backup that can be restored from a blob in Azure storage. Use this to
+// get information about the databases stored in a backup.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// backupID - ID of the backup.
-func (client AppsClient) GetBackupStatus(ctx context.Context, resourceGroupName string, name string, backupID string) (result BackupItem, err error) {
+// request - a RestoreRequest object that includes Azure storage URL and blog name for discovery of backup.
+// slot - name of the deployment slot. If a slot is not specified, the API will perform discovery for the
+// production slot.
+func (client AppsClient) DiscoverBackupSlot(ctx context.Context, resourceGroupName string, name string, request RestoreRequest, slot string) (result RestoreRequest, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupStatus")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.DiscoverBackupSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -7740,37 +7769,42 @@ func (client AppsClient) GetBackupStatus(ctx context.Context, resourceGroupName
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetBackupStatus", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: request,
+ Constraints: []validation.Constraint{{Target: "request.RestoreRequestProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.RestoreRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.RestoreRequestProperties.Overwrite", Name: validation.Null, Rule: true, Chain: nil},
+ }}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "DiscoverBackupSlot", err.Error())
}
- req, err := client.GetBackupStatusPreparer(ctx, resourceGroupName, name, backupID)
+ req, err := client.DiscoverBackupSlotPreparer(ctx, resourceGroupName, name, request, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetBackupStatusSender(req)
+ resp, err := client.DiscoverBackupSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", resp, "Failure sending request")
return
}
- result, err = client.GetBackupStatusResponder(resp)
+ result, err = client.DiscoverBackupSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "DiscoverBackupSlot", resp, "Failure responding to request")
}
return
}
-// GetBackupStatusPreparer prepares the GetBackupStatus request.
-func (client AppsClient) GetBackupStatusPreparer(ctx context.Context, resourceGroupName string, name string, backupID string) (*http.Request, error) {
+// DiscoverBackupSlotPreparer prepares the DiscoverBackupSlot request.
+func (client AppsClient) DiscoverBackupSlotPreparer(ctx context.Context, resourceGroupName string, name string, request RestoreRequest, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -7780,23 +7814,25 @@ func (client AppsClient) GetBackupStatusPreparer(ctx context.Context, resourceGr
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/discoverbackup", pathParameters),
+ autorest.WithJSON(request),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetBackupStatusSender sends the GetBackupStatus request. The method will close the
+// DiscoverBackupSlotSender sends the DiscoverBackupSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetBackupStatusSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) DiscoverBackupSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetBackupStatusResponder handles the response to the GetBackupStatus request. The method always
+// DiscoverBackupSlotResponder handles the response to the DiscoverBackupSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetBackupStatusResponder(resp *http.Response) (result BackupItem, err error) {
+func (client AppsClient) DiscoverBackupSlotResponder(resp *http.Response) (result RestoreRequest, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -7807,20 +7843,17 @@ func (client AppsClient) GetBackupStatusResponder(resp *http.Response) (result B
return
}
-// GetBackupStatusSlot gets a backup of an app by its ID.
+// GenerateNewSitePublishingPassword generates a new publishing password for an app (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// backupID - ID of the backup.
-// slot - name of the deployment slot. If a slot is not specified, the API will get a backup of the production
-// slot.
-func (client AppsClient) GetBackupStatusSlot(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (result BackupItem, err error) {
+func (client AppsClient) GenerateNewSitePublishingPassword(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupStatusSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GenerateNewSitePublishingPassword")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7830,37 +7863,35 @@ func (client AppsClient) GetBackupStatusSlot(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetBackupStatusSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GenerateNewSitePublishingPassword", err.Error())
}
- req, err := client.GetBackupStatusSlotPreparer(ctx, resourceGroupName, name, backupID, slot)
+ req, err := client.GenerateNewSitePublishingPasswordPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", nil, "Failure preparing request")
return
}
- resp, err := client.GetBackupStatusSlotSender(req)
+ resp, err := client.GenerateNewSitePublishingPasswordSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", resp, "Failure sending request")
return
}
- result, err = client.GetBackupStatusSlotResponder(resp)
+ result, err = client.GenerateNewSitePublishingPasswordResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPassword", resp, "Failure responding to request")
}
return
}
-// GetBackupStatusSlotPreparer prepares the GetBackupStatusSlot request.
-func (client AppsClient) GetBackupStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (*http.Request, error) {
+// GenerateNewSitePublishingPasswordPreparer prepares the GenerateNewSitePublishingPassword request.
+func (client AppsClient) GenerateNewSitePublishingPasswordPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -7870,45 +7901,46 @@ func (client AppsClient) GetBackupStatusSlotPreparer(ctx context.Context, resour
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/newpassword", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetBackupStatusSlotSender sends the GetBackupStatusSlot request. The method will close the
+// GenerateNewSitePublishingPasswordSender sends the GenerateNewSitePublishingPassword request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetBackupStatusSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GenerateNewSitePublishingPasswordSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetBackupStatusSlotResponder handles the response to the GetBackupStatusSlot request. The method always
+// GenerateNewSitePublishingPasswordResponder handles the response to the GenerateNewSitePublishingPassword request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetBackupStatusSlotResponder(resp *http.Response) (result BackupItem, err error) {
+func (client AppsClient) GenerateNewSitePublishingPasswordResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetConfiguration gets the configuration of an app, such as platform version and bitness, default documents, virtual
-// applications, Always On, etc.
+// GenerateNewSitePublishingPasswordSlot generates a new publishing password for an app (or deployment slot, if
+// specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GetConfiguration(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResource, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API generate a new publishing password
+// for the production slot.
+func (client AppsClient) GenerateNewSitePublishingPasswordSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfiguration")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GenerateNewSitePublishingPasswordSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -7918,35 +7950,36 @@ func (client AppsClient) GetConfiguration(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetConfiguration", err.Error())
+ return result, validation.NewError("web.AppsClient", "GenerateNewSitePublishingPasswordSlot", err.Error())
}
- req, err := client.GetConfigurationPreparer(ctx, resourceGroupName, name)
+ req, err := client.GenerateNewSitePublishingPasswordSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetConfigurationSender(req)
+ resp, err := client.GenerateNewSitePublishingPasswordSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", resp, "Failure sending request")
return
}
- result, err = client.GetConfigurationResponder(resp)
+ result, err = client.GenerateNewSitePublishingPasswordSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GenerateNewSitePublishingPasswordSlot", resp, "Failure responding to request")
}
return
}
-// GetConfigurationPreparer prepares the GetConfiguration request.
-func (client AppsClient) GetConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GenerateNewSitePublishingPasswordSlotPreparer prepares the GenerateNewSitePublishingPasswordSlot request.
+func (client AppsClient) GenerateNewSitePublishingPasswordSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -7956,43 +7989,39 @@ func (client AppsClient) GetConfigurationPreparer(ctx context.Context, resourceG
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/newpassword", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetConfigurationSender sends the GetConfiguration request. The method will close the
+// GenerateNewSitePublishingPasswordSlotSender sends the GenerateNewSitePublishingPasswordSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetConfigurationSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GenerateNewSitePublishingPasswordSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetConfigurationResponder handles the response to the GetConfiguration request. The method always
+// GenerateNewSitePublishingPasswordSlotResponder handles the response to the GenerateNewSitePublishingPasswordSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetConfigurationResponder(resp *http.Response) (result SiteConfigResource, err error) {
+func (client AppsClient) GenerateNewSitePublishingPasswordSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// GetConfigurationSlot gets the configuration of an app, such as platform version and bitness, default documents,
-// virtual applications, Always On, etc.
+// Get gets the details of a web, mobile, or API app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
-// production slot.
-func (client AppsClient) GetConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResource, err error) {
+func (client AppsClient) Get(ctx context.Context, resourceGroupName string, name string) (result Site, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.Get")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8006,36 +8035,35 @@ func (client AppsClient) GetConfigurationSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetConfigurationSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "Get", err.Error())
}
- req, err := client.GetConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", nil, "Failure preparing request")
return
}
- resp, err := client.GetConfigurationSlotSender(req)
+ resp, err := client.GetSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", resp, "Failure sending request")
return
}
- result, err = client.GetConfigurationSlotResponder(resp)
+ result, err = client.GetResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "Get", resp, "Failure responding to request")
}
return
}
-// GetConfigurationSlotPreparer prepares the GetConfigurationSlot request.
-func (client AppsClient) GetConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetPreparer prepares the Get request.
+func (client AppsClient) GetPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -8047,39 +8075,38 @@ func (client AppsClient) GetConfigurationSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetConfigurationSlotSender sends the GetConfigurationSlot request. The method will close the
+// GetSender sends the Get request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetConfigurationSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetConfigurationSlotResponder handles the response to the GetConfigurationSlot request. The method always
+// GetResponder handles the response to the Get request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetConfigurationSlotResponder(resp *http.Response) (result SiteConfigResource, err error) {
+func (client AppsClient) GetResponder(resp *http.Response) (result Site, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetConfigurationSnapshot gets a snapshot of the configuration of an app at a previous point in time.
+// GetAuthSettings gets the Authentication/Authorization settings of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// snapshotID - the ID of the snapshot to read.
-func (client AppsClient) GetConfigurationSnapshot(ctx context.Context, resourceGroupName string, name string, snapshotID string) (result SiteConfigResource, err error) {
+func (client AppsClient) GetAuthSettings(ctx context.Context, resourceGroupName string, name string) (result SiteAuthSettings, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSnapshot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetAuthSettings")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8093,36 +8120,35 @@ func (client AppsClient) GetConfigurationSnapshot(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetConfigurationSnapshot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetAuthSettings", err.Error())
}
- req, err := client.GetConfigurationSnapshotPreparer(ctx, resourceGroupName, name, snapshotID)
+ req, err := client.GetAuthSettingsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", nil, "Failure preparing request")
return
}
- resp, err := client.GetConfigurationSnapshotSender(req)
+ resp, err := client.GetAuthSettingsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", resp, "Failure sending request")
return
}
- result, err = client.GetConfigurationSnapshotResponder(resp)
+ result, err = client.GetAuthSettingsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettings", resp, "Failure responding to request")
}
return
}
-// GetConfigurationSnapshotPreparer prepares the GetConfigurationSnapshot request.
-func (client AppsClient) GetConfigurationSnapshotPreparer(ctx context.Context, resourceGroupName string, name string, snapshotID string) (*http.Request, error) {
+// GetAuthSettingsPreparer prepares the GetAuthSettings request.
+func (client AppsClient) GetAuthSettingsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "snapshotId": autorest.Encode("path", snapshotID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -8132,23 +8158,23 @@ func (client AppsClient) GetConfigurationSnapshotPreparer(ctx context.Context, r
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web/snapshots/{snapshotId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/authsettings/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetConfigurationSnapshotSender sends the GetConfigurationSnapshot request. The method will close the
+// GetAuthSettingsSender sends the GetAuthSettings request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetConfigurationSnapshotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetAuthSettingsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetConfigurationSnapshotResponder handles the response to the GetConfigurationSnapshot request. The method always
+// GetAuthSettingsResponder handles the response to the GetAuthSettings request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetConfigurationSnapshotResponder(resp *http.Response) (result SiteConfigResource, err error) {
+func (client AppsClient) GetAuthSettingsResponder(resp *http.Response) (result SiteAuthSettings, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8159,16 +8185,15 @@ func (client AppsClient) GetConfigurationSnapshotResponder(resp *http.Response)
return
}
-// GetConfigurationSnapshotSlot gets a snapshot of the configuration of an app at a previous point in time.
+// GetAuthSettingsSlot gets the Authentication/Authorization settings of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// snapshotID - the ID of the snapshot to read.
-// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
+// slot - name of the deployment slot. If a slot is not specified, the API will get the settings for the
// production slot.
-func (client AppsClient) GetConfigurationSnapshotSlot(ctx context.Context, resourceGroupName string, name string, snapshotID string, slot string) (result SiteConfigResource, err error) {
+func (client AppsClient) GetAuthSettingsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteAuthSettings, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSnapshotSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetAuthSettingsSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8182,37 +8207,36 @@ func (client AppsClient) GetConfigurationSnapshotSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetConfigurationSnapshotSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetAuthSettingsSlot", err.Error())
}
- req, err := client.GetConfigurationSnapshotSlotPreparer(ctx, resourceGroupName, name, snapshotID, slot)
+ req, err := client.GetAuthSettingsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetConfigurationSnapshotSlotSender(req)
+ resp, err := client.GetAuthSettingsSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", resp, "Failure sending request")
return
}
- result, err = client.GetConfigurationSnapshotSlotResponder(resp)
+ result, err = client.GetAuthSettingsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetAuthSettingsSlot", resp, "Failure responding to request")
}
return
}
-// GetConfigurationSnapshotSlotPreparer prepares the GetConfigurationSnapshotSlot request.
-func (client AppsClient) GetConfigurationSnapshotSlotPreparer(ctx context.Context, resourceGroupName string, name string, snapshotID string, slot string) (*http.Request, error) {
+// GetAuthSettingsSlotPreparer prepares the GetAuthSettingsSlot request.
+func (client AppsClient) GetAuthSettingsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
- "snapshotId": autorest.Encode("path", snapshotID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -8222,23 +8246,23 @@ func (client AppsClient) GetConfigurationSnapshotSlotPreparer(ctx context.Contex
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetConfigurationSnapshotSlotSender sends the GetConfigurationSnapshotSlot request. The method will close the
+// GetAuthSettingsSlotSender sends the GetAuthSettingsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetConfigurationSnapshotSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetAuthSettingsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetConfigurationSnapshotSlotResponder handles the response to the GetConfigurationSnapshotSlot request. The method always
+// GetAuthSettingsSlotResponder handles the response to the GetAuthSettingsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetConfigurationSnapshotSlotResponder(resp *http.Response) (result SiteConfigResource, err error) {
+func (client AppsClient) GetAuthSettingsSlotResponder(resp *http.Response) (result SiteAuthSettings, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8249,13 +8273,13 @@ func (client AppsClient) GetConfigurationSnapshotSlotResponder(resp *http.Respon
return
}
-// GetContainerLogsZip gets the ZIP archived docker log files for the given site
+// GetBackupConfiguration gets the backup configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetContainerLogsZip(ctx context.Context, resourceGroupName string, name string) (result ReadCloser, err error) {
+// name - name of the app.
+func (client AppsClient) GetBackupConfiguration(ctx context.Context, resourceGroupName string, name string) (result BackupRequest, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContainerLogsZip")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupConfiguration")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8269,32 +8293,32 @@ func (client AppsClient) GetContainerLogsZip(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetContainerLogsZip", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetBackupConfiguration", err.Error())
}
- req, err := client.GetContainerLogsZipPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetBackupConfigurationPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", nil, "Failure preparing request")
return
}
- resp, err := client.GetContainerLogsZipSender(req)
+ resp, err := client.GetBackupConfigurationSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", resp, "Failure sending request")
return
}
- result, err = client.GetContainerLogsZipResponder(resp)
+ result, err = client.GetBackupConfigurationResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfiguration", resp, "Failure responding to request")
}
return
}
-// GetContainerLogsZipPreparer prepares the GetContainerLogsZip request.
-func (client AppsClient) GetContainerLogsZipPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetBackupConfigurationPreparer prepares the GetBackupConfiguration request.
+func (client AppsClient) GetBackupConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -8309,38 +8333,40 @@ func (client AppsClient) GetContainerLogsZipPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/containerlogs/zip/download", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/backup/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetContainerLogsZipSender sends the GetContainerLogsZip request. The method will close the
+// GetBackupConfigurationSender sends the GetBackupConfiguration request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetContainerLogsZipSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetBackupConfigurationSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetContainerLogsZipResponder handles the response to the GetContainerLogsZip request. The method always
+// GetBackupConfigurationResponder handles the response to the GetBackupConfiguration request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetContainerLogsZipResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetBackupConfigurationResponder(resp *http.Response) (result BackupRequest, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetContainerLogsZipSlot gets the ZIP archived docker log files for the given site
+// GetBackupConfigurationSlot gets the backup configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetContainerLogsZipSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ReadCloser, err error) {
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will get the backup configuration
+// for the production slot.
+func (client AppsClient) GetBackupConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupRequest, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContainerLogsZipSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupConfigurationSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8354,32 +8380,32 @@ func (client AppsClient) GetContainerLogsZipSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetContainerLogsZipSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetBackupConfigurationSlot", err.Error())
}
- req, err := client.GetContainerLogsZipSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetBackupConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetContainerLogsZipSlotSender(req)
+ resp, err := client.GetBackupConfigurationSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", resp, "Failure sending request")
return
}
- result, err = client.GetContainerLogsZipSlotResponder(resp)
+ result, err = client.GetBackupConfigurationSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupConfigurationSlot", resp, "Failure responding to request")
}
return
}
-// GetContainerLogsZipSlotPreparer prepares the GetContainerLogsZipSlot request.
-func (client AppsClient) GetContainerLogsZipSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetBackupConfigurationSlotPreparer prepares the GetBackupConfigurationSlot request.
+func (client AppsClient) GetBackupConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -8395,38 +8421,39 @@ func (client AppsClient) GetContainerLogsZipSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/containerlogs/zip/download", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetContainerLogsZipSlotSender sends the GetContainerLogsZipSlot request. The method will close the
+// GetBackupConfigurationSlotSender sends the GetBackupConfigurationSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetContainerLogsZipSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetBackupConfigurationSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetContainerLogsZipSlotResponder handles the response to the GetContainerLogsZipSlot request. The method always
+// GetBackupConfigurationSlotResponder handles the response to the GetBackupConfigurationSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetContainerLogsZipSlotResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetBackupConfigurationSlotResponder(resp *http.Response) (result BackupRequest, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetContinuousWebJob gets a continuous web job by its ID for an app, or a deployment slot.
+// GetBackupStatus gets a backup of an app by its ID.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-func (client AppsClient) GetContinuousWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result ContinuousWebJob, err error) {
+// name - name of the app.
+// backupID - ID of the backup.
+func (client AppsClient) GetBackupStatus(ctx context.Context, resourceGroupName string, name string, backupID string) (result BackupItem, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContinuousWebJob")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupStatus")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8440,37 +8467,37 @@ func (client AppsClient) GetContinuousWebJob(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetContinuousWebJob", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetBackupStatus", err.Error())
}
- req, err := client.GetContinuousWebJobPreparer(ctx, resourceGroupName, name, webJobName)
+ req, err := client.GetBackupStatusPreparer(ctx, resourceGroupName, name, backupID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", nil, "Failure preparing request")
return
}
- resp, err := client.GetContinuousWebJobSender(req)
+ resp, err := client.GetBackupStatusSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", resp, "Failure sending request")
return
}
- result, err = client.GetContinuousWebJobResponder(resp)
+ result, err = client.GetBackupStatusResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatus", resp, "Failure responding to request")
}
return
}
-// GetContinuousWebJobPreparer prepares the GetContinuousWebJob request.
-func (client AppsClient) GetContinuousWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
+// GetBackupStatusPreparer prepares the GetBackupStatus request.
+func (client AppsClient) GetBackupStatusPreparer(ctx context.Context, resourceGroupName string, name string, backupID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -8481,41 +8508,41 @@ func (client AppsClient) GetContinuousWebJobPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetContinuousWebJobSender sends the GetContinuousWebJob request. The method will close the
+// GetBackupStatusSender sends the GetBackupStatus request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetContinuousWebJobSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetBackupStatusSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetContinuousWebJobResponder handles the response to the GetContinuousWebJob request. The method always
+// GetBackupStatusResponder handles the response to the GetBackupStatus request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetContinuousWebJobResponder(resp *http.Response) (result ContinuousWebJob, err error) {
+func (client AppsClient) GetBackupStatusResponder(resp *http.Response) (result BackupItem, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetContinuousWebJobSlot gets a continuous web job by its ID for an app, or a deployment slot.
+// GetBackupStatusSlot gets a backup of an app by its ID.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) GetContinuousWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result ContinuousWebJob, err error) {
+// name - name of the app.
+// backupID - ID of the backup.
+// slot - name of the deployment slot. If a slot is not specified, the API will get a backup of the production
+// slot.
+func (client AppsClient) GetBackupStatusSlot(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (result BackupItem, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContinuousWebJobSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetBackupStatusSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8529,38 +8556,38 @@ func (client AppsClient) GetContinuousWebJobSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetContinuousWebJobSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetBackupStatusSlot", err.Error())
}
- req, err := client.GetContinuousWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
+ req, err := client.GetBackupStatusSlotPreparer(ctx, resourceGroupName, name, backupID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetContinuousWebJobSlotSender(req)
+ resp, err := client.GetBackupStatusSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", resp, "Failure sending request")
return
}
- result, err = client.GetContinuousWebJobSlotResponder(resp)
+ result, err = client.GetBackupStatusSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetBackupStatusSlot", resp, "Failure responding to request")
}
return
}
-// GetContinuousWebJobSlotPreparer prepares the GetContinuousWebJobSlot request.
-func (client AppsClient) GetContinuousWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
+// GetBackupStatusSlotPreparer prepares the GetBackupStatusSlot request.
+func (client AppsClient) GetBackupStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -8571,39 +8598,39 @@ func (client AppsClient) GetContinuousWebJobSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetContinuousWebJobSlotSender sends the GetContinuousWebJobSlot request. The method will close the
+// GetBackupStatusSlotSender sends the GetBackupStatusSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetContinuousWebJobSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetBackupStatusSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetContinuousWebJobSlotResponder handles the response to the GetContinuousWebJobSlot request. The method always
+// GetBackupStatusSlotResponder handles the response to the GetBackupStatusSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetContinuousWebJobSlotResponder(resp *http.Response) (result ContinuousWebJob, err error) {
+func (client AppsClient) GetBackupStatusSlotResponder(resp *http.Response) (result BackupItem, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetDeployment get a deployment by its ID for an app, or a deployment slot.
+// GetConfiguration gets the configuration of an app, such as platform version and bitness, default documents, virtual
+// applications, Always On, etc.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - deployment ID.
-func (client AppsClient) GetDeployment(ctx context.Context, resourceGroupName string, name string, ID string) (result Deployment, err error) {
+func (client AppsClient) GetConfiguration(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDeployment")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfiguration")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8617,34 +8644,33 @@ func (client AppsClient) GetDeployment(ctx context.Context, resourceGroupName st
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDeployment", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetConfiguration", err.Error())
}
- req, err := client.GetDeploymentPreparer(ctx, resourceGroupName, name, ID)
+ req, err := client.GetConfigurationPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", nil, "Failure preparing request")
return
}
- resp, err := client.GetDeploymentSender(req)
+ resp, err := client.GetConfigurationSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", resp, "Failure sending request")
return
}
- result, err = client.GetDeploymentResponder(resp)
+ result, err = client.GetConfigurationResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfiguration", resp, "Failure responding to request")
}
return
}
-// GetDeploymentPreparer prepares the GetDeployment request.
-func (client AppsClient) GetDeploymentPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
+// GetConfigurationPreparer prepares the GetConfiguration request.
+func (client AppsClient) GetConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -8658,21 +8684,21 @@ func (client AppsClient) GetDeploymentPreparer(ctx context.Context, resourceGrou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDeploymentSender sends the GetDeployment request. The method will close the
+// GetConfigurationSender sends the GetConfiguration request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDeploymentSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetConfigurationSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDeploymentResponder handles the response to the GetDeployment request. The method always
+// GetConfigurationResponder handles the response to the GetConfiguration request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDeploymentResponder(resp *http.Response) (result Deployment, err error) {
+func (client AppsClient) GetConfigurationResponder(resp *http.Response) (result SiteConfigResource, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8683,16 +8709,16 @@ func (client AppsClient) GetDeploymentResponder(resp *http.Response) (result Dep
return
}
-// GetDeploymentSlot get a deployment by its ID for an app, or a deployment slot.
+// GetConfigurationSlot gets the configuration of an app, such as platform version and bitness, default documents,
+// virtual applications, Always On, etc.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - deployment ID.
-// slot - name of the deployment slot. If a slot is not specified, the API gets a deployment for the production
-// slot.
-func (client AppsClient) GetDeploymentSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result Deployment, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
+// production slot.
+func (client AppsClient) GetConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDeploymentSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8706,34 +8732,33 @@ func (client AppsClient) GetDeploymentSlot(ctx context.Context, resourceGroupNam
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDeploymentSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetConfigurationSlot", err.Error())
}
- req, err := client.GetDeploymentSlotPreparer(ctx, resourceGroupName, name, ID, slot)
+ req, err := client.GetConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetDeploymentSlotSender(req)
+ resp, err := client.GetConfigurationSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", resp, "Failure sending request")
return
}
- result, err = client.GetDeploymentSlotResponder(resp)
+ result, err = client.GetConfigurationSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSlot", resp, "Failure responding to request")
}
return
}
-// GetDeploymentSlotPreparer prepares the GetDeploymentSlot request.
-func (client AppsClient) GetDeploymentSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
+// GetConfigurationSlotPreparer prepares the GetConfigurationSlot request.
+func (client AppsClient) GetConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
@@ -8748,21 +8773,21 @@ func (client AppsClient) GetDeploymentSlotPreparer(ctx context.Context, resource
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDeploymentSlotSender sends the GetDeploymentSlot request. The method will close the
+// GetConfigurationSlotSender sends the GetConfigurationSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDeploymentSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetConfigurationSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDeploymentSlotResponder handles the response to the GetDeploymentSlot request. The method always
+// GetConfigurationSlotResponder handles the response to the GetConfigurationSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDeploymentSlotResponder(resp *http.Response) (result Deployment, err error) {
+func (client AppsClient) GetConfigurationSlotResponder(resp *http.Response) (result SiteConfigResource, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8773,13 +8798,14 @@ func (client AppsClient) GetDeploymentSlotResponder(resp *http.Response) (result
return
}
-// GetDiagnosticLogsConfiguration gets the logging configuration of an app.
+// GetConfigurationSnapshot gets a snapshot of the configuration of an app at a previous point in time.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GetDiagnosticLogsConfiguration(ctx context.Context, resourceGroupName string, name string) (result SiteLogsConfig, err error) {
+// snapshotID - the ID of the snapshot to read.
+func (client AppsClient) GetConfigurationSnapshot(ctx context.Context, resourceGroupName string, name string, snapshotID string) (result SiteConfigResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDiagnosticLogsConfiguration")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSnapshot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8793,35 +8819,36 @@ func (client AppsClient) GetDiagnosticLogsConfiguration(ctx context.Context, res
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDiagnosticLogsConfiguration", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetConfigurationSnapshot", err.Error())
}
- req, err := client.GetDiagnosticLogsConfigurationPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetConfigurationSnapshotPreparer(ctx, resourceGroupName, name, snapshotID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", nil, "Failure preparing request")
return
}
- resp, err := client.GetDiagnosticLogsConfigurationSender(req)
+ resp, err := client.GetConfigurationSnapshotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", resp, "Failure sending request")
return
}
- result, err = client.GetDiagnosticLogsConfigurationResponder(resp)
+ result, err = client.GetConfigurationSnapshotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshot", resp, "Failure responding to request")
}
return
}
-// GetDiagnosticLogsConfigurationPreparer prepares the GetDiagnosticLogsConfiguration request.
-func (client AppsClient) GetDiagnosticLogsConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetConfigurationSnapshotPreparer prepares the GetConfigurationSnapshot request.
+func (client AppsClient) GetConfigurationSnapshotPreparer(ctx context.Context, resourceGroupName string, name string, snapshotID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "snapshotId": autorest.Encode("path", snapshotID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -8833,21 +8860,21 @@ func (client AppsClient) GetDiagnosticLogsConfigurationPreparer(ctx context.Cont
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/logs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web/snapshots/{snapshotId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDiagnosticLogsConfigurationSender sends the GetDiagnosticLogsConfiguration request. The method will close the
+// GetConfigurationSnapshotSender sends the GetConfigurationSnapshot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDiagnosticLogsConfigurationSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetConfigurationSnapshotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDiagnosticLogsConfigurationResponder handles the response to the GetDiagnosticLogsConfiguration request. The method always
+// GetConfigurationSnapshotResponder handles the response to the GetConfigurationSnapshot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDiagnosticLogsConfigurationResponder(resp *http.Response) (result SiteLogsConfig, err error) {
+func (client AppsClient) GetConfigurationSnapshotResponder(resp *http.Response) (result SiteConfigResource, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8858,15 +8885,16 @@ func (client AppsClient) GetDiagnosticLogsConfigurationResponder(resp *http.Resp
return
}
-// GetDiagnosticLogsConfigurationSlot gets the logging configuration of an app.
+// GetConfigurationSnapshotSlot gets a snapshot of the configuration of an app at a previous point in time.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the logging configuration
-// for the production slot.
-func (client AppsClient) GetDiagnosticLogsConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteLogsConfig, err error) {
+// snapshotID - the ID of the snapshot to read.
+// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
+// production slot.
+func (client AppsClient) GetConfigurationSnapshotSlot(ctx context.Context, resourceGroupName string, name string, snapshotID string, slot string) (result SiteConfigResource, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDiagnosticLogsConfigurationSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetConfigurationSnapshotSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8880,36 +8908,37 @@ func (client AppsClient) GetDiagnosticLogsConfigurationSlot(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDiagnosticLogsConfigurationSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetConfigurationSnapshotSlot", err.Error())
}
- req, err := client.GetDiagnosticLogsConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetConfigurationSnapshotSlotPreparer(ctx, resourceGroupName, name, snapshotID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetDiagnosticLogsConfigurationSlotSender(req)
+ resp, err := client.GetConfigurationSnapshotSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", resp, "Failure sending request")
return
}
- result, err = client.GetDiagnosticLogsConfigurationSlotResponder(resp)
+ result, err = client.GetConfigurationSnapshotSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetConfigurationSnapshotSlot", resp, "Failure responding to request")
}
return
}
-// GetDiagnosticLogsConfigurationSlotPreparer prepares the GetDiagnosticLogsConfigurationSlot request.
-func (client AppsClient) GetDiagnosticLogsConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetConfigurationSnapshotSlotPreparer prepares the GetConfigurationSnapshotSlot request.
+func (client AppsClient) GetConfigurationSnapshotSlotPreparer(ctx context.Context, resourceGroupName string, name string, snapshotID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
+ "snapshotId": autorest.Encode("path", snapshotID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -8921,21 +8950,21 @@ func (client AppsClient) GetDiagnosticLogsConfigurationSlotPreparer(ctx context.
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDiagnosticLogsConfigurationSlotSender sends the GetDiagnosticLogsConfigurationSlot request. The method will close the
+// GetConfigurationSnapshotSlotSender sends the GetConfigurationSnapshotSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDiagnosticLogsConfigurationSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetConfigurationSnapshotSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDiagnosticLogsConfigurationSlotResponder handles the response to the GetDiagnosticLogsConfigurationSlot request. The method always
+// GetConfigurationSnapshotSlotResponder handles the response to the GetConfigurationSnapshotSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDiagnosticLogsConfigurationSlotResponder(resp *http.Response) (result SiteLogsConfig, err error) {
+func (client AppsClient) GetConfigurationSnapshotSlotResponder(resp *http.Response) (result SiteConfigResource, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -8946,14 +8975,13 @@ func (client AppsClient) GetDiagnosticLogsConfigurationSlotResponder(resp *http.
return
}
-// GetDomainOwnershipIdentifier get domain ownership identifier for web app.
+// GetContainerLogsZip gets the ZIP archived docker log files for the given site
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// domainOwnershipIdentifierName - name of domain ownership identifier.
-func (client AppsClient) GetDomainOwnershipIdentifier(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (result Identifier, err error) {
+// name - name of web app.
+func (client AppsClient) GetContainerLogsZip(ctx context.Context, resourceGroupName string, name string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDomainOwnershipIdentifier")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContainerLogsZip")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -8967,37 +8995,36 @@ func (client AppsClient) GetDomainOwnershipIdentifier(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDomainOwnershipIdentifier", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetContainerLogsZip", err.Error())
}
- req, err := client.GetDomainOwnershipIdentifierPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName)
+ req, err := client.GetContainerLogsZipPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", nil, "Failure preparing request")
return
}
- resp, err := client.GetDomainOwnershipIdentifierSender(req)
+ resp, err := client.GetContainerLogsZipSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", resp, "Failure sending request")
return
}
- result, err = client.GetDomainOwnershipIdentifierResponder(resp)
+ result, err = client.GetContainerLogsZipResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZip", resp, "Failure responding to request")
}
return
}
-// GetDomainOwnershipIdentifierPreparer prepares the GetDomainOwnershipIdentifier request.
-func (client AppsClient) GetDomainOwnershipIdentifierPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (*http.Request, error) {
+// GetContainerLogsZipPreparer prepares the GetContainerLogsZip request.
+func (client AppsClient) GetContainerLogsZipPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -9006,43 +9033,40 @@ func (client AppsClient) GetDomainOwnershipIdentifierPreparer(ctx context.Contex
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/containerlogs/zip/download", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDomainOwnershipIdentifierSender sends the GetDomainOwnershipIdentifier request. The method will close the
+// GetContainerLogsZipSender sends the GetContainerLogsZip request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDomainOwnershipIdentifierSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetContainerLogsZipSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDomainOwnershipIdentifierResponder handles the response to the GetDomainOwnershipIdentifier request. The method always
+// GetContainerLogsZipResponder handles the response to the GetContainerLogsZip request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDomainOwnershipIdentifierResponder(resp *http.Response) (result Identifier, err error) {
+func (client AppsClient) GetContainerLogsZipResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
result.Response = autorest.Response{Response: resp}
return
}
-// GetDomainOwnershipIdentifierSlot get domain ownership identifier for web app.
+// GetContainerLogsZipSlot gets the ZIP archived docker log files for the given site
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// domainOwnershipIdentifierName - name of domain ownership identifier.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
-// production slot.
-func (client AppsClient) GetDomainOwnershipIdentifierSlot(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (result Identifier, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetContainerLogsZipSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDomainOwnershipIdentifierSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContainerLogsZipSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9056,38 +9080,37 @@ func (client AppsClient) GetDomainOwnershipIdentifierSlot(ctx context.Context, r
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetDomainOwnershipIdentifierSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetContainerLogsZipSlot", err.Error())
}
- req, err := client.GetDomainOwnershipIdentifierSlotPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName, slot)
+ req, err := client.GetContainerLogsZipSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetDomainOwnershipIdentifierSlotSender(req)
+ resp, err := client.GetContainerLogsZipSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", resp, "Failure sending request")
return
}
- result, err = client.GetDomainOwnershipIdentifierSlotResponder(resp)
+ result, err = client.GetContainerLogsZipSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContainerLogsZipSlot", resp, "Failure responding to request")
}
return
}
-// GetDomainOwnershipIdentifierSlotPreparer prepares the GetDomainOwnershipIdentifierSlot request.
-func (client AppsClient) GetDomainOwnershipIdentifierSlotPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (*http.Request, error) {
+// GetContainerLogsZipSlotPreparer prepares the GetContainerLogsZipSlot request.
+func (client AppsClient) GetContainerLogsZipSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -9096,41 +9119,40 @@ func (client AppsClient) GetDomainOwnershipIdentifierSlotPreparer(ctx context.Co
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/containerlogs/zip/download", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetDomainOwnershipIdentifierSlotSender sends the GetDomainOwnershipIdentifierSlot request. The method will close the
+// GetContainerLogsZipSlotSender sends the GetContainerLogsZipSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetDomainOwnershipIdentifierSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetContainerLogsZipSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetDomainOwnershipIdentifierSlotResponder handles the response to the GetDomainOwnershipIdentifierSlot request. The method always
+// GetContainerLogsZipSlotResponder handles the response to the GetContainerLogsZipSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetDomainOwnershipIdentifierSlotResponder(resp *http.Response) (result Identifier, err error) {
+func (client AppsClient) GetContainerLogsZipSlotResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
result.Response = autorest.Response{Response: resp}
return
}
-// GetFunction get function information by its ID for web site, or a deployment slot.
+// GetContinuousWebJob gets a continuous web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// functionName - function name.
-func (client AppsClient) GetFunction(ctx context.Context, resourceGroupName string, name string, functionName string) (result FunctionEnvelope, err error) {
+// webJobName - name of Web Job.
+func (client AppsClient) GetContinuousWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result ContinuousWebJob, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunction")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContinuousWebJob")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9144,37 +9166,37 @@ func (client AppsClient) GetFunction(ctx context.Context, resourceGroupName stri
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetFunction", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetContinuousWebJob", err.Error())
}
- req, err := client.GetFunctionPreparer(ctx, resourceGroupName, name, functionName)
+ req, err := client.GetContinuousWebJobPreparer(ctx, resourceGroupName, name, webJobName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", nil, "Failure preparing request")
return
}
- resp, err := client.GetFunctionSender(req)
+ resp, err := client.GetContinuousWebJobSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", resp, "Failure sending request")
return
}
- result, err = client.GetFunctionResponder(resp)
+ result, err = client.GetContinuousWebJobResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJob", resp, "Failure responding to request")
}
return
}
-// GetFunctionPreparer prepares the GetFunction request.
-func (client AppsClient) GetFunctionPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
+// GetContinuousWebJobPreparer prepares the GetContinuousWebJob request.
+func (client AppsClient) GetContinuousWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -9185,21 +9207,21 @@ func (client AppsClient) GetFunctionPreparer(ctx context.Context, resourceGroupN
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetFunctionSender sends the GetFunction request. The method will close the
+// GetContinuousWebJobSender sends the GetContinuousWebJob request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetFunctionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetContinuousWebJobSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetFunctionResponder handles the response to the GetFunction request. The method always
+// GetContinuousWebJobResponder handles the response to the GetContinuousWebJob request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetFunctionResponder(resp *http.Response) (result FunctionEnvelope, err error) {
+func (client AppsClient) GetContinuousWebJobResponder(resp *http.Response) (result ContinuousWebJob, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9210,13 +9232,16 @@ func (client AppsClient) GetFunctionResponder(resp *http.Response) (result Funct
return
}
-// GetFunctionsAdminToken fetch a short lived token that can be exchanged for a master key.
+// GetContinuousWebJobSlot gets a continuous web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetFunctionsAdminToken(ctx context.Context, resourceGroupName string, name string) (result String, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) GetContinuousWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result ContinuousWebJob, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunctionsAdminToken")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetContinuousWebJobSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9230,36 +9255,38 @@ func (client AppsClient) GetFunctionsAdminToken(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetFunctionsAdminToken", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetContinuousWebJobSlot", err.Error())
}
- req, err := client.GetFunctionsAdminTokenPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetContinuousWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetFunctionsAdminTokenSender(req)
+ resp, err := client.GetContinuousWebJobSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", resp, "Failure sending request")
return
}
- result, err = client.GetFunctionsAdminTokenResponder(resp)
+ result, err = client.GetContinuousWebJobSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetContinuousWebJobSlot", resp, "Failure responding to request")
}
return
}
-// GetFunctionsAdminTokenPreparer prepares the GetFunctionsAdminToken request.
-func (client AppsClient) GetFunctionsAdminTokenPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetContinuousWebJobSlotPreparer prepares the GetContinuousWebJobSlot request.
+func (client AppsClient) GetContinuousWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -9270,39 +9297,39 @@ func (client AppsClient) GetFunctionsAdminTokenPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/admin/token", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetFunctionsAdminTokenSender sends the GetFunctionsAdminToken request. The method will close the
+// GetContinuousWebJobSlotSender sends the GetContinuousWebJobSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetFunctionsAdminTokenSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetContinuousWebJobSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetFunctionsAdminTokenResponder handles the response to the GetFunctionsAdminToken request. The method always
+// GetContinuousWebJobSlotResponder handles the response to the GetContinuousWebJobSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetFunctionsAdminTokenResponder(resp *http.Response) (result String, err error) {
+func (client AppsClient) GetContinuousWebJobSlotResponder(resp *http.Response) (result ContinuousWebJob, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetFunctionsAdminTokenSlot fetch a short lived token that can be exchanged for a master key.
+// GetDeployment get a deployment by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetFunctionsAdminTokenSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result String, err error) {
+// name - name of the app.
+// ID - deployment ID.
+func (client AppsClient) GetDeployment(ctx context.Context, resourceGroupName string, name string, ID string) (result Deployment, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunctionsAdminTokenSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDeployment")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9316,36 +9343,36 @@ func (client AppsClient) GetFunctionsAdminTokenSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetFunctionsAdminTokenSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDeployment", err.Error())
}
- req, err := client.GetFunctionsAdminTokenSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetDeploymentPreparer(ctx, resourceGroupName, name, ID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", nil, "Failure preparing request")
return
}
- resp, err := client.GetFunctionsAdminTokenSlotSender(req)
+ resp, err := client.GetDeploymentSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", resp, "Failure sending request")
return
}
- result, err = client.GetFunctionsAdminTokenSlotResponder(resp)
+ result, err = client.GetDeploymentResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeployment", resp, "Failure responding to request")
}
return
}
-// GetFunctionsAdminTokenSlotPreparer prepares the GetFunctionsAdminTokenSlot request.
-func (client AppsClient) GetFunctionsAdminTokenSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetDeploymentPreparer prepares the GetDeployment request.
+func (client AppsClient) GetDeploymentPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -9357,39 +9384,41 @@ func (client AppsClient) GetFunctionsAdminTokenSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/admin/token", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetFunctionsAdminTokenSlotSender sends the GetFunctionsAdminTokenSlot request. The method will close the
+// GetDeploymentSender sends the GetDeployment request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetFunctionsAdminTokenSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDeploymentSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetFunctionsAdminTokenSlotResponder handles the response to the GetFunctionsAdminTokenSlot request. The method always
+// GetDeploymentResponder handles the response to the GetDeployment request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetFunctionsAdminTokenSlotResponder(resp *http.Response) (result String, err error) {
+func (client AppsClient) GetDeploymentResponder(resp *http.Response) (result Deployment, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetHostNameBinding get the named hostname binding for an app (or deployment slot, if specified).
+// GetDeploymentSlot get a deployment by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// hostName - hostname in the hostname binding.
-func (client AppsClient) GetHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string) (result HostNameBinding, err error) {
+// ID - deployment ID.
+// slot - name of the deployment slot. If a slot is not specified, the API gets a deployment for the production
+// slot.
+func (client AppsClient) GetDeploymentSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result Deployment, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHostNameBinding")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDeploymentSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9403,36 +9432,37 @@ func (client AppsClient) GetHostNameBinding(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetHostNameBinding", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDeploymentSlot", err.Error())
}
- req, err := client.GetHostNameBindingPreparer(ctx, resourceGroupName, name, hostName)
+ req, err := client.GetDeploymentSlotPreparer(ctx, resourceGroupName, name, ID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetHostNameBindingSender(req)
+ resp, err := client.GetDeploymentSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", resp, "Failure sending request")
return
}
- result, err = client.GetHostNameBindingResponder(resp)
+ result, err = client.GetDeploymentSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDeploymentSlot", resp, "Failure responding to request")
}
return
}
-// GetHostNameBindingPreparer prepares the GetHostNameBinding request.
-func (client AppsClient) GetHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string) (*http.Request, error) {
+// GetDeploymentSlotPreparer prepares the GetDeploymentSlot request.
+func (client AppsClient) GetDeploymentSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -9444,21 +9474,21 @@ func (client AppsClient) GetHostNameBindingPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetHostNameBindingSender sends the GetHostNameBinding request. The method will close the
+// GetDeploymentSlotSender sends the GetDeploymentSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetHostNameBindingSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDeploymentSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetHostNameBindingResponder handles the response to the GetHostNameBinding request. The method always
+// GetDeploymentSlotResponder handles the response to the GetDeploymentSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetHostNameBindingResponder(resp *http.Response) (result HostNameBinding, err error) {
+func (client AppsClient) GetDeploymentSlotResponder(resp *http.Response) (result Deployment, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9469,16 +9499,13 @@ func (client AppsClient) GetHostNameBindingResponder(resp *http.Response) (resul
return
}
-// GetHostNameBindingSlot get the named hostname binding for an app (or deployment slot, if specified).
+// GetDiagnosticLogsConfiguration gets the logging configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API the named binding for the production
-// slot.
-// hostName - hostname in the hostname binding.
-func (client AppsClient) GetHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (result HostNameBinding, err error) {
+func (client AppsClient) GetDiagnosticLogsConfiguration(ctx context.Context, resourceGroupName string, name string) (result SiteLogsConfig, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHostNameBindingSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDiagnosticLogsConfiguration")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9492,37 +9519,35 @@ func (client AppsClient) GetHostNameBindingSlot(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetHostNameBindingSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDiagnosticLogsConfiguration", err.Error())
}
- req, err := client.GetHostNameBindingSlotPreparer(ctx, resourceGroupName, name, slot, hostName)
+ req, err := client.GetDiagnosticLogsConfigurationPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", nil, "Failure preparing request")
return
}
- resp, err := client.GetHostNameBindingSlotSender(req)
+ resp, err := client.GetDiagnosticLogsConfigurationSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", resp, "Failure sending request")
return
}
- result, err = client.GetHostNameBindingSlotResponder(resp)
+ result, err = client.GetDiagnosticLogsConfigurationResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfiguration", resp, "Failure responding to request")
}
return
}
-// GetHostNameBindingSlotPreparer prepares the GetHostNameBindingSlot request.
-func (client AppsClient) GetHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (*http.Request, error) {
+// GetDiagnosticLogsConfigurationPreparer prepares the GetDiagnosticLogsConfiguration request.
+func (client AppsClient) GetDiagnosticLogsConfigurationPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -9534,21 +9559,21 @@ func (client AppsClient) GetHostNameBindingSlotPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/logs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetHostNameBindingSlotSender sends the GetHostNameBindingSlot request. The method will close the
+// GetDiagnosticLogsConfigurationSender sends the GetDiagnosticLogsConfiguration request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDiagnosticLogsConfigurationSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetHostNameBindingSlotResponder handles the response to the GetHostNameBindingSlot request. The method always
+// GetDiagnosticLogsConfigurationResponder handles the response to the GetDiagnosticLogsConfiguration request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetHostNameBindingSlotResponder(resp *http.Response) (result HostNameBinding, err error) {
+func (client AppsClient) GetDiagnosticLogsConfigurationResponder(resp *http.Response) (result SiteLogsConfig, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9559,15 +9584,15 @@ func (client AppsClient) GetHostNameBindingSlotResponder(resp *http.Response) (r
return
}
-// GetHybridConnection retrieves a specific Service Bus Hybrid Connection used by this Web App.
+// GetDiagnosticLogsConfigurationSlot gets the logging configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-func (client AppsClient) GetHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (result HybridConnection, err error) {
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will get the logging configuration
+// for the production slot.
+func (client AppsClient) GetDiagnosticLogsConfigurationSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteLogsConfig, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHybridConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDiagnosticLogsConfigurationSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9581,37 +9606,36 @@ func (client AppsClient) GetHybridConnection(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetHybridConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDiagnosticLogsConfigurationSlot", err.Error())
}
- req, err := client.GetHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName)
+ req, err := client.GetDiagnosticLogsConfigurationSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetHybridConnectionSender(req)
+ resp, err := client.GetDiagnosticLogsConfigurationSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", resp, "Failure sending request")
return
}
- result, err = client.GetHybridConnectionResponder(resp)
+ result, err = client.GetDiagnosticLogsConfigurationSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDiagnosticLogsConfigurationSlot", resp, "Failure responding to request")
}
return
}
-// GetHybridConnectionPreparer prepares the GetHybridConnection request.
-func (client AppsClient) GetHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (*http.Request, error) {
+// GetDiagnosticLogsConfigurationSlotPreparer prepares the GetDiagnosticLogsConfigurationSlot request.
+func (client AppsClient) GetDiagnosticLogsConfigurationSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -9623,21 +9647,21 @@ func (client AppsClient) GetHybridConnectionPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetHybridConnectionSender sends the GetHybridConnection request. The method will close the
+// GetDiagnosticLogsConfigurationSlotSender sends the GetDiagnosticLogsConfigurationSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetHybridConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDiagnosticLogsConfigurationSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetHybridConnectionResponder handles the response to the GetHybridConnection request. The method always
+// GetDiagnosticLogsConfigurationSlotResponder handles the response to the GetDiagnosticLogsConfigurationSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetHybridConnectionResponder(resp *http.Response) (result HybridConnection, err error) {
+func (client AppsClient) GetDiagnosticLogsConfigurationSlotResponder(resp *http.Response) (result SiteLogsConfig, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9648,16 +9672,14 @@ func (client AppsClient) GetHybridConnectionResponder(resp *http.Response) (resu
return
}
-// GetHybridConnectionSlot retrieves a specific Service Bus Hybrid Connection used by this Web App.
+// GetDomainOwnershipIdentifier get domain ownership identifier for web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// namespaceName - the namespace for this hybrid connection.
-// relayName - the relay name for this hybrid connection.
-// slot - the name of the slot for the web app.
-func (client AppsClient) GetHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (result HybridConnection, err error) {
+// name - name of the app.
+// domainOwnershipIdentifierName - name of domain ownership identifier.
+func (client AppsClient) GetDomainOwnershipIdentifier(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (result Identifier, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHybridConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDomainOwnershipIdentifier")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9671,39 +9693,37 @@ func (client AppsClient) GetHybridConnectionSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetHybridConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDomainOwnershipIdentifier", err.Error())
}
- req, err := client.GetHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, slot)
+ req, err := client.GetDomainOwnershipIdentifierPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", nil, "Failure preparing request")
return
}
- resp, err := client.GetHybridConnectionSlotSender(req)
+ resp, err := client.GetDomainOwnershipIdentifierSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", resp, "Failure sending request")
return
}
- result, err = client.GetHybridConnectionSlotResponder(resp)
+ result, err = client.GetDomainOwnershipIdentifierResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifier", resp, "Failure responding to request")
}
return
}
-// GetHybridConnectionSlotPreparer prepares the GetHybridConnectionSlot request.
-func (client AppsClient) GetHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (*http.Request, error) {
+// GetDomainOwnershipIdentifierPreparer prepares the GetDomainOwnershipIdentifier request.
+func (client AppsClient) GetDomainOwnershipIdentifierPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "namespaceName": autorest.Encode("path", namespaceName),
- "relayName": autorest.Encode("path", relayName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -9714,21 +9734,21 @@ func (client AppsClient) GetHybridConnectionSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetHybridConnectionSlotSender sends the GetHybridConnectionSlot request. The method will close the
+// GetDomainOwnershipIdentifierSender sends the GetDomainOwnershipIdentifier request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDomainOwnershipIdentifierSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetHybridConnectionSlotResponder handles the response to the GetHybridConnectionSlot request. The method always
+// GetDomainOwnershipIdentifierResponder handles the response to the GetDomainOwnershipIdentifier request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetHybridConnectionSlotResponder(resp *http.Response) (result HybridConnection, err error) {
+func (client AppsClient) GetDomainOwnershipIdentifierResponder(resp *http.Response) (result Identifier, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9739,16 +9759,16 @@ func (client AppsClient) GetHybridConnectionSlotResponder(resp *http.Response) (
return
}
-// GetInstanceFunctionSlot get function information by its ID for web site, or a deployment slot.
+// GetDomainOwnershipIdentifierSlot get domain ownership identifier for web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// functionName - function name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// name - name of the app.
+// domainOwnershipIdentifierName - name of domain ownership identifier.
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
// production slot.
-func (client AppsClient) GetInstanceFunctionSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result FunctionEnvelope, err error) {
+func (client AppsClient) GetDomainOwnershipIdentifierSlot(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (result Identifier, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceFunctionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetDomainOwnershipIdentifierSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9762,41 +9782,41 @@ func (client AppsClient) GetInstanceFunctionSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceFunctionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetDomainOwnershipIdentifierSlot", err.Error())
}
- req, err := client.GetInstanceFunctionSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
+ req, err := client.GetDomainOwnershipIdentifierSlotPreparer(ctx, resourceGroupName, name, domainOwnershipIdentifierName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceFunctionSlotSender(req)
+ resp, err := client.GetDomainOwnershipIdentifierSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceFunctionSlotResponder(resp)
+ result, err = client.GetDomainOwnershipIdentifierSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetDomainOwnershipIdentifierSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceFunctionSlotPreparer prepares the GetInstanceFunctionSlot request.
-func (client AppsClient) GetInstanceFunctionSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
+// GetDomainOwnershipIdentifierSlotPreparer prepares the GetDomainOwnershipIdentifierSlot request.
+func (client AppsClient) GetDomainOwnershipIdentifierSlotPreparer(ctx context.Context, resourceGroupName string, name string, domainOwnershipIdentifierName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "functionName": autorest.Encode("path", functionName),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2018-02-01"
+ "domainOwnershipIdentifierName": autorest.Encode("path", domainOwnershipIdentifierName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
@@ -9804,39 +9824,39 @@ func (client AppsClient) GetInstanceFunctionSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceFunctionSlotSender sends the GetInstanceFunctionSlot request. The method will close the
+// GetDomainOwnershipIdentifierSlotSender sends the GetDomainOwnershipIdentifierSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceFunctionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetDomainOwnershipIdentifierSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceFunctionSlotResponder handles the response to the GetInstanceFunctionSlot request. The method always
+// GetDomainOwnershipIdentifierSlotResponder handles the response to the GetDomainOwnershipIdentifierSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceFunctionSlotResponder(resp *http.Response) (result FunctionEnvelope, err error) {
+func (client AppsClient) GetDomainOwnershipIdentifierSlotResponder(resp *http.Response) (result Identifier, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceMSDeployLog get the MSDeploy Log for the last MSDeploy operation.
+// GetFunction get function information by its ID for web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// instanceID - ID of web app instance.
-func (client AppsClient) GetInstanceMSDeployLog(ctx context.Context, resourceGroupName string, name string, instanceID string) (result MSDeployLog, err error) {
+// name - site name.
+// functionName - function name.
+func (client AppsClient) GetFunction(ctx context.Context, resourceGroupName string, name string, functionName string) (result FunctionEnvelope, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMSDeployLog")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunction")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9850,34 +9870,34 @@ func (client AppsClient) GetInstanceMSDeployLog(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceMSDeployLog", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetFunction", err.Error())
}
- req, err := client.GetInstanceMSDeployLogPreparer(ctx, resourceGroupName, name, instanceID)
+ req, err := client.GetFunctionPreparer(ctx, resourceGroupName, name, functionName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceMSDeployLogSender(req)
+ resp, err := client.GetFunctionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceMSDeployLogResponder(resp)
+ result, err = client.GetFunctionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunction", resp, "Failure responding to request")
}
return
}
-// GetInstanceMSDeployLogPreparer prepares the GetInstanceMSDeployLog request.
-func (client AppsClient) GetInstanceMSDeployLogPreparer(ctx context.Context, resourceGroupName string, name string, instanceID string) (*http.Request, error) {
+// GetFunctionPreparer prepares the GetFunction request.
+func (client AppsClient) GetFunctionPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -9891,21 +9911,21 @@ func (client AppsClient) GetInstanceMSDeployLogPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceMSDeployLogSender sends the GetInstanceMSDeployLog request. The method will close the
+// GetFunctionSender sends the GetFunction request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceMSDeployLogSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetFunctionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceMSDeployLogResponder handles the response to the GetInstanceMSDeployLog request. The method always
+// GetFunctionResponder handles the response to the GetFunction request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceMSDeployLogResponder(resp *http.Response) (result MSDeployLog, err error) {
+func (client AppsClient) GetFunctionResponder(resp *http.Response) (result FunctionEnvelope, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -9916,15 +9936,13 @@ func (client AppsClient) GetInstanceMSDeployLogResponder(resp *http.Response) (r
return
}
-// GetInstanceMSDeployLogSlot get the MSDeploy Log for the last MSDeploy operation.
+// GetFunctionsAdminToken fetch a short lived token that can be exchanged for a master key.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-// instanceID - ID of web app instance.
-func (client AppsClient) GetInstanceMSDeployLogSlot(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (result MSDeployLog, err error) {
+func (client AppsClient) GetFunctionsAdminToken(ctx context.Context, resourceGroupName string, name string) (result String, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMSDeployLogSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunctionsAdminToken")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -9938,37 +9956,35 @@ func (client AppsClient) GetInstanceMSDeployLogSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceMSDeployLogSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetFunctionsAdminToken", err.Error())
}
- req, err := client.GetInstanceMSDeployLogSlotPreparer(ctx, resourceGroupName, name, slot, instanceID)
+ req, err := client.GetFunctionsAdminTokenPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceMSDeployLogSlotSender(req)
+ resp, err := client.GetFunctionsAdminTokenSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceMSDeployLogSlotResponder(resp)
+ result, err = client.GetFunctionsAdminTokenResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminToken", resp, "Failure responding to request")
}
return
}
-// GetInstanceMSDeployLogSlotPreparer prepares the GetInstanceMSDeployLogSlot request.
-func (client AppsClient) GetInstanceMSDeployLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (*http.Request, error) {
+// GetFunctionsAdminTokenPreparer prepares the GetFunctionsAdminToken request.
+func (client AppsClient) GetFunctionsAdminTokenPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -9980,39 +9996,39 @@ func (client AppsClient) GetInstanceMSDeployLogSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/admin/token", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceMSDeployLogSlotSender sends the GetInstanceMSDeployLogSlot request. The method will close the
+// GetFunctionsAdminTokenSender sends the GetFunctionsAdminToken request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceMSDeployLogSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetFunctionsAdminTokenSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceMSDeployLogSlotResponder handles the response to the GetInstanceMSDeployLogSlot request. The method always
+// GetFunctionsAdminTokenResponder handles the response to the GetFunctionsAdminToken request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceMSDeployLogSlotResponder(resp *http.Response) (result MSDeployLog, err error) {
+func (client AppsClient) GetFunctionsAdminTokenResponder(resp *http.Response) (result String, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceMsDeployStatus get the status of the last MSDeploy operation.
+// GetFunctionsAdminTokenSlot fetch a short lived token that can be exchanged for a master key.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of web app.
-// instanceID - ID of web app instance.
-func (client AppsClient) GetInstanceMsDeployStatus(ctx context.Context, resourceGroupName string, name string, instanceID string) (result MSDeployStatus, err error) {
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetFunctionsAdminTokenSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result String, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMsDeployStatus")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetFunctionsAdminTokenSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10026,36 +10042,36 @@ func (client AppsClient) GetInstanceMsDeployStatus(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceMsDeployStatus", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetFunctionsAdminTokenSlot", err.Error())
}
- req, err := client.GetInstanceMsDeployStatusPreparer(ctx, resourceGroupName, name, instanceID)
+ req, err := client.GetFunctionsAdminTokenSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceMsDeployStatusSender(req)
+ resp, err := client.GetFunctionsAdminTokenSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceMsDeployStatusResponder(resp)
+ result, err = client.GetFunctionsAdminTokenSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetFunctionsAdminTokenSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceMsDeployStatusPreparer prepares the GetInstanceMsDeployStatus request.
-func (client AppsClient) GetInstanceMsDeployStatusPreparer(ctx context.Context, resourceGroupName string, name string, instanceID string) (*http.Request, error) {
+// GetFunctionsAdminTokenSlotPreparer prepares the GetFunctionsAdminTokenSlot request.
+func (client AppsClient) GetFunctionsAdminTokenSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10067,40 +10083,39 @@ func (client AppsClient) GetInstanceMsDeployStatusPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/admin/token", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceMsDeployStatusSender sends the GetInstanceMsDeployStatus request. The method will close the
+// GetFunctionsAdminTokenSlotSender sends the GetFunctionsAdminTokenSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceMsDeployStatusSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetFunctionsAdminTokenSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceMsDeployStatusResponder handles the response to the GetInstanceMsDeployStatus request. The method always
+// GetFunctionsAdminTokenSlotResponder handles the response to the GetFunctionsAdminTokenSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceMsDeployStatusResponder(resp *http.Response) (result MSDeployStatus, err error) {
+func (client AppsClient) GetFunctionsAdminTokenSlotResponder(resp *http.Response) (result String, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceMsDeployStatusSlot get the status of the last MSDeploy operation.
+// GetHostNameBinding get the named hostname binding for an app (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-// instanceID - ID of web app instance.
-func (client AppsClient) GetInstanceMsDeployStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (result MSDeployStatus, err error) {
+// name - name of the app.
+// hostName - hostname in the hostname binding.
+func (client AppsClient) GetHostNameBinding(ctx context.Context, resourceGroupName string, name string, hostName string) (result HostNameBinding, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMsDeployStatusSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHostNameBinding")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10114,37 +10129,36 @@ func (client AppsClient) GetInstanceMsDeployStatusSlot(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceMsDeployStatusSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetHostNameBinding", err.Error())
}
- req, err := client.GetInstanceMsDeployStatusSlotPreparer(ctx, resourceGroupName, name, slot, instanceID)
+ req, err := client.GetHostNameBindingPreparer(ctx, resourceGroupName, name, hostName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceMsDeployStatusSlotSender(req)
+ resp, err := client.GetHostNameBindingSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceMsDeployStatusSlotResponder(resp)
+ result, err = client.GetHostNameBindingResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBinding", resp, "Failure responding to request")
}
return
}
-// GetInstanceMsDeployStatusSlotPreparer prepares the GetInstanceMsDeployStatusSlot request.
-func (client AppsClient) GetInstanceMsDeployStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (*http.Request, error) {
+// GetHostNameBindingPreparer prepares the GetHostNameBinding request.
+func (client AppsClient) GetHostNameBindingPreparer(ctx context.Context, resourceGroupName string, name string, hostName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10156,21 +10170,21 @@ func (client AppsClient) GetInstanceMsDeployStatusSlotPreparer(ctx context.Conte
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceMsDeployStatusSlotSender sends the GetInstanceMsDeployStatusSlot request. The method will close the
+// GetHostNameBindingSender sends the GetHostNameBinding request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceMsDeployStatusSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetHostNameBindingSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceMsDeployStatusSlotResponder handles the response to the GetInstanceMsDeployStatusSlot request. The method always
+// GetHostNameBindingResponder handles the response to the GetHostNameBinding request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceMsDeployStatusSlotResponder(resp *http.Response) (result MSDeployStatus, err error) {
+func (client AppsClient) GetHostNameBindingResponder(resp *http.Response) (result HostNameBinding, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -10181,16 +10195,16 @@ func (client AppsClient) GetInstanceMsDeployStatusSlotResponder(resp *http.Respo
return
}
-// GetInstanceProcess get process information by its ID for a specific scaled-out instance in a web site.
+// GetHostNameBindingSlot get the named hostname binding for an app (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcess(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result ProcessInfo, err error) {
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API the named binding for the production
+// slot.
+// hostName - hostname in the hostname binding.
+func (client AppsClient) GetHostNameBindingSlot(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (result HostNameBinding, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcess")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHostNameBindingSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10204,37 +10218,37 @@ func (client AppsClient) GetInstanceProcess(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcess", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetHostNameBindingSlot", err.Error())
}
- req, err := client.GetInstanceProcessPreparer(ctx, resourceGroupName, name, processID, instanceID)
+ req, err := client.GetHostNameBindingSlotPreparer(ctx, resourceGroupName, name, slot, hostName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessSender(req)
+ resp, err := client.GetHostNameBindingSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessResponder(resp)
+ result, err = client.GetHostNameBindingSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHostNameBindingSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessPreparer prepares the GetInstanceProcess request.
-func (client AppsClient) GetInstanceProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
+// GetHostNameBindingSlotPreparer prepares the GetHostNameBindingSlot request.
+func (client AppsClient) GetHostNameBindingSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, hostName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
+ "hostName": autorest.Encode("path", hostName),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10246,41 +10260,40 @@ func (client AppsClient) GetInstanceProcessPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessSender sends the GetInstanceProcess request. The method will close the
+// GetHostNameBindingSlotSender sends the GetHostNameBindingSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetHostNameBindingSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessResponder handles the response to the GetInstanceProcess request. The method always
+// GetHostNameBindingSlotResponder handles the response to the GetHostNameBindingSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessResponder(resp *http.Response) (result ProcessInfo, err error) {
+func (client AppsClient) GetHostNameBindingSlotResponder(resp *http.Response) (result HostNameBinding, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceProcessDump get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
+// GetHybridConnection retrieves a specific Service Bus Hybrid Connection used by this Web App.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessDump(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result ReadCloser, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+func (client AppsClient) GetHybridConnection(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (result HybridConnection, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessDump")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHybridConnection")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10294,36 +10307,36 @@ func (client AppsClient) GetInstanceProcessDump(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessDump", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetHybridConnection", err.Error())
}
- req, err := client.GetInstanceProcessDumpPreparer(ctx, resourceGroupName, name, processID, instanceID)
+ req, err := client.GetHybridConnectionPreparer(ctx, resourceGroupName, name, namespaceName, relayName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessDumpSender(req)
+ resp, err := client.GetHybridConnectionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessDumpResponder(resp)
+ result, err = client.GetHybridConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnection", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessDumpPreparer prepares the GetInstanceProcessDump request.
-func (client AppsClient) GetInstanceProcessDumpPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
+// GetHybridConnectionPreparer prepares the GetHybridConnection request.
+func (client AppsClient) GetHybridConnectionPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10336,43 +10349,41 @@ func (client AppsClient) GetInstanceProcessDumpPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/dump", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessDumpSender sends the GetInstanceProcessDump request. The method will close the
+// GetHybridConnectionSender sends the GetHybridConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessDumpSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetHybridConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessDumpResponder handles the response to the GetInstanceProcessDump request. The method always
+// GetHybridConnectionResponder handles the response to the GetHybridConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessDumpResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetHybridConnectionResponder(resp *http.Response) (result HybridConnection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceProcessDumpSlot get a memory dump of a process by its ID for a specific scaled-out instance in a web
-// site.
+// GetHybridConnectionSlot retrieves a specific Service Bus Hybrid Connection used by this Web App.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessDumpSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result ReadCloser, err error) {
+// name - the name of the web app.
+// namespaceName - the namespace for this hybrid connection.
+// relayName - the relay name for this hybrid connection.
+// slot - the name of the slot for the web app.
+func (client AppsClient) GetHybridConnectionSlot(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (result HybridConnection, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessDumpSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetHybridConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10386,36 +10397,36 @@ func (client AppsClient) GetInstanceProcessDumpSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessDumpSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetHybridConnectionSlot", err.Error())
}
- req, err := client.GetInstanceProcessDumpSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
+ req, err := client.GetHybridConnectionSlotPreparer(ctx, resourceGroupName, name, namespaceName, relayName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessDumpSlotSender(req)
+ resp, err := client.GetHybridConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessDumpSlotResponder(resp)
+ result, err = client.GetHybridConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetHybridConnectionSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessDumpSlotPreparer prepares the GetInstanceProcessDumpSlot request.
-func (client AppsClient) GetInstanceProcessDumpSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
+// GetHybridConnectionSlotPreparer prepares the GetHybridConnectionSlot request.
+func (client AppsClient) GetHybridConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, namespaceName string, relayName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "namespaceName": autorest.Encode("path", namespaceName),
+ "relayName": autorest.Encode("path", relayName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -10429,41 +10440,40 @@ func (client AppsClient) GetInstanceProcessDumpSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/dump", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessDumpSlotSender sends the GetInstanceProcessDumpSlot request. The method will close the
+// GetHybridConnectionSlotSender sends the GetHybridConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessDumpSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetHybridConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessDumpSlotResponder handles the response to the GetInstanceProcessDumpSlot request. The method always
+// GetHybridConnectionSlotResponder handles the response to the GetHybridConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessDumpSlotResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetHybridConnectionSlotResponder(resp *http.Response) (result HybridConnection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceProcessModule get process information by its ID for a specific scaled-out instance in a web site.
+// GetInstanceFunctionSlot get function information by its ID for web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// processID - pID.
-// baseAddress - module base address.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessModule(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, instanceID string) (result ProcessModuleInfo, err error) {
+// functionName - function name.
+// slot - name of the deployment slot.
+func (client AppsClient) GetInstanceFunctionSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result FunctionEnvelope, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessModule")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceFunctionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10477,38 +10487,37 @@ func (client AppsClient) GetInstanceProcessModule(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessModule", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceFunctionSlot", err.Error())
}
- req, err := client.GetInstanceProcessModulePreparer(ctx, resourceGroupName, name, processID, baseAddress, instanceID)
+ req, err := client.GetInstanceFunctionSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessModuleSender(req)
+ resp, err := client.GetInstanceFunctionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessModuleResponder(resp)
+ result, err = client.GetInstanceFunctionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceFunctionSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessModulePreparer prepares the GetInstanceProcessModule request.
-func (client AppsClient) GetInstanceProcessModulePreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, instanceID string) (*http.Request, error) {
+// GetInstanceFunctionSlotPreparer prepares the GetInstanceFunctionSlot request.
+func (client AppsClient) GetInstanceFunctionSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "baseAddress": autorest.Encode("path", baseAddress),
- "instanceId": autorest.Encode("path", instanceID),
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10520,21 +10529,21 @@ func (client AppsClient) GetInstanceProcessModulePreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/modules/{baseAddress}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessModuleSender sends the GetInstanceProcessModule request. The method will close the
+// GetInstanceFunctionSlotSender sends the GetInstanceFunctionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessModuleSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceFunctionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessModuleResponder handles the response to the GetInstanceProcessModule request. The method always
+// GetInstanceFunctionSlotResponder handles the response to the GetInstanceFunctionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessModuleResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
+func (client AppsClient) GetInstanceFunctionSlotResponder(resp *http.Response) (result FunctionEnvelope, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -10545,19 +10554,14 @@ func (client AppsClient) GetInstanceProcessModuleResponder(resp *http.Response)
return
}
-// GetInstanceProcessModuleSlot get process information by its ID for a specific scaled-out instance in a web site.
+// GetInstanceMSDeployLog get the MSDeploy Log for the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// baseAddress - module base address.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessModuleSlot(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string, instanceID string) (result ProcessModuleInfo, err error) {
+// name - name of web app.
+// instanceID - ID of web app instance.
+func (client AppsClient) GetInstanceMSDeployLog(ctx context.Context, resourceGroupName string, name string, instanceID string) (result MSDeployLog, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessModuleSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMSDeployLog")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10571,39 +10575,36 @@ func (client AppsClient) GetInstanceProcessModuleSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessModuleSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceMSDeployLog", err.Error())
}
- req, err := client.GetInstanceProcessModuleSlotPreparer(ctx, resourceGroupName, name, processID, baseAddress, slot, instanceID)
+ req, err := client.GetInstanceMSDeployLogPreparer(ctx, resourceGroupName, name, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessModuleSlotSender(req)
+ resp, err := client.GetInstanceMSDeployLogSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessModuleSlotResponder(resp)
+ result, err = client.GetInstanceMSDeployLogResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLog", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessModuleSlotPreparer prepares the GetInstanceProcessModuleSlot request.
-func (client AppsClient) GetInstanceProcessModuleSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string, instanceID string) (*http.Request, error) {
+// GetInstanceMSDeployLogPreparer prepares the GetInstanceMSDeployLog request.
+func (client AppsClient) GetInstanceMSDeployLogPreparer(ctx context.Context, resourceGroupName string, name string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "baseAddress": autorest.Encode("path", baseAddress),
"instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10615,21 +10616,21 @@ func (client AppsClient) GetInstanceProcessModuleSlotPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/modules/{baseAddress}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessModuleSlotSender sends the GetInstanceProcessModuleSlot request. The method will close the
+// GetInstanceMSDeployLogSender sends the GetInstanceMSDeployLog request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessModuleSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceMSDeployLogSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessModuleSlotResponder handles the response to the GetInstanceProcessModuleSlot request. The method always
+// GetInstanceMSDeployLogResponder handles the response to the GetInstanceMSDeployLog request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessModuleSlotResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
+func (client AppsClient) GetInstanceMSDeployLogResponder(resp *http.Response) (result MSDeployLog, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -10640,18 +10641,15 @@ func (client AppsClient) GetInstanceProcessModuleSlotResponder(resp *http.Respon
return
}
-// GetInstanceProcessSlot get process information by its ID for a specific scaled-out instance in a web site.
+// GetInstanceMSDeployLogSlot get the MSDeploy Log for the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result ProcessInfo, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+// instanceID - ID of web app instance.
+func (client AppsClient) GetInstanceMSDeployLogSlot(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (result MSDeployLog, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMSDeployLogSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10665,36 +10663,35 @@ func (client AppsClient) GetInstanceProcessSlot(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceMSDeployLogSlot", err.Error())
}
- req, err := client.GetInstanceProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
+ req, err := client.GetInstanceMSDeployLogSlotPreparer(ctx, resourceGroupName, name, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessSlotSender(req)
+ resp, err := client.GetInstanceMSDeployLogSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessSlotResponder(resp)
+ result, err = client.GetInstanceMSDeployLogSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMSDeployLogSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessSlotPreparer prepares the GetInstanceProcessSlot request.
-func (client AppsClient) GetInstanceProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
+// GetInstanceMSDeployLogSlotPreparer prepares the GetInstanceMSDeployLogSlot request.
+func (client AppsClient) GetInstanceMSDeployLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -10708,21 +10705,21 @@ func (client AppsClient) GetInstanceProcessSlotPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessSlotSender sends the GetInstanceProcessSlot request. The method will close the
+// GetInstanceMSDeployLogSlotSender sends the GetInstanceMSDeployLogSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceMSDeployLogSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessSlotResponder handles the response to the GetInstanceProcessSlot request. The method always
+// GetInstanceMSDeployLogSlotResponder handles the response to the GetInstanceMSDeployLogSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessSlotResponder(resp *http.Response) (result ProcessInfo, err error) {
+func (client AppsClient) GetInstanceMSDeployLogSlotResponder(resp *http.Response) (result MSDeployLog, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -10733,18 +10730,14 @@ func (client AppsClient) GetInstanceProcessSlotResponder(resp *http.Response) (r
return
}
-// GetInstanceProcessThread get thread information by Thread ID for a specific process, in a specific scaled-out
-// instance in a web site.
+// GetInstanceMsDeployStatus get the status of the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// threadID - tID.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessThread(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, instanceID string) (result ProcessThreadInfo, err error) {
+// name - name of web app.
+// instanceID - ID of web app instance.
+func (client AppsClient) GetInstanceMsDeployStatus(ctx context.Context, resourceGroupName string, name string, instanceID string) (result MSDeployStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessThread")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMsDeployStatus")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10758,39 +10751,37 @@ func (client AppsClient) GetInstanceProcessThread(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessThread", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceMsDeployStatus", err.Error())
}
- req, err := client.GetInstanceProcessThreadPreparer(ctx, resourceGroupName, name, processID, threadID, instanceID)
+ req, err := client.GetInstanceMsDeployStatusPreparer(ctx, resourceGroupName, name, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessThreadSender(req)
+ resp, err := client.GetInstanceMsDeployStatusSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessThreadResponder(resp)
+ result, err = client.GetInstanceMsDeployStatusResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatus", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessThreadPreparer prepares the GetInstanceProcessThread request.
-func (client AppsClient) GetInstanceProcessThreadPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, instanceID string) (*http.Request, error) {
+// GetInstanceMsDeployStatusPreparer prepares the GetInstanceMsDeployStatus request.
+func (client AppsClient) GetInstanceMsDeployStatusPreparer(ctx context.Context, resourceGroupName string, name string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -10801,45 +10792,40 @@ func (client AppsClient) GetInstanceProcessThreadPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/threads/{threadId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessThreadSender sends the GetInstanceProcessThread request. The method will close the
+// GetInstanceMsDeployStatusSender sends the GetInstanceMsDeployStatus request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessThreadSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceMsDeployStatusSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessThreadResponder handles the response to the GetInstanceProcessThread request. The method always
+// GetInstanceMsDeployStatusResponder handles the response to the GetInstanceMsDeployStatus request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessThreadResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
+func (client AppsClient) GetInstanceMsDeployStatusResponder(resp *http.Response) (result MSDeployStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetInstanceProcessThreadSlot get thread information by Thread ID for a specific process, in a specific scaled-out
-// instance in a web site.
+// GetInstanceMsDeployStatusSlot get the status of the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// threadID - tID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
-// response from "GET api/sites/{siteName}/instances".
-func (client AppsClient) GetInstanceProcessThreadSlot(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string, instanceID string) (result ProcessThreadInfo, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+// instanceID - ID of web app instance.
+func (client AppsClient) GetInstanceMsDeployStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (result MSDeployStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessThreadSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceMsDeployStatusSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10853,40 +10839,38 @@ func (client AppsClient) GetInstanceProcessThreadSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetInstanceProcessThreadSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceMsDeployStatusSlot", err.Error())
}
- req, err := client.GetInstanceProcessThreadSlotPreparer(ctx, resourceGroupName, name, processID, threadID, slot, instanceID)
+ req, err := client.GetInstanceMsDeployStatusSlotPreparer(ctx, resourceGroupName, name, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetInstanceProcessThreadSlotSender(req)
+ resp, err := client.GetInstanceMsDeployStatusSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", resp, "Failure sending request")
return
}
- result, err = client.GetInstanceProcessThreadSlotResponder(resp)
+ result, err = client.GetInstanceMsDeployStatusSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceMsDeployStatusSlot", resp, "Failure responding to request")
}
return
}
-// GetInstanceProcessThreadSlotPreparer prepares the GetInstanceProcessThreadSlot request.
-func (client AppsClient) GetInstanceProcessThreadSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string, instanceID string) (*http.Request, error) {
+// GetInstanceMsDeployStatusSlotPreparer prepares the GetInstanceMsDeployStatusSlot request.
+func (client AppsClient) GetInstanceMsDeployStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -10897,39 +10881,41 @@ func (client AppsClient) GetInstanceProcessThreadSlotPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/threads/{threadId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetInstanceProcessThreadSlotSender sends the GetInstanceProcessThreadSlot request. The method will close the
+// GetInstanceMsDeployStatusSlotSender sends the GetInstanceMsDeployStatusSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetInstanceProcessThreadSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceMsDeployStatusSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetInstanceProcessThreadSlotResponder handles the response to the GetInstanceProcessThreadSlot request. The method always
+// GetInstanceMsDeployStatusSlotResponder handles the response to the GetInstanceMsDeployStatusSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetInstanceProcessThreadSlotResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
+func (client AppsClient) GetInstanceMsDeployStatusSlotResponder(resp *http.Response) (result MSDeployStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetMigrateMySQLStatus returns the status of MySql in app migration, if one is active, and whether or not MySql in
-// app is enabled
+// GetInstanceProcess get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetMigrateMySQLStatus(ctx context.Context, resourceGroupName string, name string) (result MigrateMySQLStatus, err error) {
+// name - site name.
+// processID - pID.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcess(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result ProcessInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMigrateMySQLStatus")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcess")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -10943,34 +10929,36 @@ func (client AppsClient) GetMigrateMySQLStatus(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMigrateMySQLStatus", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcess", err.Error())
}
- req, err := client.GetMigrateMySQLStatusPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetInstanceProcessPreparer(ctx, resourceGroupName, name, processID, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", nil, "Failure preparing request")
return
}
- resp, err := client.GetMigrateMySQLStatusSender(req)
+ resp, err := client.GetInstanceProcessSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", resp, "Failure sending request")
return
}
- result, err = client.GetMigrateMySQLStatusResponder(resp)
+ result, err = client.GetInstanceProcessResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcess", resp, "Failure responding to request")
}
return
}
-// GetMigrateMySQLStatusPreparer prepares the GetMigrateMySQLStatus request.
-func (client AppsClient) GetMigrateMySQLStatusPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetInstanceProcessPreparer prepares the GetInstanceProcess request.
+func (client AppsClient) GetInstanceProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -10983,40 +10971,41 @@ func (client AppsClient) GetMigrateMySQLStatusPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/migratemysql/status", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMigrateMySQLStatusSender sends the GetMigrateMySQLStatus request. The method will close the
+// GetInstanceProcessSender sends the GetInstanceProcess request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMigrateMySQLStatusSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMigrateMySQLStatusResponder handles the response to the GetMigrateMySQLStatus request. The method always
+// GetInstanceProcessResponder handles the response to the GetInstanceProcess request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMigrateMySQLStatusResponder(resp *http.Response) (result MigrateMySQLStatus, err error) {
+func (client AppsClient) GetInstanceProcessResponder(resp *http.Response) (result ProcessInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetMigrateMySQLStatusSlot returns the status of MySql in app migration, if one is active, and whether or not MySql
-// in app is enabled
+// GetInstanceProcessDump get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of the deployment slot.
-func (client AppsClient) GetMigrateMySQLStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MigrateMySQLStatus, err error) {
+// name - site name.
+// processID - pID.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessDump(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMigrateMySQLStatusSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessDump")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11030,36 +11019,37 @@ func (client AppsClient) GetMigrateMySQLStatusSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMigrateMySQLStatusSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessDump", err.Error())
}
- req, err := client.GetMigrateMySQLStatusSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetInstanceProcessDumpPreparer(ctx, resourceGroupName, name, processID, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", nil, "Failure preparing request")
return
}
- resp, err := client.GetMigrateMySQLStatusSlotSender(req)
+ resp, err := client.GetInstanceProcessDumpSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", resp, "Failure sending request")
return
}
- result, err = client.GetMigrateMySQLStatusSlotResponder(resp)
+ result, err = client.GetInstanceProcessDumpResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDump", resp, "Failure responding to request")
}
return
}
-// GetMigrateMySQLStatusSlotPreparer prepares the GetMigrateMySQLStatusSlot request.
-func (client AppsClient) GetMigrateMySQLStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetInstanceProcessDumpPreparer prepares the GetInstanceProcessDump request.
+func (client AppsClient) GetInstanceProcessDumpPreparer(ctx context.Context, resourceGroupName string, name string, processID string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11071,38 +11061,43 @@ func (client AppsClient) GetMigrateMySQLStatusSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/migratemysql/status", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/dump", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMigrateMySQLStatusSlotSender sends the GetMigrateMySQLStatusSlot request. The method will close the
+// GetInstanceProcessDumpSender sends the GetInstanceProcessDump request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMigrateMySQLStatusSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessDumpSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMigrateMySQLStatusSlotResponder handles the response to the GetMigrateMySQLStatusSlot request. The method always
+// GetInstanceProcessDumpResponder handles the response to the GetInstanceProcessDump request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMigrateMySQLStatusSlotResponder(resp *http.Response) (result MigrateMySQLStatus, err error) {
+func (client AppsClient) GetInstanceProcessDumpResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
result.Response = autorest.Response{Response: resp}
return
}
-// GetMSDeployLog get the MSDeploy Log for the last MSDeploy operation.
+// GetInstanceProcessDumpSlot get a memory dump of a process by its ID for a specific scaled-out instance in a web
+// site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetMSDeployLog(ctx context.Context, resourceGroupName string, name string) (result MSDeployLog, err error) {
+// name - site name.
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessDumpSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployLog")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessDumpSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11116,35 +11111,38 @@ func (client AppsClient) GetMSDeployLog(ctx context.Context, resourceGroupName s
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMSDeployLog", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessDumpSlot", err.Error())
}
- req, err := client.GetMSDeployLogPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetInstanceProcessDumpSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetMSDeployLogSender(req)
+ resp, err := client.GetInstanceProcessDumpSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", resp, "Failure sending request")
return
}
- result, err = client.GetMSDeployLogResponder(resp)
+ result, err = client.GetInstanceProcessDumpSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessDumpSlot", resp, "Failure responding to request")
}
return
}
-// GetMSDeployLogPreparer prepares the GetMSDeployLog request.
-func (client AppsClient) GetMSDeployLogPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetInstanceProcessDumpSlotPreparer prepares the GetInstanceProcessDumpSlot request.
+func (client AppsClient) GetInstanceProcessDumpSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11156,39 +11154,41 @@ func (client AppsClient) GetMSDeployLogPreparer(ctx context.Context, resourceGro
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/dump", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMSDeployLogSender sends the GetMSDeployLog request. The method will close the
+// GetInstanceProcessDumpSlotSender sends the GetInstanceProcessDumpSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMSDeployLogSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessDumpSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMSDeployLogResponder handles the response to the GetMSDeployLog request. The method always
+// GetInstanceProcessDumpSlotResponder handles the response to the GetInstanceProcessDumpSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMSDeployLogResponder(resp *http.Response) (result MSDeployLog, err error) {
+func (client AppsClient) GetInstanceProcessDumpSlotResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
result.Response = autorest.Response{Response: resp}
return
}
-// GetMSDeployLogSlot get the MSDeploy Log for the last MSDeploy operation.
+// GetInstanceProcessModule get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetMSDeployLogSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MSDeployLog, err error) {
+// name - site name.
+// processID - pID.
+// baseAddress - module base address.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessModule(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, instanceID string) (result ProcessModuleInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployLogSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessModule")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11202,36 +11202,38 @@ func (client AppsClient) GetMSDeployLogSlot(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMSDeployLogSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessModule", err.Error())
}
- req, err := client.GetMSDeployLogSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetInstanceProcessModulePreparer(ctx, resourceGroupName, name, processID, baseAddress, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", nil, "Failure preparing request")
return
}
- resp, err := client.GetMSDeployLogSlotSender(req)
+ resp, err := client.GetInstanceProcessModuleSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", resp, "Failure sending request")
return
}
- result, err = client.GetMSDeployLogSlotResponder(resp)
+ result, err = client.GetInstanceProcessModuleResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModule", resp, "Failure responding to request")
}
return
}
-// GetMSDeployLogSlotPreparer prepares the GetMSDeployLogSlot request.
-func (client AppsClient) GetMSDeployLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetInstanceProcessModulePreparer prepares the GetInstanceProcessModule request.
+func (client AppsClient) GetInstanceProcessModulePreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "baseAddress": autorest.Encode("path", baseAddress),
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11243,21 +11245,21 @@ func (client AppsClient) GetMSDeployLogSlotPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/modules/{baseAddress}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMSDeployLogSlotSender sends the GetMSDeployLogSlot request. The method will close the
+// GetInstanceProcessModuleSender sends the GetInstanceProcessModule request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMSDeployLogSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessModuleSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMSDeployLogSlotResponder handles the response to the GetMSDeployLogSlot request. The method always
+// GetInstanceProcessModuleResponder handles the response to the GetInstanceProcessModule request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMSDeployLogSlotResponder(resp *http.Response) (result MSDeployLog, err error) {
+func (client AppsClient) GetInstanceProcessModuleResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -11268,13 +11270,19 @@ func (client AppsClient) GetMSDeployLogSlotResponder(resp *http.Response) (resul
return
}
-// GetMSDeployStatus get the status of the last MSDeploy operation.
+// GetInstanceProcessModuleSlot get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetMSDeployStatus(ctx context.Context, resourceGroupName string, name string) (result MSDeployStatus, err error) {
+// name - site name.
+// processID - pID.
+// baseAddress - module base address.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessModuleSlot(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string, instanceID string) (result ProcessModuleInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployStatus")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessModuleSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11288,35 +11296,39 @@ func (client AppsClient) GetMSDeployStatus(ctx context.Context, resourceGroupNam
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMSDeployStatus", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessModuleSlot", err.Error())
}
- req, err := client.GetMSDeployStatusPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetInstanceProcessModuleSlotPreparer(ctx, resourceGroupName, name, processID, baseAddress, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetMSDeployStatusSender(req)
+ resp, err := client.GetInstanceProcessModuleSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", resp, "Failure sending request")
return
}
- result, err = client.GetMSDeployStatusResponder(resp)
+ result, err = client.GetInstanceProcessModuleSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessModuleSlot", resp, "Failure responding to request")
}
return
}
-// GetMSDeployStatusPreparer prepares the GetMSDeployStatus request.
-func (client AppsClient) GetMSDeployStatusPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetInstanceProcessModuleSlotPreparer prepares the GetInstanceProcessModuleSlot request.
+func (client AppsClient) GetInstanceProcessModuleSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "baseAddress": autorest.Encode("path", baseAddress),
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11328,39 +11340,43 @@ func (client AppsClient) GetMSDeployStatusPreparer(ctx context.Context, resource
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/modules/{baseAddress}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMSDeployStatusSender sends the GetMSDeployStatus request. The method will close the
+// GetInstanceProcessModuleSlotSender sends the GetInstanceProcessModuleSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMSDeployStatusSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessModuleSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMSDeployStatusResponder handles the response to the GetMSDeployStatus request. The method always
+// GetInstanceProcessModuleSlotResponder handles the response to the GetInstanceProcessModuleSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMSDeployStatusResponder(resp *http.Response) (result MSDeployStatus, err error) {
+func (client AppsClient) GetInstanceProcessModuleSlotResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetMSDeployStatusSlot get the status of the last MSDeploy operation.
+// GetInstanceProcessSlot get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetMSDeployStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MSDeployStatus, err error) {
+// name - site name.
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (result ProcessInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployStatusSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11374,34 +11390,36 @@ func (client AppsClient) GetMSDeployStatusSlot(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetMSDeployStatusSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessSlot", err.Error())
}
- req, err := client.GetMSDeployStatusSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetInstanceProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetMSDeployStatusSlotSender(req)
+ resp, err := client.GetInstanceProcessSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", resp, "Failure sending request")
return
}
- result, err = client.GetMSDeployStatusSlotResponder(resp)
+ result, err = client.GetInstanceProcessSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessSlot", resp, "Failure responding to request")
}
return
}
-// GetMSDeployStatusSlotPreparer prepares the GetMSDeployStatusSlot request.
-func (client AppsClient) GetMSDeployStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetInstanceProcessSlotPreparer prepares the GetInstanceProcessSlot request.
+func (client AppsClient) GetInstanceProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -11415,39 +11433,43 @@ func (client AppsClient) GetMSDeployStatusSlotPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetMSDeployStatusSlotSender sends the GetMSDeployStatusSlot request. The method will close the
+// GetInstanceProcessSlotSender sends the GetInstanceProcessSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetMSDeployStatusSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetMSDeployStatusSlotResponder handles the response to the GetMSDeployStatusSlot request. The method always
+// GetInstanceProcessSlotResponder handles the response to the GetInstanceProcessSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetMSDeployStatusSlotResponder(resp *http.Response) (result MSDeployStatus, err error) {
+func (client AppsClient) GetInstanceProcessSlotResponder(resp *http.Response) (result ProcessInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTraceOperation gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetInstanceProcessThread get thread information by Thread ID for a specific process, in a specific scaled-out
+// instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-func (client AppsClient) GetNetworkTraceOperation(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
+// name - site name.
+// processID - pID.
+// threadID - tID.
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessThread(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, instanceID string) (result ProcessThreadInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperation")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessThread")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11461,37 +11483,39 @@ func (client AppsClient) GetNetworkTraceOperation(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperation", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessThread", err.Error())
}
- req, err := client.GetNetworkTraceOperationPreparer(ctx, resourceGroupName, name, operationID)
+ req, err := client.GetInstanceProcessThreadPreparer(ctx, resourceGroupName, name, processID, threadID, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTraceOperationSender(req)
+ resp, err := client.GetInstanceProcessThreadSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTraceOperationResponder(resp)
+ result, err = client.GetInstanceProcessThreadResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThread", resp, "Failure responding to request")
}
return
}
-// GetNetworkTraceOperationPreparer prepares the GetNetworkTraceOperation request.
-func (client AppsClient) GetNetworkTraceOperationPreparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
+// GetInstanceProcessThreadPreparer prepares the GetInstanceProcessThread request.
+func (client AppsClient) GetInstanceProcessThreadPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -11502,42 +11526,45 @@ func (client AppsClient) GetNetworkTraceOperationPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/operationresults/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/processes/{processId}/threads/{threadId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTraceOperationSender sends the GetNetworkTraceOperation request. The method will close the
+// GetInstanceProcessThreadSender sends the GetInstanceProcessThread request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTraceOperationSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessThreadSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTraceOperationResponder handles the response to the GetNetworkTraceOperation request. The method always
+// GetInstanceProcessThreadResponder handles the response to the GetInstanceProcessThread request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTraceOperationResponder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetInstanceProcessThreadResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTraceOperationSlot gets a named operation for a network trace capturing (or deployment slot, if
-// specified).
+// GetInstanceProcessThreadSlot get thread information by Thread ID for a specific process, in a specific scaled-out
+// instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
+// name - site name.
+// processID - pID.
+// threadID - tID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
// production slot.
-func (client AppsClient) GetNetworkTraceOperationSlot(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
+// instanceID - ID of a specific scaled-out instance. This is the value of the name property in the JSON
+// response from "GET api/sites/{siteName}/instances".
+func (client AppsClient) GetInstanceProcessThreadSlot(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string, instanceID string) (result ProcessThreadInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetInstanceProcessThreadSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11551,38 +11578,40 @@ func (client AppsClient) GetNetworkTraceOperationSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetInstanceProcessThreadSlot", err.Error())
}
- req, err := client.GetNetworkTraceOperationSlotPreparer(ctx, resourceGroupName, name, operationID, slot)
+ req, err := client.GetInstanceProcessThreadSlotPreparer(ctx, resourceGroupName, name, processID, threadID, slot, instanceID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTraceOperationSlotSender(req)
+ resp, err := client.GetInstanceProcessThreadSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTraceOperationSlotResponder(resp)
+ result, err = client.GetInstanceProcessThreadSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetInstanceProcessThreadSlot", resp, "Failure responding to request")
}
return
}
-// GetNetworkTraceOperationSlotPreparer prepares the GetNetworkTraceOperationSlot request.
-func (client AppsClient) GetNetworkTraceOperationSlotPreparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
+// GetInstanceProcessThreadSlotPreparer prepares the GetInstanceProcessThreadSlot request.
+func (client AppsClient) GetInstanceProcessThreadSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string, instanceID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "instanceId": autorest.Encode("path", instanceID),
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -11593,42 +11622,39 @@ func (client AppsClient) GetNetworkTraceOperationSlotPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/operationresults/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/processes/{processId}/threads/{threadId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTraceOperationSlotSender sends the GetNetworkTraceOperationSlot request. The method will close the
+// GetInstanceProcessThreadSlotSender sends the GetInstanceProcessThreadSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTraceOperationSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetInstanceProcessThreadSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTraceOperationSlotResponder handles the response to the GetNetworkTraceOperationSlot request. The method always
+// GetInstanceProcessThreadSlotResponder handles the response to the GetInstanceProcessThreadSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTraceOperationSlotResponder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetInstanceProcessThreadSlotResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTraceOperationSlotV2 gets a named operation for a network trace capturing (or deployment slot, if
-// specified).
+// GetMigrateMySQLStatus returns the status of MySql in app migration, if one is active, and whether or not MySql in
+// app is enabled
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
-// production slot.
-func (client AppsClient) GetNetworkTraceOperationSlotV2(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+func (client AppsClient) GetMigrateMySQLStatus(ctx context.Context, resourceGroupName string, name string) (result MigrateMySQLStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationSlotV2")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMigrateMySQLStatus")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11642,37 +11668,35 @@ func (client AppsClient) GetNetworkTraceOperationSlotV2(ctx context.Context, res
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationSlotV2", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMigrateMySQLStatus", err.Error())
}
- req, err := client.GetNetworkTraceOperationSlotV2Preparer(ctx, resourceGroupName, name, operationID, slot)
+ req, err := client.GetMigrateMySQLStatusPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTraceOperationSlotV2Sender(req)
+ resp, err := client.GetMigrateMySQLStatusSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTraceOperationSlotV2Responder(resp)
+ result, err = client.GetMigrateMySQLStatusResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatus", resp, "Failure responding to request")
}
return
}
-// GetNetworkTraceOperationSlotV2Preparer prepares the GetNetworkTraceOperationSlotV2 request.
-func (client AppsClient) GetNetworkTraceOperationSlotV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
+// GetMigrateMySQLStatusPreparer prepares the GetMigrateMySQLStatus request.
+func (client AppsClient) GetMigrateMySQLStatusPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11684,39 +11708,40 @@ func (client AppsClient) GetNetworkTraceOperationSlotV2Preparer(ctx context.Cont
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTraces/current/operationresults/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/migratemysql/status", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTraceOperationSlotV2Sender sends the GetNetworkTraceOperationSlotV2 request. The method will close the
+// GetMigrateMySQLStatusSender sends the GetMigrateMySQLStatus request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTraceOperationSlotV2Sender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMigrateMySQLStatusSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTraceOperationSlotV2Responder handles the response to the GetNetworkTraceOperationSlotV2 request. The method always
+// GetMigrateMySQLStatusResponder handles the response to the GetMigrateMySQLStatus request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTraceOperationSlotV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMigrateMySQLStatusResponder(resp *http.Response) (result MigrateMySQLStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTraceOperationV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetMigrateMySQLStatusSlot returns the status of MySql in app migration, if one is active, and whether or not MySql
+// in app is enabled
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-func (client AppsClient) GetNetworkTraceOperationV2(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+// slot - name of the deployment slot.
+func (client AppsClient) GetMigrateMySQLStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MigrateMySQLStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationV2")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMigrateMySQLStatusSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11730,36 +11755,36 @@ func (client AppsClient) GetNetworkTraceOperationV2(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationV2", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMigrateMySQLStatusSlot", err.Error())
}
- req, err := client.GetNetworkTraceOperationV2Preparer(ctx, resourceGroupName, name, operationID)
+ req, err := client.GetMigrateMySQLStatusSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTraceOperationV2Sender(req)
+ resp, err := client.GetMigrateMySQLStatusSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTraceOperationV2Responder(resp)
+ result, err = client.GetMigrateMySQLStatusSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMigrateMySQLStatusSlot", resp, "Failure responding to request")
}
return
}
-// GetNetworkTraceOperationV2Preparer prepares the GetNetworkTraceOperationV2 request.
-func (client AppsClient) GetNetworkTraceOperationV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
+// GetMigrateMySQLStatusSlotPreparer prepares the GetMigrateMySQLStatusSlot request.
+func (client AppsClient) GetMigrateMySQLStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11771,39 +11796,38 @@ func (client AppsClient) GetNetworkTraceOperationV2Preparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTraces/current/operationresults/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/migratemysql/status", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTraceOperationV2Sender sends the GetNetworkTraceOperationV2 request. The method will close the
+// GetMigrateMySQLStatusSlotSender sends the GetMigrateMySQLStatusSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTraceOperationV2Sender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMigrateMySQLStatusSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTraceOperationV2Responder handles the response to the GetNetworkTraceOperationV2 request. The method always
+// GetMigrateMySQLStatusSlotResponder handles the response to the GetMigrateMySQLStatusSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTraceOperationV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMigrateMySQLStatusSlotResponder(resp *http.Response) (result MigrateMySQLStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTraces gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetMSDeployLog get the MSDeploy Log for the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-func (client AppsClient) GetNetworkTraces(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+func (client AppsClient) GetMSDeployLog(ctx context.Context, resourceGroupName string, name string) (result MSDeployLog, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraces")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployLog")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11817,35 +11841,34 @@ func (client AppsClient) GetNetworkTraces(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTraces", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMSDeployLog", err.Error())
}
- req, err := client.GetNetworkTracesPreparer(ctx, resourceGroupName, name, operationID)
+ req, err := client.GetMSDeployLogPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTracesSender(req)
+ resp, err := client.GetMSDeployLogSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTracesResponder(resp)
+ result, err = client.GetMSDeployLogResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLog", resp, "Failure responding to request")
}
return
}
-// GetNetworkTracesPreparer prepares the GetNetworkTraces request.
-func (client AppsClient) GetNetworkTracesPreparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
+// GetMSDeployLogPreparer prepares the GetMSDeployLog request.
+func (client AppsClient) GetMSDeployLogPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -11858,41 +11881,39 @@ func (client AppsClient) GetNetworkTracesPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTracesSender sends the GetNetworkTraces request. The method will close the
+// GetMSDeployLogSender sends the GetMSDeployLog request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTracesSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMSDeployLogSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTracesResponder handles the response to the GetNetworkTraces request. The method always
+// GetMSDeployLogResponder handles the response to the GetMSDeployLog request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTracesResponder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMSDeployLogResponder(resp *http.Response) (result MSDeployLog, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTracesSlot gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetMSDeployLogSlot get the MSDeploy Log for the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
-// production slot.
-func (client AppsClient) GetNetworkTracesSlot(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetMSDeployLogSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MSDeployLog, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployLogSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11906,35 +11927,34 @@ func (client AppsClient) GetNetworkTracesSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTracesSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMSDeployLogSlot", err.Error())
}
- req, err := client.GetNetworkTracesSlotPreparer(ctx, resourceGroupName, name, operationID, slot)
+ req, err := client.GetMSDeployLogSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTracesSlotSender(req)
+ resp, err := client.GetMSDeployLogSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTracesSlotResponder(resp)
+ result, err = client.GetMSDeployLogSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployLogSlot", resp, "Failure responding to request")
}
return
}
-// GetNetworkTracesSlotPreparer prepares the GetNetworkTracesSlot request.
-func (client AppsClient) GetNetworkTracesSlotPreparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
+// GetMSDeployLogSlotPreparer prepares the GetMSDeployLogSlot request.
+func (client AppsClient) GetMSDeployLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -11948,41 +11968,38 @@ func (client AppsClient) GetNetworkTracesSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTracesSlotSender sends the GetNetworkTracesSlot request. The method will close the
+// GetMSDeployLogSlotSender sends the GetMSDeployLogSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTracesSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMSDeployLogSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTracesSlotResponder handles the response to the GetNetworkTracesSlot request. The method always
+// GetMSDeployLogSlotResponder handles the response to the GetMSDeployLogSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTracesSlotResponder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMSDeployLogSlotResponder(resp *http.Response) (result MSDeployLog, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTracesSlotV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetMSDeployStatus get the status of the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
-// production slot.
-func (client AppsClient) GetNetworkTracesSlotV2(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+func (client AppsClient) GetMSDeployStatus(ctx context.Context, resourceGroupName string, name string) (result MSDeployStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesSlotV2")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployStatus")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -11996,37 +12013,35 @@ func (client AppsClient) GetNetworkTracesSlotV2(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTracesSlotV2", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMSDeployStatus", err.Error())
}
- req, err := client.GetNetworkTracesSlotV2Preparer(ctx, resourceGroupName, name, operationID, slot)
+ req, err := client.GetMSDeployStatusPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTracesSlotV2Sender(req)
+ resp, err := client.GetMSDeployStatusSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTracesSlotV2Responder(resp)
+ result, err = client.GetMSDeployStatusResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatus", resp, "Failure responding to request")
}
return
}
-// GetNetworkTracesSlotV2Preparer prepares the GetNetworkTracesSlotV2 request.
-func (client AppsClient) GetNetworkTracesSlotV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
+// GetMSDeployStatusPreparer prepares the GetMSDeployStatus request.
+func (client AppsClient) GetMSDeployStatusPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12038,39 +12053,39 @@ func (client AppsClient) GetNetworkTracesSlotV2Preparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTraces/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTracesSlotV2Sender sends the GetNetworkTracesSlotV2 request. The method will close the
+// GetMSDeployStatusSender sends the GetMSDeployStatus request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTracesSlotV2Sender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMSDeployStatusSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTracesSlotV2Responder handles the response to the GetNetworkTracesSlotV2 request. The method always
+// GetMSDeployStatusResponder handles the response to the GetMSDeployStatus request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTracesSlotV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMSDeployStatusResponder(resp *http.Response) (result MSDeployStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetNetworkTracesV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
+// GetMSDeployStatusSlot get the status of the last MSDeploy operation.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// operationID - GUID of the operation.
-func (client AppsClient) GetNetworkTracesV2(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetMSDeployStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result MSDeployStatus, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesV2")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetMSDeployStatusSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12084,36 +12099,36 @@ func (client AppsClient) GetNetworkTracesV2(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetNetworkTracesV2", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetMSDeployStatusSlot", err.Error())
}
- req, err := client.GetNetworkTracesV2Preparer(ctx, resourceGroupName, name, operationID)
+ req, err := client.GetMSDeployStatusSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetNetworkTracesV2Sender(req)
+ resp, err := client.GetMSDeployStatusSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", resp, "Failure sending request")
return
}
- result, err = client.GetNetworkTracesV2Responder(resp)
+ result, err = client.GetMSDeployStatusSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetMSDeployStatusSlot", resp, "Failure responding to request")
}
return
}
-// GetNetworkTracesV2Preparer prepares the GetNetworkTracesV2 request.
-func (client AppsClient) GetNetworkTracesV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
+// GetMSDeployStatusSlotPreparer prepares the GetMSDeployStatusSlot request.
+func (client AppsClient) GetMSDeployStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12125,39 +12140,39 @@ func (client AppsClient) GetNetworkTracesV2Preparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTraces/{operationId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetNetworkTracesV2Sender sends the GetNetworkTracesV2 request. The method will close the
+// GetMSDeployStatusSlotSender sends the GetMSDeployStatusSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetNetworkTracesV2Sender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetMSDeployStatusSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetNetworkTracesV2Responder handles the response to the GetNetworkTracesV2 request. The method always
+// GetMSDeployStatusSlotResponder handles the response to the GetMSDeployStatusSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetNetworkTracesV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
+func (client AppsClient) GetMSDeployStatusSlotResponder(resp *http.Response) (result MSDeployStatus, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPremierAddOn gets a named add-on of an app.
+// GetNetworkTraceOperation gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// premierAddOnName - add-on name.
-func (client AppsClient) GetPremierAddOn(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (result PremierAddOn, err error) {
+// operationID - GUID of the operation.
+func (client AppsClient) GetNetworkTraceOperation(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPremierAddOn")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperation")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12171,35 +12186,35 @@ func (client AppsClient) GetPremierAddOn(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPremierAddOn", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperation", err.Error())
}
- req, err := client.GetPremierAddOnPreparer(ctx, resourceGroupName, name, premierAddOnName)
+ req, err := client.GetNetworkTraceOperationPreparer(ctx, resourceGroupName, name, operationID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", nil, "Failure preparing request")
return
}
- resp, err := client.GetPremierAddOnSender(req)
+ resp, err := client.GetNetworkTraceOperationSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", resp, "Failure sending request")
return
}
- result, err = client.GetPremierAddOnResponder(resp)
+ result, err = client.GetNetworkTraceOperationResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperation", resp, "Failure responding to request")
}
return
}
-// GetPremierAddOnPreparer prepares the GetPremierAddOn request.
-func (client AppsClient) GetPremierAddOnPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (*http.Request, error) {
+// GetNetworkTraceOperationPreparer prepares the GetNetworkTraceOperation request.
+func (client AppsClient) GetNetworkTraceOperationPreparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "premierAddOnName": autorest.Encode("path", premierAddOnName),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12212,41 +12227,42 @@ func (client AppsClient) GetPremierAddOnPreparer(ctx context.Context, resourceGr
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/operationresults/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPremierAddOnSender sends the GetPremierAddOn request. The method will close the
+// GetNetworkTraceOperationSender sends the GetNetworkTraceOperation request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPremierAddOnSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTraceOperationSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPremierAddOnResponder handles the response to the GetPremierAddOn request. The method always
+// GetNetworkTraceOperationResponder handles the response to the GetNetworkTraceOperation request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPremierAddOnResponder(resp *http.Response) (result PremierAddOn, err error) {
+func (client AppsClient) GetNetworkTraceOperationResponder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPremierAddOnSlot gets a named add-on of an app.
+// GetNetworkTraceOperationSlot gets a named operation for a network trace capturing (or deployment slot, if
+// specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// premierAddOnName - add-on name.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the named add-on for the
+// operationID - GUID of the operation.
+// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
// production slot.
-func (client AppsClient) GetPremierAddOnSlot(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (result PremierAddOn, err error) {
+func (client AppsClient) GetNetworkTraceOperationSlot(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPremierAddOnSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12260,35 +12276,35 @@ func (client AppsClient) GetPremierAddOnSlot(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPremierAddOnSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationSlot", err.Error())
}
- req, err := client.GetPremierAddOnSlotPreparer(ctx, resourceGroupName, name, premierAddOnName, slot)
+ req, err := client.GetNetworkTraceOperationSlotPreparer(ctx, resourceGroupName, name, operationID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetPremierAddOnSlotSender(req)
+ resp, err := client.GetNetworkTraceOperationSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", resp, "Failure sending request")
return
}
- result, err = client.GetPremierAddOnSlotResponder(resp)
+ result, err = client.GetNetworkTraceOperationSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlot", resp, "Failure responding to request")
}
return
}
-// GetPremierAddOnSlotPreparer prepares the GetPremierAddOnSlot request.
-func (client AppsClient) GetPremierAddOnSlotPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (*http.Request, error) {
+// GetNetworkTraceOperationSlotPreparer prepares the GetNetworkTraceOperationSlot request.
+func (client AppsClient) GetNetworkTraceOperationSlotPreparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "premierAddOnName": autorest.Encode("path", premierAddOnName),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -12302,39 +12318,42 @@ func (client AppsClient) GetPremierAddOnSlotPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/operationresults/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPremierAddOnSlotSender sends the GetPremierAddOnSlot request. The method will close the
+// GetNetworkTraceOperationSlotSender sends the GetNetworkTraceOperationSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPremierAddOnSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTraceOperationSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPremierAddOnSlotResponder handles the response to the GetPremierAddOnSlot request. The method always
+// GetNetworkTraceOperationSlotResponder handles the response to the GetNetworkTraceOperationSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPremierAddOnSlotResponder(resp *http.Response) (result PremierAddOn, err error) {
+func (client AppsClient) GetNetworkTraceOperationSlotResponder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPrivateAccess gets data around private site access enablement and authorized Virtual Networks that can access the
-// site.
+// GetNetworkTraceOperationSlotV2 gets a named operation for a network trace capturing (or deployment slot, if
+// specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-func (client AppsClient) GetPrivateAccess(ctx context.Context, resourceGroupName string, name string) (result PrivateAccess, err error) {
+// name - name of the app.
+// operationID - GUID of the operation.
+// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
+// production slot.
+func (client AppsClient) GetNetworkTraceOperationSlotV2(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPrivateAccess")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationSlotV2")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12348,35 +12367,37 @@ func (client AppsClient) GetPrivateAccess(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPrivateAccess", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationSlotV2", err.Error())
}
- req, err := client.GetPrivateAccessPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetNetworkTraceOperationSlotV2Preparer(ctx, resourceGroupName, name, operationID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", nil, "Failure preparing request")
return
}
- resp, err := client.GetPrivateAccessSender(req)
+ resp, err := client.GetNetworkTraceOperationSlotV2Sender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", resp, "Failure sending request")
return
}
- result, err = client.GetPrivateAccessResponder(resp)
+ result, err = client.GetNetworkTraceOperationSlotV2Responder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationSlotV2", resp, "Failure responding to request")
}
return
}
-// GetPrivateAccessPreparer prepares the GetPrivateAccess request.
-func (client AppsClient) GetPrivateAccessPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetNetworkTraceOperationSlotV2Preparer prepares the GetNetworkTraceOperationSlotV2 request.
+func (client AppsClient) GetNetworkTraceOperationSlotV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12388,40 +12409,39 @@ func (client AppsClient) GetPrivateAccessPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/privateAccess/virtualNetworks", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTraces/current/operationresults/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPrivateAccessSender sends the GetPrivateAccess request. The method will close the
+// GetNetworkTraceOperationSlotV2Sender sends the GetNetworkTraceOperationSlotV2 request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPrivateAccessSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTraceOperationSlotV2Sender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPrivateAccessResponder handles the response to the GetPrivateAccess request. The method always
+// GetNetworkTraceOperationSlotV2Responder handles the response to the GetNetworkTraceOperationSlotV2 request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPrivateAccessResponder(resp *http.Response) (result PrivateAccess, err error) {
+func (client AppsClient) GetNetworkTraceOperationSlotV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPrivateAccessSlot gets data around private site access enablement and authorized Virtual Networks that can access
-// the site.
+// GetNetworkTraceOperationV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - the name of the web app.
-// slot - the name of the slot for the web app.
-func (client AppsClient) GetPrivateAccessSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result PrivateAccess, err error) {
+// name - name of the app.
+// operationID - GUID of the operation.
+func (client AppsClient) GetNetworkTraceOperationV2(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPrivateAccessSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraceOperationV2")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12435,36 +12455,36 @@ func (client AppsClient) GetPrivateAccessSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPrivateAccessSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTraceOperationV2", err.Error())
}
- req, err := client.GetPrivateAccessSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetNetworkTraceOperationV2Preparer(ctx, resourceGroupName, name, operationID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", nil, "Failure preparing request")
return
}
- resp, err := client.GetPrivateAccessSlotSender(req)
+ resp, err := client.GetNetworkTraceOperationV2Sender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", resp, "Failure sending request")
return
}
- result, err = client.GetPrivateAccessSlotResponder(resp)
+ result, err = client.GetNetworkTraceOperationV2Responder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraceOperationV2", resp, "Failure responding to request")
}
return
}
-// GetPrivateAccessSlotPreparer prepares the GetPrivateAccessSlot request.
-func (client AppsClient) GetPrivateAccessSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetNetworkTraceOperationV2Preparer prepares the GetNetworkTraceOperationV2 request.
+func (client AppsClient) GetNetworkTraceOperationV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12476,39 +12496,39 @@ func (client AppsClient) GetPrivateAccessSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/privateAccess/virtualNetworks", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTraces/current/operationresults/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPrivateAccessSlotSender sends the GetPrivateAccessSlot request. The method will close the
+// GetNetworkTraceOperationV2Sender sends the GetNetworkTraceOperationV2 request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPrivateAccessSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTraceOperationV2Sender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPrivateAccessSlotResponder handles the response to the GetPrivateAccessSlot request. The method always
+// GetNetworkTraceOperationV2Responder handles the response to the GetNetworkTraceOperationV2 request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPrivateAccessSlotResponder(resp *http.Response) (result PrivateAccess, err error) {
+func (client AppsClient) GetNetworkTraceOperationV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcess get process information by its ID for a specific scaled-out instance in a web site.
+// GetNetworkTraces gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-func (client AppsClient) GetProcess(ctx context.Context, resourceGroupName string, name string, processID string) (result ProcessInfo, err error) {
+// name - name of the app.
+// operationID - GUID of the operation.
+func (client AppsClient) GetNetworkTraces(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcess")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTraces")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12522,35 +12542,35 @@ func (client AppsClient) GetProcess(ctx context.Context, resourceGroupName strin
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcess", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTraces", err.Error())
}
- req, err := client.GetProcessPreparer(ctx, resourceGroupName, name, processID)
+ req, err := client.GetNetworkTracesPreparer(ctx, resourceGroupName, name, operationID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessSender(req)
+ resp, err := client.GetNetworkTracesSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", resp, "Failure sending request")
return
}
- result, err = client.GetProcessResponder(resp)
+ result, err = client.GetNetworkTracesResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTraces", resp, "Failure responding to request")
}
return
}
-// GetProcessPreparer prepares the GetProcess request.
-func (client AppsClient) GetProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
+// GetNetworkTracesPreparer prepares the GetNetworkTraces request.
+func (client AppsClient) GetNetworkTracesPreparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12563,39 +12583,41 @@ func (client AppsClient) GetProcessPreparer(ctx context.Context, resourceGroupNa
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessSender sends the GetProcess request. The method will close the
+// GetNetworkTracesSender sends the GetNetworkTraces request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTracesSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessResponder handles the response to the GetProcess request. The method always
+// GetNetworkTracesResponder handles the response to the GetNetworkTraces request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessResponder(resp *http.Response) (result ProcessInfo, err error) {
+func (client AppsClient) GetNetworkTracesResponder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessDump get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
+// GetNetworkTracesSlot gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-func (client AppsClient) GetProcessDump(ctx context.Context, resourceGroupName string, name string, processID string) (result ReadCloser, err error) {
+// name - name of the app.
+// operationID - GUID of the operation.
+// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
+// production slot.
+func (client AppsClient) GetNetworkTracesSlot(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessDump")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12609,36 +12631,37 @@ func (client AppsClient) GetProcessDump(ctx context.Context, resourceGroupName s
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessDump", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTracesSlot", err.Error())
}
- req, err := client.GetProcessDumpPreparer(ctx, resourceGroupName, name, processID)
+ req, err := client.GetNetworkTracesSlotPreparer(ctx, resourceGroupName, name, operationID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessDumpSender(req)
+ resp, err := client.GetNetworkTracesSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", resp, "Failure sending request")
return
}
- result, err = client.GetProcessDumpResponder(resp)
+ result, err = client.GetNetworkTracesSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlot", resp, "Failure responding to request")
}
return
}
-// GetProcessDumpPreparer prepares the GetProcessDump request.
-func (client AppsClient) GetProcessDumpPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
+// GetNetworkTracesSlotPreparer prepares the GetNetworkTracesSlot request.
+func (client AppsClient) GetNetworkTracesSlotPreparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12650,40 +12673,41 @@ func (client AppsClient) GetProcessDumpPreparer(ctx context.Context, resourceGro
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/dump", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessDumpSender sends the GetProcessDump request. The method will close the
+// GetNetworkTracesSlotSender sends the GetNetworkTracesSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessDumpSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTracesSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessDumpResponder handles the response to the GetProcessDump request. The method always
+// GetNetworkTracesSlotResponder handles the response to the GetNetworkTracesSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessDumpResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetNetworkTracesSlotResponder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessDumpSlot get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
+// GetNetworkTracesSlotV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// name - name of the app.
+// operationID - GUID of the operation.
+// slot - name of the deployment slot. If a slot is not specified, the API will get an operation for the
// production slot.
-func (client AppsClient) GetProcessDumpSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result ReadCloser, err error) {
+func (client AppsClient) GetNetworkTracesSlotV2(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessDumpSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesSlotV2")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12697,35 +12721,35 @@ func (client AppsClient) GetProcessDumpSlot(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessDumpSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTracesSlotV2", err.Error())
}
- req, err := client.GetProcessDumpSlotPreparer(ctx, resourceGroupName, name, processID, slot)
+ req, err := client.GetNetworkTracesSlotV2Preparer(ctx, resourceGroupName, name, operationID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessDumpSlotSender(req)
+ resp, err := client.GetNetworkTracesSlotV2Sender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", resp, "Failure sending request")
return
}
- result, err = client.GetProcessDumpSlotResponder(resp)
+ result, err = client.GetNetworkTracesSlotV2Responder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesSlotV2", resp, "Failure responding to request")
}
return
}
-// GetProcessDumpSlotPreparer prepares the GetProcessDumpSlot request.
-func (client AppsClient) GetProcessDumpSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
+// GetNetworkTracesSlotV2Preparer prepares the GetNetworkTracesSlotV2 request.
+func (client AppsClient) GetNetworkTracesSlotV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -12739,39 +12763,39 @@ func (client AppsClient) GetProcessDumpSlotPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/dump", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTraces/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessDumpSlotSender sends the GetProcessDumpSlot request. The method will close the
+// GetNetworkTracesSlotV2Sender sends the GetNetworkTracesSlotV2 request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessDumpSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTracesSlotV2Sender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessDumpSlotResponder handles the response to the GetProcessDumpSlot request. The method always
+// GetNetworkTracesSlotV2Responder handles the response to the GetNetworkTracesSlotV2 request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessDumpSlotResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetNetworkTracesSlotV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result.Value),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessModule get process information by its ID for a specific scaled-out instance in a web site.
+// GetNetworkTracesV2 gets a named operation for a network trace capturing (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// baseAddress - module base address.
-func (client AppsClient) GetProcessModule(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string) (result ProcessModuleInfo, err error) {
+// name - name of the app.
+// operationID - GUID of the operation.
+func (client AppsClient) GetNetworkTracesV2(ctx context.Context, resourceGroupName string, name string, operationID string) (result ListNetworkTrace, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessModule")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetNetworkTracesV2")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12785,36 +12809,35 @@ func (client AppsClient) GetProcessModule(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessModule", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetNetworkTracesV2", err.Error())
}
- req, err := client.GetProcessModulePreparer(ctx, resourceGroupName, name, processID, baseAddress)
+ req, err := client.GetNetworkTracesV2Preparer(ctx, resourceGroupName, name, operationID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessModuleSender(req)
+ resp, err := client.GetNetworkTracesV2Sender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", resp, "Failure sending request")
return
}
- result, err = client.GetProcessModuleResponder(resp)
+ result, err = client.GetNetworkTracesV2Responder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetNetworkTracesV2", resp, "Failure responding to request")
}
return
}
-// GetProcessModulePreparer prepares the GetProcessModule request.
-func (client AppsClient) GetProcessModulePreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string) (*http.Request, error) {
+// GetNetworkTracesV2Preparer prepares the GetNetworkTracesV2 request.
+func (client AppsClient) GetNetworkTracesV2Preparer(ctx context.Context, resourceGroupName string, name string, operationID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "baseAddress": autorest.Encode("path", baseAddress),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "operationId": autorest.Encode("path", operationID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12827,42 +12850,39 @@ func (client AppsClient) GetProcessModulePreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/modules/{baseAddress}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTraces/{operationId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessModuleSender sends the GetProcessModule request. The method will close the
+// GetNetworkTracesV2Sender sends the GetNetworkTracesV2 request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessModuleSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetNetworkTracesV2Sender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessModuleResponder handles the response to the GetProcessModule request. The method always
+// GetNetworkTracesV2Responder handles the response to the GetNetworkTracesV2 request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessModuleResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
+func (client AppsClient) GetNetworkTracesV2Responder(resp *http.Response) (result ListNetworkTrace, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result.Value),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessModuleSlot get process information by its ID for a specific scaled-out instance in a web site.
+// GetPremierAddOn gets a named add-on of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// baseAddress - module base address.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) GetProcessModuleSlot(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string) (result ProcessModuleInfo, err error) {
+// name - name of the app.
+// premierAddOnName - add-on name.
+func (client AppsClient) GetPremierAddOn(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (result PremierAddOn, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessModuleSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPremierAddOn")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12876,38 +12896,36 @@ func (client AppsClient) GetProcessModuleSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessModuleSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPremierAddOn", err.Error())
}
- req, err := client.GetProcessModuleSlotPreparer(ctx, resourceGroupName, name, processID, baseAddress, slot)
+ req, err := client.GetPremierAddOnPreparer(ctx, resourceGroupName, name, premierAddOnName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessModuleSlotSender(req)
+ resp, err := client.GetPremierAddOnSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", resp, "Failure sending request")
return
}
- result, err = client.GetProcessModuleSlotResponder(resp)
+ result, err = client.GetPremierAddOnResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOn", resp, "Failure responding to request")
}
return
}
-// GetProcessModuleSlotPreparer prepares the GetProcessModuleSlot request.
-func (client AppsClient) GetProcessModuleSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string) (*http.Request, error) {
+// GetPremierAddOnPreparer prepares the GetPremierAddOn request.
+func (client AppsClient) GetPremierAddOnPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "baseAddress": autorest.Encode("path", baseAddress),
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -12919,41 +12937,41 @@ func (client AppsClient) GetProcessModuleSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/modules/{baseAddress}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessModuleSlotSender sends the GetProcessModuleSlot request. The method will close the
+// GetPremierAddOnSender sends the GetPremierAddOn request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessModuleSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPremierAddOnSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessModuleSlotResponder handles the response to the GetProcessModuleSlot request. The method always
+// GetPremierAddOnResponder handles the response to the GetPremierAddOn request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessModuleSlotResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
+func (client AppsClient) GetPremierAddOnResponder(resp *http.Response) (result PremierAddOn, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessSlot get process information by its ID for a specific scaled-out instance in a web site.
+// GetPremierAddOnSlot gets a named add-on of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// name - name of the app.
+// premierAddOnName - add-on name.
+// slot - name of the deployment slot. If a slot is not specified, the API will get the named add-on for the
// production slot.
-func (client AppsClient) GetProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result ProcessInfo, err error) {
+func (client AppsClient) GetPremierAddOnSlot(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (result PremierAddOn, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPremierAddOnSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -12967,35 +12985,35 @@ func (client AppsClient) GetProcessSlot(ctx context.Context, resourceGroupName s
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPremierAddOnSlot", err.Error())
}
- req, err := client.GetProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot)
+ req, err := client.GetPremierAddOnSlotPreparer(ctx, resourceGroupName, name, premierAddOnName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessSlotSender(req)
+ resp, err := client.GetPremierAddOnSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", resp, "Failure sending request")
return
}
- result, err = client.GetProcessSlotResponder(resp)
+ result, err = client.GetPremierAddOnSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPremierAddOnSlot", resp, "Failure responding to request")
}
return
}
-// GetProcessSlotPreparer prepares the GetProcessSlot request.
-func (client AppsClient) GetProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
+// GetPremierAddOnSlotPreparer prepares the GetPremierAddOnSlot request.
+func (client AppsClient) GetPremierAddOnSlotPreparer(ctx context.Context, resourceGroupName string, name string, premierAddOnName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
+ "premierAddOnName": autorest.Encode("path", premierAddOnName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -13009,41 +13027,39 @@ func (client AppsClient) GetProcessSlotPreparer(ctx context.Context, resourceGro
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessSlotSender sends the GetProcessSlot request. The method will close the
+// GetPremierAddOnSlotSender sends the GetPremierAddOnSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPremierAddOnSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessSlotResponder handles the response to the GetProcessSlot request. The method always
+// GetPremierAddOnSlotResponder handles the response to the GetPremierAddOnSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessSlotResponder(resp *http.Response) (result ProcessInfo, err error) {
+func (client AppsClient) GetPremierAddOnSlotResponder(resp *http.Response) (result PremierAddOn, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessThread get thread information by Thread ID for a specific process, in a specific scaled-out instance in a
-// web site.
+// GetPrivateAccess gets data around private site access enablement and authorized Virtual Networks that can access the
+// site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// threadID - tID.
-func (client AppsClient) GetProcessThread(ctx context.Context, resourceGroupName string, name string, processID string, threadID string) (result ProcessThreadInfo, err error) {
+// name - the name of the web app.
+func (client AppsClient) GetPrivateAccess(ctx context.Context, resourceGroupName string, name string) (result PrivateAccess, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessThread")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPrivateAccess")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13057,38 +13073,36 @@ func (client AppsClient) GetProcessThread(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessThread", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPrivateAccess", err.Error())
}
- req, err := client.GetProcessThreadPreparer(ctx, resourceGroupName, name, processID, threadID)
+ req, err := client.GetPrivateAccessPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessThreadSender(req)
+ resp, err := client.GetPrivateAccessSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", resp, "Failure sending request")
return
}
- result, err = client.GetProcessThreadResponder(resp)
+ result, err = client.GetPrivateAccessResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccess", resp, "Failure responding to request")
}
return
}
-// GetProcessThreadPreparer prepares the GetProcessThread request.
-func (client AppsClient) GetProcessThreadPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string) (*http.Request, error) {
+// GetPrivateAccessPreparer prepares the GetPrivateAccess request.
+func (client AppsClient) GetPrivateAccessPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -13099,43 +13113,40 @@ func (client AppsClient) GetProcessThreadPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/threads/{threadId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/privateAccess/virtualNetworks", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessThreadSender sends the GetProcessThread request. The method will close the
+// GetPrivateAccessSender sends the GetPrivateAccess request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessThreadSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPrivateAccessSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessThreadResponder handles the response to the GetProcessThread request. The method always
+// GetPrivateAccessResponder handles the response to the GetPrivateAccess request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessThreadResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
+func (client AppsClient) GetPrivateAccessResponder(resp *http.Response) (result PrivateAccess, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetProcessThreadSlot get thread information by Thread ID for a specific process, in a specific scaled-out instance
-// in a web site.
+// GetPrivateAccessSlot gets data around private site access enablement and authorized Virtual Networks that can access
+// the site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// processID - pID.
-// threadID - tID.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) GetProcessThreadSlot(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string) (result ProcessThreadInfo, err error) {
+// name - the name of the web app.
+// slot - the name of the slot for the web app.
+func (client AppsClient) GetPrivateAccessSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result PrivateAccess, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessThreadSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPrivateAccessSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13149,39 +13160,37 @@ func (client AppsClient) GetProcessThreadSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetProcessThreadSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPrivateAccessSlot", err.Error())
}
- req, err := client.GetProcessThreadSlotPreparer(ctx, resourceGroupName, name, processID, threadID, slot)
+ req, err := client.GetPrivateAccessSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetProcessThreadSlotSender(req)
+ resp, err := client.GetPrivateAccessSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", resp, "Failure sending request")
return
}
- result, err = client.GetProcessThreadSlotResponder(resp)
+ result, err = client.GetPrivateAccessSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPrivateAccessSlot", resp, "Failure responding to request")
}
return
}
-// GetProcessThreadSlotPreparer prepares the GetProcessThreadSlot request.
-func (client AppsClient) GetProcessThreadSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string) (*http.Request, error) {
+// GetPrivateAccessSlotPreparer prepares the GetPrivateAccessSlot request.
+func (client AppsClient) GetPrivateAccessSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
- "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -13192,39 +13201,39 @@ func (client AppsClient) GetProcessThreadSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/threads/{threadId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/privateAccess/virtualNetworks", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetProcessThreadSlotSender sends the GetProcessThreadSlot request. The method will close the
+// GetPrivateAccessSlotSender sends the GetPrivateAccessSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetProcessThreadSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPrivateAccessSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetProcessThreadSlotResponder handles the response to the GetProcessThreadSlot request. The method always
+// GetPrivateAccessSlotResponder handles the response to the GetPrivateAccessSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetProcessThreadSlotResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
+func (client AppsClient) GetPrivateAccessSlotResponder(resp *http.Response) (result PrivateAccess, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPublicCertificate get the named public certificate for an app (or deployment slot, if specified).
+// GetProcess get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// publicCertificateName - public certificate name.
-func (client AppsClient) GetPublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (result PublicCertificate, err error) {
+// name - site name.
+// processID - pID.
+func (client AppsClient) GetProcess(ctx context.Context, resourceGroupName string, name string, processID string) (result ProcessInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPublicCertificate")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcess")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13238,37 +13247,37 @@ func (client AppsClient) GetPublicCertificate(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPublicCertificate", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcess", err.Error())
}
- req, err := client.GetPublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName)
+ req, err := client.GetProcessPreparer(ctx, resourceGroupName, name, processID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", nil, "Failure preparing request")
return
}
- resp, err := client.GetPublicCertificateSender(req)
+ resp, err := client.GetProcessSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", resp, "Failure sending request")
return
}
- result, err = client.GetPublicCertificateResponder(resp)
+ result, err = client.GetProcessResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcess", resp, "Failure responding to request")
}
return
}
-// GetPublicCertificatePreparer prepares the GetPublicCertificate request.
-func (client AppsClient) GetPublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (*http.Request, error) {
+// GetProcessPreparer prepares the GetProcess request.
+func (client AppsClient) GetProcessPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -13279,41 +13288,39 @@ func (client AppsClient) GetPublicCertificatePreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPublicCertificateSender sends the GetPublicCertificate request. The method will close the
+// GetProcessSender sends the GetProcess request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPublicCertificateSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPublicCertificateResponder handles the response to the GetPublicCertificate request. The method always
+// GetProcessResponder handles the response to the GetProcess request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPublicCertificateResponder(resp *http.Response) (result PublicCertificate, err error) {
+func (client AppsClient) GetProcessResponder(resp *http.Response) (result ProcessInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetPublicCertificateSlot get the named public certificate for an app (or deployment slot, if specified).
+// GetProcessDump get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API the named binding for the production
-// slot.
-// publicCertificateName - public certificate name.
-func (client AppsClient) GetPublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (result PublicCertificate, err error) {
+// name - site name.
+// processID - pID.
+func (client AppsClient) GetProcessDump(ctx context.Context, resourceGroupName string, name string, processID string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPublicCertificateSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessDump")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13327,38 +13334,37 @@ func (client AppsClient) GetPublicCertificateSlot(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetPublicCertificateSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessDump", err.Error())
}
- req, err := client.GetPublicCertificateSlotPreparer(ctx, resourceGroupName, name, slot, publicCertificateName)
+ req, err := client.GetProcessDumpPreparer(ctx, resourceGroupName, name, processID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", nil, "Failure preparing request")
return
}
- resp, err := client.GetPublicCertificateSlotSender(req)
+ resp, err := client.GetProcessDumpSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", resp, "Failure sending request")
return
}
- result, err = client.GetPublicCertificateSlotResponder(resp)
+ result, err = client.GetProcessDumpResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDump", resp, "Failure responding to request")
}
return
}
-// GetPublicCertificateSlotPreparer prepares the GetPublicCertificateSlot request.
-func (client AppsClient) GetPublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (*http.Request, error) {
+// GetProcessDumpPreparer prepares the GetProcessDump request.
+func (client AppsClient) GetProcessDumpPreparer(ctx context.Context, resourceGroupName string, name string, processID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "publicCertificateName": autorest.Encode("path", publicCertificateName),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -13369,39 +13375,40 @@ func (client AppsClient) GetPublicCertificateSlotPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/dump", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetPublicCertificateSlotSender sends the GetPublicCertificateSlot request. The method will close the
+// GetProcessDumpSender sends the GetProcessDump request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetPublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessDumpSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetPublicCertificateSlotResponder handles the response to the GetPublicCertificateSlot request. The method always
+// GetProcessDumpResponder handles the response to the GetProcessDump request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetPublicCertificateSlotResponder(resp *http.Response) (result PublicCertificate, err error) {
+func (client AppsClient) GetProcessDumpResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
result.Response = autorest.Response{Response: resp}
return
}
-// GetRelayServiceConnection gets a hybrid connection configuration by its name.
+// GetProcessDumpSlot get a memory dump of a process by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection.
-func (client AppsClient) GetRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string) (result RelayServiceConnectionEntity, err error) {
+// name - site name.
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) GetProcessDumpSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetRelayServiceConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessDumpSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13415,36 +13422,37 @@ func (client AppsClient) GetRelayServiceConnection(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetRelayServiceConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessDumpSlot", err.Error())
}
- req, err := client.GetRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName)
+ req, err := client.GetProcessDumpSlotPreparer(ctx, resourceGroupName, name, processID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetRelayServiceConnectionSender(req)
+ resp, err := client.GetProcessDumpSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", resp, "Failure sending request")
return
}
- result, err = client.GetRelayServiceConnectionResponder(resp)
+ result, err = client.GetProcessDumpSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessDumpSlot", resp, "Failure responding to request")
}
return
}
-// GetRelayServiceConnectionPreparer prepares the GetRelayServiceConnection request.
-func (client AppsClient) GetRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string) (*http.Request, error) {
+// GetProcessDumpSlotPreparer prepares the GetProcessDumpSlot request.
+func (client AppsClient) GetProcessDumpSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -13456,41 +13464,39 @@ func (client AppsClient) GetRelayServiceConnectionPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/dump", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetRelayServiceConnectionSender sends the GetRelayServiceConnection request. The method will close the
+// GetProcessDumpSlotSender sends the GetProcessDumpSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessDumpSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetRelayServiceConnectionResponder handles the response to the GetRelayServiceConnection request. The method always
+// GetProcessDumpSlotResponder handles the response to the GetProcessDumpSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetRelayServiceConnectionResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
+func (client AppsClient) GetProcessDumpSlotResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound))
result.Response = autorest.Response{Response: resp}
return
}
-// GetRelayServiceConnectionSlot gets a hybrid connection configuration by its name.
+// GetProcessModule get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// entityName - name of the hybrid connection.
-// slot - name of the deployment slot. If a slot is not specified, the API will get a hybrid connection for the
-// production slot.
-func (client AppsClient) GetRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (result RelayServiceConnectionEntity, err error) {
+// name - site name.
+// processID - pID.
+// baseAddress - module base address.
+func (client AppsClient) GetProcessModule(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string) (result ProcessModuleInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetRelayServiceConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessModule")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13504,37 +13510,37 @@ func (client AppsClient) GetRelayServiceConnectionSlot(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetRelayServiceConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessModule", err.Error())
}
- req, err := client.GetRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, slot)
+ req, err := client.GetProcessModulePreparer(ctx, resourceGroupName, name, processID, baseAddress)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", nil, "Failure preparing request")
return
}
- resp, err := client.GetRelayServiceConnectionSlotSender(req)
+ resp, err := client.GetProcessModuleSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", resp, "Failure sending request")
return
}
- result, err = client.GetRelayServiceConnectionSlotResponder(resp)
+ result, err = client.GetProcessModuleResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModule", resp, "Failure responding to request")
}
return
}
-// GetRelayServiceConnectionSlotPreparer prepares the GetRelayServiceConnectionSlot request.
-func (client AppsClient) GetRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (*http.Request, error) {
+// GetProcessModulePreparer prepares the GetProcessModule request.
+func (client AppsClient) GetProcessModulePreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "entityName": autorest.Encode("path", entityName),
+ "baseAddress": autorest.Encode("path", baseAddress),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -13546,39 +13552,42 @@ func (client AppsClient) GetRelayServiceConnectionSlotPreparer(ctx context.Conte
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/modules/{baseAddress}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetRelayServiceConnectionSlotSender sends the GetRelayServiceConnectionSlot request. The method will close the
+// GetProcessModuleSender sends the GetProcessModule request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessModuleSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetRelayServiceConnectionSlotResponder handles the response to the GetRelayServiceConnectionSlot request. The method always
+// GetProcessModuleResponder handles the response to the GetProcessModule request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetRelayServiceConnectionSlotResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
+func (client AppsClient) GetProcessModuleResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSiteExtension get site extension information by its ID for a web site, or a deployment slot.
+// GetProcessModuleSlot get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// siteExtensionID - site extension name.
-func (client AppsClient) GetSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result SiteExtensionInfo, err error) {
+// processID - pID.
+// baseAddress - module base address.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) GetProcessModuleSlot(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string) (result ProcessModuleInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSiteExtension")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessModuleSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13592,36 +13601,38 @@ func (client AppsClient) GetSiteExtension(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSiteExtension", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessModuleSlot", err.Error())
}
- req, err := client.GetSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
+ req, err := client.GetProcessModuleSlotPreparer(ctx, resourceGroupName, name, processID, baseAddress, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetSiteExtensionSender(req)
+ resp, err := client.GetProcessModuleSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", resp, "Failure sending request")
return
}
- result, err = client.GetSiteExtensionResponder(resp)
+ result, err = client.GetProcessModuleSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessModuleSlot", resp, "Failure responding to request")
}
return
}
-// GetSiteExtensionPreparer prepares the GetSiteExtension request.
-func (client AppsClient) GetSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
+// GetProcessModuleSlotPreparer prepares the GetProcessModuleSlot request.
+func (client AppsClient) GetProcessModuleSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, baseAddress string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "baseAddress": autorest.Encode("path", baseAddress),
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -13633,21 +13644,21 @@ func (client AppsClient) GetSiteExtensionPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/modules/{baseAddress}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSiteExtensionSender sends the GetSiteExtension request. The method will close the
+// GetProcessModuleSlotSender sends the GetProcessModuleSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSiteExtensionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessModuleSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSiteExtensionResponder handles the response to the GetSiteExtension request. The method always
+// GetProcessModuleSlotResponder handles the response to the GetProcessModuleSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSiteExtensionResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+func (client AppsClient) GetProcessModuleSlotResponder(resp *http.Response) (result ProcessModuleInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -13658,16 +13669,16 @@ func (client AppsClient) GetSiteExtensionResponder(resp *http.Response) (result
return
}
-// GetSiteExtensionSlot get site extension information by its ID for a web site, or a deployment slot.
+// GetProcessSlot get process information by its ID for a specific scaled-out instance in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// siteExtensionID - site extension name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// processID - pID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
// production slot.
-func (client AppsClient) GetSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result SiteExtensionInfo, err error) {
+func (client AppsClient) GetProcessSlot(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (result ProcessInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSiteExtensionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13681,36 +13692,36 @@ func (client AppsClient) GetSiteExtensionSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSiteExtensionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessSlot", err.Error())
}
- req, err := client.GetSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
+ req, err := client.GetProcessSlotPreparer(ctx, resourceGroupName, name, processID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetSiteExtensionSlotSender(req)
+ resp, err := client.GetProcessSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", resp, "Failure sending request")
return
}
- result, err = client.GetSiteExtensionSlotResponder(resp)
+ result, err = client.GetProcessSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessSlot", resp, "Failure responding to request")
}
return
}
-// GetSiteExtensionSlotPreparer prepares the GetSiteExtensionSlot request.
-func (client AppsClient) GetSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
+// GetProcessSlotPreparer prepares the GetProcessSlot request.
+func (client AppsClient) GetProcessSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -13723,21 +13734,21 @@ func (client AppsClient) GetSiteExtensionSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSiteExtensionSlotSender sends the GetSiteExtensionSlot request. The method will close the
+// GetProcessSlotSender sends the GetProcessSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSiteExtensionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSiteExtensionSlotResponder handles the response to the GetSiteExtensionSlot request. The method always
+// GetProcessSlotResponder handles the response to the GetProcessSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSiteExtensionSlotResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+func (client AppsClient) GetProcessSlotResponder(resp *http.Response) (result ProcessInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -13748,13 +13759,16 @@ func (client AppsClient) GetSiteExtensionSlotResponder(resp *http.Response) (res
return
}
-// GetSitePhpErrorLogFlag gets web app's event logs.
+// GetProcessThread get thread information by Thread ID for a specific process, in a specific scaled-out instance in a
+// web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetSitePhpErrorLogFlag(ctx context.Context, resourceGroupName string, name string) (result SitePhpErrorLogFlag, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSitePhpErrorLogFlag")
+// name - site name.
+// processID - pID.
+// threadID - tID.
+func (client AppsClient) GetProcessThread(ctx context.Context, resourceGroupName string, name string, processID string, threadID string) (result ProcessThreadInfo, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessThread")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13768,36 +13782,38 @@ func (client AppsClient) GetSitePhpErrorLogFlag(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSitePhpErrorLogFlag", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessThread", err.Error())
}
- req, err := client.GetSitePhpErrorLogFlagPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetProcessThreadPreparer(ctx, resourceGroupName, name, processID, threadID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", nil, "Failure preparing request")
return
}
- resp, err := client.GetSitePhpErrorLogFlagSender(req)
+ resp, err := client.GetProcessThreadSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", resp, "Failure sending request")
return
}
- result, err = client.GetSitePhpErrorLogFlagResponder(resp)
+ result, err = client.GetProcessThreadResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThread", resp, "Failure responding to request")
}
return
}
-// GetSitePhpErrorLogFlagPreparer prepares the GetSitePhpErrorLogFlag request.
-func (client AppsClient) GetSitePhpErrorLogFlagPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetProcessThreadPreparer prepares the GetProcessThread request.
+func (client AppsClient) GetProcessThreadPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -13808,39 +13824,43 @@ func (client AppsClient) GetSitePhpErrorLogFlagPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/phplogging", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/processes/{processId}/threads/{threadId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSitePhpErrorLogFlagSender sends the GetSitePhpErrorLogFlag request. The method will close the
+// GetProcessThreadSender sends the GetProcessThread request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSitePhpErrorLogFlagSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessThreadSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSitePhpErrorLogFlagResponder handles the response to the GetSitePhpErrorLogFlag request. The method always
+// GetProcessThreadResponder handles the response to the GetProcessThread request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSitePhpErrorLogFlagResponder(resp *http.Response) (result SitePhpErrorLogFlag, err error) {
+func (client AppsClient) GetProcessThreadResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSitePhpErrorLogFlagSlot gets web app's event logs.
+// GetProcessThreadSlot get thread information by Thread ID for a specific process, in a specific scaled-out instance
+// in a web site.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetSitePhpErrorLogFlagSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SitePhpErrorLogFlag, err error) {
+// name - site name.
+// processID - pID.
+// threadID - tID.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) GetProcessThreadSlot(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string) (result ProcessThreadInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSitePhpErrorLogFlagSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetProcessThreadSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13854,37 +13874,39 @@ func (client AppsClient) GetSitePhpErrorLogFlagSlot(ctx context.Context, resourc
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSitePhpErrorLogFlagSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetProcessThreadSlot", err.Error())
}
- req, err := client.GetSitePhpErrorLogFlagSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetProcessThreadSlotPreparer(ctx, resourceGroupName, name, processID, threadID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetSitePhpErrorLogFlagSlotSender(req)
+ resp, err := client.GetProcessThreadSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", resp, "Failure sending request")
return
}
- result, err = client.GetSitePhpErrorLogFlagSlotResponder(resp)
+ result, err = client.GetProcessThreadSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetProcessThreadSlot", resp, "Failure responding to request")
}
return
}
-// GetSitePhpErrorLogFlagSlotPreparer prepares the GetSitePhpErrorLogFlagSlot request.
-func (client AppsClient) GetSitePhpErrorLogFlagSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetProcessThreadSlotPreparer prepares the GetProcessThreadSlot request.
+func (client AppsClient) GetProcessThreadSlotPreparer(ctx context.Context, resourceGroupName string, name string, processID string, threadID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
+ "processId": autorest.Encode("path", processID),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "threadId": autorest.Encode("path", threadID),
}
const APIVersion = "2018-02-01"
@@ -13895,39 +13917,39 @@ func (client AppsClient) GetSitePhpErrorLogFlagSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/phplogging", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/processes/{processId}/threads/{threadId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSitePhpErrorLogFlagSlotSender sends the GetSitePhpErrorLogFlagSlot request. The method will close the
+// GetProcessThreadSlotSender sends the GetProcessThreadSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSitePhpErrorLogFlagSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetProcessThreadSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSitePhpErrorLogFlagSlotResponder handles the response to the GetSitePhpErrorLogFlagSlot request. The method always
+// GetProcessThreadSlotResponder handles the response to the GetProcessThreadSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSitePhpErrorLogFlagSlotResponder(resp *http.Response) (result SitePhpErrorLogFlag, err error) {
+func (client AppsClient) GetProcessThreadSlotResponder(resp *http.Response) (result ProcessThreadInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSlot gets the details of a web, mobile, or API app.
+// GetPublicCertificate get the named public certificate for an app (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. By default, this API returns the production slot.
-func (client AppsClient) GetSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result Site, err error) {
+// publicCertificateName - public certificate name.
+func (client AppsClient) GetPublicCertificate(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (result PublicCertificate, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPublicCertificate")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -13941,37 +13963,37 @@ func (client AppsClient) GetSlot(ctx context.Context, resourceGroupName string,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPublicCertificate", err.Error())
}
- req, err := client.GetSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetPublicCertificatePreparer(ctx, resourceGroupName, name, publicCertificateName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", nil, "Failure preparing request")
return
}
- resp, err := client.GetSlotSender(req)
+ resp, err := client.GetPublicCertificateSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", resp, "Failure sending request")
return
}
- result, err = client.GetSlotResponder(resp)
+ result, err = client.GetPublicCertificateResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificate", resp, "Failure responding to request")
}
return
}
-// GetSlotPreparer prepares the GetSlot request.
-func (client AppsClient) GetSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetPublicCertificatePreparer prepares the GetPublicCertificate request.
+func (client AppsClient) GetPublicCertificatePreparer(ctx context.Context, resourceGroupName string, name string, publicCertificateName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -13982,38 +14004,41 @@ func (client AppsClient) GetSlotPreparer(ctx context.Context, resourceGroupName
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSlotSender sends the GetSlot request. The method will close the
+// GetPublicCertificateSender sends the GetPublicCertificate request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPublicCertificateSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSlotResponder handles the response to the GetSlot request. The method always
+// GetPublicCertificateResponder handles the response to the GetPublicCertificate request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSlotResponder(resp *http.Response) (result Site, err error) {
+func (client AppsClient) GetPublicCertificateResponder(resp *http.Response) (result PublicCertificate, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSourceControl gets the source control configuration of an app.
+// GetPublicCertificateSlot get the named public certificate for an app (or deployment slot, if specified).
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GetSourceControl(ctx context.Context, resourceGroupName string, name string) (result SiteSourceControl, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API the named binding for the production
+// slot.
+// publicCertificateName - public certificate name.
+func (client AppsClient) GetPublicCertificateSlot(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (result PublicCertificate, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSourceControl")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetPublicCertificateSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14027,36 +14052,38 @@ func (client AppsClient) GetSourceControl(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSourceControl", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetPublicCertificateSlot", err.Error())
}
- req, err := client.GetSourceControlPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetPublicCertificateSlotPreparer(ctx, resourceGroupName, name, slot, publicCertificateName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetSourceControlSender(req)
+ resp, err := client.GetPublicCertificateSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", resp, "Failure sending request")
return
}
- result, err = client.GetSourceControlResponder(resp)
+ result, err = client.GetPublicCertificateSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetPublicCertificateSlot", resp, "Failure responding to request")
}
return
}
-// GetSourceControlPreparer prepares the GetSourceControl request.
-func (client AppsClient) GetSourceControlPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetPublicCertificateSlotPreparer prepares the GetPublicCertificateSlot request.
+func (client AppsClient) GetPublicCertificateSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string, publicCertificateName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "publicCertificateName": autorest.Encode("path", publicCertificateName),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2018-02-01"
@@ -14067,40 +14094,39 @@ func (client AppsClient) GetSourceControlPreparer(ctx context.Context, resourceG
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSourceControlSender sends the GetSourceControl request. The method will close the
+// GetPublicCertificateSlotSender sends the GetPublicCertificateSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSourceControlSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetPublicCertificateSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSourceControlResponder handles the response to the GetSourceControl request. The method always
+// GetPublicCertificateSlotResponder handles the response to the GetPublicCertificateSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSourceControlResponder(resp *http.Response) (result SiteSourceControl, err error) {
+func (client AppsClient) GetPublicCertificateSlotResponder(resp *http.Response) (result PublicCertificate, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSourceControlSlot gets the source control configuration of an app.
+// GetRelayServiceConnection gets a hybrid connection configuration by its name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the source control
-// configuration for the production slot.
-func (client AppsClient) GetSourceControlSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteSourceControl, err error) {
+// entityName - name of the hybrid connection.
+func (client AppsClient) GetRelayServiceConnection(ctx context.Context, resourceGroupName string, name string, entityName string) (result RelayServiceConnectionEntity, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSourceControlSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetRelayServiceConnection")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14114,36 +14140,36 @@ func (client AppsClient) GetSourceControlSlot(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSourceControlSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetRelayServiceConnection", err.Error())
}
- req, err := client.GetSourceControlSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetRelayServiceConnectionPreparer(ctx, resourceGroupName, name, entityName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", nil, "Failure preparing request")
return
}
- resp, err := client.GetSourceControlSlotSender(req)
+ resp, err := client.GetRelayServiceConnectionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", resp, "Failure sending request")
return
}
- result, err = client.GetSourceControlSlotResponder(resp)
+ result, err = client.GetRelayServiceConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnection", resp, "Failure responding to request")
}
return
}
-// GetSourceControlSlotPreparer prepares the GetSourceControlSlot request.
-func (client AppsClient) GetSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetRelayServiceConnectionPreparer prepares the GetRelayServiceConnection request.
+func (client AppsClient) GetRelayServiceConnectionPreparer(ctx context.Context, resourceGroupName string, name string, entityName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -14155,38 +14181,41 @@ func (client AppsClient) GetSourceControlSlotPreparer(ctx context.Context, resou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSourceControlSlotSender sends the GetSourceControlSlot request. The method will close the
+// GetRelayServiceConnectionSender sends the GetRelayServiceConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSourceControlSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetRelayServiceConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSourceControlSlotResponder handles the response to the GetSourceControlSlot request. The method always
+// GetRelayServiceConnectionResponder handles the response to the GetRelayServiceConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSourceControlSlotResponder(resp *http.Response) (result SiteSourceControl, err error) {
+func (client AppsClient) GetRelayServiceConnectionResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetSwiftVirtualNetworkConnection gets a Swift Virtual Network connection.
+// GetRelayServiceConnectionSlot gets a hybrid connection configuration by its name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) GetSwiftVirtualNetworkConnection(ctx context.Context, resourceGroupName string, name string) (result SwiftVirtualNetwork, err error) {
+// entityName - name of the hybrid connection.
+// slot - name of the deployment slot. If a slot is not specified, the API will get a hybrid connection for the
+// production slot.
+func (client AppsClient) GetRelayServiceConnectionSlot(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (result RelayServiceConnectionEntity, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSwiftVirtualNetworkConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetRelayServiceConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14200,35 +14229,37 @@ func (client AppsClient) GetSwiftVirtualNetworkConnection(ctx context.Context, r
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSwiftVirtualNetworkConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetRelayServiceConnectionSlot", err.Error())
}
- req, err := client.GetSwiftVirtualNetworkConnectionPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetRelayServiceConnectionSlotPreparer(ctx, resourceGroupName, name, entityName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetSwiftVirtualNetworkConnectionSender(req)
+ resp, err := client.GetRelayServiceConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetSwiftVirtualNetworkConnectionResponder(resp)
+ result, err = client.GetRelayServiceConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetRelayServiceConnectionSlot", resp, "Failure responding to request")
}
return
}
-// GetSwiftVirtualNetworkConnectionPreparer prepares the GetSwiftVirtualNetworkConnection request.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetRelayServiceConnectionSlotPreparer prepares the GetRelayServiceConnectionSlot request.
+func (client AppsClient) GetRelayServiceConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, entityName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "entityName": autorest.Encode("path", entityName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -14240,21 +14271,21 @@ func (client AppsClient) GetSwiftVirtualNetworkConnectionPreparer(ctx context.Co
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSwiftVirtualNetworkConnectionSender sends the GetSwiftVirtualNetworkConnection request. The method will close the
+// GetRelayServiceConnectionSlotSender sends the GetRelayServiceConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetRelayServiceConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSwiftVirtualNetworkConnectionResponder handles the response to the GetSwiftVirtualNetworkConnection request. The method always
+// GetRelayServiceConnectionSlotResponder handles the response to the GetRelayServiceConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
+func (client AppsClient) GetRelayServiceConnectionSlotResponder(resp *http.Response) (result RelayServiceConnectionEntity, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -14265,15 +14296,14 @@ func (client AppsClient) GetSwiftVirtualNetworkConnectionResponder(resp *http.Re
return
}
-// GetSwiftVirtualNetworkConnectionSlot gets a Swift Virtual Network connection.
+// GetSiteExtension get site extension information by its ID for a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get a gateway for the
-// production slot's Virtual Network.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SwiftVirtualNetwork, err error) {
+// name - site name.
+// siteExtensionID - site extension name.
+func (client AppsClient) GetSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result SiteExtensionInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSwiftVirtualNetworkConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSiteExtension")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14287,36 +14317,36 @@ func (client AppsClient) GetSwiftVirtualNetworkConnectionSlot(ctx context.Contex
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSiteExtension", err.Error())
}
- req, err := client.GetSwiftVirtualNetworkConnectionSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", nil, "Failure preparing request")
return
}
- resp, err := client.GetSwiftVirtualNetworkConnectionSlotSender(req)
+ resp, err := client.GetSiteExtensionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", resp, "Failure sending request")
return
}
- result, err = client.GetSwiftVirtualNetworkConnectionSlotResponder(resp)
+ result, err = client.GetSiteExtensionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtension", resp, "Failure responding to request")
}
return
}
-// GetSwiftVirtualNetworkConnectionSlotPreparer prepares the GetSwiftVirtualNetworkConnectionSlot request.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetSiteExtensionPreparer prepares the GetSiteExtension request.
+func (client AppsClient) GetSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -14328,39 +14358,41 @@ func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotPreparer(ctx contex
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetSwiftVirtualNetworkConnectionSlotSender sends the GetSwiftVirtualNetworkConnectionSlot request. The method will close the
+// GetSiteExtensionSender sends the GetSiteExtension request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSiteExtensionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetSwiftVirtualNetworkConnectionSlotResponder handles the response to the GetSwiftVirtualNetworkConnectionSlot request. The method always
+// GetSiteExtensionResponder handles the response to the GetSiteExtension request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
+func (client AppsClient) GetSiteExtensionResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetTriggeredWebJob gets a triggered web job by its ID for an app, or a deployment slot.
+// GetSiteExtensionSlot get site extension information by its ID for a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// webJobName - name of Web Job.
-func (client AppsClient) GetTriggeredWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result TriggeredWebJob, err error) {
+// siteExtensionID - site extension name.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) GetSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result SiteExtensionInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJob")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSiteExtensionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14374,37 +14406,38 @@ func (client AppsClient) GetTriggeredWebJob(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetTriggeredWebJob", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSiteExtensionSlot", err.Error())
}
- req, err := client.GetTriggeredWebJobPreparer(ctx, resourceGroupName, name, webJobName)
+ req, err := client.GetSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetTriggeredWebJobSender(req)
+ resp, err := client.GetSiteExtensionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetTriggeredWebJobResponder(resp)
+ result, err = client.GetSiteExtensionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSiteExtensionSlot", resp, "Failure responding to request")
}
return
}
-// GetTriggeredWebJobPreparer prepares the GetTriggeredWebJob request.
-func (client AppsClient) GetTriggeredWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
+// GetSiteExtensionSlotPreparer prepares the GetSiteExtensionSlot request.
+func (client AppsClient) GetSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -14415,21 +14448,21 @@ func (client AppsClient) GetTriggeredWebJobPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetTriggeredWebJobSender sends the GetTriggeredWebJob request. The method will close the
+// GetSiteExtensionSlotSender sends the GetSiteExtensionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetTriggeredWebJobSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSiteExtensionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetTriggeredWebJobResponder handles the response to the GetTriggeredWebJob request. The method always
+// GetSiteExtensionSlotResponder handles the response to the GetSiteExtensionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetTriggeredWebJobResponder(resp *http.Response) (result TriggeredWebJob, err error) {
+func (client AppsClient) GetSiteExtensionSlotResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -14440,15 +14473,13 @@ func (client AppsClient) GetTriggeredWebJobResponder(resp *http.Response) (resul
return
}
-// GetTriggeredWebJobHistory gets a triggered web job's history by its ID for an app, , or a deployment slot.
+// GetSitePhpErrorLogFlag gets web app's event logs.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-// ID - history ID.
-func (client AppsClient) GetTriggeredWebJobHistory(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string) (result TriggeredJobHistory, err error) {
+// name - name of web app.
+func (client AppsClient) GetSitePhpErrorLogFlag(ctx context.Context, resourceGroupName string, name string) (result SitePhpErrorLogFlag, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobHistory")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSitePhpErrorLogFlag")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14462,38 +14493,36 @@ func (client AppsClient) GetTriggeredWebJobHistory(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobHistory", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSitePhpErrorLogFlag", err.Error())
}
- req, err := client.GetTriggeredWebJobHistoryPreparer(ctx, resourceGroupName, name, webJobName, ID)
+ req, err := client.GetSitePhpErrorLogFlagPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", nil, "Failure preparing request")
return
}
- resp, err := client.GetTriggeredWebJobHistorySender(req)
+ resp, err := client.GetSitePhpErrorLogFlagSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", resp, "Failure sending request")
return
}
- result, err = client.GetTriggeredWebJobHistoryResponder(resp)
+ result, err = client.GetSitePhpErrorLogFlagResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlag", resp, "Failure responding to request")
}
return
}
-// GetTriggeredWebJobHistoryPreparer prepares the GetTriggeredWebJobHistory request.
-func (client AppsClient) GetTriggeredWebJobHistoryPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string) (*http.Request, error) {
+// GetSitePhpErrorLogFlagPreparer prepares the GetSitePhpErrorLogFlag request.
+func (client AppsClient) GetSitePhpErrorLogFlagPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -14504,42 +14533,39 @@ func (client AppsClient) GetTriggeredWebJobHistoryPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}/history/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/phplogging", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetTriggeredWebJobHistorySender sends the GetTriggeredWebJobHistory request. The method will close the
+// GetSitePhpErrorLogFlagSender sends the GetSitePhpErrorLogFlag request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetTriggeredWebJobHistorySender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSitePhpErrorLogFlagSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetTriggeredWebJobHistoryResponder handles the response to the GetTriggeredWebJobHistory request. The method always
+// GetSitePhpErrorLogFlagResponder handles the response to the GetSitePhpErrorLogFlag request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetTriggeredWebJobHistoryResponder(resp *http.Response) (result TriggeredJobHistory, err error) {
+func (client AppsClient) GetSitePhpErrorLogFlagResponder(resp *http.Response) (result SitePhpErrorLogFlag, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetTriggeredWebJobHistorySlot gets a triggered web job's history by its ID for an app, , or a deployment slot.
+// GetSitePhpErrorLogFlagSlot gets web app's event logs.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-// ID - history ID.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) GetTriggeredWebJobHistorySlot(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string, slot string) (result TriggeredJobHistory, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetSitePhpErrorLogFlagSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SitePhpErrorLogFlag, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobHistorySlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSitePhpErrorLogFlagSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14553,39 +14579,37 @@ func (client AppsClient) GetTriggeredWebJobHistorySlot(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobHistorySlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSitePhpErrorLogFlagSlot", err.Error())
}
- req, err := client.GetTriggeredWebJobHistorySlotPreparer(ctx, resourceGroupName, name, webJobName, ID, slot)
+ req, err := client.GetSitePhpErrorLogFlagSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetTriggeredWebJobHistorySlotSender(req)
+ resp, err := client.GetSitePhpErrorLogFlagSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", resp, "Failure sending request")
return
}
- result, err = client.GetTriggeredWebJobHistorySlotResponder(resp)
+ result, err = client.GetSitePhpErrorLogFlagSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSitePhpErrorLogFlagSlot", resp, "Failure responding to request")
}
return
}
-// GetTriggeredWebJobHistorySlotPreparer prepares the GetTriggeredWebJobHistorySlot request.
-func (client AppsClient) GetTriggeredWebJobHistorySlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string, slot string) (*http.Request, error) {
+// GetSitePhpErrorLogFlagSlotPreparer prepares the GetSitePhpErrorLogFlagSlot request.
+func (client AppsClient) GetSitePhpErrorLogFlagSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -14596,41 +14620,39 @@ func (client AppsClient) GetTriggeredWebJobHistorySlotPreparer(ctx context.Conte
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}/history/{id}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/phplogging", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetTriggeredWebJobHistorySlotSender sends the GetTriggeredWebJobHistorySlot request. The method will close the
+// GetSitePhpErrorLogFlagSlotSender sends the GetSitePhpErrorLogFlagSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetTriggeredWebJobHistorySlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSitePhpErrorLogFlagSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetTriggeredWebJobHistorySlotResponder handles the response to the GetTriggeredWebJobHistorySlot request. The method always
+// GetSitePhpErrorLogFlagSlotResponder handles the response to the GetSitePhpErrorLogFlagSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetTriggeredWebJobHistorySlotResponder(resp *http.Response) (result TriggeredJobHistory, err error) {
+func (client AppsClient) GetSitePhpErrorLogFlagSlotResponder(resp *http.Response) (result SitePhpErrorLogFlag, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetTriggeredWebJobSlot gets a triggered web job by its ID for an app, or a deployment slot.
+// GetSlot gets the details of a web, mobile, or API app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// webJobName - name of Web Job.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) GetTriggeredWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result TriggeredWebJob, err error) {
+// name - name of the app.
+// slot - name of the deployment slot. By default, this API returns the production slot.
+func (client AppsClient) GetSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result Site, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14644,38 +14666,37 @@ func (client AppsClient) GetTriggeredWebJobSlot(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSlot", err.Error())
}
- req, err := client.GetTriggeredWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
+ req, err := client.GetSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetTriggeredWebJobSlotSender(req)
+ resp, err := client.GetSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", resp, "Failure sending request")
return
}
- result, err = client.GetTriggeredWebJobSlotResponder(resp)
+ result, err = client.GetSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSlot", resp, "Failure responding to request")
}
return
}
-// GetTriggeredWebJobSlotPreparer prepares the GetTriggeredWebJobSlot request.
-func (client AppsClient) GetTriggeredWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
+// GetSlotPreparer prepares the GetSlot request.
+func (client AppsClient) GetSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -14686,21 +14707,21 @@ func (client AppsClient) GetTriggeredWebJobSlotPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetTriggeredWebJobSlotSender sends the GetTriggeredWebJobSlot request. The method will close the
+// GetSlotSender sends the GetSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetTriggeredWebJobSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetTriggeredWebJobSlotResponder handles the response to the GetTriggeredWebJobSlot request. The method always
+// GetSlotResponder handles the response to the GetSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetTriggeredWebJobSlotResponder(resp *http.Response) (result TriggeredWebJob, err error) {
+func (client AppsClient) GetSlotResponder(resp *http.Response) (result Site, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -14711,14 +14732,13 @@ func (client AppsClient) GetTriggeredWebJobSlotResponder(resp *http.Response) (r
return
}
-// GetVnetConnection gets a virtual network the app (or deployment slot) is connected to by name.
+// GetSourceControl gets the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the virtual network.
-func (client AppsClient) GetVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string) (result VnetInfo, err error) {
+func (client AppsClient) GetSourceControl(ctx context.Context, resourceGroupName string, name string) (result SiteSourceControl, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnection")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSourceControl")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14732,37 +14752,36 @@ func (client AppsClient) GetVnetConnection(ctx context.Context, resourceGroupNam
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetVnetConnection", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSourceControl", err.Error())
}
- req, err := client.GetVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName)
+ req, err := client.GetSourceControlPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", nil, "Failure preparing request")
return
}
- resp, err := client.GetVnetConnectionSender(req)
+ resp, err := client.GetSourceControlSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", resp, "Failure sending request")
return
}
- result, err = client.GetVnetConnectionResponder(resp)
+ result, err = client.GetSourceControlResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControl", resp, "Failure responding to request")
}
return
}
-// GetVnetConnectionPreparer prepares the GetVnetConnection request.
-func (client AppsClient) GetVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string) (*http.Request, error) {
+// GetSourceControlPreparer prepares the GetSourceControl request.
+func (client AppsClient) GetSourceControlPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -14773,40 +14792,40 @@ func (client AppsClient) GetVnetConnectionPreparer(ctx context.Context, resource
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/sourcecontrols/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetVnetConnectionSender sends the GetVnetConnection request. The method will close the
+// GetSourceControlSender sends the GetSourceControl request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetVnetConnectionSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSourceControlSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetVnetConnectionResponder handles the response to the GetVnetConnection request. The method always
+// GetSourceControlResponder handles the response to the GetSourceControl request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetVnetConnectionResponder(resp *http.Response) (result VnetInfo, err error) {
+func (client AppsClient) GetSourceControlResponder(resp *http.Response) (result SiteSourceControl, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetVnetConnectionGateway gets an app's Virtual Network gateway.
+// GetSourceControlSlot gets the source control configuration of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the Virtual Network.
-// gatewayName - name of the gateway. Currently, the only supported string is "primary".
-func (client AppsClient) GetVnetConnectionGateway(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string) (result VnetGateway, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will get the source control
+// configuration for the production slot.
+func (client AppsClient) GetSourceControlSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteSourceControl, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionGateway")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSourceControlSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14820,38 +14839,37 @@ func (client AppsClient) GetVnetConnectionGateway(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetVnetConnectionGateway", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSourceControlSlot", err.Error())
}
- req, err := client.GetVnetConnectionGatewayPreparer(ctx, resourceGroupName, name, vnetName, gatewayName)
+ req, err := client.GetSourceControlSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetVnetConnectionGatewaySender(req)
+ resp, err := client.GetSourceControlSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", resp, "Failure sending request")
return
}
- result, err = client.GetVnetConnectionGatewayResponder(resp)
+ result, err = client.GetSourceControlSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSourceControlSlot", resp, "Failure responding to request")
}
return
}
-// GetVnetConnectionGatewayPreparer prepares the GetVnetConnectionGateway request.
-func (client AppsClient) GetVnetConnectionGatewayPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string) (*http.Request, error) {
+// GetSourceControlSlotPreparer prepares the GetSourceControlSlot request.
+func (client AppsClient) GetSourceControlSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -14862,42 +14880,38 @@ func (client AppsClient) GetVnetConnectionGatewayPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/sourcecontrols/web", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetVnetConnectionGatewaySender sends the GetVnetConnectionGateway request. The method will close the
+// GetSourceControlSlotSender sends the GetSourceControlSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetVnetConnectionGatewaySender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSourceControlSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetVnetConnectionGatewayResponder handles the response to the GetVnetConnectionGateway request. The method always
+// GetSourceControlSlotResponder handles the response to the GetSourceControlSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetVnetConnectionGatewayResponder(resp *http.Response) (result VnetGateway, err error) {
+func (client AppsClient) GetSourceControlSlotResponder(resp *http.Response) (result SiteSourceControl, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusAccepted),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetVnetConnectionGatewaySlot gets an app's Virtual Network gateway.
+// GetSwiftVirtualNetworkConnection gets a Swift Virtual Network connection.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the Virtual Network.
-// gatewayName - name of the gateway. Currently, the only supported string is "primary".
-// slot - name of the deployment slot. If a slot is not specified, the API will get a gateway for the
-// production slot's Virtual Network.
-func (client AppsClient) GetVnetConnectionGatewaySlot(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, slot string) (result VnetGateway, err error) {
+func (client AppsClient) GetSwiftVirtualNetworkConnection(ctx context.Context, resourceGroupName string, name string) (result SwiftVirtualNetwork, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionGatewaySlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSwiftVirtualNetworkConnection")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -14911,39 +14925,36 @@ func (client AppsClient) GetVnetConnectionGatewaySlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetVnetConnectionGatewaySlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSwiftVirtualNetworkConnection", err.Error())
}
- req, err := client.GetVnetConnectionGatewaySlotPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, slot)
+ req, err := client.GetSwiftVirtualNetworkConnectionPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", nil, "Failure preparing request")
return
}
- resp, err := client.GetVnetConnectionGatewaySlotSender(req)
+ resp, err := client.GetSwiftVirtualNetworkConnectionSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", resp, "Failure sending request")
return
}
- result, err = client.GetVnetConnectionGatewaySlotResponder(resp)
+ result, err = client.GetSwiftVirtualNetworkConnectionResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnection", resp, "Failure responding to request")
}
return
}
-// GetVnetConnectionGatewaySlotPreparer prepares the GetVnetConnectionGatewaySlot request.
-func (client AppsClient) GetVnetConnectionGatewaySlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, slot string) (*http.Request, error) {
+// GetSwiftVirtualNetworkConnectionPreparer prepares the GetSwiftVirtualNetworkConnection request.
+func (client AppsClient) GetSwiftVirtualNetworkConnectionPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -14954,41 +14965,40 @@ func (client AppsClient) GetVnetConnectionGatewaySlotPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkConfig/virtualNetwork", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetVnetConnectionGatewaySlotSender sends the GetVnetConnectionGatewaySlot request. The method will close the
+// GetSwiftVirtualNetworkConnectionSender sends the GetSwiftVirtualNetworkConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetVnetConnectionGatewaySlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSwiftVirtualNetworkConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetVnetConnectionGatewaySlotResponder handles the response to the GetVnetConnectionGatewaySlot request. The method always
+// GetSwiftVirtualNetworkConnectionResponder handles the response to the GetSwiftVirtualNetworkConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetVnetConnectionGatewaySlotResponder(resp *http.Response) (result VnetGateway, err error) {
+func (client AppsClient) GetSwiftVirtualNetworkConnectionResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetVnetConnectionSlot gets a virtual network the app (or deployment slot) is connected to by name.
+// GetSwiftVirtualNetworkConnectionSlot gets a Swift Virtual Network connection.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// vnetName - name of the virtual network.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the named virtual network
-// for the production slot.
-func (client AppsClient) GetVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (result VnetInfo, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will get a gateway for the
+// production slot's Virtual Network.
+func (client AppsClient) GetSwiftVirtualNetworkConnectionSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SwiftVirtualNetwork, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetSwiftVirtualNetworkConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15002,38 +15012,37 @@ func (client AppsClient) GetVnetConnectionSlot(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetVnetConnectionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", err.Error())
}
- req, err := client.GetVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, slot)
+ req, err := client.GetSwiftVirtualNetworkConnectionSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetVnetConnectionSlotSender(req)
+ resp, err := client.GetSwiftVirtualNetworkConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.GetVnetConnectionSlotResponder(resp)
+ result, err = client.GetSwiftVirtualNetworkConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetSwiftVirtualNetworkConnectionSlot", resp, "Failure responding to request")
}
return
}
-// GetVnetConnectionSlotPreparer prepares the GetVnetConnectionSlot request.
-func (client AppsClient) GetVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (*http.Request, error) {
+// GetSwiftVirtualNetworkConnectionSlotPreparer prepares the GetSwiftVirtualNetworkConnectionSlot request.
+func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
- "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -15044,21 +15053,21 @@ func (client AppsClient) GetVnetConnectionSlotPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkConfig/virtualNetwork", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetVnetConnectionSlotSender sends the GetVnetConnectionSlot request. The method will close the
+// GetSwiftVirtualNetworkConnectionSlotSender sends the GetSwiftVirtualNetworkConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetVnetConnectionSlotResponder handles the response to the GetVnetConnectionSlot request. The method always
+// GetSwiftVirtualNetworkConnectionSlotResponder handles the response to the GetSwiftVirtualNetworkConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetVnetConnectionSlotResponder(resp *http.Response) (result VnetInfo, err error) {
+func (client AppsClient) GetSwiftVirtualNetworkConnectionSlotResponder(resp *http.Response) (result SwiftVirtualNetwork, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -15069,14 +15078,14 @@ func (client AppsClient) GetVnetConnectionSlotResponder(resp *http.Response) (re
return
}
-// GetWebJob get webjob information for an app, or a deployment slot.
+// GetTriggeredWebJob gets a triggered web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// webJobName - name of the web job.
-func (client AppsClient) GetWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result Job, err error) {
+// webJobName - name of Web Job.
+func (client AppsClient) GetTriggeredWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result TriggeredWebJob, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebJob")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJob")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15090,32 +15099,32 @@ func (client AppsClient) GetWebJob(ctx context.Context, resourceGroupName string
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetWebJob", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetTriggeredWebJob", err.Error())
}
- req, err := client.GetWebJobPreparer(ctx, resourceGroupName, name, webJobName)
+ req, err := client.GetTriggeredWebJobPreparer(ctx, resourceGroupName, name, webJobName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", nil, "Failure preparing request")
return
}
- resp, err := client.GetWebJobSender(req)
+ resp, err := client.GetTriggeredWebJobSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", resp, "Failure sending request")
return
}
- result, err = client.GetWebJobResponder(resp)
+ result, err = client.GetTriggeredWebJobResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJob", resp, "Failure responding to request")
}
return
}
-// GetWebJobPreparer prepares the GetWebJob request.
-func (client AppsClient) GetWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
+// GetTriggeredWebJobPreparer prepares the GetTriggeredWebJob request.
+func (client AppsClient) GetTriggeredWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -15131,41 +15140,40 @@ func (client AppsClient) GetWebJobPreparer(ctx context.Context, resourceGroupNam
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/webjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetWebJobSender sends the GetWebJob request. The method will close the
+// GetTriggeredWebJobSender sends the GetTriggeredWebJob request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetWebJobSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetTriggeredWebJobSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetWebJobResponder handles the response to the GetWebJob request. The method always
+// GetTriggeredWebJobResponder handles the response to the GetTriggeredWebJob request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetWebJobResponder(resp *http.Response) (result Job, err error) {
+func (client AppsClient) GetTriggeredWebJobResponder(resp *http.Response) (result TriggeredWebJob, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetWebJobSlot get webjob information for an app, or a deployment slot.
+// GetTriggeredWebJobHistory gets a triggered web job's history by its ID for an app, , or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// webJobName - name of the web job.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) GetWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result Job, err error) {
+// webJobName - name of Web Job.
+// ID - history ID.
+func (client AppsClient) GetTriggeredWebJobHistory(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string) (result TriggeredJobHistory, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebJobSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobHistory")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15179,36 +15187,36 @@ func (client AppsClient) GetWebJobSlot(ctx context.Context, resourceGroupName st
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetWebJobSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobHistory", err.Error())
}
- req, err := client.GetWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
+ req, err := client.GetTriggeredWebJobHistoryPreparer(ctx, resourceGroupName, name, webJobName, ID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", nil, "Failure preparing request")
return
}
- resp, err := client.GetWebJobSlotSender(req)
+ resp, err := client.GetTriggeredWebJobHistorySender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", resp, "Failure sending request")
return
}
- result, err = client.GetWebJobSlotResponder(resp)
+ result, err = client.GetTriggeredWebJobHistoryResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistory", resp, "Failure responding to request")
}
return
}
-// GetWebJobSlotPreparer prepares the GetWebJobSlot request.
-func (client AppsClient) GetWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
+// GetTriggeredWebJobHistoryPreparer prepares the GetTriggeredWebJobHistory request.
+func (client AppsClient) GetTriggeredWebJobHistoryPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
"webJobName": autorest.Encode("path", webJobName),
}
@@ -15221,38 +15229,42 @@ func (client AppsClient) GetWebJobSlotPreparer(ctx context.Context, resourceGrou
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/webjobs/{webJobName}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/triggeredwebjobs/{webJobName}/history/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetWebJobSlotSender sends the GetWebJobSlot request. The method will close the
+// GetTriggeredWebJobHistorySender sends the GetTriggeredWebJobHistory request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetWebJobSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetTriggeredWebJobHistorySender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetWebJobSlotResponder handles the response to the GetWebJobSlot request. The method always
+// GetTriggeredWebJobHistoryResponder handles the response to the GetTriggeredWebJobHistory request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetWebJobSlotResponder(resp *http.Response) (result Job, err error) {
+func (client AppsClient) GetTriggeredWebJobHistoryResponder(resp *http.Response) (result TriggeredJobHistory, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetWebSiteContainerLogs gets the last lines of docker logs for the given site
+// GetTriggeredWebJobHistorySlot gets a triggered web job's history by its ID for an app, , or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-func (client AppsClient) GetWebSiteContainerLogs(ctx context.Context, resourceGroupName string, name string) (result ReadCloser, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+// ID - history ID.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) GetTriggeredWebJobHistorySlot(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string, slot string) (result TriggeredJobHistory, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebSiteContainerLogs")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobHistorySlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15266,36 +15278,39 @@ func (client AppsClient) GetWebSiteContainerLogs(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetWebSiteContainerLogs", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobHistorySlot", err.Error())
}
- req, err := client.GetWebSiteContainerLogsPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetTriggeredWebJobHistorySlotPreparer(ctx, resourceGroupName, name, webJobName, ID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetWebSiteContainerLogsSender(req)
+ resp, err := client.GetTriggeredWebJobHistorySlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", resp, "Failure sending request")
return
}
- result, err = client.GetWebSiteContainerLogsResponder(resp)
+ result, err = client.GetTriggeredWebJobHistorySlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobHistorySlot", resp, "Failure responding to request")
}
return
}
-// GetWebSiteContainerLogsPreparer prepares the GetWebSiteContainerLogs request.
-func (client AppsClient) GetWebSiteContainerLogsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetTriggeredWebJobHistorySlotPreparer prepares the GetTriggeredWebJobHistorySlot request.
+func (client AppsClient) GetTriggeredWebJobHistorySlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, ID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -15304,40 +15319,43 @@ func (client AppsClient) GetWebSiteContainerLogsPreparer(ctx context.Context, re
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/containerlogs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}/history/{id}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetWebSiteContainerLogsSender sends the GetWebSiteContainerLogs request. The method will close the
+// GetTriggeredWebJobHistorySlotSender sends the GetTriggeredWebJobHistorySlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetWebSiteContainerLogsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetTriggeredWebJobHistorySlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetWebSiteContainerLogsResponder handles the response to the GetWebSiteContainerLogs request. The method always
+// GetTriggeredWebJobHistorySlotResponder handles the response to the GetTriggeredWebJobHistorySlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetWebSiteContainerLogsResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetTriggeredWebJobHistorySlotResponder(resp *http.Response) (result TriggeredJobHistory, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// GetWebSiteContainerLogsSlot gets the last lines of docker logs for the given site
+// GetTriggeredWebJobSlot gets a triggered web job by its ID for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) GetWebSiteContainerLogsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ReadCloser, err error) {
+// name - site name.
+// webJobName - name of Web Job.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) GetTriggeredWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result TriggeredWebJob, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebSiteContainerLogsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetTriggeredWebJobSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15351,37 +15369,38 @@ func (client AppsClient) GetWebSiteContainerLogsSlot(ctx context.Context, resour
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "GetWebSiteContainerLogsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetTriggeredWebJobSlot", err.Error())
}
- req, err := client.GetWebSiteContainerLogsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetTriggeredWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", nil, "Failure preparing request")
return
}
- resp, err := client.GetWebSiteContainerLogsSlotSender(req)
+ resp, err := client.GetTriggeredWebJobSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", resp, "Failure sending request")
return
}
- result, err = client.GetWebSiteContainerLogsSlotResponder(resp)
+ result, err = client.GetTriggeredWebJobSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetTriggeredWebJobSlot", resp, "Failure responding to request")
}
return
}
-// GetWebSiteContainerLogsSlotPreparer prepares the GetWebSiteContainerLogsSlot request.
-func (client AppsClient) GetWebSiteContainerLogsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetTriggeredWebJobSlotPreparer prepares the GetTriggeredWebJobSlot request.
+func (client AppsClient) GetTriggeredWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -15390,44 +15409,45 @@ func (client AppsClient) GetWebSiteContainerLogsSlotPreparer(ctx context.Context
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/containerlogs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/triggeredwebjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// GetWebSiteContainerLogsSlotSender sends the GetWebSiteContainerLogsSlot request. The method will close the
+// GetTriggeredWebJobSlotSender sends the GetTriggeredWebJobSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) GetWebSiteContainerLogsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetTriggeredWebJobSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// GetWebSiteContainerLogsSlotResponder handles the response to the GetWebSiteContainerLogsSlot request. The method always
+// GetTriggeredWebJobSlotResponder handles the response to the GetTriggeredWebJobSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) GetWebSiteContainerLogsSlotResponder(resp *http.Response) (result ReadCloser, err error) {
- result.Value = &resp.Body
+func (client AppsClient) GetTriggeredWebJobSlotResponder(resp *http.Response) (result TriggeredWebJob, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// InstallSiteExtension install site extension on a web site, or a deployment slot.
+// GetVnetConnection gets a virtual network the app (or deployment slot) is connected to by name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// siteExtensionID - site extension name.
-func (client AppsClient) InstallSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result AppsInstallSiteExtensionFuture, err error) {
+// name - name of the app.
+// vnetName - name of the virtual network.
+func (client AppsClient) GetVnetConnection(ctx context.Context, resourceGroupName string, name string, vnetName string) (result VnetInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.InstallSiteExtension")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnection")
defer func() {
sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -15437,31 +15457,37 @@ func (client AppsClient) InstallSiteExtension(ctx context.Context, resourceGroup
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "InstallSiteExtension", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetVnetConnection", err.Error())
}
- req, err := client.InstallSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
+ req, err := client.GetVnetConnectionPreparer(ctx, resourceGroupName, name, vnetName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtension", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", nil, "Failure preparing request")
return
}
- result, err = client.InstallSiteExtensionSender(req)
+ resp, err := client.GetVnetConnectionSender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtension", result.Response(), "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", resp, "Failure sending request")
return
}
+ result, err = client.GetVnetConnectionResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnection", resp, "Failure responding to request")
+ }
+
return
}
-// InstallSiteExtensionPreparer prepares the InstallSiteExtension request.
-func (client AppsClient) InstallSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
+// GetVnetConnectionPreparer prepares the GetVnetConnection request.
+func (client AppsClient) GetVnetConnectionPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -15470,53 +15496,46 @@ func (client AppsClient) InstallSiteExtensionPreparer(ctx context.Context, resou
}
preparer := autorest.CreatePreparer(
- autorest.AsPut(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// InstallSiteExtensionSender sends the InstallSiteExtension request. The method will close the
+// GetVnetConnectionSender sends the GetVnetConnection request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) InstallSiteExtensionSender(req *http.Request) (future AppsInstallSiteExtensionFuture, err error) {
+func (client AppsClient) GetVnetConnectionSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
+ return autorest.SendWithSender(client, req, sd...)
}
-// InstallSiteExtensionResponder handles the response to the InstallSiteExtension request. The method always
+// GetVnetConnectionResponder handles the response to the GetVnetConnection request. The method always
// closes the http.Response Body.
-func (client AppsClient) InstallSiteExtensionResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+func (client AppsClient) GetVnetConnectionResponder(resp *http.Response) (result VnetInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusTooManyRequests),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// InstallSiteExtensionSlot install site extension on a web site, or a deployment slot.
+// GetVnetConnectionGateway gets an app's Virtual Network gateway.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// siteExtensionID - site extension name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) InstallSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result AppsInstallSiteExtensionSlotFuture, err error) {
+// name - name of the app.
+// vnetName - name of the Virtual Network.
+// gatewayName - name of the gateway. Currently, the only supported string is "primary".
+func (client AppsClient) GetVnetConnectionGateway(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string) (result VnetGateway, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.InstallSiteExtensionSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionGateway")
defer func() {
sc := -1
- if result.Response() != nil {
- sc = result.Response().StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -15526,32 +15545,38 @@ func (client AppsClient) InstallSiteExtensionSlot(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "InstallSiteExtensionSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetVnetConnectionGateway", err.Error())
}
- req, err := client.InstallSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
+ req, err := client.GetVnetConnectionGatewayPreparer(ctx, resourceGroupName, name, vnetName, gatewayName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtensionSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", nil, "Failure preparing request")
return
}
- result, err = client.InstallSiteExtensionSlotSender(req)
+ resp, err := client.GetVnetConnectionGatewaySender(req)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtensionSlot", result.Response(), "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", resp, "Failure sending request")
return
}
+ result, err = client.GetVnetConnectionGatewayResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGateway", resp, "Failure responding to request")
+ }
+
return
}
-// InstallSiteExtensionSlotPreparer prepares the InstallSiteExtensionSlot request.
-func (client AppsClient) InstallSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
+// GetVnetConnectionGatewayPreparer prepares the GetVnetConnectionGateway request.
+func (client AppsClient) GetVnetConnectionGatewayPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "siteExtensionId": autorest.Encode("path", siteExtensionID),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -15560,46 +15585,44 @@ func (client AppsClient) InstallSiteExtensionSlotPreparer(ctx context.Context, r
}
preparer := autorest.CreatePreparer(
- autorest.AsPut(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// InstallSiteExtensionSlotSender sends the InstallSiteExtensionSlot request. The method will close the
+// GetVnetConnectionGatewaySender sends the GetVnetConnectionGateway request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) InstallSiteExtensionSlotSender(req *http.Request) (future AppsInstallSiteExtensionSlotFuture, err error) {
+func (client AppsClient) GetVnetConnectionGatewaySender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- var resp *http.Response
- resp, err = autorest.SendWithSender(client, req, sd...)
- if err != nil {
- return
- }
- future.Future, err = azure.NewFutureFromResponse(resp)
- return
+ return autorest.SendWithSender(client, req, sd...)
}
-// InstallSiteExtensionSlotResponder handles the response to the InstallSiteExtensionSlot request. The method always
+// GetVnetConnectionGatewayResponder handles the response to the GetVnetConnectionGateway request. The method always
// closes the http.Response Body.
-func (client AppsClient) InstallSiteExtensionSlotResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+func (client AppsClient) GetVnetConnectionGatewayResponder(resp *http.Response) (result VnetGateway, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusTooManyRequests),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// IsCloneable shows whether an app can be cloned to another resource group or subscription.
+// GetVnetConnectionGatewaySlot gets an app's Virtual Network gateway.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) IsCloneable(ctx context.Context, resourceGroupName string, name string) (result SiteCloneability, err error) {
+// vnetName - name of the Virtual Network.
+// gatewayName - name of the gateway. Currently, the only supported string is "primary".
+// slot - name of the deployment slot. If a slot is not specified, the API will get a gateway for the
+// production slot's Virtual Network.
+func (client AppsClient) GetVnetConnectionGatewaySlot(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, slot string) (result VnetGateway, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.IsCloneable")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionGatewaySlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15613,36 +15636,39 @@ func (client AppsClient) IsCloneable(ctx context.Context, resourceGroupName stri
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "IsCloneable", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetVnetConnectionGatewaySlot", err.Error())
}
- req, err := client.IsCloneablePreparer(ctx, resourceGroupName, name)
+ req, err := client.GetVnetConnectionGatewaySlotPreparer(ctx, resourceGroupName, name, vnetName, gatewayName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", nil, "Failure preparing request")
return
}
- resp, err := client.IsCloneableSender(req)
+ resp, err := client.GetVnetConnectionGatewaySlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", resp, "Failure sending request")
return
}
- result, err = client.IsCloneableResponder(resp)
+ result, err = client.GetVnetConnectionGatewaySlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionGatewaySlot", resp, "Failure responding to request")
}
return
}
-// IsCloneablePreparer prepares the IsCloneable request.
-func (client AppsClient) IsCloneablePreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetVnetConnectionGatewaySlotPreparer prepares the GetVnetConnectionGatewaySlot request.
+func (client AppsClient) GetVnetConnectionGatewaySlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, gatewayName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "gatewayName": autorest.Encode("path", gatewayName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -15651,41 +15677,43 @@ func (client AppsClient) IsCloneablePreparer(ctx context.Context, resourceGroupN
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/iscloneable", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}/gateways/{gatewayName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// IsCloneableSender sends the IsCloneable request. The method will close the
+// GetVnetConnectionGatewaySlotSender sends the GetVnetConnectionGatewaySlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) IsCloneableSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetVnetConnectionGatewaySlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// IsCloneableResponder handles the response to the IsCloneable request. The method always
+// GetVnetConnectionGatewaySlotResponder handles the response to the GetVnetConnectionGatewaySlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) IsCloneableResponder(resp *http.Response) (result SiteCloneability, err error) {
+func (client AppsClient) GetVnetConnectionGatewaySlotResponder(resp *http.Response) (result VnetGateway, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// IsCloneableSlot shows whether an app can be cloned to another resource group or subscription.
+// GetVnetConnectionSlot gets a virtual network the app (or deployment slot) is connected to by name.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. By default, this API returns information on the production slot.
-func (client AppsClient) IsCloneableSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteCloneability, err error) {
+// vnetName - name of the virtual network.
+// slot - name of the deployment slot. If a slot is not specified, the API will get the named virtual network
+// for the production slot.
+func (client AppsClient) GetVnetConnectionSlot(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (result VnetInfo, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.IsCloneableSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetVnetConnectionSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15699,37 +15727,38 @@ func (client AppsClient) IsCloneableSlot(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "IsCloneableSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetVnetConnectionSlot", err.Error())
}
- req, err := client.IsCloneableSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetVnetConnectionSlotPreparer(ctx, resourceGroupName, name, vnetName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", nil, "Failure preparing request")
return
}
- resp, err := client.IsCloneableSlotSender(req)
+ resp, err := client.GetVnetConnectionSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", resp, "Failure sending request")
return
}
- result, err = client.IsCloneableSlotResponder(resp)
+ result, err = client.GetVnetConnectionSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetVnetConnectionSlot", resp, "Failure responding to request")
}
return
}
-// IsCloneableSlotPreparer prepares the IsCloneableSlot request.
-func (client AppsClient) IsCloneableSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetVnetConnectionSlotPreparer prepares the GetVnetConnectionSlot request.
+func (client AppsClient) GetVnetConnectionSlotPreparer(ctx context.Context, resourceGroupName string, name string, vnetName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "vnetName": autorest.Encode("path", vnetName),
}
const APIVersion = "2018-02-01"
@@ -15738,23 +15767,23 @@ func (client AppsClient) IsCloneableSlotPreparer(ctx context.Context, resourceGr
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/iscloneable", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/virtualNetworkConnections/{vnetName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// IsCloneableSlotSender sends the IsCloneableSlot request. The method will close the
+// GetVnetConnectionSlotSender sends the GetVnetConnectionSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) IsCloneableSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetVnetConnectionSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// IsCloneableSlotResponder handles the response to the IsCloneableSlot request. The method always
+// GetVnetConnectionSlotResponder handles the response to the GetVnetConnectionSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) IsCloneableSlotResponder(resp *http.Response) (result SiteCloneability, err error) {
+func (client AppsClient) GetVnetConnectionSlotResponder(resp *http.Response) (result VnetInfo, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -15765,44 +15794,58 @@ func (client AppsClient) IsCloneableSlotResponder(resp *http.Response) (result S
return
}
-// List get all apps for a subscription.
-func (client AppsClient) List(ctx context.Context) (result AppCollectionPage, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.List")
- defer func() {
+// GetWebJob get webjob information for an app, or a deployment slot.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - site name.
+// webJobName - name of the web job.
+func (client AppsClient) GetWebJob(ctx context.Context, resourceGroupName string, name string, webJobName string) (result Job, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebJob")
+ defer func() {
sc := -1
- if result.ac.Response.Response != nil {
- sc = result.ac.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
- result.fn = client.listNextResults
- req, err := client.ListPreparer(ctx)
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "GetWebJob", err.Error())
+ }
+
+ req, err := client.GetWebJobPreparer(ctx, resourceGroupName, name, webJobName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "List", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", nil, "Failure preparing request")
return
}
- resp, err := client.ListSender(req)
+ resp, err := client.GetWebJobSender(req)
if err != nil {
- result.ac.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "List", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", resp, "Failure sending request")
return
}
- result.ac, err = client.ListResponder(resp)
+ result, err = client.GetWebJobResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "List", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJob", resp, "Failure responding to request")
}
return
}
-// ListPreparer prepares the List request.
-func (client AppsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+// GetWebJobPreparer prepares the GetWebJob request.
+func (client AppsClient) GetWebJobPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -15813,21 +15856,21 @@ func (client AppsClient) ListPreparer(ctx context.Context) (*http.Request, error
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Web/sites", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/webjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListSender sends the List request. The method will close the
+// GetWebJobSender sends the GetWebJob request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetWebJobSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListResponder handles the response to the List request. The method always
+// GetWebJobResponder handles the response to the GetWebJob request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListResponder(resp *http.Response) (result AppCollection, err error) {
+func (client AppsClient) GetWebJobResponder(resp *http.Response) (result Job, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -15838,50 +15881,16 @@ func (client AppsClient) ListResponder(resp *http.Response) (result AppCollectio
return
}
-// listNextResults retrieves the next set of results, if any.
-func (client AppsClient) listNextResults(ctx context.Context, lastResults AppCollection) (result AppCollection, err error) {
- req, err := lastResults.appCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListComplete(ctx context.Context) (result AppCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.List")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.List(ctx)
- return
-}
-
-// ListApplicationSettings gets the application settings of an app.
+// GetWebJobSlot get webjob information for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) ListApplicationSettings(ctx context.Context, resourceGroupName string, name string) (result StringDictionary, err error) {
+// name - site name.
+// webJobName - name of the web job.
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) GetWebJobSlot(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (result Job, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListApplicationSettings")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebJobSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15895,36 +15904,38 @@ func (client AppsClient) ListApplicationSettings(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListApplicationSettings", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetWebJobSlot", err.Error())
}
- req, err := client.ListApplicationSettingsPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetWebJobSlotPreparer(ctx, resourceGroupName, name, webJobName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListApplicationSettingsSender(req)
+ resp, err := client.GetWebJobSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", resp, "Failure sending request")
return
}
- result, err = client.ListApplicationSettingsResponder(resp)
+ result, err = client.GetWebJobSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebJobSlot", resp, "Failure responding to request")
}
return
}
-// ListApplicationSettingsPreparer prepares the ListApplicationSettings request.
-func (client AppsClient) ListApplicationSettingsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetWebJobSlotPreparer prepares the GetWebJobSlot request.
+func (client AppsClient) GetWebJobSlotPreparer(ctx context.Context, resourceGroupName string, name string, webJobName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ "webJobName": autorest.Encode("path", webJobName),
}
const APIVersion = "2018-02-01"
@@ -15933,23 +15944,23 @@ func (client AppsClient) ListApplicationSettingsPreparer(ctx context.Context, re
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/appsettings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/webjobs/{webJobName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListApplicationSettingsSender sends the ListApplicationSettings request. The method will close the
+// GetWebJobSlotSender sends the GetWebJobSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListApplicationSettingsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetWebJobSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListApplicationSettingsResponder handles the response to the ListApplicationSettings request. The method always
+// GetWebJobSlotResponder handles the response to the GetWebJobSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListApplicationSettingsResponder(resp *http.Response) (result StringDictionary, err error) {
+func (client AppsClient) GetWebJobSlotResponder(resp *http.Response) (result Job, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -15960,15 +15971,13 @@ func (client AppsClient) ListApplicationSettingsResponder(resp *http.Response) (
return
}
-// ListApplicationSettingsSlot gets the application settings of an app.
+// GetWebSiteContainerLogs gets the last lines of docker logs for the given site
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the application settings
-// for the production slot.
-func (client AppsClient) ListApplicationSettingsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result StringDictionary, err error) {
+// name - name of web app.
+func (client AppsClient) GetWebSiteContainerLogs(ctx context.Context, resourceGroupName string, name string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListApplicationSettingsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebSiteContainerLogs")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -15982,36 +15991,35 @@ func (client AppsClient) ListApplicationSettingsSlot(ctx context.Context, resour
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListApplicationSettingsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetWebSiteContainerLogs", err.Error())
}
- req, err := client.ListApplicationSettingsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.GetWebSiteContainerLogsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", nil, "Failure preparing request")
return
}
- resp, err := client.ListApplicationSettingsSlotSender(req)
+ resp, err := client.GetWebSiteContainerLogsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", resp, "Failure sending request")
return
}
- result, err = client.ListApplicationSettingsSlotResponder(resp)
+ result, err = client.GetWebSiteContainerLogsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogs", resp, "Failure responding to request")
}
return
}
-// ListApplicationSettingsSlotPreparer prepares the ListApplicationSettingsSlot request.
-func (client AppsClient) ListApplicationSettingsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// GetWebSiteContainerLogsPreparer prepares the GetWebSiteContainerLogs request.
+func (client AppsClient) GetWebSiteContainerLogsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16023,38 +16031,38 @@ func (client AppsClient) ListApplicationSettingsSlotPreparer(ctx context.Context
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/containerlogs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListApplicationSettingsSlotSender sends the ListApplicationSettingsSlot request. The method will close the
+// GetWebSiteContainerLogsSender sends the GetWebSiteContainerLogs request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListApplicationSettingsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetWebSiteContainerLogsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListApplicationSettingsSlotResponder handles the response to the ListApplicationSettingsSlot request. The method always
+// GetWebSiteContainerLogsResponder handles the response to the GetWebSiteContainerLogs request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListApplicationSettingsSlotResponder(resp *http.Response) (result StringDictionary, err error) {
+func (client AppsClient) GetWebSiteContainerLogsResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
result.Response = autorest.Response{Response: resp}
return
}
-// ListAzureStorageAccounts gets the Azure storage account configurations of an app.
+// GetWebSiteContainerLogsSlot gets the last lines of docker logs for the given site
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) ListAzureStorageAccounts(ctx context.Context, resourceGroupName string, name string) (result AzureStoragePropertyDictionaryResource, err error) {
+// name - name of web app.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) GetWebSiteContainerLogsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ReadCloser, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListAzureStorageAccounts")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.GetWebSiteContainerLogsSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -16068,35 +16076,36 @@ func (client AppsClient) ListAzureStorageAccounts(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListAzureStorageAccounts", err.Error())
+ return result, validation.NewError("web.AppsClient", "GetWebSiteContainerLogsSlot", err.Error())
}
- req, err := client.ListAzureStorageAccountsPreparer(ctx, resourceGroupName, name)
+ req, err := client.GetWebSiteContainerLogsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListAzureStorageAccountsSender(req)
+ resp, err := client.GetWebSiteContainerLogsSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", resp, "Failure sending request")
return
}
- result, err = client.ListAzureStorageAccountsResponder(resp)
+ result, err = client.GetWebSiteContainerLogsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "GetWebSiteContainerLogsSlot", resp, "Failure responding to request")
}
return
}
-// ListAzureStorageAccountsPreparer prepares the ListAzureStorageAccounts request.
-func (client AppsClient) ListAzureStorageAccountsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// GetWebSiteContainerLogsSlotPreparer prepares the GetWebSiteContainerLogsSlot request.
+func (client AppsClient) GetWebSiteContainerLogsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16108,44 +16117,42 @@ func (client AppsClient) ListAzureStorageAccountsPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/azurestorageaccounts/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/containerlogs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListAzureStorageAccountsSender sends the ListAzureStorageAccounts request. The method will close the
+// GetWebSiteContainerLogsSlotSender sends the GetWebSiteContainerLogsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListAzureStorageAccountsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) GetWebSiteContainerLogsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListAzureStorageAccountsResponder handles the response to the ListAzureStorageAccounts request. The method always
+// GetWebSiteContainerLogsSlotResponder handles the response to the GetWebSiteContainerLogsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListAzureStorageAccountsResponder(resp *http.Response) (result AzureStoragePropertyDictionaryResource, err error) {
+func (client AppsClient) GetWebSiteContainerLogsSlotResponder(resp *http.Response) (result ReadCloser, err error) {
+ result.Value = &resp.Body
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent))
result.Response = autorest.Response{Response: resp}
return
}
-// ListAzureStorageAccountsSlot gets the Azure storage account configurations of an app.
+// InstallSiteExtension install site extension on a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will update the Azure storage
-// account configurations for the production slot.
-func (client AppsClient) ListAzureStorageAccountsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result AzureStoragePropertyDictionaryResource, err error) {
+// name - site name.
+// siteExtensionID - site extension name.
+func (client AppsClient) InstallSiteExtension(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (result AppsInstallSiteExtensionFuture, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListAzureStorageAccountsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.InstallSiteExtension")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16155,35 +16162,119 @@ func (client AppsClient) ListAzureStorageAccountsSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListAzureStorageAccountsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "InstallSiteExtension", err.Error())
}
- req, err := client.ListAzureStorageAccountsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.InstallSiteExtensionPreparer(ctx, resourceGroupName, name, siteExtensionID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtension", nil, "Failure preparing request")
return
}
- resp, err := client.ListAzureStorageAccountsSlotSender(req)
+ result, err = client.InstallSiteExtensionSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtension", result.Response(), "Failure sending request")
return
}
- result, err = client.ListAzureStorageAccountsSlotResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", resp, "Failure responding to request")
- }
-
return
}
-// ListAzureStorageAccountsSlotPreparer prepares the ListAzureStorageAccountsSlot request.
-func (client AppsClient) ListAzureStorageAccountsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
+// InstallSiteExtensionPreparer prepares the InstallSiteExtension request.
+func (client AppsClient) InstallSiteExtensionPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// InstallSiteExtensionSender sends the InstallSiteExtension request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) InstallSiteExtensionSender(req *http.Request) (future AppsInstallSiteExtensionFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// InstallSiteExtensionResponder handles the response to the InstallSiteExtension request. The method always
+// closes the http.Response Body.
+func (client AppsClient) InstallSiteExtensionResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusTooManyRequests),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// InstallSiteExtensionSlot install site extension on a web site, or a deployment slot.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - site name.
+// siteExtensionID - site extension name.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) InstallSiteExtensionSlot(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (result AppsInstallSiteExtensionSlotFuture, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.InstallSiteExtensionSlot")
+ defer func() {
+ sc := -1
+ if result.Response() != nil {
+ sc = result.Response().StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "InstallSiteExtensionSlot", err.Error())
+ }
+
+ req, err := client.InstallSiteExtensionSlotPreparer(ctx, resourceGroupName, name, siteExtensionID, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtensionSlot", nil, "Failure preparing request")
+ return
+ }
+
+ result, err = client.InstallSiteExtensionSlotSender(req)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "InstallSiteExtensionSlot", result.Response(), "Failure sending request")
+ return
+ }
+
+ return
+}
+
+// InstallSiteExtensionSlotPreparer prepares the InstallSiteExtensionSlot request.
+func (client AppsClient) InstallSiteExtensionSlotPreparer(ctx context.Context, resourceGroupName string, name string, siteExtensionID string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "siteExtensionId": autorest.Encode("path", siteExtensionID),
"slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16193,24 +16284,115 @@ func (client AppsClient) ListAzureStorageAccountsSlotPreparer(ctx context.Contex
"api-version": APIVersion,
}
+ preparer := autorest.CreatePreparer(
+ autorest.AsPut(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/siteextensions/{siteExtensionId}", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// InstallSiteExtensionSlotSender sends the InstallSiteExtensionSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) InstallSiteExtensionSlotSender(req *http.Request) (future AppsInstallSiteExtensionSlotFuture, err error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ var resp *http.Response
+ resp, err = autorest.SendWithSender(client, req, sd...)
+ if err != nil {
+ return
+ }
+ future.Future, err = azure.NewFutureFromResponse(resp)
+ return
+}
+
+// InstallSiteExtensionSlotResponder handles the response to the InstallSiteExtensionSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) InstallSiteExtensionSlotResponder(resp *http.Response) (result SiteExtensionInfo, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated, http.StatusTooManyRequests),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// IsCloneable shows whether an app can be cloned to another resource group or subscription.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) IsCloneable(ctx context.Context, resourceGroupName string, name string) (result SiteCloneability, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.IsCloneable")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "IsCloneable", err.Error())
+ }
+
+ req, err := client.IsCloneablePreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.IsCloneableSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.IsCloneableResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneable", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// IsCloneablePreparer prepares the IsCloneable request.
+func (client AppsClient) IsCloneablePreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/azurestorageaccounts/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/iscloneable", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListAzureStorageAccountsSlotSender sends the ListAzureStorageAccountsSlot request. The method will close the
+// IsCloneableSender sends the IsCloneable request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListAzureStorageAccountsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) IsCloneableSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListAzureStorageAccountsSlotResponder handles the response to the ListAzureStorageAccountsSlot request. The method always
+// IsCloneableResponder handles the response to the IsCloneable request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListAzureStorageAccountsSlotResponder(resp *http.Response) (result AzureStoragePropertyDictionaryResource, err error) {
+func (client AppsClient) IsCloneableResponder(resp *http.Response) (result SiteCloneability, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16221,17 +16403,18 @@ func (client AppsClient) ListAzureStorageAccountsSlotResponder(resp *http.Respon
return
}
-// ListBackups gets existing backups of an app.
+// IsCloneableSlot shows whether an app can be cloned to another resource group or subscription.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) ListBackups(ctx context.Context, resourceGroupName string, name string) (result BackupItemCollectionPage, err error) {
+// slot - name of the deployment slot. By default, this API returns information on the production slot.
+func (client AppsClient) IsCloneableSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteCloneability, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackups")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.IsCloneableSlot")
defer func() {
sc := -1
- if result.bic.Response.Response != nil {
- sc = result.bic.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16241,36 +16424,36 @@ func (client AppsClient) ListBackups(ctx context.Context, resourceGroupName stri
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListBackups", err.Error())
+ return result, validation.NewError("web.AppsClient", "IsCloneableSlot", err.Error())
}
- result.fn = client.listBackupsNextResults
- req, err := client.ListBackupsPreparer(ctx, resourceGroupName, name)
+ req, err := client.IsCloneableSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListBackupsSender(req)
+ resp, err := client.IsCloneableSlotSender(req)
if err != nil {
- result.bic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", resp, "Failure sending request")
return
}
- result.bic, err = client.ListBackupsResponder(resp)
+ result, err = client.IsCloneableSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "IsCloneableSlot", resp, "Failure responding to request")
}
return
}
-// ListBackupsPreparer prepares the ListBackups request.
-func (client AppsClient) ListBackupsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// IsCloneableSlotPreparer prepares the IsCloneableSlot request.
+func (client AppsClient) IsCloneableSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16279,24 +16462,1022 @@ func (client AppsClient) ListBackupsPreparer(ctx context.Context, resourceGroupN
"api-version": APIVersion,
}
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/iscloneable", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// IsCloneableSlotSender sends the IsCloneableSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) IsCloneableSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// IsCloneableSlotResponder handles the response to the IsCloneableSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) IsCloneableSlotResponder(resp *http.Response) (result SiteCloneability, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// List get all apps for a subscription.
+func (client AppsClient) List(ctx context.Context) (result AppCollectionPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.List")
+ defer func() {
+ sc := -1
+ if result.ac.Response.Response != nil {
+ sc = result.ac.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.fn = client.listNextResults
+ req, err := client.ListPreparer(ctx)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "List", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.ac.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "List", resp, "Failure sending request")
+ return
+ }
+
+ result.ac, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "List", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListPreparer prepares the List request.
+func (client AppsClient) ListPreparer(ctx context.Context) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsGet(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/providers/Microsoft.Web/sites", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSender sends the List request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListResponder handles the response to the List request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListResponder(resp *http.Response) (result AppCollection, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listNextResults retrieves the next set of results, if any.
+func (client AppsClient) listNextResults(ctx context.Context, lastResults AppCollection) (result AppCollection, err error) {
+ req, err := lastResults.appCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListComplete(ctx context.Context) (result AppCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.List")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.List(ctx)
+ return
+}
+
+// ListApplicationSettings gets the application settings of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) ListApplicationSettings(ctx context.Context, resourceGroupName string, name string) (result StringDictionary, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListApplicationSettings")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListApplicationSettings", err.Error())
+ }
+
+ req, err := client.ListApplicationSettingsPreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListApplicationSettingsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListApplicationSettingsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettings", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListApplicationSettingsPreparer prepares the ListApplicationSettings request.
+func (client AppsClient) ListApplicationSettingsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/appsettings/list", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListApplicationSettingsSender sends the ListApplicationSettings request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListApplicationSettingsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListApplicationSettingsResponder handles the response to the ListApplicationSettings request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListApplicationSettingsResponder(resp *http.Response) (result StringDictionary, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListApplicationSettingsSlot gets the application settings of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will get the application settings
+// for the production slot.
+func (client AppsClient) ListApplicationSettingsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result StringDictionary, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListApplicationSettingsSlot")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListApplicationSettingsSlot", err.Error())
+ }
+
+ req, err := client.ListApplicationSettingsSlotPreparer(ctx, resourceGroupName, name, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListApplicationSettingsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListApplicationSettingsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListApplicationSettingsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListApplicationSettingsSlotPreparer prepares the ListApplicationSettingsSlot request.
+func (client AppsClient) ListApplicationSettingsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings/list", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListApplicationSettingsSlotSender sends the ListApplicationSettingsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListApplicationSettingsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListApplicationSettingsSlotResponder handles the response to the ListApplicationSettingsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListApplicationSettingsSlotResponder(resp *http.Response) (result StringDictionary, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListAzureStorageAccounts gets the Azure storage account configurations of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) ListAzureStorageAccounts(ctx context.Context, resourceGroupName string, name string) (result AzureStoragePropertyDictionaryResource, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListAzureStorageAccounts")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListAzureStorageAccounts", err.Error())
+ }
+
+ req, err := client.ListAzureStorageAccountsPreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListAzureStorageAccountsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListAzureStorageAccountsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccounts", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListAzureStorageAccountsPreparer prepares the ListAzureStorageAccounts request.
+func (client AppsClient) ListAzureStorageAccountsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/azurestorageaccounts/list", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListAzureStorageAccountsSender sends the ListAzureStorageAccounts request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListAzureStorageAccountsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListAzureStorageAccountsResponder handles the response to the ListAzureStorageAccounts request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListAzureStorageAccountsResponder(resp *http.Response) (result AzureStoragePropertyDictionaryResource, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListAzureStorageAccountsSlot gets the Azure storage account configurations of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will update the Azure storage
+// account configurations for the production slot.
+func (client AppsClient) ListAzureStorageAccountsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result AzureStoragePropertyDictionaryResource, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListAzureStorageAccountsSlot")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListAzureStorageAccountsSlot", err.Error())
+ }
+
+ req, err := client.ListAzureStorageAccountsSlotPreparer(ctx, resourceGroupName, name, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListAzureStorageAccountsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListAzureStorageAccountsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListAzureStorageAccountsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListAzureStorageAccountsSlotPreparer prepares the ListAzureStorageAccountsSlot request.
+func (client AppsClient) ListAzureStorageAccountsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/azurestorageaccounts/list", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListAzureStorageAccountsSlotSender sends the ListAzureStorageAccountsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListAzureStorageAccountsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListAzureStorageAccountsSlotResponder handles the response to the ListAzureStorageAccountsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListAzureStorageAccountsSlotResponder(resp *http.Response) (result AzureStoragePropertyDictionaryResource, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListBackups gets existing backups of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) ListBackups(ctx context.Context, resourceGroupName string, name string) (result BackupItemCollectionPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackups")
+ defer func() {
+ sc := -1
+ if result.bic.Response.Response != nil {
+ sc = result.bic.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListBackups", err.Error())
+ }
+
+ result.fn = client.listBackupsNextResults
+ req, err := client.ListBackupsPreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListBackupsSender(req)
+ if err != nil {
+ result.bic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", resp, "Failure sending request")
+ return
+ }
+
+ result.bic, err = client.ListBackupsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackups", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListBackupsPreparer prepares the ListBackups request.
+func (client AppsClient) ListBackupsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-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.Web/sites/{name}/backups", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListBackupsSender sends the ListBackups request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListBackupsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListBackupsResponder handles the response to the ListBackups request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListBackupsResponder(resp *http.Response) (result BackupItemCollection, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listBackupsNextResults retrieves the next set of results, if any.
+func (client AppsClient) listBackupsNextResults(ctx context.Context, lastResults BackupItemCollection) (result BackupItemCollection, err error) {
+ req, err := lastResults.backupItemCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListBackupsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListBackupsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListBackupsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListBackupsComplete(ctx context.Context, resourceGroupName string, name string) (result BackupItemCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackups")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListBackups(ctx, resourceGroupName, name)
+ return
+}
+
+// ListBackupsSlot gets existing backups of an app.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will get backups of the production
+// slot.
+func (client AppsClient) ListBackupsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupItemCollectionPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupsSlot")
+ defer func() {
+ sc := -1
+ if result.bic.Response.Response != nil {
+ sc = result.bic.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListBackupsSlot", err.Error())
+ }
+
+ result.fn = client.listBackupsSlotNextResults
+ req, err := client.ListBackupsSlotPreparer(ctx, resourceGroupName, name, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListBackupsSlotSender(req)
+ if err != nil {
+ result.bic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", resp, "Failure sending request")
+ return
+ }
+
+ result.bic, err = client.ListBackupsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListBackupsSlotPreparer prepares the ListBackupsSlot request.
+func (client AppsClient) ListBackupsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-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.Web/sites/{name}/slots/{slot}/backups", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListBackupsSlotSender sends the ListBackupsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListBackupsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListBackupsSlotResponder handles the response to the ListBackupsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListBackupsSlotResponder(resp *http.Response) (result BackupItemCollection, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listBackupsSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listBackupsSlotNextResults(ctx context.Context, lastResults BackupItemCollection) (result BackupItemCollection, err error) {
+ req, err := lastResults.backupItemCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListBackupsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListBackupsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListBackupsSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListBackupsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupItemCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupsSlot")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListBackupsSlot(ctx, resourceGroupName, name, slot)
+ return
+}
+
+// ListBackupStatusSecrets gets status of a web app backup that may be in progress, including secrets associated with
+// the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is
+// passed in the request body.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of web app.
+// backupID - ID of backup.
+// request - information on backup request.
+func (client AppsClient) ListBackupStatusSecrets(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest) (result BackupItem, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupStatusSecrets")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: request,
+ Constraints: []validation.Constraint{{Target: "request.BackupRequestProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.BackupSchedule.FrequencyInterval", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule.KeepAtLeastOneBackup", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule.RetentionPeriodInDays", Name: validation.Null, Rule: true, Chain: nil},
+ }},
+ }}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListBackupStatusSecrets", err.Error())
+ }
+
+ req, err := client.ListBackupStatusSecretsPreparer(ctx, resourceGroupName, name, backupID, request)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListBackupStatusSecretsSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListBackupStatusSecretsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListBackupStatusSecretsPreparer prepares the ListBackupStatusSecrets request.
+func (client AppsClient) ListBackupStatusSecretsPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupId": autorest.Encode("path", backupID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}/list", pathParameters),
+ autorest.WithJSON(request),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListBackupStatusSecretsSender sends the ListBackupStatusSecrets request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListBackupStatusSecretsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListBackupStatusSecretsResponder handles the response to the ListBackupStatusSecrets request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListBackupStatusSecretsResponder(resp *http.Response) (result BackupItem, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListBackupStatusSecretsSlot gets status of a web app backup that may be in progress, including secrets associated
+// with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new
+// URL is passed in the request body.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of web app.
+// backupID - ID of backup.
+// request - information on backup request.
+// slot - name of web app slot. If not specified then will default to production slot.
+func (client AppsClient) ListBackupStatusSecretsSlot(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest, slot string) (result BackupItem, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupStatusSecretsSlot")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
+ {TargetValue: request,
+ Constraints: []validation.Constraint{{Target: "request.BackupRequestProperties", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule", Name: validation.Null, Rule: false,
+ Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.BackupSchedule.FrequencyInterval", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule.KeepAtLeastOneBackup", Name: validation.Null, Rule: true, Chain: nil},
+ {Target: "request.BackupRequestProperties.BackupSchedule.RetentionPeriodInDays", Name: validation.Null, Rule: true, Chain: nil},
+ }},
+ }}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListBackupStatusSecretsSlot", err.Error())
+ }
+
+ req, err := client.ListBackupStatusSecretsSlotPreparer(ctx, resourceGroupName, name, backupID, request, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListBackupStatusSecretsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListBackupStatusSecretsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListBackupStatusSecretsSlotPreparer prepares the ListBackupStatusSecretsSlot request.
+func (client AppsClient) ListBackupStatusSecretsSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "backupId": autorest.Encode("path", backupID),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsContentType("application/json; charset=utf-8"),
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}/list", pathParameters),
+ autorest.WithJSON(request),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListBackupStatusSecretsSlotSender sends the ListBackupStatusSecretsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListBackupStatusSecretsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListBackupStatusSecretsSlotResponder handles the response to the ListBackupStatusSecretsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListBackupStatusSecretsSlotResponder(resp *http.Response) (result BackupItem, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListByResourceGroup gets all web, mobile, and API apps in the specified resource group.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// includeSlots - specify true to include deployment slots in results. The default is false,
+// which only gives you the production slot of all apps.
+func (client AppsClient) ListByResourceGroup(ctx context.Context, resourceGroupName string, includeSlots *bool) (result AppCollectionPage, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListByResourceGroup")
+ defer func() {
+ sc := -1
+ if result.ac.Response.Response != nil {
+ sc = result.ac.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListByResourceGroup", err.Error())
+ }
+
+ result.fn = client.listByResourceGroupNextResults
+ req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName, includeSlots)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListByResourceGroupSender(req)
+ if err != nil {
+ result.ac.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", resp, "Failure sending request")
+ return
+ }
+
+ result.ac, err = client.ListByResourceGroupResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
+func (client AppsClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string, includeSlots *bool) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+ if includeSlots != nil {
+ queryParameters["includeSlots"] = autorest.Encode("query", *includeSlots)
+ }
+
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListBackupsSender sends the ListBackups request. The method will close the
+// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListBackupsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListBackupsResponder handles the response to the ListBackups request. The method always
+// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListBackupsResponder(resp *http.Response) (result BackupItemCollection, err error) {
+func (client AppsClient) ListByResourceGroupResponder(resp *http.Response) (result AppCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16307,31 +17488,31 @@ func (client AppsClient) ListBackupsResponder(resp *http.Response) (result Backu
return
}
-// listBackupsNextResults retrieves the next set of results, if any.
-func (client AppsClient) listBackupsNextResults(ctx context.Context, lastResults BackupItemCollection) (result BackupItemCollection, err error) {
- req, err := lastResults.backupItemCollectionPreparer(ctx)
+// listByResourceGroupNextResults retrieves the next set of results, if any.
+func (client AppsClient) listByResourceGroupNextResults(ctx context.Context, lastResults AppCollection) (result AppCollection, err error) {
+ req, err := lastResults.appCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListBackupsSender(req)
+ resp, err := client.ListByResourceGroupSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListBackupsResponder(resp)
+ result, err = client.ListByResourceGroupResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListBackupsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListBackupsComplete(ctx context.Context, resourceGroupName string, name string) (result BackupItemCollectionIterator, err error) {
+// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string, includeSlots *bool) (result AppCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackups")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListByResourceGroup")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -16340,23 +17521,21 @@ func (client AppsClient) ListBackupsComplete(ctx context.Context, resourceGroupN
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListBackups(ctx, resourceGroupName, name)
+ result.page, err = client.ListByResourceGroup(ctx, resourceGroupName, includeSlots)
return
}
-// ListBackupsSlot gets existing backups of an app.
+// ListConfigurations list the configurations of an app
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get backups of the production
-// slot.
-func (client AppsClient) ListBackupsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupItemCollectionPage, err error) {
+func (client AppsClient) ListConfigurations(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResourceCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurations")
defer func() {
sc := -1
- if result.bic.Response.Response != nil {
- sc = result.bic.Response.Response.StatusCode
+ if result.scrc.Response.Response != nil {
+ sc = result.scrc.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16366,37 +17545,36 @@ func (client AppsClient) ListBackupsSlot(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListBackupsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListConfigurations", err.Error())
}
- result.fn = client.listBackupsSlotNextResults
- req, err := client.ListBackupsSlotPreparer(ctx, resourceGroupName, name, slot)
+ result.fn = client.listConfigurationsNextResults
+ req, err := client.ListConfigurationsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", nil, "Failure preparing request")
return
}
- resp, err := client.ListBackupsSlotSender(req)
+ resp, err := client.ListConfigurationsSender(req)
if err != nil {
- result.bic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", resp, "Failure sending request")
+ result.scrc.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", resp, "Failure sending request")
return
}
- result.bic, err = client.ListBackupsSlotResponder(resp)
+ result.scrc, err = client.ListConfigurationsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", resp, "Failure responding to request")
}
return
}
-// ListBackupsSlotPreparer prepares the ListBackupsSlot request.
-func (client AppsClient) ListBackupsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListConfigurationsPreparer prepares the ListConfigurations request.
+func (client AppsClient) ListConfigurationsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16408,21 +17586,21 @@ func (client AppsClient) ListBackupsSlotPreparer(ctx context.Context, resourceGr
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListBackupsSlotSender sends the ListBackupsSlot request. The method will close the
+// ListConfigurationsSender sends the ListConfigurations request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListBackupsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConfigurationsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListBackupsSlotResponder handles the response to the ListBackupsSlot request. The method always
+// ListConfigurationsResponder handles the response to the ListConfigurations request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListBackupsSlotResponder(resp *http.Response) (result BackupItemCollection, err error) {
+func (client AppsClient) ListConfigurationsResponder(resp *http.Response) (result SiteConfigResourceCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16433,31 +17611,31 @@ func (client AppsClient) ListBackupsSlotResponder(resp *http.Response) (result B
return
}
-// listBackupsSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listBackupsSlotNextResults(ctx context.Context, lastResults BackupItemCollection) (result BackupItemCollection, err error) {
- req, err := lastResults.backupItemCollectionPreparer(ctx)
+// listConfigurationsNextResults retrieves the next set of results, if any.
+func (client AppsClient) listConfigurationsNextResults(ctx context.Context, lastResults SiteConfigResourceCollection) (result SiteConfigResourceCollection, err error) {
+ req, err := lastResults.siteConfigResourceCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListBackupsSlotSender(req)
+ resp, err := client.ListConfigurationsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListBackupsSlotResponder(resp)
+ result, err = client.ListConfigurationsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listBackupsSlotNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListBackupsSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListBackupsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result BackupItemCollectionIterator, err error) {
+// ListConfigurationsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListConfigurationsComplete(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResourceCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurations")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -16466,25 +17644,22 @@ func (client AppsClient) ListBackupsSlotComplete(ctx context.Context, resourceGr
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListBackupsSlot(ctx, resourceGroupName, name, slot)
+ result.page, err = client.ListConfigurations(ctx, resourceGroupName, name)
return
}
-// ListBackupStatusSecrets gets status of a web app backup that may be in progress, including secrets associated with
-// the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new URL is
-// passed in the request body.
+// ListConfigurationSnapshotInfo gets a list of web app configuration snapshots identifiers. Each element of the list
+// contains a timestamp and the ID of the snapshot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// backupID - ID of backup.
-// request - information on backup request.
-func (client AppsClient) ListBackupStatusSecrets(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest) (result BackupItem, err error) {
+// name - name of the app.
+func (client AppsClient) ListConfigurationSnapshotInfo(ctx context.Context, resourceGroupName string, name string) (result SiteConfigurationSnapshotInfoCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupStatusSecrets")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfo")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.scsic.Response.Response != nil {
+ sc = result.scsic.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16493,44 +17668,35 @@ func (client AppsClient) ListBackupStatusSecrets(ctx context.Context, resourceGr
{TargetValue: resourceGroupName,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: request,
- Constraints: []validation.Constraint{{Target: "request.BackupRequestProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.BackupSchedule.FrequencyInterval", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule.KeepAtLeastOneBackup", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule.RetentionPeriodInDays", Name: validation.Null, Rule: true, Chain: nil},
- }},
- }}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListBackupStatusSecrets", err.Error())
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListConfigurationSnapshotInfo", err.Error())
}
- req, err := client.ListBackupStatusSecretsPreparer(ctx, resourceGroupName, name, backupID, request)
+ result.fn = client.listConfigurationSnapshotInfoNextResults
+ req, err := client.ListConfigurationSnapshotInfoPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", nil, "Failure preparing request")
return
}
- resp, err := client.ListBackupStatusSecretsSender(req)
+ resp, err := client.ListConfigurationSnapshotInfoSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", resp, "Failure sending request")
+ result.scsic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", resp, "Failure sending request")
return
}
- result, err = client.ListBackupStatusSecretsResponder(resp)
+ result.scsic, err = client.ListConfigurationSnapshotInfoResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecrets", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", resp, "Failure responding to request")
}
return
}
-// ListBackupStatusSecretsPreparer prepares the ListBackupStatusSecrets request.
-func (client AppsClient) ListBackupStatusSecretsPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest) (*http.Request, error) {
+// ListConfigurationSnapshotInfoPreparer prepares the ListConfigurationSnapshotInfo request.
+func (client AppsClient) ListConfigurationSnapshotInfoPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -16542,25 +17708,23 @@ func (client AppsClient) ListBackupStatusSecretsPreparer(ctx context.Context, re
}
preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}/list", pathParameters),
- autorest.WithJSON(request),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web/snapshots", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListBackupStatusSecretsSender sends the ListBackupStatusSecrets request. The method will close the
+// ListConfigurationSnapshotInfoSender sends the ListConfigurationSnapshotInfo request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListBackupStatusSecretsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConfigurationSnapshotInfoSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListBackupStatusSecretsResponder handles the response to the ListBackupStatusSecrets request. The method always
+// ListConfigurationSnapshotInfoResponder handles the response to the ListConfigurationSnapshotInfo request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListBackupStatusSecretsResponder(resp *http.Response) (result BackupItem, err error) {
+func (client AppsClient) ListConfigurationSnapshotInfoResponder(resp *http.Response) (result SiteConfigurationSnapshotInfoCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16571,121 +17735,57 @@ func (client AppsClient) ListBackupStatusSecretsResponder(resp *http.Response) (
return
}
-// ListBackupStatusSecretsSlot gets status of a web app backup that may be in progress, including secrets associated
-// with the backup, such as the Azure Storage SAS URL. Also can be used to update the SAS URL for the backup if a new
-// URL is passed in the request body.
-// Parameters:
-// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of web app.
-// backupID - ID of backup.
-// request - information on backup request.
-// slot - name of web app slot. If not specified then will default to production slot.
-func (client AppsClient) ListBackupStatusSecretsSlot(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest, slot string) (result BackupItem, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListBackupStatusSecretsSlot")
- defer func() {
- sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- if err := validation.Validate([]validation.Validation{
- {TargetValue: resourceGroupName,
- Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
- {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
- {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}},
- {TargetValue: request,
- Constraints: []validation.Constraint{{Target: "request.BackupRequestProperties", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.StorageAccountURL", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule", Name: validation.Null, Rule: false,
- Chain: []validation.Constraint{{Target: "request.BackupRequestProperties.BackupSchedule.FrequencyInterval", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule.KeepAtLeastOneBackup", Name: validation.Null, Rule: true, Chain: nil},
- {Target: "request.BackupRequestProperties.BackupSchedule.RetentionPeriodInDays", Name: validation.Null, Rule: true, Chain: nil},
- }},
- }}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListBackupStatusSecretsSlot", err.Error())
- }
-
- req, err := client.ListBackupStatusSecretsSlotPreparer(ctx, resourceGroupName, name, backupID, request, slot)
+// listConfigurationSnapshotInfoNextResults retrieves the next set of results, if any.
+func (client AppsClient) listConfigurationSnapshotInfoNextResults(ctx context.Context, lastResults SiteConfigurationSnapshotInfoCollection) (result SiteConfigurationSnapshotInfoCollection, err error) {
+ req, err := lastResults.siteConfigurationSnapshotInfoCollectionPreparer(ctx)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", nil, "Failure preparing request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
return
}
-
- resp, err := client.ListBackupStatusSecretsSlotSender(req)
+ resp, err := client.ListConfigurationSnapshotInfoSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", resp, "Failure sending request")
- return
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", resp, "Failure sending next results request")
}
-
- result, err = client.ListBackupStatusSecretsSlotResponder(resp)
+ result, err = client.ListConfigurationSnapshotInfoResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListBackupStatusSecretsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", resp, "Failure responding to next results request")
}
-
return
}
-// ListBackupStatusSecretsSlotPreparer prepares the ListBackupStatusSecretsSlot request.
-func (client AppsClient) ListBackupStatusSecretsSlotPreparer(ctx context.Context, resourceGroupName string, name string, backupID string, request BackupRequest, slot string) (*http.Request, error) {
- pathParameters := map[string]interface{}{
- "backupId": autorest.Encode("path", backupID),
- "name": autorest.Encode("path", name),
- "resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
- "subscriptionId": autorest.Encode("path", client.SubscriptionID),
- }
-
- const APIVersion = "2018-02-01"
- queryParameters := map[string]interface{}{
- "api-version": APIVersion,
- }
-
- preparer := autorest.CreatePreparer(
- autorest.AsContentType("application/json; charset=utf-8"),
- autorest.AsPost(),
- autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}/list", pathParameters),
- autorest.WithJSON(request),
- autorest.WithQueryParameters(queryParameters))
- return preparer.Prepare((&http.Request{}).WithContext(ctx))
-}
-
-// ListBackupStatusSecretsSlotSender sends the ListBackupStatusSecretsSlot request. The method will close the
-// http.Response Body if it receives an error.
-func (client AppsClient) ListBackupStatusSecretsSlotSender(req *http.Request) (*http.Response, error) {
- sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
- return autorest.SendWithSender(client, req, sd...)
-}
-
-// ListBackupStatusSecretsSlotResponder handles the response to the ListBackupStatusSecretsSlot request. The method always
-// closes the http.Response Body.
-func (client AppsClient) ListBackupStatusSecretsSlotResponder(resp *http.Response) (result BackupItem, err error) {
- err = autorest.Respond(
- resp,
- client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+// ListConfigurationSnapshotInfoComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListConfigurationSnapshotInfoComplete(ctx context.Context, resourceGroupName string, name string) (result SiteConfigurationSnapshotInfoCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfo")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListConfigurationSnapshotInfo(ctx, resourceGroupName, name)
return
}
-// ListByResourceGroup gets all web, mobile, and API apps in the specified resource group.
+// ListConfigurationSnapshotInfoSlot gets a list of web app configuration snapshots identifiers. Each element of the
+// list contains a timestamp and the ID of the snapshot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// includeSlots - specify true to include deployment slots in results. The default is false,
-// which only gives you the production slot of all apps.
-func (client AppsClient) ListByResourceGroup(ctx context.Context, resourceGroupName string, includeSlots *bool) (result AppCollectionPage, err error) {
+// name - name of the app.
+// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
+// production slot.
+func (client AppsClient) ListConfigurationSnapshotInfoSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigurationSnapshotInfoCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListByResourceGroup")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfoSlot")
defer func() {
sc := -1
- if result.ac.Response.Response != nil {
- sc = result.ac.Response.Response.StatusCode
+ if result.scsic.Response.Response != nil {
+ sc = result.scsic.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16695,35 +17795,37 @@ func (client AppsClient) ListByResourceGroup(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListByResourceGroup", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListConfigurationSnapshotInfoSlot", err.Error())
}
- result.fn = client.listByResourceGroupNextResults
- req, err := client.ListByResourceGroupPreparer(ctx, resourceGroupName, includeSlots)
+ result.fn = client.listConfigurationSnapshotInfoSlotNextResults
+ req, err := client.ListConfigurationSnapshotInfoSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListByResourceGroupSender(req)
+ resp, err := client.ListConfigurationSnapshotInfoSlotSender(req)
if err != nil {
- result.ac.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", resp, "Failure sending request")
+ result.scsic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", resp, "Failure sending request")
return
}
- result.ac, err = client.ListByResourceGroupResponder(resp)
+ result.scsic, err = client.ListConfigurationSnapshotInfoSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListByResourceGroup", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", resp, "Failure responding to request")
}
return
}
-// ListByResourceGroupPreparer prepares the ListByResourceGroup request.
-func (client AppsClient) ListByResourceGroupPreparer(ctx context.Context, resourceGroupName string, includeSlots *bool) (*http.Request, error) {
+// ListConfigurationSnapshotInfoSlotPreparer prepares the ListConfigurationSnapshotInfoSlot request.
+func (client AppsClient) ListConfigurationSnapshotInfoSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16731,28 +17833,25 @@ func (client AppsClient) ListByResourceGroupPreparer(ctx context.Context, resour
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
- if includeSlots != nil {
- queryParameters["includeSlots"] = autorest.Encode("query", *includeSlots)
- }
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListByResourceGroupSender sends the ListByResourceGroup request. The method will close the
+// ListConfigurationSnapshotInfoSlotSender sends the ListConfigurationSnapshotInfoSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListByResourceGroupSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConfigurationSnapshotInfoSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListByResourceGroupResponder handles the response to the ListByResourceGroup request. The method always
+// ListConfigurationSnapshotInfoSlotResponder handles the response to the ListConfigurationSnapshotInfoSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListByResourceGroupResponder(resp *http.Response) (result AppCollection, err error) {
+func (client AppsClient) ListConfigurationSnapshotInfoSlotResponder(resp *http.Response) (result SiteConfigurationSnapshotInfoCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16763,31 +17862,31 @@ func (client AppsClient) ListByResourceGroupResponder(resp *http.Response) (resu
return
}
-// listByResourceGroupNextResults retrieves the next set of results, if any.
-func (client AppsClient) listByResourceGroupNextResults(ctx context.Context, lastResults AppCollection) (result AppCollection, err error) {
- req, err := lastResults.appCollectionPreparer(ctx)
+// listConfigurationSnapshotInfoSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listConfigurationSnapshotInfoSlotNextResults(ctx context.Context, lastResults SiteConfigurationSnapshotInfoCollection) (result SiteConfigurationSnapshotInfoCollection, err error) {
+ req, err := lastResults.siteConfigurationSnapshotInfoCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListByResourceGroupSender(req)
+ resp, err := client.ListConfigurationSnapshotInfoSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListByResourceGroupResponder(resp)
+ result, err = client.ListConfigurationSnapshotInfoSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listByResourceGroupNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListByResourceGroupComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListByResourceGroupComplete(ctx context.Context, resourceGroupName string, includeSlots *bool) (result AppCollectionIterator, err error) {
+// ListConfigurationSnapshotInfoSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListConfigurationSnapshotInfoSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigurationSnapshotInfoCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListByResourceGroup")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfoSlot")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -16796,17 +17895,19 @@ func (client AppsClient) ListByResourceGroupComplete(ctx context.Context, resour
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListByResourceGroup(ctx, resourceGroupName, includeSlots)
+ result.page, err = client.ListConfigurationSnapshotInfoSlot(ctx, resourceGroupName, name, slot)
return
}
-// ListConfigurations list the configurations of an app
+// ListConfigurationsSlot list the configurations of an app
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) ListConfigurations(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResourceCollectionPage, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
+// production slot.
+func (client AppsClient) ListConfigurationsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResourceCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurations")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationsSlot")
defer func() {
sc := -1
if result.scrc.Response.Response != nil {
@@ -16820,36 +17921,37 @@ func (client AppsClient) ListConfigurations(ctx context.Context, resourceGroupNa
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConfigurations", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListConfigurationsSlot", err.Error())
}
- result.fn = client.listConfigurationsNextResults
- req, err := client.ListConfigurationsPreparer(ctx, resourceGroupName, name)
+ result.fn = client.listConfigurationsSlotNextResults
+ req, err := client.ListConfigurationsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListConfigurationsSender(req)
+ resp, err := client.ListConfigurationsSlotSender(req)
if err != nil {
result.scrc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", resp, "Failure sending request")
return
}
- result.scrc, err = client.ListConfigurationsResponder(resp)
+ result.scrc, err = client.ListConfigurationsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurations", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", resp, "Failure responding to request")
}
return
}
-// ListConfigurationsPreparer prepares the ListConfigurations request.
-func (client AppsClient) ListConfigurationsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListConfigurationsSlotPreparer prepares the ListConfigurationsSlot request.
+func (client AppsClient) ListConfigurationsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -16861,21 +17963,21 @@ func (client AppsClient) ListConfigurationsPreparer(ctx context.Context, resourc
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConfigurationsSender sends the ListConfigurations request. The method will close the
+// ListConfigurationsSlotSender sends the ListConfigurationsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConfigurationsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConfigurationsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConfigurationsResponder handles the response to the ListConfigurations request. The method always
+// ListConfigurationsSlotResponder handles the response to the ListConfigurationsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConfigurationsResponder(resp *http.Response) (result SiteConfigResourceCollection, err error) {
+func (client AppsClient) ListConfigurationsSlotResponder(resp *http.Response) (result SiteConfigResourceCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -16886,31 +17988,31 @@ func (client AppsClient) ListConfigurationsResponder(resp *http.Response) (resul
return
}
-// listConfigurationsNextResults retrieves the next set of results, if any.
-func (client AppsClient) listConfigurationsNextResults(ctx context.Context, lastResults SiteConfigResourceCollection) (result SiteConfigResourceCollection, err error) {
+// listConfigurationsSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listConfigurationsSlotNextResults(ctx context.Context, lastResults SiteConfigResourceCollection) (result SiteConfigResourceCollection, err error) {
req, err := lastResults.siteConfigResourceCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListConfigurationsSender(req)
+ resp, err := client.ListConfigurationsSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListConfigurationsResponder(resp)
+ result, err = client.ListConfigurationsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListConfigurationsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListConfigurationsComplete(ctx context.Context, resourceGroupName string, name string) (result SiteConfigResourceCollectionIterator, err error) {
+// ListConfigurationsSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListConfigurationsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResourceCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurations")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationsSlot")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -16919,22 +18021,21 @@ func (client AppsClient) ListConfigurationsComplete(ctx context.Context, resourc
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListConfigurations(ctx, resourceGroupName, name)
+ result.page, err = client.ListConfigurationsSlot(ctx, resourceGroupName, name, slot)
return
}
-// ListConfigurationSnapshotInfo gets a list of web app configuration snapshots identifiers. Each element of the list
-// contains a timestamp and the ID of the snapshot.
+// ListConnectionStrings gets the connection strings of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) ListConfigurationSnapshotInfo(ctx context.Context, resourceGroupName string, name string) (result SiteConfigurationSnapshotInfoCollectionPage, err error) {
+func (client AppsClient) ListConnectionStrings(ctx context.Context, resourceGroupName string, name string) (result ConnectionStringDictionary, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfo")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConnectionStrings")
defer func() {
sc := -1
- if result.scsic.Response.Response != nil {
- sc = result.scsic.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -16944,33 +18045,32 @@ func (client AppsClient) ListConfigurationSnapshotInfo(ctx context.Context, reso
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConfigurationSnapshotInfo", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListConnectionStrings", err.Error())
}
- result.fn = client.listConfigurationSnapshotInfoNextResults
- req, err := client.ListConfigurationSnapshotInfoPreparer(ctx, resourceGroupName, name)
+ req, err := client.ListConnectionStringsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", nil, "Failure preparing request")
return
}
- resp, err := client.ListConfigurationSnapshotInfoSender(req)
+ resp, err := client.ListConnectionStringsSender(req)
if err != nil {
- result.scsic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", resp, "Failure sending request")
return
}
- result.scsic, err = client.ListConfigurationSnapshotInfoResponder(resp)
+ result, err = client.ListConnectionStringsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfo", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", resp, "Failure responding to request")
}
return
}
-// ListConfigurationSnapshotInfoPreparer prepares the ListConfigurationSnapshotInfo request.
-func (client AppsClient) ListConfigurationSnapshotInfoPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListConnectionStringsPreparer prepares the ListConnectionStrings request.
+func (client AppsClient) ListConnectionStringsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -16983,23 +18083,23 @@ func (client AppsClient) ListConfigurationSnapshotInfoPreparer(ctx context.Conte
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/web/snapshots", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/connectionstrings/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConfigurationSnapshotInfoSender sends the ListConfigurationSnapshotInfo request. The method will close the
+// ListConnectionStringsSender sends the ListConnectionStrings request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConfigurationSnapshotInfoSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConnectionStringsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConfigurationSnapshotInfoResponder handles the response to the ListConfigurationSnapshotInfo request. The method always
+// ListConnectionStringsResponder handles the response to the ListConnectionStrings request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConfigurationSnapshotInfoResponder(resp *http.Response) (result SiteConfigurationSnapshotInfoCollection, err error) {
+func (client AppsClient) ListConnectionStringsResponder(resp *http.Response) (result ConnectionStringDictionary, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17010,57 +18110,19 @@ func (client AppsClient) ListConfigurationSnapshotInfoResponder(resp *http.Respo
return
}
-// listConfigurationSnapshotInfoNextResults retrieves the next set of results, if any.
-func (client AppsClient) listConfigurationSnapshotInfoNextResults(ctx context.Context, lastResults SiteConfigurationSnapshotInfoCollection) (result SiteConfigurationSnapshotInfoCollection, err error) {
- req, err := lastResults.siteConfigurationSnapshotInfoCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListConfigurationSnapshotInfoSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListConfigurationSnapshotInfoResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListConfigurationSnapshotInfoComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListConfigurationSnapshotInfoComplete(ctx context.Context, resourceGroupName string, name string) (result SiteConfigurationSnapshotInfoCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfo")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListConfigurationSnapshotInfo(ctx, resourceGroupName, name)
- return
-}
-
-// ListConfigurationSnapshotInfoSlot gets a list of web app configuration snapshots identifiers. Each element of the
-// list contains a timestamp and the ID of the snapshot.
+// ListConnectionStringsSlot gets the connection strings of an app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
-// production slot.
-func (client AppsClient) ListConfigurationSnapshotInfoSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigurationSnapshotInfoCollectionPage, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will get the connection settings for
+// the production slot.
+func (client AppsClient) ListConnectionStringsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ConnectionStringDictionary, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfoSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConnectionStringsSlot")
defer func() {
- sc := -1
- if result.scsic.Response.Response != nil {
- sc = result.scsic.Response.Response.StatusCode
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17070,33 +18132,32 @@ func (client AppsClient) ListConfigurationSnapshotInfoSlot(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConfigurationSnapshotInfoSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListConnectionStringsSlot", err.Error())
}
- result.fn = client.listConfigurationSnapshotInfoSlotNextResults
- req, err := client.ListConfigurationSnapshotInfoSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.ListConnectionStringsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListConfigurationSnapshotInfoSlotSender(req)
+ resp, err := client.ListConnectionStringsSlotSender(req)
if err != nil {
- result.scsic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", resp, "Failure sending request")
return
}
- result.scsic, err = client.ListConfigurationSnapshotInfoSlotResponder(resp)
+ result, err = client.ListConnectionStringsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationSnapshotInfoSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", resp, "Failure responding to request")
}
return
}
-// ListConfigurationSnapshotInfoSlotPreparer prepares the ListConfigurationSnapshotInfoSlot request.
-func (client AppsClient) ListConfigurationSnapshotInfoSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListConnectionStringsSlotPreparer prepares the ListConnectionStringsSlot request.
+func (client AppsClient) ListConnectionStringsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -17110,23 +18171,23 @@ func (client AppsClient) ListConfigurationSnapshotInfoSlotPreparer(ctx context.C
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings/list", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConfigurationSnapshotInfoSlotSender sends the ListConfigurationSnapshotInfoSlot request. The method will close the
+// ListConnectionStringsSlotSender sends the ListConnectionStringsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConfigurationSnapshotInfoSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListConnectionStringsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConfigurationSnapshotInfoSlotResponder handles the response to the ListConfigurationSnapshotInfoSlot request. The method always
+// ListConnectionStringsSlotResponder handles the response to the ListConnectionStringsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConfigurationSnapshotInfoSlotResponder(resp *http.Response) (result SiteConfigurationSnapshotInfoCollection, err error) {
+func (client AppsClient) ListConnectionStringsSlotResponder(resp *http.Response) (result ConnectionStringDictionary, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17137,56 +18198,17 @@ func (client AppsClient) ListConfigurationSnapshotInfoSlotResponder(resp *http.R
return
}
-// listConfigurationSnapshotInfoSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listConfigurationSnapshotInfoSlotNextResults(ctx context.Context, lastResults SiteConfigurationSnapshotInfoCollection) (result SiteConfigurationSnapshotInfoCollection, err error) {
- req, err := lastResults.siteConfigurationSnapshotInfoCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListConfigurationSnapshotInfoSlotSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListConfigurationSnapshotInfoSlotResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationSnapshotInfoSlotNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListConfigurationSnapshotInfoSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListConfigurationSnapshotInfoSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigurationSnapshotInfoCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationSnapshotInfoSlot")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListConfigurationSnapshotInfoSlot(ctx, resourceGroupName, name, slot)
- return
-}
-
-// ListConfigurationsSlot list the configurations of an app
+// ListContinuousWebJobs list continuous web jobs for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will return configuration for the
-// production slot.
-func (client AppsClient) ListConfigurationsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResourceCollectionPage, err error) {
+// name - site name.
+func (client AppsClient) ListContinuousWebJobs(ctx context.Context, resourceGroupName string, name string) (result ContinuousWebJobCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobs")
defer func() {
sc := -1
- if result.scrc.Response.Response != nil {
- sc = result.scrc.Response.Response.StatusCode
+ if result.cwjc.Response.Response != nil {
+ sc = result.cwjc.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17196,37 +18218,36 @@ func (client AppsClient) ListConfigurationsSlot(ctx context.Context, resourceGro
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConfigurationsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListContinuousWebJobs", err.Error())
}
- result.fn = client.listConfigurationsSlotNextResults
- req, err := client.ListConfigurationsSlotPreparer(ctx, resourceGroupName, name, slot)
+ result.fn = client.listContinuousWebJobsNextResults
+ req, err := client.ListContinuousWebJobsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", nil, "Failure preparing request")
return
}
- resp, err := client.ListConfigurationsSlotSender(req)
+ resp, err := client.ListContinuousWebJobsSender(req)
if err != nil {
- result.scrc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", resp, "Failure sending request")
+ result.cwjc.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", resp, "Failure sending request")
return
}
- result.scrc, err = client.ListConfigurationsSlotResponder(resp)
+ result.cwjc, err = client.ListContinuousWebJobsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConfigurationsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", resp, "Failure responding to request")
}
return
}
-// ListConfigurationsSlotPreparer prepares the ListConfigurationsSlot request.
-func (client AppsClient) ListConfigurationsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListContinuousWebJobsPreparer prepares the ListContinuousWebJobs request.
+func (client AppsClient) ListContinuousWebJobsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17238,21 +18259,21 @@ func (client AppsClient) ListConfigurationsSlotPreparer(ctx context.Context, res
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConfigurationsSlotSender sends the ListConfigurationsSlot request. The method will close the
+// ListContinuousWebJobsSender sends the ListContinuousWebJobs request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConfigurationsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListContinuousWebJobsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConfigurationsSlotResponder handles the response to the ListConfigurationsSlot request. The method always
+// ListContinuousWebJobsResponder handles the response to the ListContinuousWebJobs request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConfigurationsSlotResponder(resp *http.Response) (result SiteConfigResourceCollection, err error) {
+func (client AppsClient) ListContinuousWebJobsResponder(resp *http.Response) (result ContinuousWebJobCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17263,31 +18284,31 @@ func (client AppsClient) ListConfigurationsSlotResponder(resp *http.Response) (r
return
}
-// listConfigurationsSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listConfigurationsSlotNextResults(ctx context.Context, lastResults SiteConfigResourceCollection) (result SiteConfigResourceCollection, err error) {
- req, err := lastResults.siteConfigResourceCollectionPreparer(ctx)
+// listContinuousWebJobsNextResults retrieves the next set of results, if any.
+func (client AppsClient) listContinuousWebJobsNextResults(ctx context.Context, lastResults ContinuousWebJobCollection) (result ContinuousWebJobCollection, err error) {
+ req, err := lastResults.continuousWebJobCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListConfigurationsSlotSender(req)
+ resp, err := client.ListContinuousWebJobsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListConfigurationsSlotResponder(resp)
+ result, err = client.ListContinuousWebJobsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listConfigurationsSlotNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListConfigurationsSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListConfigurationsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SiteConfigResourceCollectionIterator, err error) {
+// ListContinuousWebJobsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListContinuousWebJobsComplete(ctx context.Context, resourceGroupName string, name string) (result ContinuousWebJobCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConfigurationsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobs")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -17296,21 +18317,23 @@ func (client AppsClient) ListConfigurationsSlotComplete(ctx context.Context, res
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListConfigurationsSlot(ctx, resourceGroupName, name, slot)
+ result.page, err = client.ListContinuousWebJobs(ctx, resourceGroupName, name)
return
}
-// ListConnectionStrings gets the connection strings of an app.
+// ListContinuousWebJobsSlot list continuous web jobs for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) ListConnectionStrings(ctx context.Context, resourceGroupName string, name string) (result ConnectionStringDictionary, err error) {
+// name - site name.
+// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
+// production slot.
+func (client AppsClient) ListContinuousWebJobsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ContinuousWebJobCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConnectionStrings")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobsSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.cwjc.Response.Response != nil {
+ sc = result.cwjc.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17320,35 +18343,37 @@ func (client AppsClient) ListConnectionStrings(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConnectionStrings", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListContinuousWebJobsSlot", err.Error())
}
- req, err := client.ListConnectionStringsPreparer(ctx, resourceGroupName, name)
+ result.fn = client.listContinuousWebJobsSlotNextResults
+ req, err := client.ListContinuousWebJobsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListConnectionStringsSender(req)
+ resp, err := client.ListContinuousWebJobsSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", resp, "Failure sending request")
+ result.cwjc.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", resp, "Failure sending request")
return
}
- result, err = client.ListConnectionStringsResponder(resp)
+ result.cwjc, err = client.ListContinuousWebJobsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStrings", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", resp, "Failure responding to request")
}
return
}
-// ListConnectionStringsPreparer prepares the ListConnectionStrings request.
-func (client AppsClient) ListConnectionStringsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListContinuousWebJobsSlotPreparer prepares the ListContinuousWebJobsSlot request.
+func (client AppsClient) ListContinuousWebJobsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17358,23 +18383,23 @@ func (client AppsClient) ListConnectionStringsPreparer(ctx context.Context, reso
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/connectionstrings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConnectionStringsSender sends the ListConnectionStrings request. The method will close the
+// ListContinuousWebJobsSlotSender sends the ListContinuousWebJobsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConnectionStringsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListContinuousWebJobsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConnectionStringsResponder handles the response to the ListConnectionStrings request. The method always
+// ListContinuousWebJobsSlotResponder handles the response to the ListContinuousWebJobsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConnectionStringsResponder(resp *http.Response) (result ConnectionStringDictionary, err error) {
+func (client AppsClient) ListContinuousWebJobsSlotResponder(resp *http.Response) (result ContinuousWebJobCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17385,15 +18410,52 @@ func (client AppsClient) ListConnectionStringsResponder(resp *http.Response) (re
return
}
-// ListConnectionStringsSlot gets the connection strings of an app.
+// listContinuousWebJobsSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listContinuousWebJobsSlotNextResults(ctx context.Context, lastResults ContinuousWebJobCollection) (result ContinuousWebJobCollection, err error) {
+ req, err := lastResults.continuousWebJobCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListContinuousWebJobsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListContinuousWebJobsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListContinuousWebJobsSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListContinuousWebJobsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result ContinuousWebJobCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobsSlot")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListContinuousWebJobsSlot(ctx, resourceGroupName, name, slot)
+ return
+}
+
+// ListDeploymentLog list deployment log for specific deployment for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will get the connection settings for
-// the production slot.
-func (client AppsClient) ListConnectionStringsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ConnectionStringDictionary, err error) {
+// ID - the ID of a specific deployment. This is the value of the name property in the JSON response from "GET
+// /api/sites/{siteName}/deployments".
+func (client AppsClient) ListDeploymentLog(ctx context.Context, resourceGroupName string, name string, ID string) (result Deployment, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListConnectionStringsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentLog")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -17407,36 +18469,36 @@ func (client AppsClient) ListConnectionStringsSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListConnectionStringsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDeploymentLog", err.Error())
}
- req, err := client.ListConnectionStringsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.ListDeploymentLogPreparer(ctx, resourceGroupName, name, ID)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", nil, "Failure preparing request")
return
}
- resp, err := client.ListConnectionStringsSlotSender(req)
+ resp, err := client.ListDeploymentLogSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", resp, "Failure sending request")
return
}
- result, err = client.ListConnectionStringsSlotResponder(resp)
+ result, err = client.ListDeploymentLogResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListConnectionStringsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", resp, "Failure responding to request")
}
return
}
-
-// ListConnectionStringsSlotPreparer prepares the ListConnectionStringsSlot request.
-func (client AppsClient) ListConnectionStringsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+
+// ListDeploymentLogPreparer prepares the ListDeploymentLog request.
+func (client AppsClient) ListDeploymentLogPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17446,23 +18508,23 @@ func (client AppsClient) ListConnectionStringsSlotPreparer(ctx context.Context,
}
preparer := autorest.CreatePreparer(
- autorest.AsPost(),
+ autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings/list", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListConnectionStringsSlotSender sends the ListConnectionStringsSlot request. The method will close the
+// ListDeploymentLogSender sends the ListDeploymentLog request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListConnectionStringsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDeploymentLogSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListConnectionStringsSlotResponder handles the response to the ListConnectionStringsSlot request. The method always
+// ListDeploymentLogResponder handles the response to the ListDeploymentLog request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListConnectionStringsSlotResponder(resp *http.Response) (result ConnectionStringDictionary, err error) {
+func (client AppsClient) ListDeploymentLogResponder(resp *http.Response) (result Deployment, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17473,17 +18535,21 @@ func (client AppsClient) ListConnectionStringsSlotResponder(resp *http.Response)
return
}
-// ListContinuousWebJobs list continuous web jobs for an app, or a deployment slot.
+// ListDeploymentLogSlot list deployment log for specific deployment for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-func (client AppsClient) ListContinuousWebJobs(ctx context.Context, resourceGroupName string, name string) (result ContinuousWebJobCollectionPage, err error) {
+// name - name of the app.
+// ID - the ID of a specific deployment. This is the value of the name property in the JSON response from "GET
+// /api/sites/{siteName}/deployments".
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) ListDeploymentLogSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result Deployment, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobs")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentLogSlot")
defer func() {
sc := -1
- if result.cwjc.Response.Response != nil {
- sc = result.cwjc.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17493,36 +18559,37 @@ func (client AppsClient) ListContinuousWebJobs(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListContinuousWebJobs", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDeploymentLogSlot", err.Error())
}
- result.fn = client.listContinuousWebJobsNextResults
- req, err := client.ListContinuousWebJobsPreparer(ctx, resourceGroupName, name)
+ req, err := client.ListDeploymentLogSlotPreparer(ctx, resourceGroupName, name, ID, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListContinuousWebJobsSender(req)
+ resp, err := client.ListDeploymentLogSlotSender(req)
if err != nil {
- result.cwjc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", resp, "Failure sending request")
return
}
- result.cwjc, err = client.ListContinuousWebJobsResponder(resp)
+ result, err = client.ListDeploymentLogSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobs", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", resp, "Failure responding to request")
}
return
}
-// ListContinuousWebJobsPreparer prepares the ListContinuousWebJobs request.
-func (client AppsClient) ListContinuousWebJobsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListDeploymentLogSlotPreparer prepares the ListDeploymentLogSlot request.
+func (client AppsClient) ListDeploymentLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17534,21 +18601,21 @@ func (client AppsClient) ListContinuousWebJobsPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/continuouswebjobs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}/log", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListContinuousWebJobsSender sends the ListContinuousWebJobs request. The method will close the
+// ListDeploymentLogSlotSender sends the ListDeploymentLogSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListContinuousWebJobsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDeploymentLogSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListContinuousWebJobsResponder handles the response to the ListContinuousWebJobs request. The method always
+// ListDeploymentLogSlotResponder handles the response to the ListDeploymentLogSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListContinuousWebJobsResponder(resp *http.Response) (result ContinuousWebJobCollection, err error) {
+func (client AppsClient) ListDeploymentLogSlotResponder(resp *http.Response) (result Deployment, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17559,56 +18626,17 @@ func (client AppsClient) ListContinuousWebJobsResponder(resp *http.Response) (re
return
}
-// listContinuousWebJobsNextResults retrieves the next set of results, if any.
-func (client AppsClient) listContinuousWebJobsNextResults(ctx context.Context, lastResults ContinuousWebJobCollection) (result ContinuousWebJobCollection, err error) {
- req, err := lastResults.continuousWebJobCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListContinuousWebJobsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListContinuousWebJobsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListContinuousWebJobsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListContinuousWebJobsComplete(ctx context.Context, resourceGroupName string, name string) (result ContinuousWebJobCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobs")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListContinuousWebJobs(ctx, resourceGroupName, name)
- return
-}
-
-// ListContinuousWebJobsSlot list continuous web jobs for an app, or a deployment slot.
+// ListDeployments list deployments for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - site name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) ListContinuousWebJobsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result ContinuousWebJobCollectionPage, err error) {
+// name - name of the app.
+func (client AppsClient) ListDeployments(ctx context.Context, resourceGroupName string, name string) (result DeploymentCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeployments")
defer func() {
sc := -1
- if result.cwjc.Response.Response != nil {
- sc = result.cwjc.Response.Response.StatusCode
+ if result.dc.Response.Response != nil {
+ sc = result.dc.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17618,37 +18646,36 @@ func (client AppsClient) ListContinuousWebJobsSlot(ctx context.Context, resource
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListContinuousWebJobsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDeployments", err.Error())
}
- result.fn = client.listContinuousWebJobsSlotNextResults
- req, err := client.ListContinuousWebJobsSlotPreparer(ctx, resourceGroupName, name, slot)
+ result.fn = client.listDeploymentsNextResults
+ req, err := client.ListDeploymentsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", nil, "Failure preparing request")
return
}
- resp, err := client.ListContinuousWebJobsSlotSender(req)
+ resp, err := client.ListDeploymentsSender(req)
if err != nil {
- result.cwjc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", resp, "Failure sending request")
+ result.dc.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", resp, "Failure sending request")
return
}
- result.cwjc, err = client.ListContinuousWebJobsSlotResponder(resp)
+ result.dc, err = client.ListDeploymentsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListContinuousWebJobsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", resp, "Failure responding to request")
}
return
}
-// ListContinuousWebJobsSlotPreparer prepares the ListContinuousWebJobsSlot request.
-func (client AppsClient) ListContinuousWebJobsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListDeploymentsPreparer prepares the ListDeployments request.
+func (client AppsClient) ListDeploymentsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17660,21 +18687,21 @@ func (client AppsClient) ListContinuousWebJobsSlotPreparer(ctx context.Context,
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/continuouswebjobs", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListContinuousWebJobsSlotSender sends the ListContinuousWebJobsSlot request. The method will close the
+// ListDeploymentsSender sends the ListDeployments request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListContinuousWebJobsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDeploymentsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListContinuousWebJobsSlotResponder handles the response to the ListContinuousWebJobsSlot request. The method always
+// ListDeploymentsResponder handles the response to the ListDeployments request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListContinuousWebJobsSlotResponder(resp *http.Response) (result ContinuousWebJobCollection, err error) {
+func (client AppsClient) ListDeploymentsResponder(resp *http.Response) (result DeploymentCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17685,31 +18712,31 @@ func (client AppsClient) ListContinuousWebJobsSlotResponder(resp *http.Response)
return
}
-// listContinuousWebJobsSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listContinuousWebJobsSlotNextResults(ctx context.Context, lastResults ContinuousWebJobCollection) (result ContinuousWebJobCollection, err error) {
- req, err := lastResults.continuousWebJobCollectionPreparer(ctx)
+// listDeploymentsNextResults retrieves the next set of results, if any.
+func (client AppsClient) listDeploymentsNextResults(ctx context.Context, lastResults DeploymentCollection) (result DeploymentCollection, err error) {
+ req, err := lastResults.deploymentCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListContinuousWebJobsSlotSender(req)
+ resp, err := client.ListDeploymentsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListContinuousWebJobsSlotResponder(resp)
+ result, err = client.ListDeploymentsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listContinuousWebJobsSlotNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListContinuousWebJobsSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListContinuousWebJobsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result ContinuousWebJobCollectionIterator, err error) {
+// ListDeploymentsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListDeploymentsComplete(ctx context.Context, resourceGroupName string, name string) (result DeploymentCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListContinuousWebJobsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeployments")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -17718,23 +18745,23 @@ func (client AppsClient) ListContinuousWebJobsSlotComplete(ctx context.Context,
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListContinuousWebJobsSlot(ctx, resourceGroupName, name, slot)
+ result.page, err = client.ListDeployments(ctx, resourceGroupName, name)
return
}
-// ListDeploymentLog list deployment log for specific deployment for an app, or a deployment slot.
+// ListDeploymentsSlot list deployments for an app, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - the ID of a specific deployment. This is the value of the name property in the JSON response from "GET
-// /api/sites/{siteName}/deployments".
-func (client AppsClient) ListDeploymentLog(ctx context.Context, resourceGroupName string, name string, ID string) (result Deployment, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
+// production slot.
+func (client AppsClient) ListDeploymentsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result DeploymentCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentLog")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentsSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.dc.Response.Response != nil {
+ sc = result.dc.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17744,36 +18771,37 @@ func (client AppsClient) ListDeploymentLog(ctx context.Context, resourceGroupNam
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDeploymentLog", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDeploymentsSlot", err.Error())
}
- req, err := client.ListDeploymentLogPreparer(ctx, resourceGroupName, name, ID)
+ result.fn = client.listDeploymentsSlotNextResults
+ req, err := client.ListDeploymentsSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListDeploymentLogSender(req)
+ resp, err := client.ListDeploymentsSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", resp, "Failure sending request")
+ result.dc.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", resp, "Failure sending request")
return
}
- result, err = client.ListDeploymentLogResponder(resp)
+ result.dc, err = client.ListDeploymentsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLog", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", resp, "Failure responding to request")
}
return
}
-// ListDeploymentLogPreparer prepares the ListDeploymentLog request.
-func (client AppsClient) ListDeploymentLogPreparer(ctx context.Context, resourceGroupName string, name string, ID string) (*http.Request, error) {
+// ListDeploymentsSlotPreparer prepares the ListDeploymentsSlot request.
+func (client AppsClient) ListDeploymentsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17785,21 +18813,21 @@ func (client AppsClient) ListDeploymentLogPreparer(ctx context.Context, resource
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments/{id}/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDeploymentLogSender sends the ListDeploymentLog request. The method will close the
+// ListDeploymentsSlotSender sends the ListDeploymentsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDeploymentLogSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDeploymentsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDeploymentLogResponder handles the response to the ListDeploymentLog request. The method always
+// ListDeploymentsSlotResponder handles the response to the ListDeploymentsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDeploymentLogResponder(resp *http.Response) (result Deployment, err error) {
+func (client AppsClient) ListDeploymentsSlotResponder(resp *http.Response) (result DeploymentCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17810,21 +18838,54 @@ func (client AppsClient) ListDeploymentLogResponder(resp *http.Response) (result
return
}
-// ListDeploymentLogSlot list deployment log for specific deployment for an app, or a deployment slot.
+// listDeploymentsSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listDeploymentsSlotNextResults(ctx context.Context, lastResults DeploymentCollection) (result DeploymentCollection, err error) {
+ req, err := lastResults.deploymentCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListDeploymentsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListDeploymentsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListDeploymentsSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListDeploymentsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result DeploymentCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentsSlot")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListDeploymentsSlot(ctx, resourceGroupName, name, slot)
+ return
+}
+
+// ListDomainOwnershipIdentifiers lists ownership identifiers for domain associated with web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// ID - the ID of a specific deployment. This is the value of the name property in the JSON response from "GET
-// /api/sites/{siteName}/deployments".
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) ListDeploymentLogSlot(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (result Deployment, err error) {
+func (client AppsClient) ListDomainOwnershipIdentifiers(ctx context.Context, resourceGroupName string, name string) (result IdentifierCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentLogSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiers")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.ic.Response.Response != nil {
+ sc = result.ic.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17834,37 +18895,36 @@ func (client AppsClient) ListDeploymentLogSlot(ctx context.Context, resourceGrou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDeploymentLogSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDomainOwnershipIdentifiers", err.Error())
}
- req, err := client.ListDeploymentLogSlotPreparer(ctx, resourceGroupName, name, ID, slot)
+ result.fn = client.listDomainOwnershipIdentifiersNextResults
+ req, err := client.ListDomainOwnershipIdentifiersPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", nil, "Failure preparing request")
return
}
- resp, err := client.ListDeploymentLogSlotSender(req)
+ resp, err := client.ListDomainOwnershipIdentifiersSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", resp, "Failure sending request")
+ result.ic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", resp, "Failure sending request")
return
}
- result, err = client.ListDeploymentLogSlotResponder(resp)
+ result.ic, err = client.ListDomainOwnershipIdentifiersResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentLogSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", resp, "Failure responding to request")
}
return
}
-// ListDeploymentLogSlotPreparer prepares the ListDeploymentLogSlot request.
-func (client AppsClient) ListDeploymentLogSlotPreparer(ctx context.Context, resourceGroupName string, name string, ID string, slot string) (*http.Request, error) {
+// ListDomainOwnershipIdentifiersPreparer prepares the ListDomainOwnershipIdentifiers request.
+func (client AppsClient) ListDomainOwnershipIdentifiersPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "id": autorest.Encode("path", ID),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17876,21 +18936,21 @@ func (client AppsClient) ListDeploymentLogSlotPreparer(ctx context.Context, reso
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}/log", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDeploymentLogSlotSender sends the ListDeploymentLogSlot request. The method will close the
+// ListDomainOwnershipIdentifiersSender sends the ListDomainOwnershipIdentifiers request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDeploymentLogSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDomainOwnershipIdentifiersSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDeploymentLogSlotResponder handles the response to the ListDeploymentLogSlot request. The method always
+// ListDomainOwnershipIdentifiersResponder handles the response to the ListDomainOwnershipIdentifiers request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDeploymentLogSlotResponder(resp *http.Response) (result Deployment, err error) {
+func (client AppsClient) ListDomainOwnershipIdentifiersResponder(resp *http.Response) (result IdentifierCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17901,17 +18961,56 @@ func (client AppsClient) ListDeploymentLogSlotResponder(resp *http.Response) (re
return
}
-// ListDeployments list deployments for an app, or a deployment slot.
+// listDomainOwnershipIdentifiersNextResults retrieves the next set of results, if any.
+func (client AppsClient) listDomainOwnershipIdentifiersNextResults(ctx context.Context, lastResults IdentifierCollection) (result IdentifierCollection, err error) {
+ req, err := lastResults.identifierCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListDomainOwnershipIdentifiersSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListDomainOwnershipIdentifiersResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListDomainOwnershipIdentifiersComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListDomainOwnershipIdentifiersComplete(ctx context.Context, resourceGroupName string, name string) (result IdentifierCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiers")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListDomainOwnershipIdentifiers(ctx, resourceGroupName, name)
+ return
+}
+
+// ListDomainOwnershipIdentifiersSlot lists ownership identifiers for domain associated with web app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) ListDeployments(ctx context.Context, resourceGroupName string, name string) (result DeploymentCollectionPage, err error) {
+// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
+// production slot.
+func (client AppsClient) ListDomainOwnershipIdentifiersSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result IdentifierCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeployments")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiersSlot")
defer func() {
sc := -1
- if result.dc.Response.Response != nil {
- sc = result.dc.Response.Response.StatusCode
+ if result.ic.Response.Response != nil {
+ sc = result.ic.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -17921,36 +19020,37 @@ func (client AppsClient) ListDeployments(ctx context.Context, resourceGroupName
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDeployments", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListDomainOwnershipIdentifiersSlot", err.Error())
}
- result.fn = client.listDeploymentsNextResults
- req, err := client.ListDeploymentsPreparer(ctx, resourceGroupName, name)
+ result.fn = client.listDomainOwnershipIdentifiersSlotNextResults
+ req, err := client.ListDomainOwnershipIdentifiersSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListDeploymentsSender(req)
+ resp, err := client.ListDomainOwnershipIdentifiersSlotSender(req)
if err != nil {
- result.dc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", resp, "Failure sending request")
+ result.ic.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", resp, "Failure sending request")
return
}
- result.dc, err = client.ListDeploymentsResponder(resp)
+ result.ic, err = client.ListDomainOwnershipIdentifiersSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeployments", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", resp, "Failure responding to request")
}
return
}
-// ListDeploymentsPreparer prepares the ListDeployments request.
-func (client AppsClient) ListDeploymentsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListDomainOwnershipIdentifiersSlotPreparer prepares the ListDomainOwnershipIdentifiersSlot request.
+func (client AppsClient) ListDomainOwnershipIdentifiersSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -17962,21 +19062,21 @@ func (client AppsClient) ListDeploymentsPreparer(ctx context.Context, resourceGr
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/deployments", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDeploymentsSender sends the ListDeployments request. The method will close the
+// ListDomainOwnershipIdentifiersSlotSender sends the ListDomainOwnershipIdentifiersSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDeploymentsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListDomainOwnershipIdentifiersSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDeploymentsResponder handles the response to the ListDeployments request. The method always
+// ListDomainOwnershipIdentifiersSlotResponder handles the response to the ListDomainOwnershipIdentifiersSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDeploymentsResponder(resp *http.Response) (result DeploymentCollection, err error) {
+func (client AppsClient) ListDomainOwnershipIdentifiersSlotResponder(resp *http.Response) (result IdentifierCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -17987,31 +19087,31 @@ func (client AppsClient) ListDeploymentsResponder(resp *http.Response) (result D
return
}
-// listDeploymentsNextResults retrieves the next set of results, if any.
-func (client AppsClient) listDeploymentsNextResults(ctx context.Context, lastResults DeploymentCollection) (result DeploymentCollection, err error) {
- req, err := lastResults.deploymentCollectionPreparer(ctx)
+// listDomainOwnershipIdentifiersSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listDomainOwnershipIdentifiersSlotNextResults(ctx context.Context, lastResults IdentifierCollection) (result IdentifierCollection, err error) {
+ req, err := lastResults.identifierCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListDeploymentsSender(req)
+ resp, err := client.ListDomainOwnershipIdentifiersSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListDeploymentsResponder(resp)
+ result, err = client.ListDomainOwnershipIdentifiersSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListDeploymentsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListDeploymentsComplete(ctx context.Context, resourceGroupName string, name string) (result DeploymentCollectionIterator, err error) {
+// ListDomainOwnershipIdentifiersSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListDomainOwnershipIdentifiersSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result IdentifierCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeployments")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiersSlot")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -18020,23 +19120,22 @@ func (client AppsClient) ListDeploymentsComplete(ctx context.Context, resourceGr
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListDeployments(ctx, resourceGroupName, name)
+ result.page, err = client.ListDomainOwnershipIdentifiersSlot(ctx, resourceGroupName, name, slot)
return
}
-// ListDeploymentsSlot list deployments for an app, or a deployment slot.
+// ListFunctionKeys get function keys for a function in a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API returns deployments for the
-// production slot.
-func (client AppsClient) ListDeploymentsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result DeploymentCollectionPage, err error) {
+// name - site name.
+// functionName - function name.
+func (client AppsClient) ListFunctionKeys(ctx context.Context, resourceGroupName string, name string, functionName string) (result StringDictionary, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionKeys")
defer func() {
sc := -1
- if result.dc.Response.Response != nil {
- sc = result.dc.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -18046,37 +19145,36 @@ func (client AppsClient) ListDeploymentsSlot(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDeploymentsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListFunctionKeys", err.Error())
}
- result.fn = client.listDeploymentsSlotNextResults
- req, err := client.ListDeploymentsSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.ListFunctionKeysPreparer(ctx, resourceGroupName, name, functionName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeys", nil, "Failure preparing request")
return
}
- resp, err := client.ListDeploymentsSlotSender(req)
+ resp, err := client.ListFunctionKeysSender(req)
if err != nil {
- result.dc.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeys", resp, "Failure sending request")
return
}
- result.dc, err = client.ListDeploymentsSlotResponder(resp)
+ result, err = client.ListFunctionKeysResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDeploymentsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeys", resp, "Failure responding to request")
}
return
}
-// ListDeploymentsSlotPreparer prepares the ListDeploymentsSlot request.
-func (client AppsClient) ListDeploymentsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListFunctionKeysPreparer prepares the ListFunctionKeys request.
+func (client AppsClient) ListFunctionKeysPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -18086,23 +19184,23 @@ func (client AppsClient) ListDeploymentsSlotPreparer(ctx context.Context, resour
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}/listkeys", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDeploymentsSlotSender sends the ListDeploymentsSlot request. The method will close the
+// ListFunctionKeysSender sends the ListFunctionKeys request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDeploymentsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListFunctionKeysSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDeploymentsSlotResponder handles the response to the ListDeploymentsSlot request. The method always
+// ListFunctionKeysResponder handles the response to the ListFunctionKeys request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDeploymentsSlotResponder(resp *http.Response) (result DeploymentCollection, err error) {
+func (client AppsClient) ListFunctionKeysResponder(resp *http.Response) (result StringDictionary, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -18113,54 +19211,106 @@ func (client AppsClient) ListDeploymentsSlotResponder(resp *http.Response) (resu
return
}
-// listDeploymentsSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listDeploymentsSlotNextResults(ctx context.Context, lastResults DeploymentCollection) (result DeploymentCollection, err error) {
- req, err := lastResults.deploymentCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", nil, "Failure preparing next results request")
+// ListFunctionKeysSlot get function keys for a function in a web site, or a deployment slot.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - site name.
+// functionName - function name.
+// slot - name of the deployment slot.
+func (client AppsClient) ListFunctionKeysSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result StringDictionary, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionKeysSlot")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
}
- if req == nil {
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListFunctionKeysSlot", err.Error())
+ }
+
+ req, err := client.ListFunctionKeysSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeysSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListDeploymentsSlotSender(req)
+
+ resp, err := client.ListFunctionKeysSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", resp, "Failure sending next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeysSlot", resp, "Failure sending request")
+ return
}
- result, err = client.ListDeploymentsSlotResponder(resp)
+
+ result, err = client.ListFunctionKeysSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listDeploymentsSlotNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionKeysSlot", resp, "Failure responding to request")
}
+
return
}
-// ListDeploymentsSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListDeploymentsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result DeploymentCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDeploymentsSlot")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
+// ListFunctionKeysSlotPreparer prepares the ListFunctionKeysSlot request.
+func (client AppsClient) ListFunctionKeysSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "functionName": autorest.Encode("path", functionName),
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
- result.page, err = client.ListDeploymentsSlot(ctx, resourceGroupName, name, slot)
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}/listkeys", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListFunctionKeysSlotSender sends the ListFunctionKeysSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListFunctionKeysSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListFunctionKeysSlotResponder handles the response to the ListFunctionKeysSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListFunctionKeysSlotResponder(resp *http.Response) (result StringDictionary, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
return
}
-// ListDomainOwnershipIdentifiers lists ownership identifiers for domain associated with web app.
+// ListFunctions list the functions for a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-func (client AppsClient) ListDomainOwnershipIdentifiers(ctx context.Context, resourceGroupName string, name string) (result IdentifierCollectionPage, err error) {
+// name - site name.
+func (client AppsClient) ListFunctions(ctx context.Context, resourceGroupName string, name string) (result FunctionEnvelopeCollectionPage, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiers")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctions")
defer func() {
sc := -1
- if result.ic.Response.Response != nil {
- sc = result.ic.Response.Response.StatusCode
+ if result.fec.Response.Response != nil {
+ sc = result.fec.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -18170,33 +19320,33 @@ func (client AppsClient) ListDomainOwnershipIdentifiers(ctx context.Context, res
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDomainOwnershipIdentifiers", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListFunctions", err.Error())
}
- result.fn = client.listDomainOwnershipIdentifiersNextResults
- req, err := client.ListDomainOwnershipIdentifiersPreparer(ctx, resourceGroupName, name)
+ result.fn = client.listFunctionsNextResults
+ req, err := client.ListFunctionsPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", nil, "Failure preparing request")
return
}
- resp, err := client.ListDomainOwnershipIdentifiersSender(req)
+ resp, err := client.ListFunctionsSender(req)
if err != nil {
- result.ic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", resp, "Failure sending request")
+ result.fec.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", resp, "Failure sending request")
return
}
- result.ic, err = client.ListDomainOwnershipIdentifiersResponder(resp)
+ result.fec, err = client.ListFunctionsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiers", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", resp, "Failure responding to request")
}
return
}
-// ListDomainOwnershipIdentifiersPreparer prepares the ListDomainOwnershipIdentifiers request.
-func (client AppsClient) ListDomainOwnershipIdentifiersPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListFunctionsPreparer prepares the ListFunctions request.
+func (client AppsClient) ListFunctionsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -18211,56 +19361,56 @@ func (client AppsClient) ListDomainOwnershipIdentifiersPreparer(ctx context.Cont
preparer := autorest.CreatePreparer(
autorest.AsGet(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/domainOwnershipIdentifiers", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDomainOwnershipIdentifiersSender sends the ListDomainOwnershipIdentifiers request. The method will close the
+// ListFunctionsSender sends the ListFunctions request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDomainOwnershipIdentifiersSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListFunctionsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDomainOwnershipIdentifiersResponder handles the response to the ListDomainOwnershipIdentifiers request. The method always
+// ListFunctionsResponder handles the response to the ListFunctions request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDomainOwnershipIdentifiersResponder(resp *http.Response) (result IdentifierCollection, err error) {
+func (client AppsClient) ListFunctionsResponder(resp *http.Response) (result FunctionEnvelopeCollection, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
-// listDomainOwnershipIdentifiersNextResults retrieves the next set of results, if any.
-func (client AppsClient) listDomainOwnershipIdentifiersNextResults(ctx context.Context, lastResults IdentifierCollection) (result IdentifierCollection, err error) {
- req, err := lastResults.identifierCollectionPreparer(ctx)
+// listFunctionsNextResults retrieves the next set of results, if any.
+func (client AppsClient) listFunctionsNextResults(ctx context.Context, lastResults FunctionEnvelopeCollection) (result FunctionEnvelopeCollection, err error) {
+ req, err := lastResults.functionEnvelopeCollectionPreparer(ctx)
if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", nil, "Failure preparing next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", nil, "Failure preparing next results request")
}
if req == nil {
return
}
- resp, err := client.ListDomainOwnershipIdentifiersSender(req)
+ resp, err := client.ListFunctionsSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", resp, "Failure sending next results request")
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", resp, "Failure sending next results request")
}
- result, err = client.ListDomainOwnershipIdentifiersResponder(resp)
+ result, err = client.ListFunctionsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersNextResults", resp, "Failure responding to next results request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", resp, "Failure responding to next results request")
}
return
}
-// ListDomainOwnershipIdentifiersComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListDomainOwnershipIdentifiersComplete(ctx context.Context, resourceGroupName string, name string) (result IdentifierCollectionIterator, err error) {
+// ListFunctionsComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListFunctionsComplete(ctx context.Context, resourceGroupName string, name string) (result FunctionEnvelopeCollectionIterator, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiers")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctions")
defer func() {
sc := -1
if result.Response().Response.Response != nil {
@@ -18269,23 +19419,22 @@ func (client AppsClient) ListDomainOwnershipIdentifiersComplete(ctx context.Cont
tracing.EndSpan(ctx, sc, err)
}()
}
- result.page, err = client.ListDomainOwnershipIdentifiers(ctx, resourceGroupName, name)
+ result.page, err = client.ListFunctions(ctx, resourceGroupName, name)
return
}
-// ListDomainOwnershipIdentifiersSlot lists ownership identifiers for domain associated with web app.
+// ListFunctionSecrets get function secrets for a function in a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
-// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will delete the binding for the
-// production slot.
-func (client AppsClient) ListDomainOwnershipIdentifiersSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result IdentifierCollectionPage, err error) {
+// name - site name.
+// functionName - function name.
+func (client AppsClient) ListFunctionSecrets(ctx context.Context, resourceGroupName string, name string, functionName string) (result FunctionSecrets, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiersSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionSecrets")
defer func() {
sc := -1
- if result.ic.Response.Response != nil {
- sc = result.ic.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -18295,37 +19444,36 @@ func (client AppsClient) ListDomainOwnershipIdentifiersSlot(ctx context.Context,
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListDomainOwnershipIdentifiersSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListFunctionSecrets", err.Error())
}
- result.fn = client.listDomainOwnershipIdentifiersSlotNextResults
- req, err := client.ListDomainOwnershipIdentifiersSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.ListFunctionSecretsPreparer(ctx, resourceGroupName, name, functionName)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", nil, "Failure preparing request")
return
}
- resp, err := client.ListDomainOwnershipIdentifiersSlotSender(req)
+ resp, err := client.ListFunctionSecretsSender(req)
if err != nil {
- result.ic.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", resp, "Failure sending request")
return
}
- result.ic, err = client.ListDomainOwnershipIdentifiersSlotResponder(resp)
+ result, err = client.ListFunctionSecretsResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListDomainOwnershipIdentifiersSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", resp, "Failure responding to request")
}
return
}
-// ListDomainOwnershipIdentifiersSlotPreparer prepares the ListDomainOwnershipIdentifiersSlot request.
-func (client AppsClient) ListDomainOwnershipIdentifiersSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListFunctionSecretsPreparer prepares the ListFunctionSecrets request.
+func (client AppsClient) ListFunctionSecretsPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
- "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -18335,23 +19483,23 @@ func (client AppsClient) ListDomainOwnershipIdentifiersSlotPreparer(ctx context.
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}/listsecrets", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListDomainOwnershipIdentifiersSlotSender sends the ListDomainOwnershipIdentifiersSlot request. The method will close the
+// ListFunctionSecretsSender sends the ListFunctionSecrets request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListDomainOwnershipIdentifiersSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListFunctionSecretsSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListDomainOwnershipIdentifiersSlotResponder handles the response to the ListDomainOwnershipIdentifiersSlot request. The method always
+// ListFunctionSecretsResponder handles the response to the ListFunctionSecrets request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListDomainOwnershipIdentifiersSlotResponder(resp *http.Response) (result IdentifierCollection, err error) {
+func (client AppsClient) ListFunctionSecretsResponder(resp *http.Response) (result FunctionSecrets, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -18362,54 +19510,19 @@ func (client AppsClient) ListDomainOwnershipIdentifiersSlotResponder(resp *http.
return
}
-// listDomainOwnershipIdentifiersSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listDomainOwnershipIdentifiersSlotNextResults(ctx context.Context, lastResults IdentifierCollection) (result IdentifierCollection, err error) {
- req, err := lastResults.identifierCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListDomainOwnershipIdentifiersSlotSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListDomainOwnershipIdentifiersSlotResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listDomainOwnershipIdentifiersSlotNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListDomainOwnershipIdentifiersSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListDomainOwnershipIdentifiersSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result IdentifierCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListDomainOwnershipIdentifiersSlot")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListDomainOwnershipIdentifiersSlot(ctx, resourceGroupName, name, slot)
- return
-}
-
-// ListFunctions list the functions for a web site, or a deployment slot.
+// ListFunctionSecretsSlot get function secrets for a function in a web site, or a deployment slot.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-func (client AppsClient) ListFunctions(ctx context.Context, resourceGroupName string, name string) (result FunctionEnvelopeCollectionPage, err error) {
+// functionName - function name.
+// slot - name of the deployment slot.
+func (client AppsClient) ListFunctionSecretsSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result FunctionSecrets, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctions")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionSecretsSlot")
defer func() {
sc := -1
- if result.fec.Response.Response != nil {
- sc = result.fec.Response.Response.StatusCode
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -18419,36 +19532,37 @@ func (client AppsClient) ListFunctions(ctx context.Context, resourceGroupName st
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListFunctions", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListFunctionSecretsSlot", err.Error())
}
- result.fn = client.listFunctionsNextResults
- req, err := client.ListFunctionsPreparer(ctx, resourceGroupName, name)
+ req, err := client.ListFunctionSecretsSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListFunctionsSender(req)
+ resp, err := client.ListFunctionSecretsSlotSender(req)
if err != nil {
- result.fec.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", resp, "Failure sending request")
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", resp, "Failure sending request")
return
}
- result.fec, err = client.ListFunctionsResponder(resp)
+ result, err = client.ListFunctionSecretsSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctions", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", resp, "Failure responding to request")
}
return
}
-// ListFunctionsPreparer prepares the ListFunctions request.
-func (client AppsClient) ListFunctionsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListFunctionSecretsSlotPreparer prepares the ListFunctionSecretsSlot request.
+func (client AppsClient) ListFunctionSecretsSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
+ "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
@@ -18458,78 +19572,40 @@ func (client AppsClient) ListFunctionsPreparer(ctx context.Context, resourceGrou
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}/listsecrets", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListFunctionsSender sends the ListFunctions request. The method will close the
+// ListFunctionSecretsSlotSender sends the ListFunctionSecretsSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListFunctionsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListFunctionSecretsSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListFunctionsResponder handles the response to the ListFunctions request. The method always
+// ListFunctionSecretsSlotResponder handles the response to the ListFunctionSecretsSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListFunctionsResponder(resp *http.Response) (result FunctionEnvelopeCollection, err error) {
+func (client AppsClient) ListFunctionSecretsSlotResponder(resp *http.Response) (result FunctionSecrets, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNotFound),
- autorest.ByUnmarshallingJSON(&result),
- autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
- return
-}
-
-// listFunctionsNextResults retrieves the next set of results, if any.
-func (client AppsClient) listFunctionsNextResults(ctx context.Context, lastResults FunctionEnvelopeCollection) (result FunctionEnvelopeCollection, err error) {
- req, err := lastResults.functionEnvelopeCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListFunctionsSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListFunctionsResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listFunctionsNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListFunctionsComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListFunctionsComplete(ctx context.Context, resourceGroupName string, name string) (result FunctionEnvelopeCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctions")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListFunctions(ctx, resourceGroupName, name)
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
return
}
-// ListFunctionSecrets get function secrets for a function in a web site, or a deployment slot.
+// ListHostKeys get host secrets for a function app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// functionName - function name.
-func (client AppsClient) ListFunctionSecrets(ctx context.Context, resourceGroupName string, name string, functionName string) (result FunctionSecrets, err error) {
+func (client AppsClient) ListHostKeys(ctx context.Context, resourceGroupName string, name string) (result HostKeys, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionSecrets")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListHostKeys")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -18543,34 +19619,33 @@ func (client AppsClient) ListFunctionSecrets(ctx context.Context, resourceGroupN
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListFunctionSecrets", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListHostKeys", err.Error())
}
- req, err := client.ListFunctionSecretsPreparer(ctx, resourceGroupName, name, functionName)
+ req, err := client.ListHostKeysPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeys", nil, "Failure preparing request")
return
}
- resp, err := client.ListFunctionSecretsSender(req)
+ resp, err := client.ListHostKeysSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeys", resp, "Failure sending request")
return
}
- result, err = client.ListFunctionSecretsResponder(resp)
+ result, err = client.ListHostKeysResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecrets", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeys", resp, "Failure responding to request")
}
return
}
-// ListFunctionSecretsPreparer prepares the ListFunctionSecrets request.
-func (client AppsClient) ListFunctionSecretsPreparer(ctx context.Context, resourceGroupName string, name string, functionName string) (*http.Request, error) {
+// ListHostKeysPreparer prepares the ListHostKeys request.
+func (client AppsClient) ListHostKeysPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
@@ -18584,21 +19659,21 @@ func (client AppsClient) ListFunctionSecretsPreparer(ctx context.Context, resour
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/{functionName}/listsecrets", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/host/default/listkeys", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListFunctionSecretsSender sends the ListFunctionSecrets request. The method will close the
+// ListHostKeysSender sends the ListHostKeys request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListFunctionSecretsSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListHostKeysSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListFunctionSecretsResponder handles the response to the ListFunctionSecrets request. The method always
+// ListHostKeysResponder handles the response to the ListHostKeys request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListFunctionSecretsResponder(resp *http.Response) (result FunctionSecrets, err error) {
+func (client AppsClient) ListHostKeysResponder(resp *http.Response) (result HostKeys, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -18609,16 +19684,14 @@ func (client AppsClient) ListFunctionSecretsResponder(resp *http.Response) (resu
return
}
-// ListFunctionSecretsSlot get function secrets for a function in a web site, or a deployment slot.
+// ListHostKeysSlot get host secrets for a function app.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// functionName - function name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
-func (client AppsClient) ListFunctionSecretsSlot(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (result FunctionSecrets, err error) {
+// slot - name of the deployment slot.
+func (client AppsClient) ListHostKeysSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result HostKeys, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListFunctionSecretsSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListHostKeysSlot")
defer func() {
sc := -1
if result.Response.Response != nil {
@@ -18632,34 +19705,33 @@ func (client AppsClient) ListFunctionSecretsSlot(ctx context.Context, resourceGr
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListFunctionSecretsSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListHostKeysSlot", err.Error())
}
- req, err := client.ListFunctionSecretsSlotPreparer(ctx, resourceGroupName, name, functionName, slot)
+ req, err := client.ListHostKeysSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeysSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListFunctionSecretsSlotSender(req)
+ resp, err := client.ListHostKeysSlotSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", resp, "Failure sending request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeysSlot", resp, "Failure sending request")
return
}
- result, err = client.ListFunctionSecretsSlotResponder(resp)
+ result, err = client.ListHostKeysSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListFunctionSecretsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListHostKeysSlot", resp, "Failure responding to request")
}
return
}
-// ListFunctionSecretsSlotPreparer prepares the ListFunctionSecretsSlot request.
-func (client AppsClient) ListFunctionSecretsSlotPreparer(ctx context.Context, resourceGroupName string, name string, functionName string, slot string) (*http.Request, error) {
+// ListHostKeysSlotPreparer prepares the ListHostKeysSlot request.
+func (client AppsClient) ListHostKeysSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
- "functionName": autorest.Encode("path", functionName),
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"slot": autorest.Encode("path", slot),
@@ -18674,21 +19746,21 @@ func (client AppsClient) ListFunctionSecretsSlotPreparer(ctx context.Context, re
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/{functionName}/listsecrets", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/host/default/listkeys", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListFunctionSecretsSlotSender sends the ListFunctionSecretsSlot request. The method will close the
+// ListHostKeysSlotSender sends the ListHostKeysSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListFunctionSecretsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListHostKeysSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListFunctionSecretsSlotResponder handles the response to the ListFunctionSecretsSlot request. The method always
+// ListHostKeysSlotResponder handles the response to the ListHostKeysSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListFunctionSecretsSlotResponder(resp *http.Response) (result FunctionSecrets, err error) {
+func (client AppsClient) ListHostKeysSlotResponder(resp *http.Response) (result HostKeys, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -19304,8 +20376,7 @@ func (client AppsClient) ListHybridConnectionsSlotResponder(resp *http.Response)
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - site name.
-// slot - name of the deployment slot. If a slot is not specified, the API deletes a deployment for the
-// production slot.
+// slot - name of the deployment slot.
func (client AppsClient) ListInstanceFunctionsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result FunctionEnvelopeCollectionPage, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListInstanceFunctionsSlot")
@@ -24584,16 +25655,225 @@ func (client AppsClient) ListSnapshotsSlot(ctx context.Context, resourceGroupNam
return
}
- result.sc, err = client.ListSnapshotsSlotResponder(resp)
+ result.sc, err = client.ListSnapshotsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSnapshotsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListSnapshotsSlotPreparer prepares the ListSnapshotsSlot request.
+func (client AppsClient) ListSnapshotsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-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.Web/sites/{name}/slots/{slot}/snapshots", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSnapshotsSlotSender sends the ListSnapshotsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListSnapshotsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListSnapshotsSlotResponder handles the response to the ListSnapshotsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListSnapshotsSlotResponder(resp *http.Response) (result SnapshotCollection, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// listSnapshotsSlotNextResults retrieves the next set of results, if any.
+func (client AppsClient) listSnapshotsSlotNextResults(ctx context.Context, lastResults SnapshotCollection) (result SnapshotCollection, err error) {
+ req, err := lastResults.snapshotCollectionPreparer(ctx)
+ if err != nil {
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", nil, "Failure preparing next results request")
+ }
+ if req == nil {
+ return
+ }
+ resp, err := client.ListSnapshotsSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ return result, autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", resp, "Failure sending next results request")
+ }
+ result, err = client.ListSnapshotsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", resp, "Failure responding to next results request")
+ }
+ return
+}
+
+// ListSnapshotsSlotComplete enumerates all values, automatically crossing page boundaries as required.
+func (client AppsClient) ListSnapshotsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SnapshotCollectionIterator, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSnapshotsSlot")
+ defer func() {
+ sc := -1
+ if result.Response().Response.Response != nil {
+ sc = result.page.Response().Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ result.page, err = client.ListSnapshotsSlot(ctx, resourceGroupName, name, slot)
+ return
+}
+
+// ListSyncFunctionTriggers this is to allow calling via powershell and ARM template.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) ListSyncFunctionTriggers(ctx context.Context, resourceGroupName string, name string) (result FunctionSecrets, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncFunctionTriggers")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListSyncFunctionTriggers", err.Error())
+ }
+
+ req, err := client.ListSyncFunctionTriggersPreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSyncFunctionTriggersSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListSyncFunctionTriggersResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// ListSyncFunctionTriggersPreparer prepares the ListSyncFunctionTriggers request.
+func (client AppsClient) ListSyncFunctionTriggersPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/listsyncfunctiontriggerstatus", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// ListSyncFunctionTriggersSender sends the ListSyncFunctionTriggers request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) ListSyncFunctionTriggersSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// ListSyncFunctionTriggersResponder handles the response to the ListSyncFunctionTriggers request. The method always
+// closes the http.Response Body.
+func (client AppsClient) ListSyncFunctionTriggersResponder(resp *http.Response) (result FunctionSecrets, err error) {
+ err = autorest.Respond(
+ resp,
+ client.ByInspecting(),
+ azure.WithErrorUnlessStatusCode(http.StatusOK),
+ autorest.ByUnmarshallingJSON(&result),
+ autorest.ByClosing())
+ result.Response = autorest.Response{Response: resp}
+ return
+}
+
+// ListSyncFunctionTriggersSlot this is to allow calling via powershell and ARM template.
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+// slot - name of the deployment slot.
+func (client AppsClient) ListSyncFunctionTriggersSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result FunctionSecrets, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncFunctionTriggersSlot")
+ defer func() {
+ sc := -1
+ if result.Response.Response != nil {
+ sc = result.Response.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "ListSyncFunctionTriggersSlot", err.Error())
+ }
+
+ req, err := client.ListSyncFunctionTriggersSlotPreparer(ctx, resourceGroupName, name, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.ListSyncFunctionTriggersSlotSender(req)
+ if err != nil {
+ result.Response = autorest.Response{Response: resp}
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.ListSyncFunctionTriggersSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSnapshotsSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", resp, "Failure responding to request")
}
return
}
-// ListSnapshotsSlotPreparer prepares the ListSnapshotsSlot request.
-func (client AppsClient) ListSnapshotsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListSyncFunctionTriggersSlotPreparer prepares the ListSyncFunctionTriggersSlot request.
+func (client AppsClient) ListSyncFunctionTriggersSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -24607,23 +25887,23 @@ func (client AppsClient) ListSnapshotsSlotPreparer(ctx context.Context, resource
}
preparer := autorest.CreatePreparer(
- autorest.AsGet(),
+ autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/snapshots", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/listsyncfunctiontriggerstatus", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListSnapshotsSlotSender sends the ListSnapshotsSlot request. The method will close the
+// ListSyncFunctionTriggersSlotSender sends the ListSyncFunctionTriggersSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListSnapshotsSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListSyncFunctionTriggersSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListSnapshotsSlotResponder handles the response to the ListSnapshotsSlot request. The method always
+// ListSyncFunctionTriggersSlotResponder handles the response to the ListSyncFunctionTriggersSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListSnapshotsSlotResponder(resp *http.Response) (result SnapshotCollection, err error) {
+func (client AppsClient) ListSyncFunctionTriggersSlotResponder(resp *http.Response) (result FunctionSecrets, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
@@ -24634,54 +25914,17 @@ func (client AppsClient) ListSnapshotsSlotResponder(resp *http.Response) (result
return
}
-// listSnapshotsSlotNextResults retrieves the next set of results, if any.
-func (client AppsClient) listSnapshotsSlotNextResults(ctx context.Context, lastResults SnapshotCollection) (result SnapshotCollection, err error) {
- req, err := lastResults.snapshotCollectionPreparer(ctx)
- if err != nil {
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", nil, "Failure preparing next results request")
- }
- if req == nil {
- return
- }
- resp, err := client.ListSnapshotsSlotSender(req)
- if err != nil {
- result.Response = autorest.Response{Response: resp}
- return result, autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", resp, "Failure sending next results request")
- }
- result, err = client.ListSnapshotsSlotResponder(resp)
- if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "listSnapshotsSlotNextResults", resp, "Failure responding to next results request")
- }
- return
-}
-
-// ListSnapshotsSlotComplete enumerates all values, automatically crossing page boundaries as required.
-func (client AppsClient) ListSnapshotsSlotComplete(ctx context.Context, resourceGroupName string, name string, slot string) (result SnapshotCollectionIterator, err error) {
- if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSnapshotsSlot")
- defer func() {
- sc := -1
- if result.Response().Response.Response != nil {
- sc = result.page.Response().Response.Response.StatusCode
- }
- tracing.EndSpan(ctx, sc, err)
- }()
- }
- result.page, err = client.ListSnapshotsSlot(ctx, resourceGroupName, name, slot)
- return
-}
-
-// ListSyncFunctionTriggers this is to allow calling via powershell and ARM template.
+// ListSyncStatus this is to allow calling via powershell and ARM template.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-func (client AppsClient) ListSyncFunctionTriggers(ctx context.Context, resourceGroupName string, name string) (result FunctionSecrets, err error) {
+func (client AppsClient) ListSyncStatus(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncFunctionTriggers")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncStatus")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -24691,32 +25934,32 @@ func (client AppsClient) ListSyncFunctionTriggers(ctx context.Context, resourceG
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListSyncFunctionTriggers", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListSyncStatus", err.Error())
}
- req, err := client.ListSyncFunctionTriggersPreparer(ctx, resourceGroupName, name)
+ req, err := client.ListSyncStatusPreparer(ctx, resourceGroupName, name)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatus", nil, "Failure preparing request")
return
}
- resp, err := client.ListSyncFunctionTriggersSender(req)
+ resp, err := client.ListSyncStatusSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatus", resp, "Failure sending request")
return
}
- result, err = client.ListSyncFunctionTriggersResponder(resp)
+ result, err = client.ListSyncStatusResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggers", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatus", resp, "Failure responding to request")
}
return
}
-// ListSyncFunctionTriggersPreparer prepares the ListSyncFunctionTriggers request.
-func (client AppsClient) ListSyncFunctionTriggersPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+// ListSyncStatusPreparer prepares the ListSyncStatus request.
+func (client AppsClient) ListSyncStatusPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -24731,44 +25974,42 @@ func (client AppsClient) ListSyncFunctionTriggersPreparer(ctx context.Context, r
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/listsyncfunctiontriggerstatus", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/host/default/listsyncstatus", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListSyncFunctionTriggersSender sends the ListSyncFunctionTriggers request. The method will close the
+// ListSyncStatusSender sends the ListSyncStatus request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListSyncFunctionTriggersSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListSyncStatusSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListSyncFunctionTriggersResponder handles the response to the ListSyncFunctionTriggers request. The method always
+// ListSyncStatusResponder handles the response to the ListSyncStatus request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListSyncFunctionTriggersResponder(resp *http.Response) (result FunctionSecrets, err error) {
+func (client AppsClient) ListSyncStatusResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
-// ListSyncFunctionTriggersSlot this is to allow calling via powershell and ARM template.
+// ListSyncStatusSlot this is to allow calling via powershell and ARM template.
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will restore a backup of the
-// production slot.
-func (client AppsClient) ListSyncFunctionTriggersSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result FunctionSecrets, err error) {
+// slot - name of the deployment slot.
+func (client AppsClient) ListSyncStatusSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
- ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncFunctionTriggersSlot")
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.ListSyncStatusSlot")
defer func() {
sc := -1
- if result.Response.Response != nil {
- sc = result.Response.Response.StatusCode
+ if result.Response != nil {
+ sc = result.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
@@ -24778,32 +26019,32 @@ func (client AppsClient) ListSyncFunctionTriggersSlot(ctx context.Context, resou
Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
{Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
{Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
- return result, validation.NewError("web.AppsClient", "ListSyncFunctionTriggersSlot", err.Error())
+ return result, validation.NewError("web.AppsClient", "ListSyncStatusSlot", err.Error())
}
- req, err := client.ListSyncFunctionTriggersSlotPreparer(ctx, resourceGroupName, name, slot)
+ req, err := client.ListSyncStatusSlotPreparer(ctx, resourceGroupName, name, slot)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", nil, "Failure preparing request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatusSlot", nil, "Failure preparing request")
return
}
- resp, err := client.ListSyncFunctionTriggersSlotSender(req)
+ resp, err := client.ListSyncStatusSlotSender(req)
if err != nil {
- result.Response = autorest.Response{Response: resp}
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", resp, "Failure sending request")
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatusSlot", resp, "Failure sending request")
return
}
- result, err = client.ListSyncFunctionTriggersSlotResponder(resp)
+ result, err = client.ListSyncStatusSlotResponder(resp)
if err != nil {
- err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncFunctionTriggersSlot", resp, "Failure responding to request")
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "ListSyncStatusSlot", resp, "Failure responding to request")
}
return
}
-// ListSyncFunctionTriggersSlotPreparer prepares the ListSyncFunctionTriggersSlot request.
-func (client AppsClient) ListSyncFunctionTriggersSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+// ListSyncStatusSlotPreparer prepares the ListSyncStatusSlot request.
+func (client AppsClient) ListSyncStatusSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"name": autorest.Encode("path", name),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
@@ -24819,28 +26060,27 @@ func (client AppsClient) ListSyncFunctionTriggersSlotPreparer(ctx context.Contex
preparer := autorest.CreatePreparer(
autorest.AsPost(),
autorest.WithBaseURL(client.BaseURI),
- autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/listsyncfunctiontriggerstatus", pathParameters),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/host/default/listsyncstatus", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
-// ListSyncFunctionTriggersSlotSender sends the ListSyncFunctionTriggersSlot request. The method will close the
+// ListSyncStatusSlotSender sends the ListSyncStatusSlot request. The method will close the
// http.Response Body if it receives an error.
-func (client AppsClient) ListSyncFunctionTriggersSlotSender(req *http.Request) (*http.Response, error) {
+func (client AppsClient) ListSyncStatusSlotSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
-// ListSyncFunctionTriggersSlotResponder handles the response to the ListSyncFunctionTriggersSlot request. The method always
+// ListSyncStatusSlotResponder handles the response to the ListSyncStatusSlot request. The method always
// closes the http.Response Body.
-func (client AppsClient) ListSyncFunctionTriggersSlotResponder(resp *http.Response) (result FunctionSecrets, err error) {
+func (client AppsClient) ListSyncStatusSlotResponder(resp *http.Response) (result autorest.Response, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
- azure.WithErrorUnlessStatusCode(http.StatusOK),
- autorest.ByUnmarshallingJSON(&result),
+ azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent),
autorest.ByClosing())
- result.Response = autorest.Response{Response: resp}
+ result.Response = resp
return
}
@@ -29646,7 +30886,177 @@ func (client AppsClient) SwapSlotWithProductionResponder(resp *http.Response) (r
return
}
-// SyncFunctionTriggers syncs function trigger metadata to the scale controller
+// SyncFunctions syncs function trigger metadata to the management database
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+func (client AppsClient) SyncFunctions(ctx context.Context, resourceGroupName string, name string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.SyncFunctions")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "SyncFunctions", err.Error())
+ }
+
+ req, err := client.SyncFunctionsPreparer(ctx, resourceGroupName, name)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctions", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.SyncFunctionsSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctions", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.SyncFunctionsResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctions", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// SyncFunctionsPreparer prepares the SyncFunctions request.
+func (client AppsClient) SyncFunctionsPreparer(ctx context.Context, resourceGroupName string, name string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/host/default/sync", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// SyncFunctionsSender sends the SyncFunctions request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) SyncFunctionsSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// SyncFunctionsResponder handles the response to the SyncFunctions request. The method always
+// closes the http.Response Body.
+func (client AppsClient) SyncFunctionsResponder(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
+}
+
+// SyncFunctionsSlot syncs function trigger metadata to the management database
+// Parameters:
+// resourceGroupName - name of the resource group to which the resource belongs.
+// name - name of the app.
+// slot - name of the deployment slot.
+func (client AppsClient) SyncFunctionsSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
+ if tracing.IsEnabled() {
+ ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.SyncFunctionsSlot")
+ defer func() {
+ sc := -1
+ if result.Response != nil {
+ sc = result.Response.StatusCode
+ }
+ tracing.EndSpan(ctx, sc, err)
+ }()
+ }
+ if err := validation.Validate([]validation.Validation{
+ {TargetValue: resourceGroupName,
+ Constraints: []validation.Constraint{{Target: "resourceGroupName", Name: validation.MaxLength, Rule: 90, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.MinLength, Rule: 1, Chain: nil},
+ {Target: "resourceGroupName", Name: validation.Pattern, Rule: `^[-\w\._\(\)]+[^\.]$`, Chain: nil}}}}); err != nil {
+ return result, validation.NewError("web.AppsClient", "SyncFunctionsSlot", err.Error())
+ }
+
+ req, err := client.SyncFunctionsSlotPreparer(ctx, resourceGroupName, name, slot)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctionsSlot", nil, "Failure preparing request")
+ return
+ }
+
+ resp, err := client.SyncFunctionsSlotSender(req)
+ if err != nil {
+ result.Response = resp
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctionsSlot", resp, "Failure sending request")
+ return
+ }
+
+ result, err = client.SyncFunctionsSlotResponder(resp)
+ if err != nil {
+ err = autorest.NewErrorWithError(err, "web.AppsClient", "SyncFunctionsSlot", resp, "Failure responding to request")
+ }
+
+ return
+}
+
+// SyncFunctionsSlotPreparer prepares the SyncFunctionsSlot request.
+func (client AppsClient) SyncFunctionsSlotPreparer(ctx context.Context, resourceGroupName string, name string, slot string) (*http.Request, error) {
+ pathParameters := map[string]interface{}{
+ "name": autorest.Encode("path", name),
+ "resourceGroupName": autorest.Encode("path", resourceGroupName),
+ "slot": autorest.Encode("path", slot),
+ "subscriptionId": autorest.Encode("path", client.SubscriptionID),
+ }
+
+ const APIVersion = "2018-02-01"
+ queryParameters := map[string]interface{}{
+ "api-version": APIVersion,
+ }
+
+ preparer := autorest.CreatePreparer(
+ autorest.AsPost(),
+ autorest.WithBaseURL(client.BaseURI),
+ autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/host/default/sync", pathParameters),
+ autorest.WithQueryParameters(queryParameters))
+ return preparer.Prepare((&http.Request{}).WithContext(ctx))
+}
+
+// SyncFunctionsSlotSender sends the SyncFunctionsSlot request. The method will close the
+// http.Response Body if it receives an error.
+func (client AppsClient) SyncFunctionsSlotSender(req *http.Request) (*http.Response, error) {
+ sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
+ return autorest.SendWithSender(client, req, sd...)
+}
+
+// SyncFunctionsSlotResponder handles the response to the SyncFunctionsSlot request. The method always
+// closes the http.Response Body.
+func (client AppsClient) SyncFunctionsSlotResponder(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
+}
+
+// SyncFunctionTriggers syncs function trigger metadata to the management database
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
@@ -29730,12 +31140,11 @@ func (client AppsClient) SyncFunctionTriggersResponder(resp *http.Response) (res
return
}
-// SyncFunctionTriggersSlot syncs function trigger metadata to the scale controller
+// SyncFunctionTriggersSlot syncs function trigger metadata to the management database
// Parameters:
// resourceGroupName - name of the resource group to which the resource belongs.
// name - name of the app.
-// slot - name of the deployment slot. If a slot is not specified, the API will restore a backup of the
-// production slot.
+// slot - name of the deployment slot.
func (client AppsClient) SyncFunctionTriggersSlot(ctx context.Context, resourceGroupName string, name string, slot string) (result autorest.Response, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AppsClient.SyncFunctionTriggersSlot")
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/models.go b/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/models.go
index b8666162d53b..24b150a12227 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/models.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web/models.go
@@ -9813,7 +9813,7 @@ type FileSystemHTTPLogsConfig struct {
Enabled *bool `json:"enabled,omitempty"`
}
-// FunctionEnvelope web Job Information.
+// FunctionEnvelope function information.
type FunctionEnvelope struct {
autorest.Response `json:"-"`
// FunctionEnvelopeProperties - FunctionEnvelope resource specific properties
@@ -10056,6 +10056,8 @@ type FunctionEnvelopeProperties struct {
ScriptHref *string `json:"script_href,omitempty"`
// ConfigHref - Config URI.
ConfigHref *string `json:"config_href,omitempty"`
+ // TestDataHref - Test data URI.
+ TestDataHref *string `json:"test_data_href,omitempty"`
// SecretsFileHref - Secrets file URI.
SecretsFileHref *string `json:"secrets_file_href,omitempty"`
// Href - Function URI.
@@ -10066,6 +10068,12 @@ type FunctionEnvelopeProperties struct {
Files map[string]*string `json:"files"`
// TestData - Test data used when testing via the Azure Portal.
TestData *string `json:"test_data,omitempty"`
+ // InvokeURLTemplate - The invocation URL
+ InvokeURLTemplate *string `json:"invoke_url_template,omitempty"`
+ // Language - The function language
+ Language *string `json:"language,omitempty"`
+ // IsDisabled - Value indicating whether the function is disabled
+ IsDisabled *bool `json:"isDisabled,omitempty"`
}
// MarshalJSON is the custom marshaler for FunctionEnvelopeProperties.
@@ -10083,6 +10091,9 @@ func (fe FunctionEnvelopeProperties) MarshalJSON() ([]byte, error) {
if fe.ConfigHref != nil {
objectMap["config_href"] = fe.ConfigHref
}
+ if fe.TestDataHref != nil {
+ objectMap["test_data_href"] = fe.TestDataHref
+ }
if fe.SecretsFileHref != nil {
objectMap["secrets_file_href"] = fe.SecretsFileHref
}
@@ -10098,6 +10109,15 @@ func (fe FunctionEnvelopeProperties) MarshalJSON() ([]byte, error) {
if fe.TestData != nil {
objectMap["test_data"] = fe.TestData
}
+ if fe.InvokeURLTemplate != nil {
+ objectMap["invoke_url_template"] = fe.InvokeURLTemplate
+ }
+ if fe.Language != nil {
+ objectMap["language"] = fe.Language
+ }
+ if fe.IsDisabled != nil {
+ objectMap["isDisabled"] = fe.IsDisabled
+ }
return json.Marshal(objectMap)
}
@@ -10502,6 +10522,32 @@ type HostingEnvironmentProfile struct {
Type *string `json:"type,omitempty"`
}
+// HostKeys functions host level keys.
+type HostKeys struct {
+ autorest.Response `json:"-"`
+ // MasterKey - Secret key.
+ MasterKey *string `json:"masterKey,omitempty"`
+ // FunctionKeys - Host level function keys.
+ FunctionKeys map[string]*string `json:"functionKeys"`
+ // SystemKeys - System keys.
+ SystemKeys map[string]*string `json:"systemKeys"`
+}
+
+// MarshalJSON is the custom marshaler for HostKeys.
+func (hk HostKeys) MarshalJSON() ([]byte, error) {
+ objectMap := make(map[string]interface{})
+ if hk.MasterKey != nil {
+ objectMap["masterKey"] = hk.MasterKey
+ }
+ if hk.FunctionKeys != nil {
+ objectMap["functionKeys"] = hk.FunctionKeys
+ }
+ if hk.SystemKeys != nil {
+ objectMap["systemKeys"] = hk.SystemKeys
+ }
+ return json.Marshal(objectMap)
+}
+
// HostName details of a hostname derived from a domain.
type HostName struct {
// Name - Name of the hostname.
@@ -11945,6 +11991,15 @@ func (j JobProperties) MarshalJSON() ([]byte, error) {
return json.Marshal(objectMap)
}
+// KeyInfo function key info.
+type KeyInfo struct {
+ autorest.Response `json:"-"`
+ // Name - Key name
+ Name *string `json:"name,omitempty"`
+ // Value - Key value
+ Value *string `json:"value,omitempty"`
+}
+
// ListCapability ...
type ListCapability struct {
autorest.Response `json:"-"`
diff --git a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
index 8947c1ffc9c0..38c89d8f8d54 100644
--- a/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
+++ b/vendor/github.com/Azure/azure-sdk-for-go/version/version.go
@@ -18,4 +18,4 @@ package version
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
// Number contains the semantic version of this SDK.
-const Number = "v34.1.0"
+const Number = "v35.0.0"
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/devicetoken.go b/vendor/github.com/Azure/go-autorest/autorest/adal/devicetoken.go
index b38f4c245897..914f8af5e4ea 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/devicetoken.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/devicetoken.go
@@ -24,6 +24,7 @@ package adal
*/
import (
+ "context"
"encoding/json"
"fmt"
"io/ioutil"
@@ -101,7 +102,14 @@ type deviceToken struct {
// InitiateDeviceAuth initiates a device auth flow. It returns a DeviceCode
// that can be used with CheckForUserCompletion or WaitForUserCompletion.
+// Deprecated: use InitiateDeviceAuthWithContext() instead.
func InitiateDeviceAuth(sender Sender, oauthConfig OAuthConfig, clientID, resource string) (*DeviceCode, error) {
+ return InitiateDeviceAuthWithContext(context.Background(), sender, oauthConfig, clientID, resource)
+}
+
+// InitiateDeviceAuthWithContext initiates a device auth flow. It returns a DeviceCode
+// that can be used with CheckForUserCompletion or WaitForUserCompletion.
+func InitiateDeviceAuthWithContext(ctx context.Context, sender Sender, oauthConfig OAuthConfig, clientID, resource string) (*DeviceCode, error) {
v := url.Values{
"client_id": []string{clientID},
"resource": []string{resource},
@@ -117,7 +125,7 @@ func InitiateDeviceAuth(sender Sender, oauthConfig OAuthConfig, clientID, resour
req.ContentLength = int64(len(s))
req.Header.Set(contentType, mimeTypeFormPost)
- resp, err := sender.Do(req)
+ resp, err := sender.Do(req.WithContext(ctx))
if err != nil {
return nil, fmt.Errorf("%s %s: %s", logPrefix, errCodeSendingFails, err.Error())
}
@@ -151,7 +159,14 @@ func InitiateDeviceAuth(sender Sender, oauthConfig OAuthConfig, clientID, resour
// CheckForUserCompletion takes a DeviceCode and checks with the Azure AD OAuth endpoint
// to see if the device flow has: been completed, timed out, or otherwise failed
+// Deprecated: use CheckForUserCompletionWithContext() instead.
func CheckForUserCompletion(sender Sender, code *DeviceCode) (*Token, error) {
+ return CheckForUserCompletionWithContext(context.Background(), sender, code)
+}
+
+// CheckForUserCompletionWithContext takes a DeviceCode and checks with the Azure AD OAuth endpoint
+// to see if the device flow has: been completed, timed out, or otherwise failed
+func CheckForUserCompletionWithContext(ctx context.Context, sender Sender, code *DeviceCode) (*Token, error) {
v := url.Values{
"client_id": []string{code.ClientID},
"code": []string{*code.DeviceCode},
@@ -169,7 +184,7 @@ func CheckForUserCompletion(sender Sender, code *DeviceCode) (*Token, error) {
req.ContentLength = int64(len(s))
req.Header.Set(contentType, mimeTypeFormPost)
- resp, err := sender.Do(req)
+ resp, err := sender.Do(req.WithContext(ctx))
if err != nil {
return nil, fmt.Errorf("%s %s: %s", logPrefix, errTokenSendingFails, err.Error())
}
@@ -213,12 +228,19 @@ func CheckForUserCompletion(sender Sender, code *DeviceCode) (*Token, error) {
// WaitForUserCompletion calls CheckForUserCompletion repeatedly until a token is granted or an error state occurs.
// This prevents the user from looping and checking against 'ErrDeviceAuthorizationPending'.
+// Deprecated: use WaitForUserCompletionWithContext() instead.
func WaitForUserCompletion(sender Sender, code *DeviceCode) (*Token, error) {
+ return WaitForUserCompletionWithContext(context.Background(), sender, code)
+}
+
+// WaitForUserCompletionWithContext calls CheckForUserCompletion repeatedly until a token is granted or an error
+// state occurs. This prevents the user from looping and checking against 'ErrDeviceAuthorizationPending'.
+func WaitForUserCompletionWithContext(ctx context.Context, sender Sender, code *DeviceCode) (*Token, error) {
intervalDuration := time.Duration(*code.Interval) * time.Second
waitDuration := intervalDuration
for {
- token, err := CheckForUserCompletion(sender, code)
+ token, err := CheckForUserCompletionWithContext(ctx, sender, code)
if err == nil {
return token, nil
@@ -237,6 +259,11 @@ func WaitForUserCompletion(sender Sender, code *DeviceCode) (*Token, error) {
return nil, fmt.Errorf("%s Error waiting for user to complete device flow. Server told us to slow_down too much", logPrefix)
}
- time.Sleep(waitDuration)
+ select {
+ case <-time.After(waitDuration):
+ // noop
+ case <-ctx.Done():
+ return nil, ctx.Err()
+ }
}
}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/adal/token.go b/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
index b72753498365..33bbd6ea1505 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/adal/token.go
@@ -26,9 +26,9 @@ import (
"fmt"
"io/ioutil"
"math"
- "net"
"net/http"
"net/url"
+ "os"
"strings"
"sync"
"time"
@@ -63,6 +63,12 @@ const (
// the default number of attempts to refresh an MSI authentication token
defaultMaxMSIRefreshAttempts = 5
+
+ // asMSIEndpointEnv is the environment variable used to store the endpoint on App Service and Functions
+ asMSIEndpointEnv = "MSI_ENDPOINT"
+
+ // asMSISecretEnv is the environment variable used to store the request secret on App Service and Functions
+ asMSISecretEnv = "MSI_SECRET"
)
// OAuthTokenProvider is an interface which should be implemented by an access token retriever
@@ -100,6 +106,9 @@ type RefresherWithContext interface {
// a successful token refresh
type TokenRefreshCallback func(Token) error
+// TokenRefresh is a type representing a custom callback to refresh a token
+type TokenRefresh func(ctx context.Context, resource string) (*Token, error)
+
// Token encapsulates the access token used to authorize Azure requests.
// https://docs.microsoft.com/en-us/azure/active-directory/develop/v1-oauth2-client-creds-grant-flow#service-to-service-access-token-response
type Token struct {
@@ -338,10 +347,11 @@ func (secret ServicePrincipalAuthorizationCodeSecret) MarshalJSON() ([]byte, err
// ServicePrincipalToken encapsulates a Token created for a Service Principal.
type ServicePrincipalToken struct {
- inner servicePrincipalToken
- refreshLock *sync.RWMutex
- sender Sender
- refreshCallbacks []TokenRefreshCallback
+ inner servicePrincipalToken
+ refreshLock *sync.RWMutex
+ sender Sender
+ customRefreshFunc TokenRefresh
+ refreshCallbacks []TokenRefreshCallback
// MaxMSIRefreshAttempts is the maximum number of attempts to refresh an MSI token.
MaxMSIRefreshAttempts int
}
@@ -356,6 +366,11 @@ func (spt *ServicePrincipalToken) SetRefreshCallbacks(callbacks []TokenRefreshCa
spt.refreshCallbacks = callbacks
}
+// SetCustomRefreshFunc sets a custom refresh function used to refresh the token.
+func (spt *ServicePrincipalToken) SetCustomRefreshFunc(customRefreshFunc TokenRefresh) {
+ spt.customRefreshFunc = customRefreshFunc
+}
+
// MarshalJSON implements the json.Marshaler interface.
func (spt ServicePrincipalToken) MarshalJSON() ([]byte, error) {
return json.Marshal(spt.inner)
@@ -634,6 +649,31 @@ func GetMSIVMEndpoint() (string, error) {
return msiEndpoint, nil
}
+func isAppService() bool {
+ _, asMSIEndpointEnvExists := os.LookupEnv(asMSIEndpointEnv)
+ _, asMSISecretEnvExists := os.LookupEnv(asMSISecretEnv)
+
+ return asMSIEndpointEnvExists && asMSISecretEnvExists
+}
+
+// GetMSIAppServiceEndpoint get the MSI endpoint for App Service and Functions
+func GetMSIAppServiceEndpoint() (string, error) {
+ asMSIEndpoint, asMSIEndpointEnvExists := os.LookupEnv(asMSIEndpointEnv)
+
+ if asMSIEndpointEnvExists {
+ return asMSIEndpoint, nil
+ }
+ return "", errors.New("MSI endpoint not found")
+}
+
+// GetMSIEndpoint get the appropriate MSI endpoint depending on the runtime environment
+func GetMSIEndpoint() (string, error) {
+ if isAppService() {
+ return GetMSIAppServiceEndpoint()
+ }
+ return GetMSIVMEndpoint()
+}
+
// NewServicePrincipalTokenFromMSI creates a ServicePrincipalToken via the MSI VM Extension.
// It will use the system assigned identity when creating the token.
func NewServicePrincipalTokenFromMSI(msiEndpoint, resource string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
@@ -666,7 +706,12 @@ func newServicePrincipalTokenFromMSI(msiEndpoint, resource string, userAssignedI
v := url.Values{}
v.Set("resource", resource)
- v.Set("api-version", "2018-02-01")
+ // App Service MSI currently only supports token API version 2017-09-01
+ if isAppService() {
+ v.Set("api-version", "2017-09-01")
+ } else {
+ v.Set("api-version", "2018-02-01")
+ }
if userAssignedID != nil {
v.Set("client_id", *userAssignedID)
}
@@ -750,13 +795,13 @@ func (spt *ServicePrincipalToken) InvokeRefreshCallbacks(token Token) error {
}
// Refresh obtains a fresh token for the Service Principal.
-// This method is not safe for concurrent use and should be syncrhonized.
+// This method is safe for concurrent use.
func (spt *ServicePrincipalToken) Refresh() error {
return spt.RefreshWithContext(context.Background())
}
// RefreshWithContext obtains a fresh token for the Service Principal.
-// This method is not safe for concurrent use and should be syncrhonized.
+// This method is safe for concurrent use.
func (spt *ServicePrincipalToken) RefreshWithContext(ctx context.Context) error {
spt.refreshLock.Lock()
defer spt.refreshLock.Unlock()
@@ -764,13 +809,13 @@ func (spt *ServicePrincipalToken) RefreshWithContext(ctx context.Context) error
}
// RefreshExchange refreshes the token, but for a different resource.
-// This method is not safe for concurrent use and should be syncrhonized.
+// This method is safe for concurrent use.
func (spt *ServicePrincipalToken) RefreshExchange(resource string) error {
return spt.RefreshExchangeWithContext(context.Background(), resource)
}
// RefreshExchangeWithContext refreshes the token, but for a different resource.
-// This method is not safe for concurrent use and should be syncrhonized.
+// This method is safe for concurrent use.
func (spt *ServicePrincipalToken) RefreshExchangeWithContext(ctx context.Context, resource string) error {
spt.refreshLock.Lock()
defer spt.refreshLock.Unlock()
@@ -793,15 +838,29 @@ func isIMDS(u url.URL) bool {
if err != nil {
return false
}
- return u.Host == imds.Host && u.Path == imds.Path
+ return (u.Host == imds.Host && u.Path == imds.Path) || isAppService()
}
func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource string) error {
+ if spt.customRefreshFunc != nil {
+ token, err := spt.customRefreshFunc(ctx, resource)
+ if err != nil {
+ return err
+ }
+ spt.inner.Token = *token
+ return spt.InvokeRefreshCallbacks(spt.inner.Token)
+ }
+
req, err := http.NewRequest(http.MethodPost, spt.inner.OauthConfig.TokenEndpoint.String(), nil)
if err != nil {
return fmt.Errorf("adal: Failed to build the refresh request. Error = '%v'", err)
}
req.Header.Add("User-Agent", UserAgent())
+ // Add header when runtime is on App Service or Functions
+ if isAppService() {
+ asMSISecret, _ := os.LookupEnv(asMSISecretEnv)
+ req.Header.Add("Secret", asMSISecret)
+ }
req = req.WithContext(ctx)
if !isIMDS(spt.inner.OauthConfig.TokenEndpoint) {
v := url.Values{}
@@ -846,7 +905,8 @@ func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource
resp, err = spt.sender.Do(req)
}
if err != nil {
- return newTokenRefreshError(fmt.Sprintf("adal: Failed to execute the refresh request. Error = '%v'", err), nil)
+ // don't return a TokenRefreshError here; this will allow retry logic to apply
+ return fmt.Errorf("adal: Failed to execute the refresh request. Error = '%v'", err)
}
defer resp.Body.Close()
@@ -913,10 +973,8 @@ func retryForIMDS(sender Sender, req *http.Request, maxAttempts int) (resp *http
for attempt < maxAttempts {
resp, err = sender.Do(req)
- // retry on temporary network errors, e.g. transient network failures.
- // if we don't receive a response then assume we can't connect to the
- // endpoint so we're likely not running on an Azure VM so don't retry.
- if (err != nil && !isTemporaryNetworkError(err)) || resp == nil || resp.StatusCode == http.StatusOK || !containsInt(retries, resp.StatusCode) {
+ // we want to retry if err is not nil or the status code is in the list of retry codes
+ if err == nil && !responseHasStatusCode(resp, retries...) {
return
}
@@ -940,20 +998,12 @@ func retryForIMDS(sender Sender, req *http.Request, maxAttempts int) (resp *http
return
}
-// returns true if the specified error is a temporary network error or false if it's not.
-// if the error doesn't implement the net.Error interface the return value is true.
-func isTemporaryNetworkError(err error) bool {
- if netErr, ok := err.(net.Error); !ok || (ok && netErr.Temporary()) {
- return true
- }
- return false
-}
-
-// returns true if slice ints contains the value n
-func containsInt(ints []int, n int) bool {
- for _, i := range ints {
- if i == n {
- return true
+func responseHasStatusCode(resp *http.Response, codes ...int) bool {
+ if resp != nil {
+ for _, i := range codes {
+ if i == resp.StatusCode {
+ return true
+ }
}
}
return false
diff --git a/vendor/github.com/Azure/go-autorest/autorest/preparer.go b/vendor/github.com/Azure/go-autorest/autorest/preparer.go
index 9f864ab1a15f..6e8ed64eba1c 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/preparer.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/preparer.go
@@ -523,7 +523,7 @@ func parseURL(u *url.URL, path string) (*url.URL, error) {
// WithQueryParameters returns a PrepareDecorators that encodes and applies the query parameters
// given in the supplied map (i.e., key=value).
func WithQueryParameters(queryParameters map[string]interface{}) PrepareDecorator {
- parameters := ensureValueStrings(queryParameters)
+ parameters := MapToValues(queryParameters)
return func(p Preparer) Preparer {
return PreparerFunc(func(r *http.Request) (*http.Request, error) {
r, err := p.Prepare(r)
@@ -531,14 +531,16 @@ func WithQueryParameters(queryParameters map[string]interface{}) PrepareDecorato
if r.URL == nil {
return r, NewError("autorest", "WithQueryParameters", "Invoked with a nil URL")
}
-
v := r.URL.Query()
for key, value := range parameters {
- d, err := url.QueryUnescape(value)
- if err != nil {
- return r, err
+ for i := range value {
+ d, err := url.QueryUnescape(value[i])
+ if err != nil {
+ return r, err
+ }
+ value[i] = d
}
- v.Add(key, d)
+ v[key] = value
}
r.URL.RawQuery = v.Encode()
}
diff --git a/vendor/github.com/Azure/go-autorest/autorest/sender.go b/vendor/github.com/Azure/go-autorest/autorest/sender.go
index e582489b326b..5e595d7b1a34 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/sender.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/sender.go
@@ -289,10 +289,6 @@ func doRetryForStatusCodesImpl(s Sender, r *http.Request, count429 bool, attempt
return
}
resp, err = s.Do(rr.Request())
- // if the error isn't temporary don't bother retrying
- if err != nil && !IsTemporaryNetworkError(err) {
- return
- }
// we want to retry if err is not nil (e.g. transient network failure). note that for failed authentication
// resp and err will both have a value, so in this case we don't want to retry as it will never succeed.
if err == nil && !ResponseHasStatusCode(resp, codes...) || IsTokenRefreshError(err) {
diff --git a/vendor/github.com/Azure/go-autorest/autorest/version.go b/vendor/github.com/Azure/go-autorest/autorest/version.go
index cb851937a11a..7a71089c9c4c 100644
--- a/vendor/github.com/Azure/go-autorest/autorest/version.go
+++ b/vendor/github.com/Azure/go-autorest/autorest/version.go
@@ -19,7 +19,7 @@ import (
"runtime"
)
-const number = "v13.0.0"
+const number = "v13.0.2"
var (
userAgent = fmt.Sprintf("Go/%s (%s-%s) go-autorest/%s",
diff --git a/vendor/github.com/hashicorp/go-azure-helpers/authentication/auth_method_azure_cli_token.go b/vendor/github.com/hashicorp/go-azure-helpers/authentication/auth_method_azure_cli_token.go
index c35c1da9c1fe..73816d4bb548 100644
--- a/vendor/github.com/hashicorp/go-azure-helpers/authentication/auth_method_azure_cli_token.go
+++ b/vendor/github.com/hashicorp/go-azure-helpers/authentication/auth_method_azure_cli_token.go
@@ -90,6 +90,21 @@ func (a azureCliTokenAuth) getAuthorizationToken(sender autorest.Sender, oauth *
return nil, err
}
+ var refreshFunc adal.TokenRefresh = func(ctx context.Context, resource string) (*adal.Token, error) {
+ token, err := obtainAuthorizationToken(resource, a.profile.subscriptionId)
+ if err != nil {
+ return nil, err
+ }
+
+ adalToken, err := token.ToADALToken()
+ if err != nil {
+ return nil, err
+ }
+
+ return &adalToken, nil
+ }
+ spt.SetCustomRefreshFunc(refreshFunc)
+
auth := autorest.NewBearerAuthorizer(spt)
return auth, nil
}
diff --git a/vendor/github.com/hashicorp/go-azure-helpers/storage/sas_token.go b/vendor/github.com/hashicorp/go-azure-helpers/storage/sas_token.go
index 62585a34a9cc..80e228a77ec5 100644
--- a/vendor/github.com/hashicorp/go-azure-helpers/storage/sas_token.go
+++ b/vendor/github.com/hashicorp/go-azure-helpers/storage/sas_token.go
@@ -7,6 +7,8 @@ import (
"fmt"
"net/url"
"strings"
+
+ "github.com/Azure/go-autorest/autorest/azure"
)
const (
@@ -68,6 +70,28 @@ func ComputeAccountSASToken(accountName string,
return sasToken, nil
}
+// ComputeAccountSASConnectionString computes the composed SAS Connection String for a Storage Account based on the
+// sas token
+func ComputeAccountSASConnectionString(env *azure.Environment, accountName string, sasToken string) string {
+ return fmt.Sprintf(
+ "BlobEndpoint=https://%[1]s.blob.%[2]s/;"+
+ "FileEndpoint=https://%[1]s.file.%[2]s/;"+
+ "QueueEndpoint=https://%[1]s.queue.%[2]s/;"+
+ "TableEndpoint=https://%[1]s.table.%[2]s/;"+
+ "SharedAccessSignature=%[3]s", accountName, env.StorageEndpointSuffix, sasToken[1:]) // need to cut the first character '?' from the sas token
+}
+
+// ComputeAccountSASConnectionUrlForType computes the SAS Connection String for a Storage Account based on the
+// sas token and the storage type
+func ComputeAccountSASConnectionUrlForType(env *azure.Environment, accountName string, sasToken string, storageType string) (*string, error) {
+ if !strings.EqualFold(storageType, "blob") && !strings.EqualFold(storageType, "file") && !strings.EqualFold(storageType, "queue") && !strings.EqualFold(storageType, "table") {
+ return nil, fmt.Errorf("Unexpected storage type %s!", storageType)
+ }
+
+ url := fmt.Sprintf("https://%s.%s.%s%s", accountName, strings.ToLower(storageType), env.StorageEndpointSuffix, sasToken)
+ return &url, nil
+}
+
func ComputeContainerSASToken(signedPermissions string,
signedStart string,
signedExpiry string,
diff --git a/vendor/modules.txt b/vendor/modules.txt
index f5e8a0b755f6..64c86e3de554 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -6,7 +6,7 @@ cloud.google.com/go/internal/optional
cloud.google.com/go/internal/trace
cloud.google.com/go/internal/version
cloud.google.com/go/storage
-# github.com/Azure/azure-sdk-for-go v34.1.0+incompatible
+# github.com/Azure/azure-sdk-for-go v35.0.0+incompatible
github.com/Azure/azure-sdk-for-go/profiles/2017-03-09/resources/mgmt/resources
github.com/Azure/azure-sdk-for-go/services/analysisservices/mgmt/2017-08-01/analysisservices
github.com/Azure/azure-sdk-for-go/services/apimanagement/mgmt/2018-01-01/apimanagement
@@ -57,8 +57,7 @@ github.com/Azure/azure-sdk-for-go/services/preview/portal/mgmt/2019-01-01-previe
github.com/Azure/azure-sdk-for-go/services/preview/resources/mgmt/2018-03-01-preview/managementgroups
github.com/Azure/azure-sdk-for-go/services/preview/security/mgmt/v1.0/security
github.com/Azure/azure-sdk-for-go/services/preview/servicebus/mgmt/2018-01-01-preview/servicebus
-github.com/Azure/azure-sdk-for-go/services/signalr/mgmt/2018-10-01/signalr
-github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2015-05-01-preview/sql
+github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-03-01-preview/sql
github.com/Azure/azure-sdk-for-go/services/preview/sql/mgmt/2017-10-01-preview/sql
github.com/Azure/azure-sdk-for-go/services/privatedns/mgmt/2018-09-01/privatedns
github.com/Azure/azure-sdk-for-go/services/provisioningservices/mgmt/2018-01-22/iothub
@@ -76,15 +75,16 @@ github.com/Azure/azure-sdk-for-go/services/scheduler/mgmt/2016-03-01/scheduler
github.com/Azure/azure-sdk-for-go/services/search/mgmt/2015-08-19/search
github.com/Azure/azure-sdk-for-go/services/servicebus/mgmt/2017-04-01/servicebus
github.com/Azure/azure-sdk-for-go/services/servicefabric/mgmt/2018-02-01/servicefabric
+github.com/Azure/azure-sdk-for-go/services/signalr/mgmt/2018-10-01/signalr
github.com/Azure/azure-sdk-for-go/services/storage/mgmt/2019-04-01/storage
github.com/Azure/azure-sdk-for-go/services/streamanalytics/mgmt/2016-03-01/streamanalytics
github.com/Azure/azure-sdk-for-go/services/trafficmanager/mgmt/2018-04-01/trafficmanager
github.com/Azure/azure-sdk-for-go/services/web/mgmt/2018-02-01/web
github.com/Azure/azure-sdk-for-go/version
-# github.com/Azure/go-autorest/autorest v0.9.0
+# github.com/Azure/go-autorest/autorest v0.9.2
github.com/Azure/go-autorest/autorest
github.com/Azure/go-autorest/autorest/azure
-# github.com/Azure/go-autorest/autorest/adal v0.6.0
+# github.com/Azure/go-autorest/autorest/adal v0.8.1-0.20191028180845-3492b2aff503
github.com/Azure/go-autorest/autorest/adal
# github.com/Azure/go-autorest/autorest/azure/cli v0.3.0
github.com/Azure/go-autorest/autorest/azure/cli
@@ -176,7 +176,7 @@ github.com/google/uuid
github.com/googleapis/gax-go/v2
# github.com/hashicorp/errwrap v1.0.0
github.com/hashicorp/errwrap
-# github.com/hashicorp/go-azure-helpers v0.9.0
+# github.com/hashicorp/go-azure-helpers v0.10.0
github.com/hashicorp/go-azure-helpers/authentication
github.com/hashicorp/go-azure-helpers/resourceproviders
github.com/hashicorp/go-azure-helpers/response