afdorigingroups

package
v0.20241209.1115630 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: MPL-2.0 Imports: 13 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/cdn/2024-02-01/afdorigingroups Documentation

The afdorigingroups SDK allows for interaction with Azure Resource Manager cdn (API Version 2024-02-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/cdn/2024-02-01/afdorigingroups"

Client Initialization

client := afdorigingroups.NewAFDOriginGroupsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: AFDOriginGroupsClient.Create

ctx := context.TODO()
id := afdorigingroups.NewOriginGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName", "originGroupName")

payload := afdorigingroups.AFDOriginGroup{
	// ...
}


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

Example Usage: AFDOriginGroupsClient.Delete

ctx := context.TODO()
id := afdorigingroups.NewOriginGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName", "originGroupName")

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

Example Usage: AFDOriginGroupsClient.Get

ctx := context.TODO()
id := afdorigingroups.NewOriginGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName", "originGroupName")

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: AFDOriginGroupsClient.ListByProfile

ctx := context.TODO()
id := afdorigingroups.NewProfileID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName")

// alternatively `client.ListByProfile(ctx, id)` can be used to do batched pagination
items, err := client.ListByProfileComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: AFDOriginGroupsClient.ListResourceUsage

ctx := context.TODO()
id := afdorigingroups.NewOriginGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName", "originGroupName")

// alternatively `client.ListResourceUsage(ctx, id)` can be used to do batched pagination
items, err := client.ListResourceUsageComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: AFDOriginGroupsClient.Update

ctx := context.TODO()
id := afdorigingroups.NewOriginGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "profileName", "originGroupName")

payload := afdorigingroups.AFDOriginGroupUpdateParameters{
	// ...
}


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 PossibleValuesForAfdProvisioningState

func PossibleValuesForAfdProvisioningState() []string

func PossibleValuesForDeploymentStatus

func PossibleValuesForDeploymentStatus() []string

func PossibleValuesForEnabledState

func PossibleValuesForEnabledState() []string

func PossibleValuesForHealthProbeRequestType

func PossibleValuesForHealthProbeRequestType() []string

func PossibleValuesForProbeProtocol

func PossibleValuesForProbeProtocol() []string

func PossibleValuesForUsageUnit

func PossibleValuesForUsageUnit() []string

func ValidateOriginGroupID

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

ValidateOriginGroupID checks that 'input' can be parsed as a Origin Group ID

func ValidateProfileID

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

ValidateProfileID checks that 'input' can be parsed as a Profile ID

Types

type AFDOriginGroup

type AFDOriginGroup struct {
	Id         *string                   `json:"id,omitempty"`
	Name       *string                   `json:"name,omitempty"`
	Properties *AFDOriginGroupProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData    `json:"systemData,omitempty"`
	Type       *string                   `json:"type,omitempty"`
}

type AFDOriginGroupOperationPredicate

type AFDOriginGroupOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (AFDOriginGroupOperationPredicate) Matches

type AFDOriginGroupProperties

type AFDOriginGroupProperties struct {
	DeploymentStatus                                      *DeploymentStatus                `json:"deploymentStatus,omitempty"`
	HealthProbeSettings                                   *HealthProbeParameters           `json:"healthProbeSettings,omitempty"`
	LoadBalancingSettings                                 *LoadBalancingSettingsParameters `json:"loadBalancingSettings,omitempty"`
	ProfileName                                           *string                          `json:"profileName,omitempty"`
	ProvisioningState                                     *AfdProvisioningState            `json:"provisioningState,omitempty"`
	SessionAffinityState                                  *EnabledState                    `json:"sessionAffinityState,omitempty"`
	TrafficRestorationTimeToHealedOrNewEndpointsInMinutes *int64                           `json:"trafficRestorationTimeToHealedOrNewEndpointsInMinutes,omitempty"`
}

type AFDOriginGroupUpdateParameters

type AFDOriginGroupUpdateParameters struct {
	Properties *AFDOriginGroupUpdatePropertiesParameters `json:"properties,omitempty"`
}

type AFDOriginGroupUpdatePropertiesParameters

type AFDOriginGroupUpdatePropertiesParameters struct {
	HealthProbeSettings                                   *HealthProbeParameters           `json:"healthProbeSettings,omitempty"`
	LoadBalancingSettings                                 *LoadBalancingSettingsParameters `json:"loadBalancingSettings,omitempty"`
	ProfileName                                           *string                          `json:"profileName,omitempty"`
	SessionAffinityState                                  *EnabledState                    `json:"sessionAffinityState,omitempty"`
	TrafficRestorationTimeToHealedOrNewEndpointsInMinutes *int64                           `json:"trafficRestorationTimeToHealedOrNewEndpointsInMinutes,omitempty"`
}

type AFDOriginGroupsClient

type AFDOriginGroupsClient struct {
	Client *resourcemanager.Client
}

func NewAFDOriginGroupsClientWithBaseURI

func NewAFDOriginGroupsClientWithBaseURI(sdkApi sdkEnv.Api) (*AFDOriginGroupsClient, error)

func (AFDOriginGroupsClient) Create

Create ...

func (AFDOriginGroupsClient) CreateThenPoll

func (c AFDOriginGroupsClient) CreateThenPoll(ctx context.Context, id OriginGroupId, input AFDOriginGroup) error

CreateThenPoll performs Create then polls until it's completed

func (AFDOriginGroupsClient) Delete

Delete ...

func (AFDOriginGroupsClient) DeleteThenPoll

func (c AFDOriginGroupsClient) DeleteThenPoll(ctx context.Context, id OriginGroupId) error

DeleteThenPoll performs Delete then polls until it's completed

func (AFDOriginGroupsClient) Get

Get ...

func (AFDOriginGroupsClient) ListByProfile

func (c AFDOriginGroupsClient) ListByProfile(ctx context.Context, id ProfileId) (result ListByProfileOperationResponse, err error)

ListByProfile ...

func (AFDOriginGroupsClient) ListByProfileComplete

ListByProfileComplete retrieves all the results into a single object

func (AFDOriginGroupsClient) ListByProfileCompleteMatchingPredicate

func (c AFDOriginGroupsClient) ListByProfileCompleteMatchingPredicate(ctx context.Context, id ProfileId, predicate AFDOriginGroupOperationPredicate) (result ListByProfileCompleteResult, err error)

ListByProfileCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (AFDOriginGroupsClient) ListResourceUsage

ListResourceUsage ...

func (AFDOriginGroupsClient) ListResourceUsageComplete

ListResourceUsageComplete retrieves all the results into a single object

func (AFDOriginGroupsClient) ListResourceUsageCompleteMatchingPredicate

func (c AFDOriginGroupsClient) ListResourceUsageCompleteMatchingPredicate(ctx context.Context, id OriginGroupId, predicate UsageOperationPredicate) (result ListResourceUsageCompleteResult, err error)

ListResourceUsageCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (AFDOriginGroupsClient) Update

Update ...

func (AFDOriginGroupsClient) UpdateThenPoll

UpdateThenPoll performs Update then polls until it's completed

type AfdProvisioningState

type AfdProvisioningState string
const (
	AfdProvisioningStateCreating  AfdProvisioningState = "Creating"
	AfdProvisioningStateDeleting  AfdProvisioningState = "Deleting"
	AfdProvisioningStateFailed    AfdProvisioningState = "Failed"
	AfdProvisioningStateSucceeded AfdProvisioningState = "Succeeded"
	AfdProvisioningStateUpdating  AfdProvisioningState = "Updating"
)

func (*AfdProvisioningState) UnmarshalJSON

func (s *AfdProvisioningState) UnmarshalJSON(bytes []byte) error

type CreateOperationResponse

type CreateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *AFDOriginGroup
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type DeploymentStatus

type DeploymentStatus string
const (
	DeploymentStatusFailed     DeploymentStatus = "Failed"
	DeploymentStatusInProgress DeploymentStatus = "InProgress"
	DeploymentStatusNotStarted DeploymentStatus = "NotStarted"
	DeploymentStatusSucceeded  DeploymentStatus = "Succeeded"
)

func (*DeploymentStatus) UnmarshalJSON

func (s *DeploymentStatus) UnmarshalJSON(bytes []byte) error

type EnabledState

type EnabledState string
const (
	EnabledStateDisabled EnabledState = "Disabled"
	EnabledStateEnabled  EnabledState = "Enabled"
)

func (*EnabledState) UnmarshalJSON

func (s *EnabledState) UnmarshalJSON(bytes []byte) error

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *AFDOriginGroup
}

type HealthProbeParameters

type HealthProbeParameters struct {
	ProbeIntervalInSeconds *int64                  `json:"probeIntervalInSeconds,omitempty"`
	ProbePath              *string                 `json:"probePath,omitempty"`
	ProbeProtocol          *ProbeProtocol          `json:"probeProtocol,omitempty"`
	ProbeRequestType       *HealthProbeRequestType `json:"probeRequestType,omitempty"`
}

type HealthProbeRequestType

type HealthProbeRequestType string
const (
	HealthProbeRequestTypeGET    HealthProbeRequestType = "GET"
	HealthProbeRequestTypeHEAD   HealthProbeRequestType = "HEAD"
	HealthProbeRequestTypeNotSet HealthProbeRequestType = "NotSet"
)

func (*HealthProbeRequestType) UnmarshalJSON

func (s *HealthProbeRequestType) UnmarshalJSON(bytes []byte) error

type ListByProfileCompleteResult

type ListByProfileCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []AFDOriginGroup
}

type ListByProfileCustomPager

type ListByProfileCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByProfileCustomPager) NextPageLink() *odata.Link

type ListByProfileOperationResponse

type ListByProfileOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]AFDOriginGroup
}

type ListResourceUsageCompleteResult

type ListResourceUsageCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Usage
}

type ListResourceUsageCustomPager

type ListResourceUsageCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListResourceUsageCustomPager) NextPageLink() *odata.Link

type ListResourceUsageOperationResponse

type ListResourceUsageOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Usage
}

type LoadBalancingSettingsParameters

type LoadBalancingSettingsParameters struct {
	AdditionalLatencyInMilliseconds *int64 `json:"additionalLatencyInMilliseconds,omitempty"`
	SampleSize                      *int64 `json:"sampleSize,omitempty"`
	SuccessfulSamplesRequired       *int64 `json:"successfulSamplesRequired,omitempty"`
}

type OriginGroupId

type OriginGroupId struct {
	SubscriptionId    string
	ResourceGroupName string
	ProfileName       string
	OriginGroupName   string
}

OriginGroupId is a struct representing the Resource ID for a Origin Group

func NewOriginGroupID

func NewOriginGroupID(subscriptionId string, resourceGroupName string, profileName string, originGroupName string) OriginGroupId

NewOriginGroupID returns a new OriginGroupId struct

func ParseOriginGroupID

func ParseOriginGroupID(input string) (*OriginGroupId, error)

ParseOriginGroupID parses 'input' into a OriginGroupId

func ParseOriginGroupIDInsensitively

func ParseOriginGroupIDInsensitively(input string) (*OriginGroupId, error)

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

func (*OriginGroupId) FromParseResult

func (id *OriginGroupId) FromParseResult(input resourceids.ParseResult) error

func (OriginGroupId) ID

func (id OriginGroupId) ID() string

ID returns the formatted Origin Group ID

func (OriginGroupId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Origin Group ID

func (OriginGroupId) String

func (id OriginGroupId) String() string

String returns a human-readable description of this Origin Group ID

type ProbeProtocol

type ProbeProtocol string
const (
	ProbeProtocolHTTP   ProbeProtocol = "Http"
	ProbeProtocolHTTPS  ProbeProtocol = "Https"
	ProbeProtocolNotSet ProbeProtocol = "NotSet"
)

func (*ProbeProtocol) UnmarshalJSON

func (s *ProbeProtocol) UnmarshalJSON(bytes []byte) error

type ProfileId

type ProfileId struct {
	SubscriptionId    string
	ResourceGroupName string
	ProfileName       string
}

ProfileId is a struct representing the Resource ID for a Profile

func NewProfileID

func NewProfileID(subscriptionId string, resourceGroupName string, profileName string) ProfileId

NewProfileID returns a new ProfileId struct

func ParseProfileID

func ParseProfileID(input string) (*ProfileId, error)

ParseProfileID parses 'input' into a ProfileId

func ParseProfileIDInsensitively

func ParseProfileIDInsensitively(input string) (*ProfileId, error)

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

func (*ProfileId) FromParseResult

func (id *ProfileId) FromParseResult(input resourceids.ParseResult) error

func (ProfileId) ID

func (id ProfileId) ID() string

ID returns the formatted Profile ID

func (ProfileId) Segments

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

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

func (ProfileId) String

func (id ProfileId) String() string

String returns a human-readable description of this Profile ID

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *AFDOriginGroup
}

type Usage

type Usage struct {
	CurrentValue int64     `json:"currentValue"`
	Id           *string   `json:"id,omitempty"`
	Limit        int64     `json:"limit"`
	Name         UsageName `json:"name"`
	Unit         UsageUnit `json:"unit"`
}

type UsageName

type UsageName struct {
	LocalizedValue *string `json:"localizedValue,omitempty"`
	Value          *string `json:"value,omitempty"`
}

type UsageOperationPredicate

type UsageOperationPredicate struct {
	CurrentValue *int64
	Id           *string
	Limit        *int64
}

func (UsageOperationPredicate) Matches

func (p UsageOperationPredicate) Matches(input Usage) bool

type UsageUnit

type UsageUnit string
const (
	UsageUnitCount UsageUnit = "Count"
)

func (*UsageUnit) UnmarshalJSON

func (s *UsageUnit) UnmarshalJSON(bytes []byte) error

Jump to

Keyboard shortcuts

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