application

package
v0.20230524.1231843 Latest Latest
Warning

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

Go to latest
Published: May 24, 2023 License: MPL-2.0 Imports: 11 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/servicefabric/2021-06-01/application Documentation

The application SDK allows for interaction with the Azure Resource Manager Service servicefabric (API Version 2021-06-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/servicefabric/2021-06-01/application"

Client Initialization

client := application.NewApplicationClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ApplicationClient.CreateOrUpdate

ctx := context.TODO()
id := application.NewApplicationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "clusterValue", "applicationValue")

payload := application.ApplicationResource{
	// ...
}


if err := client.CreateOrUpdateThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Example Usage: ApplicationClient.Delete

ctx := context.TODO()
id := application.NewApplicationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "clusterValue", "applicationValue")

if err := client.DeleteThenPoll(ctx, id); err != nil {
	// handle the error
}

Example Usage: ApplicationClient.Get

ctx := context.TODO()
id := application.NewApplicationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "clusterValue", "applicationValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ApplicationClient.List

ctx := context.TODO()
id := application.NewClusterID("12345678-1234-9876-4563-123456789012", "example-resource-group", "clusterValue")

read, err := client.List(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ApplicationClient.Update

ctx := context.TODO()
id := application.NewApplicationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "clusterValue", "applicationValue")

payload := application.ApplicationResourceUpdate{
	// ...
}


if err := client.UpdateThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForArmUpgradeFailureAction

func PossibleValuesForArmUpgradeFailureAction() []string

func PossibleValuesForRollingUpgradeMode

func PossibleValuesForRollingUpgradeMode() []string

func ValidateApplicationID

func ValidateApplicationID(input interface{}, key string) (warnings []string, errors []error)

ValidateApplicationID checks that 'input' can be parsed as a Application ID

func ValidateClusterID

func ValidateClusterID(input interface{}, key string) (warnings []string, errors []error)

ValidateClusterID checks that 'input' can be parsed as a Cluster ID

Types

type ApplicationClient

type ApplicationClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewApplicationClientWithBaseURI

func NewApplicationClientWithBaseURI(endpoint string) ApplicationClient

func (ApplicationClient) CreateOrUpdate

CreateOrUpdate ...

func (ApplicationClient) CreateOrUpdateThenPoll

func (c ApplicationClient) CreateOrUpdateThenPoll(ctx context.Context, id ApplicationId, input ApplicationResource) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (ApplicationClient) Delete

Delete ...

func (ApplicationClient) DeleteThenPoll

func (c ApplicationClient) DeleteThenPoll(ctx context.Context, id ApplicationId) error

DeleteThenPoll performs Delete then polls until it's completed

func (ApplicationClient) Get

Get ...

func (ApplicationClient) List

func (c ApplicationClient) List(ctx context.Context, id ClusterId) (result ListOperationResponse, err error)

List ...

func (ApplicationClient) Update

Update ...

func (ApplicationClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

type ApplicationId

type ApplicationId struct {
	SubscriptionId    string
	ResourceGroupName string
	ClusterName       string
	ApplicationName   string
}

ApplicationId is a struct representing the Resource ID for a Application

func NewApplicationID

func NewApplicationID(subscriptionId string, resourceGroupName string, clusterName string, applicationName string) ApplicationId

NewApplicationID returns a new ApplicationId struct

func ParseApplicationID

func ParseApplicationID(input string) (*ApplicationId, error)

ParseApplicationID parses 'input' into a ApplicationId

func ParseApplicationIDInsensitively

func ParseApplicationIDInsensitively(input string) (*ApplicationId, error)

ParseApplicationIDInsensitively parses 'input' case-insensitively into a ApplicationId note: this method should only be used for API response data and not user input

func (ApplicationId) ID

func (id ApplicationId) ID() string

ID returns the formatted Application ID

func (ApplicationId) Segments

func (id ApplicationId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Application ID

func (ApplicationId) String

func (id ApplicationId) String() string

String returns a human-readable description of this Application ID

type ApplicationMetricDescription

type ApplicationMetricDescription struct {
	MaximumCapacity          *int64  `json:"maximumCapacity,omitempty"`
	Name                     *string `json:"name,omitempty"`
	ReservationCapacity      *int64  `json:"reservationCapacity,omitempty"`
	TotalApplicationCapacity *int64  `json:"totalApplicationCapacity,omitempty"`
}

type ApplicationResource

type ApplicationResource struct {
	Etag       *string                            `json:"etag,omitempty"`
	Id         *string                            `json:"id,omitempty"`
	Identity   *identity.SystemAndUserAssignedMap `json:"identity,omitempty"`
	Location   *string                            `json:"location,omitempty"`
	Name       *string                            `json:"name,omitempty"`
	Properties *ApplicationResourceProperties     `json:"properties,omitempty"`
	SystemData *SystemData                        `json:"systemData,omitempty"`
	Tags       *map[string]string                 `json:"tags,omitempty"`
	Type       *string                            `json:"type,omitempty"`
}

type ApplicationResourceList

type ApplicationResourceList struct {
	NextLink *string                `json:"nextLink,omitempty"`
	Value    *[]ApplicationResource `json:"value,omitempty"`
}

type ApplicationResourceProperties

type ApplicationResourceProperties struct {
	ManagedIdentities         *[]ApplicationUserAssignedIdentity `json:"managedIdentities,omitempty"`
	MaximumNodes              *int64                             `json:"maximumNodes,omitempty"`
	Metrics                   *[]ApplicationMetricDescription    `json:"metrics,omitempty"`
	MinimumNodes              *int64                             `json:"minimumNodes,omitempty"`
	Parameters                *map[string]string                 `json:"parameters,omitempty"`
	ProvisioningState         *string                            `json:"provisioningState,omitempty"`
	RemoveApplicationCapacity *bool                              `json:"removeApplicationCapacity,omitempty"`
	TypeName                  *string                            `json:"typeName,omitempty"`
	TypeVersion               *string                            `json:"typeVersion,omitempty"`
	UpgradePolicy             *ApplicationUpgradePolicy          `json:"upgradePolicy,omitempty"`
}

type ApplicationResourceUpdate

type ApplicationResourceUpdate struct {
	Etag       *string                              `json:"etag,omitempty"`
	Id         *string                              `json:"id,omitempty"`
	Location   *string                              `json:"location,omitempty"`
	Name       *string                              `json:"name,omitempty"`
	Properties *ApplicationResourceUpdateProperties `json:"properties,omitempty"`
	SystemData *SystemData                          `json:"systemData,omitempty"`
	Tags       *map[string]string                   `json:"tags,omitempty"`
	Type       *string                              `json:"type,omitempty"`
}

type ApplicationResourceUpdateProperties

type ApplicationResourceUpdateProperties struct {
	ManagedIdentities         *[]ApplicationUserAssignedIdentity `json:"managedIdentities,omitempty"`
	MaximumNodes              *int64                             `json:"maximumNodes,omitempty"`
	Metrics                   *[]ApplicationMetricDescription    `json:"metrics,omitempty"`
	MinimumNodes              *int64                             `json:"minimumNodes,omitempty"`
	Parameters                *map[string]string                 `json:"parameters,omitempty"`
	RemoveApplicationCapacity *bool                              `json:"removeApplicationCapacity,omitempty"`
	TypeVersion               *string                            `json:"typeVersion,omitempty"`
	UpgradePolicy             *ApplicationUpgradePolicy          `json:"upgradePolicy,omitempty"`
}

type ApplicationUpgradePolicy

type ApplicationUpgradePolicy struct {
	ApplicationHealthPolicy        *ArmApplicationHealthPolicy        `json:"applicationHealthPolicy,omitempty"`
	ForceRestart                   *bool                              `json:"forceRestart,omitempty"`
	RecreateApplication            *bool                              `json:"recreateApplication,omitempty"`
	RollingUpgradeMonitoringPolicy *ArmRollingUpgradeMonitoringPolicy `json:"rollingUpgradeMonitoringPolicy,omitempty"`
	UpgradeMode                    *RollingUpgradeMode                `json:"upgradeMode,omitempty"`
	UpgradeReplicaSetCheckTimeout  *string                            `json:"upgradeReplicaSetCheckTimeout,omitempty"`
}

type ApplicationUserAssignedIdentity

type ApplicationUserAssignedIdentity struct {
	Name        string `json:"name"`
	PrincipalId string `json:"principalId"`
}

type ArmApplicationHealthPolicy

type ArmApplicationHealthPolicy struct {
	ConsiderWarningAsError                  *bool                                  `json:"considerWarningAsError,omitempty"`
	DefaultServiceTypeHealthPolicy          *ArmServiceTypeHealthPolicy            `json:"defaultServiceTypeHealthPolicy,omitempty"`
	MaxPercentUnhealthyDeployedApplications *int64                                 `json:"maxPercentUnhealthyDeployedApplications,omitempty"`
	ServiceTypeHealthPolicyMap              *map[string]ArmServiceTypeHealthPolicy `json:"serviceTypeHealthPolicyMap,omitempty"`
}

type ArmRollingUpgradeMonitoringPolicy

type ArmRollingUpgradeMonitoringPolicy struct {
	FailureAction             *ArmUpgradeFailureAction `json:"failureAction,omitempty"`
	HealthCheckRetryTimeout   *string                  `json:"healthCheckRetryTimeout,omitempty"`
	HealthCheckStableDuration *string                  `json:"healthCheckStableDuration,omitempty"`
	HealthCheckWaitDuration   *string                  `json:"healthCheckWaitDuration,omitempty"`
	UpgradeDomainTimeout      *string                  `json:"upgradeDomainTimeout,omitempty"`
	UpgradeTimeout            *string                  `json:"upgradeTimeout,omitempty"`
}

type ArmServiceTypeHealthPolicy

type ArmServiceTypeHealthPolicy struct {
	MaxPercentUnhealthyPartitionsPerService *int64 `json:"maxPercentUnhealthyPartitionsPerService,omitempty"`
	MaxPercentUnhealthyReplicasPerPartition *int64 `json:"maxPercentUnhealthyReplicasPerPartition,omitempty"`
	MaxPercentUnhealthyServices             *int64 `json:"maxPercentUnhealthyServices,omitempty"`
}

type ArmUpgradeFailureAction

type ArmUpgradeFailureAction string
const (
	ArmUpgradeFailureActionManual   ArmUpgradeFailureAction = "Manual"
	ArmUpgradeFailureActionRollback ArmUpgradeFailureAction = "Rollback"
)

type ClusterId

type ClusterId struct {
	SubscriptionId    string
	ResourceGroupName string
	ClusterName       string
}

ClusterId is a struct representing the Resource ID for a Cluster

func NewClusterID

func NewClusterID(subscriptionId string, resourceGroupName string, clusterName string) ClusterId

NewClusterID returns a new ClusterId struct

func ParseClusterID

func ParseClusterID(input string) (*ClusterId, error)

ParseClusterID parses 'input' into a ClusterId

func ParseClusterIDInsensitively

func ParseClusterIDInsensitively(input string) (*ClusterId, error)

ParseClusterIDInsensitively parses 'input' case-insensitively into a ClusterId note: this method should only be used for API response data and not user input

func (ClusterId) ID

func (id ClusterId) ID() string

ID returns the formatted Cluster ID

func (ClusterId) Segments

func (id ClusterId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Cluster ID

func (ClusterId) String

func (id ClusterId) String() string

String returns a human-readable description of this Cluster ID

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *ApplicationResource
}

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	Model        *ApplicationResourceList
}

type RollingUpgradeMode

type RollingUpgradeMode string
const (
	RollingUpgradeModeInvalid           RollingUpgradeMode = "Invalid"
	RollingUpgradeModeMonitored         RollingUpgradeMode = "Monitored"
	RollingUpgradeModeUnmonitoredAuto   RollingUpgradeMode = "UnmonitoredAuto"
	RollingUpgradeModeUnmonitoredManual RollingUpgradeMode = "UnmonitoredManual"
)

type SystemData

type SystemData struct {
	CreatedAt          *string `json:"createdAt,omitempty"`
	CreatedBy          *string `json:"createdBy,omitempty"`
	CreatedByType      *string `json:"createdByType,omitempty"`
	LastModifiedAt     *string `json:"lastModifiedAt,omitempty"`
	LastModifiedBy     *string `json:"lastModifiedBy,omitempty"`
	LastModifiedByType *string `json:"lastModifiedByType,omitempty"`
}

func (*SystemData) GetCreatedAtAsTime

func (o *SystemData) GetCreatedAtAsTime() (*time.Time, error)

func (*SystemData) GetLastModifiedAtAsTime

func (o *SystemData) GetLastModifiedAtAsTime() (*time.Time, error)

func (*SystemData) SetCreatedAtAsTime

func (o *SystemData) SetCreatedAtAsTime(input time.Time)

func (*SystemData) SetLastModifiedAtAsTime

func (o *SystemData) SetLastModifiedAtAsTime(input time.Time)

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

Jump to

Keyboard shortcuts

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