armdeploymentmanager

package module
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2023 License: MIT Imports: 15 Imported by: 1

README

Azure Deployment manager Module for Go

PkgGoDev

The armdeploymentmanager module provides operations for working with Azure Deployment manager.

Source code

Getting started

Prerequisites

  • an Azure subscription
  • Go 1.18 or above (You could download and install the latest version of Go from here. It will replace the existing Go on your machine. If you want to install multiple Go versions on the same machine, you could refer this doc.)

Install the package

This project uses Go modules for versioning and dependency management.

Install the Azure Deployment manager module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Deployment manager. The azidentity module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more.

cred, err := azidentity.NewDefaultAzureCredential(nil)

For more information on authentication, please see the documentation for azidentity at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azidentity.

Client Factory

Azure Deployment manager module consists of one or more clients. We provide a client factory which could be used to create any client in this module.

clientFactory, err := armdeploymentmanager.NewClientFactory(<subscription ID>, cred, nil)

You can use ClientOptions in package github.com/Azure/azure-sdk-for-go/sdk/azcore/arm to set endpoint to connect with public and sovereign clouds as well as Azure Stack. For more information, please see the documentation for azcore at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azcore.

options := arm.ClientOptions {
    ClientOptions: azcore.ClientOptions {
        Cloud: cloud.AzureChina,
    },
}
clientFactory, err := armdeploymentmanager.NewClientFactory(<subscription ID>, cred, &options)

Clients

A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory.

client := clientFactory.NewServicesClient()

Fakes

The fake package contains types used for constructing in-memory fake servers used in unit tests. This allows writing tests to cover various success/error conditions without the need for connecting to a live service.

Please see https://github.com/Azure/azure-sdk-for-go/tree/main/sdk/samples/fakes for details and examples on how to use fakes.

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Deployment manager label.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIKeyAuthentication

type APIKeyAuthentication struct {
	// REQUIRED; The location of the authentication key/value pair in the request.
	In *RestAuthLocation

	// REQUIRED; The key name of the authentication key/value pair.
	Name *string

	// REQUIRED; The authentication type.
	Type *RestAuthType

	// REQUIRED; The value of the authentication key/value pair.
	Value *string
}

APIKeyAuthentication - ApiKey authentication gives a name and a value that can be included in either the request header or query parameters.

func (*APIKeyAuthentication) GetRestRequestAuthentication added in v0.2.0

func (a *APIKeyAuthentication) GetRestRequestAuthentication() *RestRequestAuthentication

GetRestRequestAuthentication implements the RestRequestAuthenticationClassification interface for type APIKeyAuthentication.

func (APIKeyAuthentication) MarshalJSON

func (a APIKeyAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type APIKeyAuthentication.

func (*APIKeyAuthentication) UnmarshalJSON

func (a *APIKeyAuthentication) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type APIKeyAuthentication.

type ArtifactSource

type ArtifactSource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// The properties that define the artifact source.
	Properties *ArtifactSourceProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

ArtifactSource - The resource that defines the source location where the artifacts are located.

func (ArtifactSource) MarshalJSON

func (a ArtifactSource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ArtifactSource.

func (*ArtifactSource) UnmarshalJSON

func (a *ArtifactSource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ArtifactSource.

type ArtifactSourceProperties

type ArtifactSourceProperties struct {
	// REQUIRED; The authentication method to use to access the artifact source.
	Authentication AuthenticationClassification

	// REQUIRED; The type of artifact source used.
	SourceType *string

	// The path from the location that the 'authentication' property [say, a SAS URI to the blob container] refers to, to the
	// location of the artifacts. This can be used to differentiate different versions
	// of the artifacts. Or, different types of artifacts like binaries or templates. The location referenced by the authentication
	// property concatenated with this optional artifactRoot path forms the
	// artifact source location where the artifacts are expected to be found.
	ArtifactRoot *string
}

ArtifactSourceProperties - The properties that define the artifact source.

func (ArtifactSourceProperties) MarshalJSON added in v0.2.0

func (a ArtifactSourceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ArtifactSourceProperties.

func (*ArtifactSourceProperties) UnmarshalJSON added in v0.2.0

func (a *ArtifactSourceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ArtifactSourceProperties.

type ArtifactSourcePropertiesAutoGenerated

type ArtifactSourcePropertiesAutoGenerated struct {
	// REQUIRED; The authentication method to use to access the artifact source.
	Authentication AuthenticationClassification

	// REQUIRED; The type of artifact source used.
	SourceType *string

	// The path from the location that the 'authentication' property [say, a SAS URI to the blob container] refers to, to the
	// location of the artifacts. This can be used to differentiate different versions
	// of the artifacts. Or, different types of artifacts like binaries or templates. The location referenced by the authentication
	// property concatenated with this optional artifactRoot path forms the
	// artifact source location where the artifacts are expected to be found.
	ArtifactRoot *string
}

ArtifactSourcePropertiesAutoGenerated - The properties that define the source location where the artifacts are located.

func (ArtifactSourcePropertiesAutoGenerated) MarshalJSON

func (a ArtifactSourcePropertiesAutoGenerated) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ArtifactSourcePropertiesAutoGenerated.

func (*ArtifactSourcePropertiesAutoGenerated) UnmarshalJSON

func (a *ArtifactSourcePropertiesAutoGenerated) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ArtifactSourcePropertiesAutoGenerated.

type ArtifactSourcesClient

type ArtifactSourcesClient struct {
	// contains filtered or unexported fields
}

ArtifactSourcesClient contains the methods for the ArtifactSources group. Don't use this type directly, use NewArtifactSourcesClient() instead.

func NewArtifactSourcesClient

func NewArtifactSourcesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ArtifactSourcesClient, error)

NewArtifactSourcesClient creates a new instance of ArtifactSourcesClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ArtifactSourcesClient) CreateOrUpdate

func (client *ArtifactSourcesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, artifactSourceName string, options *ArtifactSourcesClientCreateOrUpdateOptions) (ArtifactSourcesClientCreateOrUpdateResponse, error)

CreateOrUpdate - Synchronously creates a new artifact source or updates an existing artifact source. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • artifactSourceName - The name of the artifact source.
  • options - ArtifactSourcesClientCreateOrUpdateOptions contains the optional parameters for the ArtifactSourcesClient.CreateOrUpdate method.
Example (CreateArtifactSource)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/artifactsource_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewArtifactSourcesClient().CreateOrUpdate(ctx, "myResourceGroup", "myArtifactSource", &armdeploymentmanager.ArtifactSourcesClientCreateOrUpdateOptions{ArtifactSourceInfo: &armdeploymentmanager.ArtifactSource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ArtifactSourceProperties{
			Authentication: &armdeploymentmanager.SasAuthentication{
				Type: to.Ptr("Sas"),
				Properties: &armdeploymentmanager.SasProperties{
					SasURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/myartifactsource?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
				},
			},
			SourceType: to.Ptr("AzureStorage"),
		},
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

Example (CreateArtifactSourceWithArtifactRootAnOffsetIntoTheStorageContainer)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/artifactsource_createorupdate_artifactroot.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewArtifactSourcesClient().CreateOrUpdate(ctx, "myResourceGroup", "myArtifactSource", &armdeploymentmanager.ArtifactSourcesClientCreateOrUpdateOptions{ArtifactSourceInfo: &armdeploymentmanager.ArtifactSource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ArtifactSourceProperties{
			ArtifactRoot: to.Ptr("1.0.0.0"),
			Authentication: &armdeploymentmanager.SasAuthentication{
				Type: to.Ptr("Sas"),
				Properties: &armdeploymentmanager.SasProperties{
					SasURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/myartifactsource?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
				},
			},
			SourceType: to.Ptr("AzureStorage"),
		},
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ArtifactSourcesClient) Delete

func (client *ArtifactSourcesClient) Delete(ctx context.Context, resourceGroupName string, artifactSourceName string, options *ArtifactSourcesClientDeleteOptions) (ArtifactSourcesClientDeleteResponse, error)

Delete - Deletes an artifact source. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • artifactSourceName - The name of the artifact source.
  • options - ArtifactSourcesClientDeleteOptions contains the optional parameters for the ArtifactSourcesClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/artifactsource_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewArtifactSourcesClient().Delete(ctx, "myResourceGroup", "myArtifactSource", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ArtifactSourcesClient) Get

func (client *ArtifactSourcesClient) Get(ctx context.Context, resourceGroupName string, artifactSourceName string, options *ArtifactSourcesClientGetOptions) (ArtifactSourcesClientGetResponse, error)

Get - Gets an artifact source. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • artifactSourceName - The name of the artifact source.
  • options - ArtifactSourcesClientGetOptions contains the optional parameters for the ArtifactSourcesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/artifactsource_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewArtifactSourcesClient().Get(ctx, "myResourceGroup", "myArtifactSource", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ArtifactSource = armdeploymentmanager.ArtifactSource{
	// 	Name: to.Ptr("myArtifactSource"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/artifactSources"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armdeploymentmanager.ArtifactSourceProperties{
	// 		Authentication: &armdeploymentmanager.SasAuthentication{
	// 			Type: to.Ptr("Sas"),
	// 			Properties: &armdeploymentmanager.SasProperties{
	// 				SasURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/myartifactsource?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
	// 			},
	// 		},
	// 		SourceType: to.Ptr("AzureStorage"),
	// 	},
	// }
}
Output:

func (*ArtifactSourcesClient) List

List - Lists the artifact sources in a resource group. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - ArtifactSourcesClientListOptions contains the optional parameters for the ArtifactSourcesClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/artifactsources_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewArtifactSourcesClient().List(ctx, "myResourceGroup", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ArtifactSourceArray = []*armdeploymentmanager.ArtifactSource{
	// 	{
	// 		Name: to.Ptr("TemplatesArtifactSource"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/artifactSources"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ArtifactSourceProperties{
	// 			Authentication: &armdeploymentmanager.SasAuthentication{
	// 				Type: to.Ptr("Sas"),
	// 				Properties: &armdeploymentmanager.SasProperties{
	// 					SasURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/templates?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
	// 				},
	// 			},
	// 			SourceType: to.Ptr("AzureStorage"),
	// 		},
	// 	},
	// 	{
	// 		Name: to.Ptr("BinariesArtifactSource"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/artifactSources"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ArtifactSourceProperties{
	// 			ArtifactRoot: to.Ptr("builds/1.0.0.1"),
	// 			Authentication: &armdeploymentmanager.SasAuthentication{
	// 				Type: to.Ptr("Sas"),
	// 				Properties: &armdeploymentmanager.SasProperties{
	// 					SasURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/binaries?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
	// 				},
	// 			},
	// 			SourceType: to.Ptr("AzureStorage"),
	// 		},
	// }}
}
Output:

type ArtifactSourcesClientCreateOrUpdateOptions added in v0.2.0

type ArtifactSourcesClientCreateOrUpdateOptions struct {
	// Source object that defines the resource.
	ArtifactSourceInfo *ArtifactSource
}

ArtifactSourcesClientCreateOrUpdateOptions contains the optional parameters for the ArtifactSourcesClient.CreateOrUpdate method.

type ArtifactSourcesClientCreateOrUpdateResponse added in v0.2.0

type ArtifactSourcesClientCreateOrUpdateResponse struct {
	// The resource that defines the source location where the artifacts are located.
	ArtifactSource
}

ArtifactSourcesClientCreateOrUpdateResponse contains the response from method ArtifactSourcesClient.CreateOrUpdate.

type ArtifactSourcesClientDeleteOptions added in v0.2.0

type ArtifactSourcesClientDeleteOptions struct {
}

ArtifactSourcesClientDeleteOptions contains the optional parameters for the ArtifactSourcesClient.Delete method.

type ArtifactSourcesClientDeleteResponse added in v0.2.0

type ArtifactSourcesClientDeleteResponse struct {
}

ArtifactSourcesClientDeleteResponse contains the response from method ArtifactSourcesClient.Delete.

type ArtifactSourcesClientGetOptions added in v0.2.0

type ArtifactSourcesClientGetOptions struct {
}

ArtifactSourcesClientGetOptions contains the optional parameters for the ArtifactSourcesClient.Get method.

type ArtifactSourcesClientGetResponse added in v0.2.0

type ArtifactSourcesClientGetResponse struct {
	// The resource that defines the source location where the artifacts are located.
	ArtifactSource
}

ArtifactSourcesClientGetResponse contains the response from method ArtifactSourcesClient.Get.

type ArtifactSourcesClientListOptions added in v0.2.0

type ArtifactSourcesClientListOptions struct {
}

ArtifactSourcesClientListOptions contains the optional parameters for the ArtifactSourcesClient.List method.

type ArtifactSourcesClientListResponse added in v0.2.0

type ArtifactSourcesClientListResponse struct {
	// The list of artifact sources.
	ArtifactSourceArray []*ArtifactSource
}

ArtifactSourcesClientListResponse contains the response from method ArtifactSourcesClient.List.

type Authentication

type Authentication struct {
	// REQUIRED; The authentication type
	Type *string
}

Authentication - Defines the authentication method and properties to access the artifacts.

func (*Authentication) GetAuthentication

func (a *Authentication) GetAuthentication() *Authentication

GetAuthentication implements the AuthenticationClassification interface for type Authentication.

func (Authentication) MarshalJSON added in v0.5.0

func (a Authentication) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Authentication.

func (*Authentication) UnmarshalJSON

func (a *Authentication) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Authentication.

type AuthenticationClassification

type AuthenticationClassification interface {
	// GetAuthentication returns the Authentication content of the underlying type.
	GetAuthentication() *Authentication
}

AuthenticationClassification provides polymorphic access to related types. Call the interface's GetAuthentication() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *Authentication, *SasAuthentication

type ClientFactory added in v0.5.0

type ClientFactory struct {
	// contains filtered or unexported fields
}

ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.

func NewClientFactory added in v0.5.0

func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error)

NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ClientFactory) NewArtifactSourcesClient added in v0.5.0

func (c *ClientFactory) NewArtifactSourcesClient() *ArtifactSourcesClient

NewArtifactSourcesClient creates a new instance of ArtifactSourcesClient.

func (*ClientFactory) NewOperationsClient added in v0.5.0

func (c *ClientFactory) NewOperationsClient() *OperationsClient

NewOperationsClient creates a new instance of OperationsClient.

func (*ClientFactory) NewRolloutsClient added in v0.5.0

func (c *ClientFactory) NewRolloutsClient() *RolloutsClient

NewRolloutsClient creates a new instance of RolloutsClient.

func (*ClientFactory) NewServiceTopologiesClient added in v0.5.0

func (c *ClientFactory) NewServiceTopologiesClient() *ServiceTopologiesClient

NewServiceTopologiesClient creates a new instance of ServiceTopologiesClient.

func (*ClientFactory) NewServiceUnitsClient added in v0.5.0

func (c *ClientFactory) NewServiceUnitsClient() *ServiceUnitsClient

NewServiceUnitsClient creates a new instance of ServiceUnitsClient.

func (*ClientFactory) NewServicesClient added in v0.5.0

func (c *ClientFactory) NewServicesClient() *ServicesClient

NewServicesClient creates a new instance of ServicesClient.

func (*ClientFactory) NewStepsClient added in v0.5.0

func (c *ClientFactory) NewStepsClient() *StepsClient

NewStepsClient creates a new instance of StepsClient.

type CloudErrorBody

type CloudErrorBody struct {
	// More detailed error information.
	Details []*CloudErrorBody

	// Error target
	Target *string

	// READ-ONLY; Error code string.
	Code *string

	// READ-ONLY; Descriptive error information.
	Message *string
}

CloudErrorBody - Detailed error information of any failure.

func (CloudErrorBody) MarshalJSON

func (c CloudErrorBody) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type CloudErrorBody.

func (*CloudErrorBody) UnmarshalJSON added in v0.5.0

func (c *CloudErrorBody) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type CloudErrorBody.

type DeploymentMode

type DeploymentMode string

DeploymentMode - Describes the type of ARM deployment to be performed on the resource.

const (
	DeploymentModeComplete    DeploymentMode = "Complete"
	DeploymentModeIncremental DeploymentMode = "Incremental"
)

func PossibleDeploymentModeValues

func PossibleDeploymentModeValues() []DeploymentMode

PossibleDeploymentModeValues returns the possible values for the DeploymentMode const type.

type HealthCheckStepAttributes

type HealthCheckStepAttributes struct {
	// REQUIRED; The duration in ISO 8601 format for which the resource is expected to be continuously healthy. If maxElasticDuration
	// is specified, healthy state duration is enforced after the detection of first
	// healthy signal.
	HealthyStateDuration *string

	// REQUIRED; The type of health check.
	Type *string

	// The duration in ISO 8601 format for which the health check waits for the resource to become healthy. Health check fails
	// if it doesn't. Health check starts to enforce healthyStateDuration once resource
	// becomes healthy.
	MaxElasticDuration *string

	// The duration in ISO 8601 format for which health check waits idly without any checks.
	WaitDuration *string
}

HealthCheckStepAttributes - The attributes for the health check step.

func (*HealthCheckStepAttributes) GetHealthCheckStepAttributes

func (h *HealthCheckStepAttributes) GetHealthCheckStepAttributes() *HealthCheckStepAttributes

GetHealthCheckStepAttributes implements the HealthCheckStepAttributesClassification interface for type HealthCheckStepAttributes.

func (HealthCheckStepAttributes) MarshalJSON added in v0.5.0

func (h HealthCheckStepAttributes) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type HealthCheckStepAttributes.

func (*HealthCheckStepAttributes) UnmarshalJSON

func (h *HealthCheckStepAttributes) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type HealthCheckStepAttributes.

type HealthCheckStepAttributesClassification

type HealthCheckStepAttributesClassification interface {
	// GetHealthCheckStepAttributes returns the HealthCheckStepAttributes content of the underlying type.
	GetHealthCheckStepAttributes() *HealthCheckStepAttributes
}

HealthCheckStepAttributesClassification provides polymorphic access to related types. Call the interface's GetHealthCheckStepAttributes() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *HealthCheckStepAttributes, *RestHealthCheckStepAttributes

type HealthCheckStepProperties

type HealthCheckStepProperties struct {
	// REQUIRED; The health check step attributes
	Attributes HealthCheckStepAttributesClassification

	// REQUIRED; The type of step.
	StepType *StepType
}

HealthCheckStepProperties - Defines the properties of a health check step.

func (*HealthCheckStepProperties) GetStepProperties added in v0.2.0

func (h *HealthCheckStepProperties) GetStepProperties() *StepProperties

GetStepProperties implements the StepPropertiesClassification interface for type HealthCheckStepProperties.

func (HealthCheckStepProperties) MarshalJSON

func (h HealthCheckStepProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type HealthCheckStepProperties.

func (*HealthCheckStepProperties) UnmarshalJSON

func (h *HealthCheckStepProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type HealthCheckStepProperties.

type Identity

type Identity struct {
	// REQUIRED; The list of identities.
	IdentityIDs []*string

	// REQUIRED; The identity type.
	Type *string
}

Identity for the resource.

func (Identity) MarshalJSON

func (i Identity) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Identity.

func (*Identity) UnmarshalJSON added in v0.5.0

func (i *Identity) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Identity.

type Message

type Message struct {
	// READ-ONLY; The actual message text.
	Message *string

	// READ-ONLY; Time in UTC this message was provided.
	TimeStamp *time.Time
}

Message - Supplementary contextual messages during a rollout.

func (Message) MarshalJSON

func (m Message) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Message.

func (*Message) UnmarshalJSON

func (m *Message) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Message.

type Operation

type Operation struct {
	// The display name of the operation.
	Display *OperationDetail

	// The name of the operation.
	Name *string

	// The origin of the operation.
	Origin *string

	// The properties of the operation.
	Properties any
}

Operation - Represents an operation that can be performed on the service.

func (Operation) MarshalJSON added in v0.5.0

func (o Operation) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Operation.

func (*Operation) UnmarshalJSON added in v0.5.0

func (o *Operation) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Operation.

type OperationDetail

type OperationDetail struct {
	// The description of the operation.
	Description *string

	// The name of the operation.
	Operation *string

	// The name of the provider that supports the operation.
	Provider *string

	// The resource type on which this operation can be performed.
	Resource *string
}

OperationDetail - The detail about an operation.

func (OperationDetail) MarshalJSON added in v0.5.0

func (o OperationDetail) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationDetail.

func (*OperationDetail) UnmarshalJSON added in v0.5.0

func (o *OperationDetail) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationDetail.

type OperationsClient

type OperationsClient struct {
	// contains filtered or unexported fields
}

OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.

func NewOperationsClient

func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)

NewOperationsClient creates a new instance of OperationsClient with the specified values.

  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*OperationsClient) List

List - Lists the supported operations. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • options - OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/operations_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewOperationsClient().List(ctx, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.OperationsList = armdeploymentmanager.OperationsList{
	// 	Value: &armdeploymentmanager.Operation{
	// 	},
	// }
}
Output:

type OperationsClientListOptions added in v0.2.0

type OperationsClientListOptions struct {
}

OperationsClientListOptions contains the optional parameters for the OperationsClient.List method.

type OperationsClientListResponse added in v0.2.0

type OperationsClientListResponse struct {
	// The operations response.
	OperationsList
}

OperationsClientListResponse contains the response from method OperationsClient.List.

type OperationsList

type OperationsList struct {
	// The list of supported operations
	Value *Operation
}

OperationsList - The operations response.

func (OperationsList) MarshalJSON added in v0.5.0

func (o OperationsList) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type OperationsList.

func (*OperationsList) UnmarshalJSON added in v0.5.0

func (o *OperationsList) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type OperationsList.

type PrePostStep

type PrePostStep struct {
	// REQUIRED; The resource Id of the step to be run.
	StepID *string
}

PrePostStep - The properties that define a step.

func (PrePostStep) MarshalJSON added in v0.5.0

func (p PrePostStep) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type PrePostStep.

func (*PrePostStep) UnmarshalJSON added in v0.5.0

func (p *PrePostStep) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type PrePostStep.

type Resource

type Resource struct {
	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

Resource - Common fields that are returned in the response for all Azure Resource Manager resources

func (Resource) MarshalJSON

func (r Resource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Resource.

func (*Resource) UnmarshalJSON

func (r *Resource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Resource.

type ResourceOperation

type ResourceOperation struct {
	// Name of the resource as specified in the artifacts. For ARM resources, this is the name of the resource specified in the
	// template.
	ResourceName *string

	// Type of the resource as specified in the artifacts. For ARM resources, this is the type of the resource specified in the
	// template.
	ResourceType *string

	// READ-ONLY; Unique identifier of the operation. For ARM resources, this is the operationId obtained from ARM service.
	OperationID *string

	// READ-ONLY; State of the resource deployment. For ARM resources, this is the current provisioning state of the resource.
	ProvisioningState *string

	// READ-ONLY; Http status code of the operation.
	StatusCode *string

	// READ-ONLY; Descriptive information of the resource operation.
	StatusMessage *string
}

ResourceOperation - Individual resource operation information.

func (ResourceOperation) MarshalJSON added in v0.5.0

func (r ResourceOperation) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ResourceOperation.

func (*ResourceOperation) UnmarshalJSON added in v0.5.0

func (r *ResourceOperation) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ResourceOperation.

type RestAuthLocation

type RestAuthLocation string

RestAuthLocation - The location of the authentication key/value pair in the request.

const (
	RestAuthLocationHeader RestAuthLocation = "Header"
	RestAuthLocationQuery  RestAuthLocation = "Query"
)

func PossibleRestAuthLocationValues

func PossibleRestAuthLocationValues() []RestAuthLocation

PossibleRestAuthLocationValues returns the possible values for the RestAuthLocation const type.

type RestAuthType

type RestAuthType string

RestAuthType - The authentication type.

const (
	RestAuthTypeAPIKey          RestAuthType = "ApiKey"
	RestAuthTypeRolloutIdentity RestAuthType = "RolloutIdentity"
)

func PossibleRestAuthTypeValues

func PossibleRestAuthTypeValues() []RestAuthType

PossibleRestAuthTypeValues returns the possible values for the RestAuthType const type.

type RestHealthCheck

type RestHealthCheck struct {
	// REQUIRED; A unique name for this check.
	Name *string

	// REQUIRED; The request to the health provider.
	Request *RestRequest

	// The expected response from the health provider. If no expected response is provided, the default is to expect the received
	// response to have an HTTP status code of 200 OK.
	Response *RestResponse
}

RestHealthCheck - A REST based health check

func (RestHealthCheck) MarshalJSON added in v0.5.0

func (r RestHealthCheck) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestHealthCheck.

func (*RestHealthCheck) UnmarshalJSON added in v0.5.0

func (r *RestHealthCheck) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestHealthCheck.

type RestHealthCheckStepAttributes

type RestHealthCheckStepAttributes struct {
	// REQUIRED; The duration in ISO 8601 format for which the resource is expected to be continuously healthy. If maxElasticDuration
	// is specified, healthy state duration is enforced after the detection of first
	// healthy signal.
	HealthyStateDuration *string

	// REQUIRED; The type of health check.
	Type *string

	// The duration in ISO 8601 format for which the health check waits for the resource to become healthy. Health check fails
	// if it doesn't. Health check starts to enforce healthyStateDuration once resource
	// becomes healthy.
	MaxElasticDuration *string

	// The REST health check parameters.
	Properties *RestParameters

	// The duration in ISO 8601 format for which health check waits idly without any checks.
	WaitDuration *string
}

RestHealthCheckStepAttributes - Defines the REST health check step properties.

func (*RestHealthCheckStepAttributes) GetHealthCheckStepAttributes added in v0.2.0

func (r *RestHealthCheckStepAttributes) GetHealthCheckStepAttributes() *HealthCheckStepAttributes

GetHealthCheckStepAttributes implements the HealthCheckStepAttributesClassification interface for type RestHealthCheckStepAttributes.

func (RestHealthCheckStepAttributes) MarshalJSON

func (r RestHealthCheckStepAttributes) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestHealthCheckStepAttributes.

func (*RestHealthCheckStepAttributes) UnmarshalJSON

func (r *RestHealthCheckStepAttributes) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestHealthCheckStepAttributes.

type RestMatchQuantifier

type RestMatchQuantifier string

RestMatchQuantifier - Indicates whether any or all of the expressions should match with the response content.

const (
	RestMatchQuantifierAll RestMatchQuantifier = "All"
	RestMatchQuantifierAny RestMatchQuantifier = "Any"
)

func PossibleRestMatchQuantifierValues

func PossibleRestMatchQuantifierValues() []RestMatchQuantifier

PossibleRestMatchQuantifierValues returns the possible values for the RestMatchQuantifier const type.

type RestParameters

type RestParameters struct {
	// REQUIRED; The list of checks that form the health check step.
	HealthChecks []*RestHealthCheck
}

RestParameters - The parameters for the REST health check.

func (RestParameters) MarshalJSON

func (r RestParameters) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestParameters.

func (*RestParameters) UnmarshalJSON added in v0.5.0

func (r *RestParameters) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestParameters.

type RestRequest

type RestRequest struct {
	// REQUIRED; The authentication information required in the request to the health provider.
	Authentication RestRequestAuthenticationClassification

	// REQUIRED; The HTTP method to use for the request.
	Method *RestRequestMethod

	// REQUIRED; The HTTP URI to use for the request.
	URI *string
}

RestRequest - The properties that make up a REST request

func (RestRequest) MarshalJSON

func (r RestRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestRequest.

func (*RestRequest) UnmarshalJSON

func (r *RestRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestRequest.

type RestRequestAuthentication

type RestRequestAuthentication struct {
	// REQUIRED; The authentication type.
	Type *RestAuthType
}

RestRequestAuthentication - The authentication information required in the REST health check request to the health provider.

func (*RestRequestAuthentication) GetRestRequestAuthentication

func (r *RestRequestAuthentication) GetRestRequestAuthentication() *RestRequestAuthentication

GetRestRequestAuthentication implements the RestRequestAuthenticationClassification interface for type RestRequestAuthentication.

func (RestRequestAuthentication) MarshalJSON added in v0.5.0

func (r RestRequestAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestRequestAuthentication.

func (*RestRequestAuthentication) UnmarshalJSON

func (r *RestRequestAuthentication) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestRequestAuthentication.

type RestRequestAuthenticationClassification

type RestRequestAuthenticationClassification interface {
	// GetRestRequestAuthentication returns the RestRequestAuthentication content of the underlying type.
	GetRestRequestAuthentication() *RestRequestAuthentication
}

RestRequestAuthenticationClassification provides polymorphic access to related types. Call the interface's GetRestRequestAuthentication() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *APIKeyAuthentication, *RestRequestAuthentication, *RolloutIdentityAuthentication

type RestRequestMethod

type RestRequestMethod string

RestRequestMethod - The HTTP method to use for the request.

const (
	RestRequestMethodGET  RestRequestMethod = "GET"
	RestRequestMethodPOST RestRequestMethod = "POST"
)

func PossibleRestRequestMethodValues

func PossibleRestRequestMethodValues() []RestRequestMethod

PossibleRestRequestMethodValues returns the possible values for the RestRequestMethod const type.

type RestResponse

type RestResponse struct {
	// The regular expressions to match the response content with.
	Regex *RestResponseRegex

	// The HTTP status codes expected in a successful health check response. The response is expected to match one of the given
	// status codes. If no expected status codes are provided, default expected status
	// code is 200 OK.
	SuccessStatusCodes []*string
}

RestResponse - The properties that make up the expected REST response

func (RestResponse) MarshalJSON

func (r RestResponse) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestResponse.

func (*RestResponse) UnmarshalJSON added in v0.5.0

func (r *RestResponse) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestResponse.

type RestResponseRegex

type RestResponseRegex struct {
	// Indicates whether any or all of the expressions should match with the response content.
	MatchQuantifier *RestMatchQuantifier

	// The list of regular expressions.
	Matches []*string
}

RestResponseRegex - The regular expressions to match the response content with.

func (RestResponseRegex) MarshalJSON

func (r RestResponseRegex) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RestResponseRegex.

func (*RestResponseRegex) UnmarshalJSON added in v0.5.0

func (r *RestResponseRegex) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RestResponseRegex.

type Rollout

type Rollout struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// Identity for the resource.
	Identity *Identity

	// The properties that define a rollout.
	Properties *RolloutProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

Rollout - Defines the rollout.

func (Rollout) MarshalJSON

func (r Rollout) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Rollout.

func (*Rollout) UnmarshalJSON

func (r *Rollout) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Rollout.

type RolloutIdentityAuthentication

type RolloutIdentityAuthentication struct {
	// REQUIRED; The authentication type.
	Type *RestAuthType
}

RolloutIdentityAuthentication - RolloutIdentity uses the user-assigned managed identity authentication context specified in the Identity property during rollout creation.

func (*RolloutIdentityAuthentication) GetRestRequestAuthentication added in v0.2.0

func (r *RolloutIdentityAuthentication) GetRestRequestAuthentication() *RestRequestAuthentication

GetRestRequestAuthentication implements the RestRequestAuthenticationClassification interface for type RolloutIdentityAuthentication.

func (RolloutIdentityAuthentication) MarshalJSON

func (r RolloutIdentityAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutIdentityAuthentication.

func (*RolloutIdentityAuthentication) UnmarshalJSON added in v0.2.0

func (r *RolloutIdentityAuthentication) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutIdentityAuthentication.

type RolloutOperationInfo

type RolloutOperationInfo struct {
	// READ-ONLY; The start time of the rollout in UTC. This property will not be set if the rollout has not completed yet.
	EndTime *time.Time

	// READ-ONLY; The detailed error information for any failure.
	Error *CloudErrorBody

	// READ-ONLY; The ordinal count of the number of retry attempts on a rollout. 0 if no retries of the rollout have been performed.
	// If the rollout is updated with a PUT, this count is reset to 0.
	RetryAttempt *int32

	// READ-ONLY; True, if all steps that succeeded on the previous run/attempt were chosen to be skipped in this retry attempt.
	// False, otherwise.
	SkipSucceededOnRetry *bool

	// READ-ONLY; The start time of the rollout in UTC.
	StartTime *time.Time
}

RolloutOperationInfo - Detailed runtime information of the rollout.

func (RolloutOperationInfo) MarshalJSON

func (r RolloutOperationInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutOperationInfo.

func (*RolloutOperationInfo) UnmarshalJSON

func (r *RolloutOperationInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutOperationInfo.

type RolloutProperties

type RolloutProperties struct {
	// REQUIRED; The version of the build being deployed.
	BuildVersion *string

	// REQUIRED; The list of step groups that define the orchestration.
	StepGroups []*StepGroup

	// REQUIRED; The resource Id of the service topology from which service units are being referenced in step groups to be deployed.
	TargetServiceTopologyID *string

	// The reference to the artifact source resource Id where the payload is located.
	ArtifactSourceID *string

	// READ-ONLY; Operational information of the rollout.
	OperationInfo *RolloutOperationInfo

	// READ-ONLY; The detailed information on the services being deployed.
	Services []*Service

	// READ-ONLY; The current status of the rollout.
	Status *string

	// READ-ONLY; The cardinal count of total number of retries performed on the rollout at a given time.
	TotalRetryAttempts *int32
}

RolloutProperties - The properties that define a rollout.

func (RolloutProperties) MarshalJSON added in v0.2.0

func (r RolloutProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutProperties.

func (*RolloutProperties) UnmarshalJSON added in v0.5.0

func (r *RolloutProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutProperties.

type RolloutPropertiesAutoGenerated

type RolloutPropertiesAutoGenerated struct {
	// READ-ONLY; Operational information of the rollout.
	OperationInfo *RolloutOperationInfo

	// READ-ONLY; The detailed information on the services being deployed.
	Services []*Service

	// READ-ONLY; The current status of the rollout.
	Status *string

	// READ-ONLY; The cardinal count of total number of retries performed on the rollout at a given time.
	TotalRetryAttempts *int32
}

RolloutPropertiesAutoGenerated - Defines the properties of a rollout.

func (RolloutPropertiesAutoGenerated) MarshalJSON

func (r RolloutPropertiesAutoGenerated) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutPropertiesAutoGenerated.

func (*RolloutPropertiesAutoGenerated) UnmarshalJSON added in v0.5.0

func (r *RolloutPropertiesAutoGenerated) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutPropertiesAutoGenerated.

type RolloutRequest

type RolloutRequest struct {
	// REQUIRED; Identity for the resource.
	Identity *Identity

	// REQUIRED; The geo-location where the resource lives
	Location *string

	// REQUIRED; Defines the properties that make up a rollout request.
	Properties *RolloutRequestProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

RolloutRequest - Defines the PUT rollout request body.

func (RolloutRequest) MarshalJSON

func (r RolloutRequest) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutRequest.

func (*RolloutRequest) UnmarshalJSON

func (r *RolloutRequest) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutRequest.

type RolloutRequestProperties

type RolloutRequestProperties struct {
	// REQUIRED; The version of the build being deployed.
	BuildVersion *string

	// REQUIRED; The list of step groups that define the orchestration.
	StepGroups []*StepGroup

	// REQUIRED; The resource Id of the service topology from which service units are being referenced in step groups to be deployed.
	TargetServiceTopologyID *string

	// The reference to the artifact source resource Id where the payload is located.
	ArtifactSourceID *string
}

RolloutRequestProperties - The properties for defining a rollout.

func (RolloutRequestProperties) MarshalJSON

func (r RolloutRequestProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutRequestProperties.

func (*RolloutRequestProperties) UnmarshalJSON added in v0.5.0

func (r *RolloutRequestProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutRequestProperties.

type RolloutStep

type RolloutStep struct {
	// REQUIRED; Name of the step.
	Name *string

	// The step group the current step is part of.
	StepGroup *string

	// READ-ONLY; Supplementary informative messages during rollout.
	Messages []*Message

	// READ-ONLY; Detailed information of specific action execution.
	OperationInfo *StepOperationInfo

	// READ-ONLY; Set of resource operations that were performed, if any, on an Azure resource.
	ResourceOperations []*ResourceOperation

	// READ-ONLY; Current state of the step.
	Status *string
}

RolloutStep - Defines a specific step on a target service unit.

func (RolloutStep) MarshalJSON

func (r RolloutStep) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type RolloutStep.

func (*RolloutStep) UnmarshalJSON added in v0.5.0

func (r *RolloutStep) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type RolloutStep.

type RolloutsClient

type RolloutsClient struct {
	// contains filtered or unexported fields
}

RolloutsClient contains the methods for the Rollouts group. Don't use this type directly, use NewRolloutsClient() instead.

func NewRolloutsClient

func NewRolloutsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*RolloutsClient, error)

NewRolloutsClient creates a new instance of RolloutsClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*RolloutsClient) BeginCreateOrUpdate

func (client *RolloutsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, rolloutName string, options *RolloutsClientBeginCreateOrUpdateOptions) (*runtime.Poller[RolloutsClientCreateOrUpdateResponse], error)

BeginCreateOrUpdate - This is an asynchronous operation and can be polled to completion using the location header returned by this operation. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • rolloutName - The rollout name.
  • options - RolloutsClientBeginCreateOrUpdateOptions contains the optional parameters for the RolloutsClient.BeginCreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollout_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewRolloutsClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myRollout", &armdeploymentmanager.RolloutsClientBeginCreateOrUpdateOptions{RolloutRequest: &armdeploymentmanager.RolloutRequest{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Identity: &armdeploymentmanager.Identity{
			Type: to.Ptr("userAssigned"),
			IdentityIDs: []*string{
				to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
		},
		Properties: &armdeploymentmanager.RolloutRequestProperties{
			ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
			BuildVersion:     to.Ptr("1.0.0.1"),
			StepGroups: []*armdeploymentmanager.StepGroup{
				{
					Name:               to.Ptr("FirstRegion"),
					DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit1'"),
					PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep1"),
						}},
					PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep1"),
						},
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
						}},
				},
				{
					Name: to.Ptr("SecondRegion"),
					DependsOnStepGroups: []*string{
						to.Ptr("FirstRegion")},
					DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit2'"),
					PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep5"),
						}},
					PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep3"),
						},
						{
							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep4"),
						}},
				}},
			TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
		},
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}
Output:

func (*RolloutsClient) Cancel

func (client *RolloutsClient) Cancel(ctx context.Context, resourceGroupName string, rolloutName string, options *RolloutsClientCancelOptions) (RolloutsClientCancelResponse, error)

Cancel - Only running rollouts can be canceled. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • rolloutName - The rollout name.
  • options - RolloutsClientCancelOptions contains the optional parameters for the RolloutsClient.Cancel method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollout_post_cancel.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewRolloutsClient().Cancel(ctx, "myResourceGroup", "myRollout", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Rollout = armdeploymentmanager.Rollout{
	// 	Name: to.Ptr("myRollout"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/rollouts"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Identity: &armdeploymentmanager.Identity{
	// 		Type: to.Ptr("userAssigned"),
	// 		IdentityIDs: []*string{
	// 			to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
	// 		},
	// 		Properties: &armdeploymentmanager.RolloutProperties{
	// 			OperationInfo: &armdeploymentmanager.RolloutOperationInfo{
	// 				RetryAttempt: to.Ptr[int32](0),
	// 				StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 			},
	// 			Services: []*armdeploymentmanager.Service{
	// 				{
	// 					TargetLocation: to.Ptr("centralus"),
	// 					TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
	// 					Name: to.Ptr("myService1"),
	// 					ServiceUnits: []*armdeploymentmanager.ServiceUnit{
	// 						{
	// 							DeploymentMode: to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
	// 							TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
	// 							Name: to.Ptr("myTopologyUni1"),
	// 							Steps: []*armdeploymentmanager.RolloutStep{
	// 								{
	// 									Name: to.Ptr("preDeploymentStep1"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:35:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 									},
	// 									Status: to.Ptr("succeeded"),
	// 								},
	// 								{
	// 									Name: to.Ptr("preDeploymentStep2"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:37:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:36:56.386Z"); return t}()),
	// 									},
	// 									Status: to.Ptr("succeeded"),
	// 								},
	// 								{
	// 									Name: to.Ptr("deploy"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										LastUpdatedTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:39:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:38:56.386Z"); return t}()),
	// 									},
	// 									ResourceOperations: []*armdeploymentmanager.ResourceOperation{
	// 										{
	// 											OperationID: to.Ptr("20FC5A21382DA306"),
	// 											ProvisioningState: to.Ptr("Succeeded"),
	// 											ResourceName: to.Ptr("keyVaultcentralus"),
	// 											ResourceType: to.Ptr("Microsoft.KeyVault/vaults"),
	// 											StatusCode: to.Ptr("OK"),
	// 											StatusMessage: to.Ptr(""),
	// 									}},
	// 									Status: to.Ptr("running"),
	// 							}},
	// 					}},
	// 			}},
	// 			Status: to.Ptr("Canceling"),
	// 			TotalRetryAttempts: to.Ptr[int32](0),
	// 			ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
	// 			BuildVersion: to.Ptr("1.0.0.1"),
	// 			StepGroups: []*armdeploymentmanager.StepGroup{
	// 				{
	// 					Name: to.Ptr("FirstRegion"),
	// 					DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit1'"),
	// 					PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep1"),
	// 					}},
	// 					PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep1"),
	// 						},
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
	// 					}},
	// 				},
	// 				{
	// 					Name: to.Ptr("SecondRegion"),
	// 					DependsOnStepGroups: []*string{
	// 						to.Ptr("FirstRegion")},
	// 						DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit2'"),
	// 						PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep5"),
	// 						}},
	// 						PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep3"),
	// 							},
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep4"),
	// 						}},
	// 				}},
	// 				TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
	// 			},
	// 		}
}
Output:

func (*RolloutsClient) Delete

func (client *RolloutsClient) Delete(ctx context.Context, resourceGroupName string, rolloutName string, options *RolloutsClientDeleteOptions) (RolloutsClientDeleteResponse, error)

Delete - Only rollouts in terminal state can be deleted. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • rolloutName - The rollout name.
  • options - RolloutsClientDeleteOptions contains the optional parameters for the RolloutsClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollout_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewRolloutsClient().Delete(ctx, "myResourceGroup", "myRollout", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*RolloutsClient) Get

func (client *RolloutsClient) Get(ctx context.Context, resourceGroupName string, rolloutName string, options *RolloutsClientGetOptions) (RolloutsClientGetResponse, error)

Get - Gets detailed information of a rollout. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • rolloutName - The rollout name.
  • options - RolloutsClientGetOptions contains the optional parameters for the RolloutsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollout_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewRolloutsClient().Get(ctx, "myResourceGroup", "myRollout", &armdeploymentmanager.RolloutsClientGetOptions{RetryAttempt: nil})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Rollout = armdeploymentmanager.Rollout{
	// 	Name: to.Ptr("myRollout"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/rollouts"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Identity: &armdeploymentmanager.Identity{
	// 		Type: to.Ptr("userAssigned"),
	// 		IdentityIDs: []*string{
	// 			to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
	// 		},
	// 		Properties: &armdeploymentmanager.RolloutProperties{
	// 			OperationInfo: &armdeploymentmanager.RolloutOperationInfo{
	// 				RetryAttempt: to.Ptr[int32](0),
	// 				StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 			},
	// 			Services: []*armdeploymentmanager.Service{
	// 				{
	// 					TargetLocation: to.Ptr("centralus"),
	// 					TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
	// 					Name: to.Ptr("myService1"),
	// 					ServiceUnits: []*armdeploymentmanager.ServiceUnit{
	// 						{
	// 							DeploymentMode: to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
	// 							TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
	// 							Name: to.Ptr("myTopologyUni1"),
	// 							Steps: []*armdeploymentmanager.RolloutStep{
	// 								{
	// 									Name: to.Ptr("preDeploymentStep1"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:35:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 									},
	// 									Status: to.Ptr("succeeded"),
	// 								},
	// 								{
	// 									Name: to.Ptr("preDeploymentStep2"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:37:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:36:56.386Z"); return t}()),
	// 									},
	// 									Status: to.Ptr("succeeded"),
	// 								},
	// 								{
	// 									Name: to.Ptr("deploy"),
	// 									OperationInfo: &armdeploymentmanager.StepOperationInfo{
	// 										LastUpdatedTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:39:28.556Z"); return t}()),
	// 										StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:38:56.386Z"); return t}()),
	// 									},
	// 									ResourceOperations: []*armdeploymentmanager.ResourceOperation{
	// 										{
	// 											OperationID: to.Ptr("20FC5A21382DA306"),
	// 											ProvisioningState: to.Ptr("Succeeded"),
	// 											ResourceName: to.Ptr("keyVaultcentralus"),
	// 											ResourceType: to.Ptr("Microsoft.KeyVault/vaults"),
	// 											StatusCode: to.Ptr("OK"),
	// 											StatusMessage: to.Ptr(""),
	// 									}},
	// 									Status: to.Ptr("running"),
	// 							}},
	// 					}},
	// 			}},
	// 			Status: to.Ptr("Running"),
	// 			TotalRetryAttempts: to.Ptr[int32](0),
	// 			ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
	// 			BuildVersion: to.Ptr("1.0.0.1"),
	// 			StepGroups: []*armdeploymentmanager.StepGroup{
	// 				{
	// 					Name: to.Ptr("FirstRegion"),
	// 					DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit1'"),
	// 					PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep1"),
	// 					}},
	// 					PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep1"),
	// 						},
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
	// 					}},
	// 				},
	// 				{
	// 					Name: to.Ptr("SecondRegion"),
	// 					DependsOnStepGroups: []*string{
	// 						to.Ptr("FirstRegion")},
	// 						DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit2'"),
	// 						PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep5"),
	// 						}},
	// 						PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep3"),
	// 							},
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep4"),
	// 						}},
	// 				}},
	// 				TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
	// 			},
	// 		}
}
Output:

func (*RolloutsClient) List

func (client *RolloutsClient) List(ctx context.Context, resourceGroupName string, options *RolloutsClientListOptions) (RolloutsClientListResponse, error)

List - Lists the rollouts in a resource group. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - RolloutsClientListOptions contains the optional parameters for the RolloutsClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollouts_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewRolloutsClient().List(ctx, "myResourceGroup", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.RolloutArray = []*armdeploymentmanager.Rollout{
	// 	{
	// 		Name: to.Ptr("CanaryRollout"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/rollouts"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Identity: &armdeploymentmanager.Identity{
	// 			Type: to.Ptr("userAssigned"),
	// 			IdentityIDs: []*string{
	// 				to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
	// 			},
	// 			Properties: &armdeploymentmanager.RolloutProperties{
	// 				OperationInfo: &armdeploymentmanager.RolloutOperationInfo{
	// 					EndTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:43:55.010Z"); return t}()),
	// 					RetryAttempt: to.Ptr[int32](0),
	// 					StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 				},
	// 				Status: to.Ptr("Succeeded"),
	// 				TotalRetryAttempts: to.Ptr[int32](0),
	// 				ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/binariesArtifactSource"),
	// 				BuildVersion: to.Ptr("1.0.0.1"),
	// 				StepGroups: []*armdeploymentmanager.StepGroup{
	// 					{
	// 						Name: to.Ptr("FirstRegion"),
	// 						DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit1'"),
	// 						PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep1"),
	// 						}},
	// 						PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep1"),
	// 							},
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
	// 						}},
	// 				}},
	// 				TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
	// 			},
	// 		},
	// 		{
	// 			Name: to.Ptr("ProdRollout"),
	// 			Type: to.Ptr("Microsoft.DeploymentManager/rollouts"),
	// 			Location: to.Ptr("centralus"),
	// 			Tags: map[string]*string{
	// 			},
	// 			Identity: &armdeploymentmanager.Identity{
	// 				Type: to.Ptr("userAssigned"),
	// 				IdentityIDs: []*string{
	// 					to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
	// 				},
	// 				Properties: &armdeploymentmanager.RolloutProperties{
	// 					OperationInfo: &armdeploymentmanager.RolloutOperationInfo{
	// 						RetryAttempt: to.Ptr[int32](0),
	// 						StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2019-05-02T03:33:56.386Z"); return t}()),
	// 					},
	// 					Status: to.Ptr("Running"),
	// 					TotalRetryAttempts: to.Ptr[int32](0),
	// 					ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/binariesArtifactSource"),
	// 					BuildVersion: to.Ptr("1.0.0.1"),
	// 					StepGroups: []*armdeploymentmanager.StepGroup{
	// 						{
	// 							Name: to.Ptr("ProdRegion"),
	// 							DependsOnStepGroups: []*string{
	// 								to.Ptr("FirstRegion")},
	// 								DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit2'"),
	// 								PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 									{
	// 										StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep3"),
	// 								}},
	// 								PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 									{
	// 										StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep"),
	// 									},
	// 									{
	// 										StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
	// 								}},
	// 						}},
	// 						TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
	// 					},
	// 			}}
}
Output:

func (*RolloutsClient) Restart

func (client *RolloutsClient) Restart(ctx context.Context, resourceGroupName string, rolloutName string, options *RolloutsClientRestartOptions) (RolloutsClientRestartResponse, error)

Restart - Only failed rollouts can be restarted. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • rolloutName - The rollout name.
  • options - RolloutsClientRestartOptions contains the optional parameters for the RolloutsClient.Restart method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/rollout_post_restart.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewRolloutsClient().Restart(ctx, "myResourceGroup", "myRollout", &armdeploymentmanager.RolloutsClientRestartOptions{SkipSucceeded: to.Ptr(true)})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.Rollout = armdeploymentmanager.Rollout{
	// 	Name: to.Ptr("myRollout"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/rollouts"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Identity: &armdeploymentmanager.Identity{
	// 		Type: to.Ptr("userAssigned"),
	// 		IdentityIDs: []*string{
	// 			to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userassignedidentities/myuseridentity")},
	// 		},
	// 		Properties: &armdeploymentmanager.RolloutProperties{
	// 			OperationInfo: &armdeploymentmanager.RolloutOperationInfo{
	// 				RetryAttempt: to.Ptr[int32](1),
	// 				StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2018-08-28T03:33:56.386Z"); return t}()),
	// 			},
	// 			Status: to.Ptr("Running"),
	// 			TotalRetryAttempts: to.Ptr[int32](1),
	// 			ArtifactSourceID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
	// 			BuildVersion: to.Ptr("1.0.0.1"),
	// 			StepGroups: []*armdeploymentmanager.StepGroup{
	// 				{
	// 					Name: to.Ptr("FirstRegion"),
	// 					DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit1'"),
	// 					PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep1"),
	// 					}},
	// 					PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep1"),
	// 						},
	// 						{
	// 							StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep2"),
	// 					}},
	// 				},
	// 				{
	// 					Name: to.Ptr("SecondRegion"),
	// 					DependsOnStepGroups: []*string{
	// 						to.Ptr("FirstRegion")},
	// 						DeploymentTargetID: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/myTopology/services/myService/serviceUnits/myServiceUnit2'"),
	// 						PostDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/postDeployStep5"),
	// 						}},
	// 						PreDeploymentSteps: []*armdeploymentmanager.PrePostStep{
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep3"),
	// 							},
	// 							{
	// 								StepID: to.Ptr("Microsoft.DeploymentManager/steps/preDeployStep4"),
	// 						}},
	// 				}},
	// 				TargetServiceTopologyID: to.Ptr("/subscriptions/caac1590-e859-444f-a9e0-62091c0f5929/resourceGroups/myResourceGroup/Microsoft.DeploymentManager/serviceTopologies/myTopology"),
	// 			},
	// 		}
}
Output:

type RolloutsClientBeginCreateOrUpdateOptions added in v0.2.0

type RolloutsClientBeginCreateOrUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string

	// Source rollout request object that defines the rollout.
	RolloutRequest *RolloutRequest
}

RolloutsClientBeginCreateOrUpdateOptions contains the optional parameters for the RolloutsClient.BeginCreateOrUpdate method.

type RolloutsClientCancelOptions added in v0.2.0

type RolloutsClientCancelOptions struct {
}

RolloutsClientCancelOptions contains the optional parameters for the RolloutsClient.Cancel method.

type RolloutsClientCancelResponse added in v0.2.0

type RolloutsClientCancelResponse struct {
	// Defines the rollout.
	Rollout
}

RolloutsClientCancelResponse contains the response from method RolloutsClient.Cancel.

type RolloutsClientCreateOrUpdateResponse added in v0.2.0

type RolloutsClientCreateOrUpdateResponse struct {
	// Defines the PUT rollout request body.
	RolloutRequest
}

RolloutsClientCreateOrUpdateResponse contains the response from method RolloutsClient.BeginCreateOrUpdate.

type RolloutsClientDeleteOptions added in v0.2.0

type RolloutsClientDeleteOptions struct {
}

RolloutsClientDeleteOptions contains the optional parameters for the RolloutsClient.Delete method.

type RolloutsClientDeleteResponse added in v0.2.0

type RolloutsClientDeleteResponse struct {
}

RolloutsClientDeleteResponse contains the response from method RolloutsClient.Delete.

type RolloutsClientGetOptions added in v0.2.0

type RolloutsClientGetOptions struct {
	// Rollout retry attempt ordinal to get the result of. If not specified, result of the latest attempt will be returned.
	RetryAttempt *int32
}

RolloutsClientGetOptions contains the optional parameters for the RolloutsClient.Get method.

type RolloutsClientGetResponse added in v0.2.0

type RolloutsClientGetResponse struct {
	// Defines the rollout.
	Rollout
}

RolloutsClientGetResponse contains the response from method RolloutsClient.Get.

type RolloutsClientListOptions added in v0.2.0

type RolloutsClientListOptions struct {
}

RolloutsClientListOptions contains the optional parameters for the RolloutsClient.List method.

type RolloutsClientListResponse added in v0.2.0

type RolloutsClientListResponse struct {
	// The list of rollouts.
	RolloutArray []*Rollout
}

RolloutsClientListResponse contains the response from method RolloutsClient.List.

type RolloutsClientRestartOptions added in v0.2.0

type RolloutsClientRestartOptions struct {
	// If true, will skip all succeeded steps so far in the rollout. If false, will execute the entire rollout again regardless
	// of the current state of individual resources. Defaults to false if not
	// specified.
	SkipSucceeded *bool
}

RolloutsClientRestartOptions contains the optional parameters for the RolloutsClient.Restart method.

type RolloutsClientRestartResponse added in v0.2.0

type RolloutsClientRestartResponse struct {
	// Defines the rollout.
	Rollout
}

RolloutsClientRestartResponse contains the response from method RolloutsClient.Restart.

type SasAuthentication

type SasAuthentication struct {
	// REQUIRED; The authentication type
	Type *string

	// The SAS properties
	Properties *SasProperties
}

SasAuthentication - Defines the properties to access the artifacts using an Azure Storage SAS URI.

func (*SasAuthentication) GetAuthentication added in v0.2.0

func (s *SasAuthentication) GetAuthentication() *Authentication

GetAuthentication implements the AuthenticationClassification interface for type SasAuthentication.

func (SasAuthentication) MarshalJSON

func (s SasAuthentication) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SasAuthentication.

func (*SasAuthentication) UnmarshalJSON

func (s *SasAuthentication) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SasAuthentication.

type SasProperties

type SasProperties struct {
	// REQUIRED; The SAS URI to the Azure Storage blob container. Any offset from the root of the container to where the artifacts
	// are located can be defined in the artifactRoot.
	SasURI *string
}

SasProperties - The properties that define SAS authentication.

func (SasProperties) MarshalJSON added in v0.5.0

func (s SasProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type SasProperties.

func (*SasProperties) UnmarshalJSON added in v0.5.0

func (s *SasProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type SasProperties.

type Service

type Service struct {
	// REQUIRED; The Azure location to which the resources in the service belong to or should be deployed to.
	TargetLocation *string

	// REQUIRED; The subscription to which the resources in the service belong to or should be deployed to.
	TargetSubscriptionID *string

	// Name of the service.
	Name *string

	// The detailed information about the units that make up the service.
	ServiceUnits []*ServiceUnit
}

Service - Defines a service.

func (Service) MarshalJSON

func (s Service) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type Service.

func (*Service) UnmarshalJSON added in v0.5.0

func (s *Service) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type Service.

type ServiceProperties

type ServiceProperties struct {
	// REQUIRED; The Azure location to which the resources in the service belong to or should be deployed to.
	TargetLocation *string

	// REQUIRED; The subscription to which the resources in the service belong to or should be deployed to.
	TargetSubscriptionID *string
}

ServiceProperties - The properties of a service.

func (ServiceProperties) MarshalJSON

func (s ServiceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceProperties.

func (*ServiceProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceProperties.

type ServiceResource

type ServiceResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// REQUIRED; The properties that define a service in a service topology.
	Properties *ServiceResourceProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

ServiceResource - The resource representation of a service in a service topology.

func (ServiceResource) MarshalJSON

func (s ServiceResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceResource.

func (*ServiceResource) UnmarshalJSON

func (s *ServiceResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceResource.

type ServiceResourceProperties

type ServiceResourceProperties struct {
	// REQUIRED; The Azure location to which the resources in the service belong to or should be deployed to.
	TargetLocation *string

	// REQUIRED; The subscription to which the resources in the service belong to or should be deployed to.
	TargetSubscriptionID *string
}

ServiceResourceProperties - The properties that define a service in a service topology.

func (ServiceResourceProperties) MarshalJSON added in v0.5.0

func (s ServiceResourceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceResourceProperties.

func (*ServiceResourceProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceResourceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceResourceProperties.

type ServiceTopologiesClient

type ServiceTopologiesClient struct {
	// contains filtered or unexported fields
}

ServiceTopologiesClient contains the methods for the ServiceTopologies group. Don't use this type directly, use NewServiceTopologiesClient() instead.

func NewServiceTopologiesClient

func NewServiceTopologiesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ServiceTopologiesClient, error)

NewServiceTopologiesClient creates a new instance of ServiceTopologiesClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ServiceTopologiesClient) CreateOrUpdate

func (client *ServiceTopologiesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceTopologyInfo ServiceTopologyResource, options *ServiceTopologiesClientCreateOrUpdateOptions) (ServiceTopologiesClientCreateOrUpdateResponse, error)

CreateOrUpdate - Synchronously creates a new service topology or updates an existing service topology. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceTopologyInfo - Source topology object defines the resource.
  • options - ServiceTopologiesClientCreateOrUpdateOptions contains the optional parameters for the ServiceTopologiesClient.CreateOrUpdate method.
Example (CreateATopologyWithArtifactSource)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/servicetopology_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServiceTopologiesClient().CreateOrUpdate(ctx, "myResourceGroup", "myTopology", armdeploymentmanager.ServiceTopologyResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ServiceTopologyResourceProperties{
			ArtifactSourceID: to.Ptr("Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

Example (CreateATopologyWithoutArtifactSource)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/servicetopology_createorupdate_noartifactsource.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServiceTopologiesClient().CreateOrUpdate(ctx, "myResourceGroup", "myTopology", armdeploymentmanager.ServiceTopologyResource{
		Location:   to.Ptr("centralus"),
		Tags:       map[string]*string{},
		Properties: &armdeploymentmanager.ServiceTopologyResourceProperties{},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ServiceTopologiesClient) Delete

func (client *ServiceTopologiesClient) Delete(ctx context.Context, resourceGroupName string, serviceTopologyName string, options *ServiceTopologiesClientDeleteOptions) (ServiceTopologiesClientDeleteResponse, error)

Delete - Deletes the service topology. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • options - ServiceTopologiesClientDeleteOptions contains the optional parameters for the ServiceTopologiesClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/servicetopology_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServiceTopologiesClient().Delete(ctx, "myResourceGroup", "myTopology", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ServiceTopologiesClient) Get

func (client *ServiceTopologiesClient) Get(ctx context.Context, resourceGroupName string, serviceTopologyName string, options *ServiceTopologiesClientGetOptions) (ServiceTopologiesClientGetResponse, error)

Get - Gets the service topology. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • options - ServiceTopologiesClientGetOptions contains the optional parameters for the ServiceTopologiesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/servicetopology_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServiceTopologiesClient().Get(ctx, "myResourceGroup", "myTopology", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceTopologyResource = armdeploymentmanager.ServiceTopologyResource{
	// 	Name: to.Ptr("myTopology"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armdeploymentmanager.ServiceTopologyResourceProperties{
	// 		ArtifactSourceID: to.Ptr("Microsoft.DeploymentManager/artifactSources/myArtifactSource"),
	// 	},
	// }
}
Output:

func (*ServiceTopologiesClient) List

List - Lists the service topologies in the resource group. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - ServiceTopologiesClientListOptions contains the optional parameters for the ServiceTopologiesClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/servicetopologies_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServiceTopologiesClient().List(ctx, "myResourceGroup", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceTopologyResourceArray = []*armdeploymentmanager.ServiceTopologyResource{
	// 	{
	// 		Name: to.Ptr("ContosoSvc1Topology"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceTopologyResourceProperties{
	// 			ArtifactSourceID: to.Ptr("Microsoft.DeploymentManager/artifactSources/contoso1ArtifactSource"),
	// 		},
	// 	},
	// 	{
	// 		Name: to.Ptr("ContosoSvc2Topology"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceTopologyResourceProperties{
	// 			ArtifactSourceID: to.Ptr("Microsoft.DeploymentManager/artifactSources/contoso2ArtifactSource"),
	// 		},
	// }}
}
Output:

type ServiceTopologiesClientCreateOrUpdateOptions added in v0.2.0

type ServiceTopologiesClientCreateOrUpdateOptions struct {
}

ServiceTopologiesClientCreateOrUpdateOptions contains the optional parameters for the ServiceTopologiesClient.CreateOrUpdate method.

type ServiceTopologiesClientCreateOrUpdateResponse added in v0.2.0

type ServiceTopologiesClientCreateOrUpdateResponse struct {
	// The resource representation of a service topology.
	ServiceTopologyResource
}

ServiceTopologiesClientCreateOrUpdateResponse contains the response from method ServiceTopologiesClient.CreateOrUpdate.

type ServiceTopologiesClientDeleteOptions added in v0.2.0

type ServiceTopologiesClientDeleteOptions struct {
}

ServiceTopologiesClientDeleteOptions contains the optional parameters for the ServiceTopologiesClient.Delete method.

type ServiceTopologiesClientDeleteResponse added in v0.2.0

type ServiceTopologiesClientDeleteResponse struct {
}

ServiceTopologiesClientDeleteResponse contains the response from method ServiceTopologiesClient.Delete.

type ServiceTopologiesClientGetOptions added in v0.2.0

type ServiceTopologiesClientGetOptions struct {
}

ServiceTopologiesClientGetOptions contains the optional parameters for the ServiceTopologiesClient.Get method.

type ServiceTopologiesClientGetResponse added in v0.2.0

type ServiceTopologiesClientGetResponse struct {
	// The resource representation of a service topology.
	ServiceTopologyResource
}

ServiceTopologiesClientGetResponse contains the response from method ServiceTopologiesClient.Get.

type ServiceTopologiesClientListOptions added in v0.2.0

type ServiceTopologiesClientListOptions struct {
}

ServiceTopologiesClientListOptions contains the optional parameters for the ServiceTopologiesClient.List method.

type ServiceTopologiesClientListResponse added in v0.2.0

type ServiceTopologiesClientListResponse struct {
	// The list of service topologies.
	ServiceTopologyResourceArray []*ServiceTopologyResource
}

ServiceTopologiesClientListResponse contains the response from method ServiceTopologiesClient.List.

type ServiceTopologyProperties

type ServiceTopologyProperties struct {
	// The resource Id of the artifact source that contains the artifacts that can be referenced in the service units.
	ArtifactSourceID *string
}

ServiceTopologyProperties - The properties of a service topology.

func (ServiceTopologyProperties) MarshalJSON added in v0.5.0

func (s ServiceTopologyProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceTopologyProperties.

func (*ServiceTopologyProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceTopologyProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceTopologyProperties.

type ServiceTopologyResource

type ServiceTopologyResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// REQUIRED; The properties that define the service topology.
	Properties *ServiceTopologyResourceProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

ServiceTopologyResource - The resource representation of a service topology.

func (ServiceTopologyResource) MarshalJSON

func (s ServiceTopologyResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceTopologyResource.

func (*ServiceTopologyResource) UnmarshalJSON

func (s *ServiceTopologyResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceTopologyResource.

type ServiceTopologyResourceProperties

type ServiceTopologyResourceProperties struct {
	// The resource Id of the artifact source that contains the artifacts that can be referenced in the service units.
	ArtifactSourceID *string
}

ServiceTopologyResourceProperties - The properties that define the service topology.

func (ServiceTopologyResourceProperties) MarshalJSON added in v0.5.0

func (s ServiceTopologyResourceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceTopologyResourceProperties.

func (*ServiceTopologyResourceProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceTopologyResourceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceTopologyResourceProperties.

type ServiceUnit

type ServiceUnit struct {
	// REQUIRED; Describes the type of ARM deployment to be performed on the resource.
	DeploymentMode *DeploymentMode

	// REQUIRED; The Azure Resource Group to which the resources in the service unit belong to or should be deployed to.
	TargetResourceGroup *string

	// The artifacts for the service unit.
	Artifacts *ServiceUnitArtifacts

	// Name of the service unit.
	Name *string

	// Detailed step information, if present.
	Steps []*RolloutStep
}

ServiceUnit - Defines a service unit.

func (ServiceUnit) MarshalJSON

func (s ServiceUnit) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceUnit.

func (*ServiceUnit) UnmarshalJSON added in v0.5.0

func (s *ServiceUnit) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceUnit.

type ServiceUnitArtifacts

type ServiceUnitArtifacts struct {
	// The path to the ARM parameters file relative to the artifact source.
	ParametersArtifactSourceRelativePath *string

	// The full URI of the ARM parameters file with the SAS token.
	ParametersURI *string

	// The path to the ARM template file relative to the artifact source.
	TemplateArtifactSourceRelativePath *string

	// The full URI of the ARM template file with the SAS token.
	TemplateURI *string
}

ServiceUnitArtifacts - Defines the artifacts of a service unit.

func (ServiceUnitArtifacts) MarshalJSON added in v0.5.0

func (s ServiceUnitArtifacts) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceUnitArtifacts.

func (*ServiceUnitArtifacts) UnmarshalJSON added in v0.5.0

func (s *ServiceUnitArtifacts) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceUnitArtifacts.

type ServiceUnitProperties

type ServiceUnitProperties struct {
	// REQUIRED; Describes the type of ARM deployment to be performed on the resource.
	DeploymentMode *DeploymentMode

	// REQUIRED; The Azure Resource Group to which the resources in the service unit belong to or should be deployed to.
	TargetResourceGroup *string

	// The artifacts for the service unit.
	Artifacts *ServiceUnitArtifacts
}

ServiceUnitProperties - Defines the properties of a service unit.

func (ServiceUnitProperties) MarshalJSON

func (s ServiceUnitProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceUnitProperties.

func (*ServiceUnitProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceUnitProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceUnitProperties.

type ServiceUnitResource

type ServiceUnitResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// REQUIRED; The properties that define the service unit.
	Properties *ServiceUnitResourceProperties

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

ServiceUnitResource - Represents the response of a service unit resource.

func (ServiceUnitResource) MarshalJSON

func (s ServiceUnitResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceUnitResource.

func (*ServiceUnitResource) UnmarshalJSON

func (s *ServiceUnitResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceUnitResource.

type ServiceUnitResourceProperties

type ServiceUnitResourceProperties struct {
	// REQUIRED; Describes the type of ARM deployment to be performed on the resource.
	DeploymentMode *DeploymentMode

	// REQUIRED; The Azure Resource Group to which the resources in the service unit belong to or should be deployed to.
	TargetResourceGroup *string

	// The artifacts for the service unit.
	Artifacts *ServiceUnitArtifacts
}

ServiceUnitResourceProperties - The properties that define the service unit.

func (ServiceUnitResourceProperties) MarshalJSON added in v0.5.0

func (s ServiceUnitResourceProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type ServiceUnitResourceProperties.

func (*ServiceUnitResourceProperties) UnmarshalJSON added in v0.5.0

func (s *ServiceUnitResourceProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type ServiceUnitResourceProperties.

type ServiceUnitsClient

type ServiceUnitsClient struct {
	// contains filtered or unexported fields
}

ServiceUnitsClient contains the methods for the ServiceUnits group. Don't use this type directly, use NewServiceUnitsClient() instead.

func NewServiceUnitsClient

func NewServiceUnitsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ServiceUnitsClient, error)

NewServiceUnitsClient creates a new instance of ServiceUnitsClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ServiceUnitsClient) BeginCreateOrUpdate

func (client *ServiceUnitsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, serviceUnitName string, serviceUnitInfo ServiceUnitResource, options *ServiceUnitsClientBeginCreateOrUpdateOptions) (*runtime.Poller[ServiceUnitsClientCreateOrUpdateResponse], error)

BeginCreateOrUpdate - This is an asynchronous operation and can be polled to completion using the operation resource returned by this operation. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • serviceUnitName - The name of the service unit resource.
  • serviceUnitInfo - The service unit resource object.
  • options - ServiceUnitsClientBeginCreateOrUpdateOptions contains the optional parameters for the ServiceUnitsClient.BeginCreateOrUpdate method.
Example (CreateServiceUnitUsingRelativePathsIntoTheArtifactSource)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/serviceunit_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewServiceUnitsClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myTopology", "myService", "myServiceUnit", armdeploymentmanager.ServiceUnitResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ServiceUnitResourceProperties{
			Artifacts: &armdeploymentmanager.ServiceUnitArtifacts{
				ParametersArtifactSourceRelativePath: to.Ptr("parameter/myTopologyUnit.parameters.json"),
				TemplateArtifactSourceRelativePath:   to.Ptr("templates/myTopologyUnit.template.json"),
			},
			DeploymentMode:      to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
			TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}
Output:

Example (CreateServiceUnitUsingSasUrIs)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/serviceunit_createorupdate_noartifactsource.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	poller, err := clientFactory.NewServiceUnitsClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myTopology", "myService", "myServiceUnit", armdeploymentmanager.ServiceUnitResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ServiceUnitResourceProperties{
			Artifacts: &armdeploymentmanager.ServiceUnitArtifacts{
				ParametersURI: to.Ptr("https://mystorageaccount.blob.core.windows.net/myartifactsource/parameter/myTopologyUnit.parameters.json?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
				TemplateURI:   to.Ptr("https://mystorageaccount.blob.core.windows.net/myartifactsource/templates/myTopologyUnit.template.json?st=2018-07-07T14%3A10%3A00Z&se=2019-12-31T15%3A10%3A00Z&sp=rl&sv=2017-04-17&sr=c&sig=Yh2SoJ1NhhLRwCLln7de%2Fkabcdefghijklmno5sWEIk%3D"),
			},
			DeploymentMode:      to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
			TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	_, err = poller.PollUntilDone(ctx, nil)
	if err != nil {
		log.Fatalf("failed to pull the result: %v", err)
	}
}
Output:

func (*ServiceUnitsClient) Delete

func (client *ServiceUnitsClient) Delete(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, serviceUnitName string, options *ServiceUnitsClientDeleteOptions) (ServiceUnitsClientDeleteResponse, error)

Delete - Deletes the service unit. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • serviceUnitName - The name of the service unit resource.
  • options - ServiceUnitsClientDeleteOptions contains the optional parameters for the ServiceUnitsClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/serviceunit_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServiceUnitsClient().Delete(ctx, "myResourceGroup", "myTopology", "myService", "myServiceUnit", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ServiceUnitsClient) Get

func (client *ServiceUnitsClient) Get(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, serviceUnitName string, options *ServiceUnitsClientGetOptions) (ServiceUnitsClientGetResponse, error)

Get - Gets the service unit. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • serviceUnitName - The name of the service unit resource.
  • options - ServiceUnitsClientGetOptions contains the optional parameters for the ServiceUnitsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/serviceunit_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServiceUnitsClient().Get(ctx, "myResourceGroup", "myTopology", "myService", "myServiceUnit", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceUnitResource = armdeploymentmanager.ServiceUnitResource{
	// 	Name: to.Ptr("myServiceUnit"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/servicetopologies/services/serviceunits"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armdeploymentmanager.ServiceUnitResourceProperties{
	// 		Artifacts: &armdeploymentmanager.ServiceUnitArtifacts{
	// 			ParametersArtifactSourceRelativePath: to.Ptr("parameter/myTopologyUnit.parameters.json"),
	// 			TemplateArtifactSourceRelativePath: to.Ptr("templates/myTopologyUnit.template.json"),
	// 		},
	// 		DeploymentMode: to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
	// 		TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
	// 	},
	// }
}
Output:

func (*ServiceUnitsClient) List

func (client *ServiceUnitsClient) List(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, options *ServiceUnitsClientListOptions) (ServiceUnitsClientListResponse, error)

List - Lists the service units under a service in the service topology. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • options - ServiceUnitsClientListOptions contains the optional parameters for the ServiceUnitsClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/serviceunits_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServiceUnitsClient().List(ctx, "myResourceGroup", "myTopology", "myService", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceUnitResourceArray = []*armdeploymentmanager.ServiceUnitResource{
	// 	{
	// 		Name: to.Ptr("BackEndServiceUnit"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/servicetopologies/services/serviceunits"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceUnitResourceProperties{
	// 			Artifacts: &armdeploymentmanager.ServiceUnitArtifacts{
	// 				ParametersArtifactSourceRelativePath: to.Ptr("parameter/backend.parameters.json"),
	// 				TemplateArtifactSourceRelativePath: to.Ptr("templates/backend.template.json"),
	// 			},
	// 			DeploymentMode: to.Ptr(armdeploymentmanager.DeploymentModeIncremental),
	// 			TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
	// 		},
	// 	},
	// 	{
	// 		Name: to.Ptr("FrontEndServiceUnit"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/servicetopologies/services/serviceunits"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceUnitResourceProperties{
	// 			Artifacts: &armdeploymentmanager.ServiceUnitArtifacts{
	// 				ParametersArtifactSourceRelativePath: to.Ptr("parameter/frontend.parameters.json"),
	// 				TemplateArtifactSourceRelativePath: to.Ptr("templates/frontend.template.json"),
	// 			},
	// 			DeploymentMode: to.Ptr(armdeploymentmanager.DeploymentModeComplete),
	// 			TargetResourceGroup: to.Ptr("myDeploymentResourceGroup"),
	// 		},
	// }}
}
Output:

type ServiceUnitsClientBeginCreateOrUpdateOptions added in v0.2.0

type ServiceUnitsClientBeginCreateOrUpdateOptions struct {
	// Resumes the LRO from the provided token.
	ResumeToken string
}

ServiceUnitsClientBeginCreateOrUpdateOptions contains the optional parameters for the ServiceUnitsClient.BeginCreateOrUpdate method.

type ServiceUnitsClientCreateOrUpdateResponse added in v0.2.0

type ServiceUnitsClientCreateOrUpdateResponse struct {
	// Represents the response of a service unit resource.
	ServiceUnitResource
}

ServiceUnitsClientCreateOrUpdateResponse contains the response from method ServiceUnitsClient.BeginCreateOrUpdate.

type ServiceUnitsClientDeleteOptions added in v0.2.0

type ServiceUnitsClientDeleteOptions struct {
}

ServiceUnitsClientDeleteOptions contains the optional parameters for the ServiceUnitsClient.Delete method.

type ServiceUnitsClientDeleteResponse added in v0.2.0

type ServiceUnitsClientDeleteResponse struct {
}

ServiceUnitsClientDeleteResponse contains the response from method ServiceUnitsClient.Delete.

type ServiceUnitsClientGetOptions added in v0.2.0

type ServiceUnitsClientGetOptions struct {
}

ServiceUnitsClientGetOptions contains the optional parameters for the ServiceUnitsClient.Get method.

type ServiceUnitsClientGetResponse added in v0.2.0

type ServiceUnitsClientGetResponse struct {
	// Represents the response of a service unit resource.
	ServiceUnitResource
}

ServiceUnitsClientGetResponse contains the response from method ServiceUnitsClient.Get.

type ServiceUnitsClientListOptions added in v0.2.0

type ServiceUnitsClientListOptions struct {
}

ServiceUnitsClientListOptions contains the optional parameters for the ServiceUnitsClient.List method.

type ServiceUnitsClientListResponse added in v0.2.0

type ServiceUnitsClientListResponse struct {
	// The list of service units.
	ServiceUnitResourceArray []*ServiceUnitResource
}

ServiceUnitsClientListResponse contains the response from method ServiceUnitsClient.List.

type ServicesClient

type ServicesClient struct {
	// contains filtered or unexported fields
}

ServicesClient contains the methods for the Services group. Don't use this type directly, use NewServicesClient() instead.

func NewServicesClient

func NewServicesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ServicesClient, error)

NewServicesClient creates a new instance of ServicesClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*ServicesClient) CreateOrUpdate

func (client *ServicesClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, serviceInfo ServiceResource, options *ServicesClientCreateOrUpdateOptions) (ServicesClientCreateOrUpdateResponse, error)

CreateOrUpdate - Synchronously creates a new service or updates an existing service. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • serviceInfo - The service object
  • options - ServicesClientCreateOrUpdateOptions contains the optional parameters for the ServicesClient.CreateOrUpdate method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/service_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServicesClient().CreateOrUpdate(ctx, "myResourceGroup", "myTopology", "myService", armdeploymentmanager.ServiceResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.ServiceResourceProperties{
			TargetLocation:       to.Ptr("centralus"),
			TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
		},
	}, nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ServicesClient) Delete

func (client *ServicesClient) Delete(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, options *ServicesClientDeleteOptions) (ServicesClientDeleteResponse, error)

Delete - Deletes the service. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • options - ServicesClientDeleteOptions contains the optional parameters for the ServicesClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/service_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewServicesClient().Delete(ctx, "myResourceGroup", "myTopology", "myService", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*ServicesClient) Get

func (client *ServicesClient) Get(ctx context.Context, resourceGroupName string, serviceTopologyName string, serviceName string, options *ServicesClientGetOptions) (ServicesClientGetResponse, error)

Get - Gets the service. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • serviceName - The name of the service resource.
  • options - ServicesClientGetOptions contains the optional parameters for the ServicesClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/service_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServicesClient().Get(ctx, "myResourceGroup", "myTopology", "myService", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceResource = armdeploymentmanager.ServiceResource{
	// 	Name: to.Ptr("myService"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/services"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armdeploymentmanager.ServiceResourceProperties{
	// 		TargetLocation: to.Ptr("centralus"),
	// 		TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
	// 	},
	// }
}
Output:

func (*ServicesClient) List

func (client *ServicesClient) List(ctx context.Context, resourceGroupName string, serviceTopologyName string, options *ServicesClientListOptions) (ServicesClientListResponse, error)

List - Lists the services in the service topology. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • serviceTopologyName - The name of the service topology .
  • options - ServicesClientListOptions contains the optional parameters for the ServicesClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/services_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewServicesClient().List(ctx, "myResourceGroup", "myTopology", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.ServiceResourceArray = []*armdeploymentmanager.ServiceResource{
	// 	{
	// 		Name: to.Ptr("Service East"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/services"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceResourceProperties{
	// 			TargetLocation: to.Ptr("eastus"),
	// 			TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
	// 		},
	// 	},
	// 	{
	// 		Name: to.Ptr("Service West"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/serviceTopologies/services"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.ServiceResourceProperties{
	// 			TargetLocation: to.Ptr("westus"),
	// 			TargetSubscriptionID: to.Ptr("600c95c5-3ee5-44fe-b190-ca38a19adcd7"),
	// 		},
	// }}
}
Output:

type ServicesClientCreateOrUpdateOptions added in v0.2.0

type ServicesClientCreateOrUpdateOptions struct {
}

ServicesClientCreateOrUpdateOptions contains the optional parameters for the ServicesClient.CreateOrUpdate method.

type ServicesClientCreateOrUpdateResponse added in v0.2.0

type ServicesClientCreateOrUpdateResponse struct {
	// The resource representation of a service in a service topology.
	ServiceResource
}

ServicesClientCreateOrUpdateResponse contains the response from method ServicesClient.CreateOrUpdate.

type ServicesClientDeleteOptions added in v0.2.0

type ServicesClientDeleteOptions struct {
}

ServicesClientDeleteOptions contains the optional parameters for the ServicesClient.Delete method.

type ServicesClientDeleteResponse added in v0.2.0

type ServicesClientDeleteResponse struct {
}

ServicesClientDeleteResponse contains the response from method ServicesClient.Delete.

type ServicesClientGetOptions added in v0.2.0

type ServicesClientGetOptions struct {
}

ServicesClientGetOptions contains the optional parameters for the ServicesClient.Get method.

type ServicesClientGetResponse added in v0.2.0

type ServicesClientGetResponse struct {
	// The resource representation of a service in a service topology.
	ServiceResource
}

ServicesClientGetResponse contains the response from method ServicesClient.Get.

type ServicesClientListOptions added in v0.2.0

type ServicesClientListOptions struct {
}

ServicesClientListOptions contains the optional parameters for the ServicesClient.List method.

type ServicesClientListResponse added in v0.2.0

type ServicesClientListResponse struct {
	// The list of services.
	ServiceResourceArray []*ServiceResource
}

ServicesClientListResponse contains the response from method ServicesClient.List.

type StepGroup

type StepGroup struct {
	// REQUIRED; The resource Id of service unit to be deployed. The service unit should be from the service topology referenced
	// in targetServiceTopologyId
	DeploymentTargetID *string

	// REQUIRED; The name of the step group.
	Name *string

	// The list of step group names on which this step group depends on.
	DependsOnStepGroups []*string

	// The list of steps to be run after deploying the target.
	PostDeploymentSteps []*PrePostStep

	// The list of steps to be run before deploying the target.
	PreDeploymentSteps []*PrePostStep
}

StepGroup - The properties that define a Step group in a rollout.

func (StepGroup) MarshalJSON

func (s StepGroup) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StepGroup.

func (*StepGroup) UnmarshalJSON added in v0.5.0

func (s *StepGroup) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StepGroup.

type StepOperationInfo

type StepOperationInfo struct {
	// The errors, if any, for the action.
	Error *CloudErrorBody

	// READ-ONLY; Unique identifier to track the request for ARM-based resources.
	CorrelationID *string

	// READ-ONLY; The name of the ARM deployment initiated as part of the step.
	DeploymentName *string

	// READ-ONLY; End time of the action in UTC.
	EndTime *time.Time

	// READ-ONLY; Last time in UTC this operation was updated.
	LastUpdatedTime *time.Time

	// READ-ONLY; Start time of the action in UTC.
	StartTime *time.Time
}

StepOperationInfo - Detailed information of a specific step run.

func (StepOperationInfo) MarshalJSON

func (s StepOperationInfo) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StepOperationInfo.

func (*StepOperationInfo) UnmarshalJSON

func (s *StepOperationInfo) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StepOperationInfo.

type StepProperties

type StepProperties struct {
	// REQUIRED; The type of step.
	StepType *StepType
}

StepProperties - The properties of a step resource.

func (*StepProperties) GetStepProperties

func (s *StepProperties) GetStepProperties() *StepProperties

GetStepProperties implements the StepPropertiesClassification interface for type StepProperties.

func (StepProperties) MarshalJSON added in v0.5.0

func (s StepProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StepProperties.

func (*StepProperties) UnmarshalJSON

func (s *StepProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StepProperties.

type StepPropertiesClassification

type StepPropertiesClassification interface {
	// GetStepProperties returns the StepProperties content of the underlying type.
	GetStepProperties() *StepProperties
}

StepPropertiesClassification provides polymorphic access to related types. Call the interface's GetStepProperties() method to access the common type. Use a type switch to determine the concrete type. The possible types are: - *HealthCheckStepProperties, *StepProperties, *WaitStepProperties

type StepResource

type StepResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// REQUIRED; The properties that define the step.
	Properties StepPropertiesClassification

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

StepResource - The resource representation of a rollout step.

func (StepResource) MarshalJSON

func (s StepResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type StepResource.

func (*StepResource) UnmarshalJSON

func (s *StepResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type StepResource.

type StepType

type StepType string

StepType - The type of step.

const (
	StepTypeHealthCheck StepType = "HealthCheck"
	StepTypeWait        StepType = "Wait"
)

func PossibleStepTypeValues

func PossibleStepTypeValues() []StepType

PossibleStepTypeValues returns the possible values for the StepType const type.

type StepsClient

type StepsClient struct {
	// contains filtered or unexported fields
}

StepsClient contains the methods for the Steps group. Don't use this type directly, use NewStepsClient() instead.

func NewStepsClient

func NewStepsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*StepsClient, error)

NewStepsClient creates a new instance of StepsClient with the specified values.

  • subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
  • credential - used to authorize requests. Usually a credential from azidentity.
  • options - pass nil to accept the default values.

func (*StepsClient) CreateOrUpdate

func (client *StepsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, stepName string, options *StepsClientCreateOrUpdateOptions) (StepsClientCreateOrUpdateResponse, error)

CreateOrUpdate - Synchronously creates a new step or updates an existing step. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • stepName - The name of the deployment step.
  • options - StepsClientCreateOrUpdateOptions contains the optional parameters for the StepsClient.CreateOrUpdate method.
Example (CreateHealthCheckStep)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/step_health_check_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewStepsClient().CreateOrUpdate(ctx, "myResourceGroup", "healthCheckStep", &armdeploymentmanager.StepsClientCreateOrUpdateOptions{StepInfo: &armdeploymentmanager.StepResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.HealthCheckStepProperties{
			StepType: to.Ptr(armdeploymentmanager.StepTypeHealthCheck),
			Attributes: &armdeploymentmanager.RestHealthCheckStepAttributes{
				Type:                 to.Ptr("REST"),
				HealthyStateDuration: to.Ptr("PT2H"),
				MaxElasticDuration:   to.Ptr("PT30M"),
				WaitDuration:         to.Ptr("PT15M"),
				Properties: &armdeploymentmanager.RestParameters{
					HealthChecks: []*armdeploymentmanager.RestHealthCheck{
						{
							Name: to.Ptr("appHealth"),
							Response: &armdeploymentmanager.RestResponse{
								Regex: &armdeploymentmanager.RestResponseRegex{
									MatchQuantifier: to.Ptr(armdeploymentmanager.RestMatchQuantifierAll),
									Matches: []*string{
										to.Ptr("(?i)Contoso-App"),
										to.Ptr("(?i)\"health_status\":((.|\n)*)\"(green|yellow)\""),
										to.Ptr("(?mi)^(\"application_host\": 94781052)$")},
								},
								SuccessStatusCodes: []*string{
									to.Ptr("OK")},
							},
							Request: &armdeploymentmanager.RestRequest{
								Method: to.Ptr(armdeploymentmanager.RestRequestMethodGET),
								Authentication: &armdeploymentmanager.APIKeyAuthentication{
									Type:  to.Ptr(armdeploymentmanager.RestAuthTypeAPIKey),
									Name:  to.Ptr("Code"),
									In:    to.Ptr(armdeploymentmanager.RestAuthLocationQuery),
									Value: to.Ptr("NBCapiMOBQyAAbCkeytoPadnvO0eGHmidwFz5rXpappznKp3Jt7LLg=="),
								},
								URI: to.Ptr("https://resthealth.healthservice.com/api/applications/contosoApp/healthStatus"),
							},
						},
						{
							Name: to.Ptr("serviceHealth"),
							Response: &armdeploymentmanager.RestResponse{
								Regex: &armdeploymentmanager.RestResponseRegex{
									MatchQuantifier: to.Ptr(armdeploymentmanager.RestMatchQuantifierAll),
									Matches: []*string{
										to.Ptr("(?i)Contoso-Service-EndToEnd"),
										to.Ptr("(?i)\"health_status\":((.|\n)*)\"(green)\"")},
								},
								SuccessStatusCodes: []*string{
									to.Ptr("OK")},
							},
							Request: &armdeploymentmanager.RestRequest{
								Method: to.Ptr(armdeploymentmanager.RestRequestMethodGET),
								Authentication: &armdeploymentmanager.APIKeyAuthentication{
									Type:  to.Ptr(armdeploymentmanager.RestAuthTypeAPIKey),
									Name:  to.Ptr("code"),
									In:    to.Ptr(armdeploymentmanager.RestAuthLocationHeader),
									Value: to.Ptr("NBCapiMOBQyAAbCkeytoPadnvO0eGHmidwFz5rXpappznKp3Jt7LLg=="),
								},
								URI: to.Ptr("https://resthealth.healthservice.com/api/services/contosoService/healthStatus"),
							},
						}},
				},
			},
		},
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

Example (CreateWaitStep)

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/step_wait_createorupdate.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewStepsClient().CreateOrUpdate(ctx, "myResourceGroup", "waitStep", &armdeploymentmanager.StepsClientCreateOrUpdateOptions{StepInfo: &armdeploymentmanager.StepResource{
		Location: to.Ptr("centralus"),
		Tags:     map[string]*string{},
		Properties: &armdeploymentmanager.WaitStepProperties{
			StepType: to.Ptr(armdeploymentmanager.StepTypeWait),
			Attributes: &armdeploymentmanager.WaitStepAttributes{
				Duration: to.Ptr("PT20M"),
			},
		},
	},
	})
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*StepsClient) Delete

func (client *StepsClient) Delete(ctx context.Context, resourceGroupName string, stepName string, options *StepsClientDeleteOptions) (StepsClientDeleteResponse, error)

Delete - Deletes the step. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • stepName - The name of the deployment step.
  • options - StepsClientDeleteOptions contains the optional parameters for the StepsClient.Delete method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/step_delete.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	_, err = clientFactory.NewStepsClient().Delete(ctx, "myResourceGroup", "deploymentStep1", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
}
Output:

func (*StepsClient) Get

func (client *StepsClient) Get(ctx context.Context, resourceGroupName string, stepName string, options *StepsClientGetOptions) (StepsClientGetResponse, error)

Get - Gets the step. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • stepName - The name of the deployment step.
  • options - StepsClientGetOptions contains the optional parameters for the StepsClient.Get method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/step_get.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewStepsClient().Get(ctx, "myResourceGroup", "waitStep", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.StepResource = armdeploymentmanager.StepResource{
	// 	Name: to.Ptr("deploymentStep1"),
	// 	Type: to.Ptr("Microsoft.DeploymentManager/steps"),
	// 	Location: to.Ptr("centralus"),
	// 	Tags: map[string]*string{
	// 	},
	// 	Properties: &armdeploymentmanager.WaitStepProperties{
	// 		StepType: to.Ptr(armdeploymentmanager.StepTypeWait),
	// 		Attributes: &armdeploymentmanager.WaitStepAttributes{
	// 			Duration: to.Ptr("PT20M"),
	// 		},
	// 	},
	// }
}
Output:

func (*StepsClient) List

func (client *StepsClient) List(ctx context.Context, resourceGroupName string, options *StepsClientListOptions) (StepsClientListResponse, error)

List - Lists the steps in a resource group. If the operation fails it returns an *azcore.ResponseError type.

Generated from API version 2019-11-01-preview

  • resourceGroupName - The name of the resource group. The name is case insensitive.
  • options - StepsClientListOptions contains the optional parameters for the StepsClient.List method.
Example

Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/7a2ac91de424f271cf91cc8009f3fe9ee8249086/specification/deploymentmanager/resource-manager/Microsoft.DeploymentManager/preview/2019-11-01-preview/examples/steps_list.json

package main

import (
	"context"
	"log"

	"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
	"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/deploymentmanager/armdeploymentmanager"
)

func main() {
	cred, err := azidentity.NewDefaultAzureCredential(nil)
	if err != nil {
		log.Fatalf("failed to obtain a credential: %v", err)
	}
	ctx := context.Background()
	clientFactory, err := armdeploymentmanager.NewClientFactory("<subscription-id>", cred, nil)
	if err != nil {
		log.Fatalf("failed to create client: %v", err)
	}
	res, err := clientFactory.NewStepsClient().List(ctx, "myResourceGroup", nil)
	if err != nil {
		log.Fatalf("failed to finish the request: %v", err)
	}
	// You could use response here. We use blank identifier for just demo purposes.
	_ = res
	// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
	// res.StepResourceArray = []*armdeploymentmanager.StepResource{
	// 	{
	// 		Name: to.Ptr("waitStepfrontEnd"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/steps"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.WaitStepProperties{
	// 			StepType: to.Ptr(armdeploymentmanager.StepTypeWait),
	// 			Attributes: &armdeploymentmanager.WaitStepAttributes{
	// 				Duration: to.Ptr("PT10M"),
	// 			},
	// 		},
	// 	},
	// 	{
	// 		Name: to.Ptr("waitStepBackEnd"),
	// 		Type: to.Ptr("Microsoft.DeploymentManager/steps"),
	// 		Location: to.Ptr("centralus"),
	// 		Tags: map[string]*string{
	// 		},
	// 		Properties: &armdeploymentmanager.WaitStepProperties{
	// 			StepType: to.Ptr(armdeploymentmanager.StepTypeWait),
	// 			Attributes: &armdeploymentmanager.WaitStepAttributes{
	// 				Duration: to.Ptr("PT30M"),
	// 			},
	// 		},
	// }}
}
Output:

type StepsClientCreateOrUpdateOptions added in v0.2.0

type StepsClientCreateOrUpdateOptions struct {
	// The step object.
	StepInfo *StepResource
}

StepsClientCreateOrUpdateOptions contains the optional parameters for the StepsClient.CreateOrUpdate method.

type StepsClientCreateOrUpdateResponse added in v0.2.0

type StepsClientCreateOrUpdateResponse struct {
	// The resource representation of a rollout step.
	StepResource
}

StepsClientCreateOrUpdateResponse contains the response from method StepsClient.CreateOrUpdate.

type StepsClientDeleteOptions added in v0.2.0

type StepsClientDeleteOptions struct {
}

StepsClientDeleteOptions contains the optional parameters for the StepsClient.Delete method.

type StepsClientDeleteResponse added in v0.2.0

type StepsClientDeleteResponse struct {
}

StepsClientDeleteResponse contains the response from method StepsClient.Delete.

type StepsClientGetOptions added in v0.2.0

type StepsClientGetOptions struct {
}

StepsClientGetOptions contains the optional parameters for the StepsClient.Get method.

type StepsClientGetResponse added in v0.2.0

type StepsClientGetResponse struct {
	// The resource representation of a rollout step.
	StepResource
}

StepsClientGetResponse contains the response from method StepsClient.Get.

type StepsClientListOptions added in v0.2.0

type StepsClientListOptions struct {
}

StepsClientListOptions contains the optional parameters for the StepsClient.List method.

type StepsClientListResponse added in v0.2.0

type StepsClientListResponse struct {
	// The list of steps.
	StepResourceArray []*StepResource
}

StepsClientListResponse contains the response from method StepsClient.List.

type TrackedResource

type TrackedResource struct {
	// REQUIRED; The geo-location where the resource lives
	Location *string

	// Resource tags.
	Tags map[string]*string

	// READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
	ID *string

	// READ-ONLY; The name of the resource
	Name *string

	// READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
	Type *string
}

TrackedResource - The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location'

func (TrackedResource) MarshalJSON

func (t TrackedResource) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type TrackedResource.

func (*TrackedResource) UnmarshalJSON

func (t *TrackedResource) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type TrackedResource.

type WaitStepAttributes

type WaitStepAttributes struct {
	// REQUIRED; The duration in ISO 8601 format of how long the wait should be.
	Duration *string
}

WaitStepAttributes - The parameters for the wait step.

func (WaitStepAttributes) MarshalJSON added in v0.5.0

func (w WaitStepAttributes) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type WaitStepAttributes.

func (*WaitStepAttributes) UnmarshalJSON added in v0.5.0

func (w *WaitStepAttributes) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type WaitStepAttributes.

type WaitStepProperties

type WaitStepProperties struct {
	// REQUIRED; The Wait attributes
	Attributes *WaitStepAttributes

	// REQUIRED; The type of step.
	StepType *StepType
}

WaitStepProperties - Defines the properties of a Wait step.

func (*WaitStepProperties) GetStepProperties added in v0.2.0

func (w *WaitStepProperties) GetStepProperties() *StepProperties

GetStepProperties implements the StepPropertiesClassification interface for type WaitStepProperties.

func (WaitStepProperties) MarshalJSON

func (w WaitStepProperties) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaller interface for type WaitStepProperties.

func (*WaitStepProperties) UnmarshalJSON

func (w *WaitStepProperties) UnmarshalJSON(data []byte) error

UnmarshalJSON implements the json.Unmarshaller interface for type WaitStepProperties.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL