Documentation ¶
Index ¶
- type APIServerAccessProfile
- type ActionType
- type AgentProfile
- type AutoUpgradeNodeImageSelection
- type AutoUpgradeNodeImageSelectionType
- type AutoUpgradeProfile
- type AutoUpgradeProfileListResult
- type AutoUpgradeProfileProperties
- type AutoUpgradeProfileProvisioningState
- type AutoUpgradeProfilesClient
- func (client *AutoUpgradeProfilesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[AutoUpgradeProfilesClientCreateOrUpdateResponse], error)
- func (client *AutoUpgradeProfilesClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[AutoUpgradeProfilesClientDeleteResponse], error)
- func (client *AutoUpgradeProfilesClient) Get(ctx context.Context, resourceGroupName string, fleetName string, ...) (AutoUpgradeProfilesClientGetResponse, error)
- func (client *AutoUpgradeProfilesClient) NewListByFleetPager(resourceGroupName string, fleetName string, ...) *runtime.Pager[AutoUpgradeProfilesClientListByFleetResponse]
- type AutoUpgradeProfilesClientBeginCreateOrUpdateOptions
- type AutoUpgradeProfilesClientBeginDeleteOptions
- type AutoUpgradeProfilesClientCreateOrUpdateResponse
- type AutoUpgradeProfilesClientDeleteResponse
- type AutoUpgradeProfilesClientGetOptions
- type AutoUpgradeProfilesClientGetResponse
- type AutoUpgradeProfilesClientListByFleetOptions
- type AutoUpgradeProfilesClientListByFleetResponse
- type ClientFactory
- func (c *ClientFactory) NewAutoUpgradeProfilesClient() *AutoUpgradeProfilesClient
- func (c *ClientFactory) NewFleetMembersClient() *FleetMembersClient
- func (c *ClientFactory) NewFleetUpdateStrategiesClient() *FleetUpdateStrategiesClient
- func (c *ClientFactory) NewFleetsClient() *FleetsClient
- func (c *ClientFactory) NewOperationsClient() *OperationsClient
- func (c *ClientFactory) NewUpdateRunsClient() *UpdateRunsClient
- type CreatedByType
- type ErrorAdditionalInfo
- type ErrorDetail
- type Fleet
- type FleetCredentialResult
- type FleetCredentialResults
- type FleetHubProfile
- type FleetListResult
- type FleetMember
- type FleetMemberListResult
- type FleetMemberProperties
- type FleetMemberProvisioningState
- type FleetMemberUpdate
- type FleetMemberUpdateProperties
- type FleetMembersClient
- func (client *FleetMembersClient) BeginCreate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetMembersClientCreateResponse], error)
- func (client *FleetMembersClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetMembersClientDeleteResponse], error)
- func (client *FleetMembersClient) BeginUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetMembersClientUpdateResponse], error)
- func (client *FleetMembersClient) Get(ctx context.Context, resourceGroupName string, fleetName string, ...) (FleetMembersClientGetResponse, error)
- func (client *FleetMembersClient) NewListByFleetPager(resourceGroupName string, fleetName string, ...) *runtime.Pager[FleetMembersClientListByFleetResponse]
- type FleetMembersClientBeginCreateOptions
- type FleetMembersClientBeginDeleteOptions
- type FleetMembersClientBeginUpdateOptions
- type FleetMembersClientCreateResponse
- type FleetMembersClientDeleteResponse
- type FleetMembersClientGetOptions
- type FleetMembersClientGetResponse
- type FleetMembersClientListByFleetOptions
- type FleetMembersClientListByFleetResponse
- type FleetMembersClientUpdateResponse
- type FleetPatch
- type FleetProperties
- type FleetProvisioningState
- type FleetUpdateStrategiesClient
- func (client *FleetUpdateStrategiesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetUpdateStrategiesClientCreateOrUpdateResponse], error)
- func (client *FleetUpdateStrategiesClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetUpdateStrategiesClientDeleteResponse], error)
- func (client *FleetUpdateStrategiesClient) Get(ctx context.Context, resourceGroupName string, fleetName string, ...) (FleetUpdateStrategiesClientGetResponse, error)
- func (client *FleetUpdateStrategiesClient) NewListByFleetPager(resourceGroupName string, fleetName string, ...) *runtime.Pager[FleetUpdateStrategiesClientListByFleetResponse]
- type FleetUpdateStrategiesClientBeginCreateOrUpdateOptions
- type FleetUpdateStrategiesClientBeginDeleteOptions
- type FleetUpdateStrategiesClientCreateOrUpdateResponse
- type FleetUpdateStrategiesClientDeleteResponse
- type FleetUpdateStrategiesClientGetOptions
- type FleetUpdateStrategiesClientGetResponse
- type FleetUpdateStrategiesClientListByFleetOptions
- type FleetUpdateStrategiesClientListByFleetResponse
- type FleetUpdateStrategy
- type FleetUpdateStrategyListResult
- type FleetUpdateStrategyProperties
- type FleetUpdateStrategyProvisioningState
- type FleetsClient
- func (client *FleetsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetsClientCreateOrUpdateResponse], error)
- func (client *FleetsClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetsClientDeleteResponse], error)
- func (client *FleetsClient) BeginUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[FleetsClientUpdateResponse], error)
- func (client *FleetsClient) Get(ctx context.Context, resourceGroupName string, fleetName string, ...) (FleetsClientGetResponse, error)
- func (client *FleetsClient) ListCredentials(ctx context.Context, resourceGroupName string, fleetName string, ...) (FleetsClientListCredentialsResponse, error)
- func (client *FleetsClient) NewListByResourceGroupPager(resourceGroupName string, options *FleetsClientListByResourceGroupOptions) *runtime.Pager[FleetsClientListByResourceGroupResponse]
- func (client *FleetsClient) NewListBySubscriptionPager(options *FleetsClientListBySubscriptionOptions) *runtime.Pager[FleetsClientListBySubscriptionResponse]
- type FleetsClientBeginCreateOrUpdateOptions
- type FleetsClientBeginDeleteOptions
- type FleetsClientBeginUpdateOptions
- type FleetsClientCreateOrUpdateResponse
- type FleetsClientDeleteResponse
- type FleetsClientGetOptions
- type FleetsClientGetResponse
- type FleetsClientListByResourceGroupOptions
- type FleetsClientListByResourceGroupResponse
- type FleetsClientListBySubscriptionOptions
- type FleetsClientListBySubscriptionResponse
- type FleetsClientListCredentialsOptions
- type FleetsClientListCredentialsResponse
- type FleetsClientUpdateResponse
- type ManagedClusterUpdate
- type ManagedClusterUpgradeSpec
- type ManagedClusterUpgradeType
- type ManagedServiceIdentity
- type ManagedServiceIdentityType
- type MemberUpdateStatus
- type NodeImageSelection
- type NodeImageSelectionStatus
- type NodeImageSelectionType
- type NodeImageVersion
- type Operation
- type OperationDisplay
- type OperationListResult
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type Origin
- type SkipProperties
- type SkipTarget
- type SystemData
- type TargetType
- type UpdateGroup
- type UpdateGroupStatus
- type UpdateRun
- type UpdateRunListResult
- type UpdateRunProperties
- type UpdateRunProvisioningState
- type UpdateRunStatus
- type UpdateRunStrategy
- type UpdateRunsClient
- func (client *UpdateRunsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[UpdateRunsClientCreateOrUpdateResponse], error)
- func (client *UpdateRunsClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[UpdateRunsClientDeleteResponse], error)
- func (client *UpdateRunsClient) BeginSkip(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[UpdateRunsClientSkipResponse], error)
- func (client *UpdateRunsClient) BeginStart(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[UpdateRunsClientStartResponse], error)
- func (client *UpdateRunsClient) BeginStop(ctx context.Context, resourceGroupName string, fleetName string, ...) (*runtime.Poller[UpdateRunsClientStopResponse], error)
- func (client *UpdateRunsClient) Get(ctx context.Context, resourceGroupName string, fleetName string, ...) (UpdateRunsClientGetResponse, error)
- func (client *UpdateRunsClient) NewListByFleetPager(resourceGroupName string, fleetName string, ...) *runtime.Pager[UpdateRunsClientListByFleetResponse]
- type UpdateRunsClientBeginCreateOrUpdateOptions
- type UpdateRunsClientBeginDeleteOptions
- type UpdateRunsClientBeginSkipOptions
- type UpdateRunsClientBeginStartOptions
- type UpdateRunsClientBeginStopOptions
- type UpdateRunsClientCreateOrUpdateResponse
- type UpdateRunsClientDeleteResponse
- type UpdateRunsClientGetOptions
- type UpdateRunsClientGetResponse
- type UpdateRunsClientListByFleetOptions
- type UpdateRunsClientListByFleetResponse
- type UpdateRunsClientSkipResponse
- type UpdateRunsClientStartResponse
- type UpdateRunsClientStopResponse
- type UpdateStage
- type UpdateStageStatus
- type UpdateState
- type UpdateStatus
- type UpgradeChannel
- type UserAssignedIdentity
- type WaitStatus
Examples ¶
- AutoUpgradeProfilesClient.BeginCreateOrUpdate
- AutoUpgradeProfilesClient.BeginDelete
- AutoUpgradeProfilesClient.Get
- AutoUpgradeProfilesClient.NewListByFleetPager
- FleetMembersClient.BeginCreate
- FleetMembersClient.BeginDelete
- FleetMembersClient.BeginUpdate
- FleetMembersClient.Get
- FleetMembersClient.NewListByFleetPager
- FleetUpdateStrategiesClient.BeginCreateOrUpdate
- FleetUpdateStrategiesClient.BeginDelete
- FleetUpdateStrategiesClient.Get
- FleetUpdateStrategiesClient.NewListByFleetPager
- FleetsClient.BeginCreateOrUpdate
- FleetsClient.BeginDelete
- FleetsClient.BeginUpdate
- FleetsClient.Get
- FleetsClient.ListCredentials
- FleetsClient.NewListByResourceGroupPager
- FleetsClient.NewListBySubscriptionPager
- OperationsClient.NewListPager
- UpdateRunsClient.BeginCreateOrUpdate
- UpdateRunsClient.BeginDelete
- UpdateRunsClient.BeginSkip
- UpdateRunsClient.BeginStart
- UpdateRunsClient.BeginStop
- UpdateRunsClient.Get
- UpdateRunsClient.NewListByFleetPager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIServerAccessProfile ¶
type APIServerAccessProfile struct { // Whether to create the Fleet hub as a private cluster or not. EnablePrivateCluster *bool // Whether to enable apiserver vnet integration for the Fleet hub or not. EnableVnetIntegration *bool // The subnet to be used when apiserver vnet integration is enabled. It is required when creating a new Fleet with BYO vnet. SubnetID *string }
APIServerAccessProfile - Access profile for the Fleet hub API server.
func (APIServerAccessProfile) MarshalJSON ¶
func (a APIServerAccessProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type APIServerAccessProfile.
func (*APIServerAccessProfile) UnmarshalJSON ¶
func (a *APIServerAccessProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type APIServerAccessProfile.
type ActionType ¶
type ActionType string
ActionType - Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
const (
ActionTypeInternal ActionType = "Internal"
)
func PossibleActionTypeValues ¶
func PossibleActionTypeValues() []ActionType
PossibleActionTypeValues returns the possible values for the ActionType const type.
type AgentProfile ¶
type AgentProfile struct { // The ID of the subnet which the Fleet hub node will join on startup. If this is not specified, a vnet and subnet will be // generated and used. SubnetID *string // The virtual machine size of the Fleet hub. VMSize *string }
AgentProfile - Agent profile for the Fleet hub.
func (AgentProfile) MarshalJSON ¶
func (a AgentProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AgentProfile.
func (*AgentProfile) UnmarshalJSON ¶
func (a *AgentProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AgentProfile.
type AutoUpgradeNodeImageSelection ¶
type AutoUpgradeNodeImageSelection struct { // REQUIRED; The node image upgrade type. Type *AutoUpgradeNodeImageSelectionType }
AutoUpgradeNodeImageSelection - The node image upgrade to be applied to the target clusters in auto upgrade.
func (AutoUpgradeNodeImageSelection) MarshalJSON ¶
func (a AutoUpgradeNodeImageSelection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AutoUpgradeNodeImageSelection.
func (*AutoUpgradeNodeImageSelection) UnmarshalJSON ¶
func (a *AutoUpgradeNodeImageSelection) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AutoUpgradeNodeImageSelection.
type AutoUpgradeNodeImageSelectionType ¶
type AutoUpgradeNodeImageSelectionType string
AutoUpgradeNodeImageSelectionType - The node image upgrade type.
const ( // AutoUpgradeNodeImageSelectionTypeConsistent - The image versions to upgrade nodes to are selected as described below: for // each node pool in managed clusters affected by the update run, the system selects the latest image version such that it // is available across all other node pools (in all other clusters) of the same image type. As a result, all node pools of // the same image type will be upgraded to the same image version. For example, if the latest image version for image type // 'AKSUbuntu-1804gen2containerd' is 'AKSUbuntu-1804gen2containerd-2021.10.12' for a node pool in cluster A in region X, and // is 'AKSUbuntu-1804gen2containerd-2021.10.17' for a node pool in cluster B in region Y, the system will upgrade both node // pools to image version 'AKSUbuntu-1804gen2containerd-2021.10.12'. AutoUpgradeNodeImageSelectionTypeConsistent AutoUpgradeNodeImageSelectionType = "Consistent" // AutoUpgradeNodeImageSelectionTypeLatest - Use the latest image version when upgrading nodes. Clusters may use different // image versions (e.g., 'AKSUbuntu-1804gen2containerd-2021.10.12' and 'AKSUbuntu-1804gen2containerd-2021.10.19') because, // for example, the latest available version is different in different regions. AutoUpgradeNodeImageSelectionTypeLatest AutoUpgradeNodeImageSelectionType = "Latest" )
func PossibleAutoUpgradeNodeImageSelectionTypeValues ¶
func PossibleAutoUpgradeNodeImageSelectionTypeValues() []AutoUpgradeNodeImageSelectionType
PossibleAutoUpgradeNodeImageSelectionTypeValues returns the possible values for the AutoUpgradeNodeImageSelectionType const type.
type AutoUpgradeProfile ¶
type AutoUpgradeProfile struct { // The resource-specific properties for this resource. Properties *AutoUpgradeProfileProperties // READ-ONLY; If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. // Entity tags are used for comparing two or more entities from the same requested resource. // HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range // (section 14.27) header fields. ETag *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; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
AutoUpgradeProfile - The AutoUpgradeProfile resource.
func (AutoUpgradeProfile) MarshalJSON ¶
func (a AutoUpgradeProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AutoUpgradeProfile.
func (*AutoUpgradeProfile) UnmarshalJSON ¶
func (a *AutoUpgradeProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AutoUpgradeProfile.
type AutoUpgradeProfileListResult ¶
type AutoUpgradeProfileListResult struct { // REQUIRED; The AutoUpgradeProfile items on this page Value []*AutoUpgradeProfile // The link to the next page of items NextLink *string }
AutoUpgradeProfileListResult - The response of a AutoUpgradeProfile list operation.
func (AutoUpgradeProfileListResult) MarshalJSON ¶
func (a AutoUpgradeProfileListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AutoUpgradeProfileListResult.
func (*AutoUpgradeProfileListResult) UnmarshalJSON ¶
func (a *AutoUpgradeProfileListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AutoUpgradeProfileListResult.
type AutoUpgradeProfileProperties ¶
type AutoUpgradeProfileProperties struct { // REQUIRED; Configures how auto-upgrade will be run. Channel *UpgradeChannel // If set to False: the auto upgrade has effect - target managed clusters will be upgraded on schedule. If set to True: the // auto upgrade has no effect - no upgrade will be run on the target managed // clusters. This is a boolean and not an enum because enabled/disabled are all available states of the auto upgrade profile. // By default, this is set to False. Disabled *bool // The node image upgrade to be applied to the target clusters in auto upgrade. NodeImageSelection *AutoUpgradeNodeImageSelection // The resource id of the UpdateStrategy resource to reference. If not specified, the auto upgrade will run on all clusters // which are members of the fleet. UpdateStrategyID *string // READ-ONLY; The provisioning state of the AutoUpgradeProfile resource. ProvisioningState *AutoUpgradeProfileProvisioningState }
AutoUpgradeProfileProperties - The properties of the AutoUpgradeProfile.
func (AutoUpgradeProfileProperties) MarshalJSON ¶
func (a AutoUpgradeProfileProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AutoUpgradeProfileProperties.
func (*AutoUpgradeProfileProperties) UnmarshalJSON ¶
func (a *AutoUpgradeProfileProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AutoUpgradeProfileProperties.
type AutoUpgradeProfileProvisioningState ¶
type AutoUpgradeProfileProvisioningState string
AutoUpgradeProfileProvisioningState - The provisioning state of the AutoUpgradeProfile resource.
const ( // AutoUpgradeProfileProvisioningStateCanceled - Resource creation was canceled. AutoUpgradeProfileProvisioningStateCanceled AutoUpgradeProfileProvisioningState = "Canceled" // AutoUpgradeProfileProvisioningStateFailed - Resource creation failed. AutoUpgradeProfileProvisioningStateFailed AutoUpgradeProfileProvisioningState = "Failed" // AutoUpgradeProfileProvisioningStateSucceeded - Resource has been created. AutoUpgradeProfileProvisioningStateSucceeded AutoUpgradeProfileProvisioningState = "Succeeded" )
func PossibleAutoUpgradeProfileProvisioningStateValues ¶
func PossibleAutoUpgradeProfileProvisioningStateValues() []AutoUpgradeProfileProvisioningState
PossibleAutoUpgradeProfileProvisioningStateValues returns the possible values for the AutoUpgradeProfileProvisioningState const type.
type AutoUpgradeProfilesClient ¶
type AutoUpgradeProfilesClient struct {
// contains filtered or unexported fields
}
AutoUpgradeProfilesClient contains the methods for the AutoUpgradeProfiles group. Don't use this type directly, use NewAutoUpgradeProfilesClient() instead.
func NewAutoUpgradeProfilesClient ¶
func NewAutoUpgradeProfilesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*AutoUpgradeProfilesClient, error)
NewAutoUpgradeProfilesClient creates a new instance of AutoUpgradeProfilesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*AutoUpgradeProfilesClient) BeginCreateOrUpdate ¶
func (client *AutoUpgradeProfilesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, autoUpgradeProfileName string, resource AutoUpgradeProfile, options *AutoUpgradeProfilesClientBeginCreateOrUpdateOptions) (*runtime.Poller[AutoUpgradeProfilesClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - Create a AutoUpgradeProfile If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- autoUpgradeProfileName - The name of the AutoUpgradeProfile resource.
- resource - Resource create parameters.
- options - AutoUpgradeProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the AutoUpgradeProfilesClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/AutoUpgradeProfiles_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewAutoUpgradeProfilesClient().BeginCreateOrUpdate(ctx, "rg1", "fleet1", "autoupgradeprofile1", armcontainerservicefleet.AutoUpgradeProfile{ Properties: &armcontainerservicefleet.AutoUpgradeProfileProperties{ Channel: to.Ptr(armcontainerservicefleet.UpgradeChannelStable), }, }, &armcontainerservicefleet.AutoUpgradeProfilesClientBeginCreateOrUpdateOptions{IfMatch: nil, IfNoneMatch: nil, }) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.AutoUpgradeProfile = armcontainerservicefleet.AutoUpgradeProfile{ // Name: to.Ptr("autoupgradeprofile1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/autoUpgradeProfiles"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/autoUpgradeProfiles/autoupgradeprofile1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.AutoUpgradeProfileProperties{ // Channel: to.Ptr(armcontainerservicefleet.UpgradeChannelStable), // ProvisioningState: to.Ptr(armcontainerservicefleet.AutoUpgradeProfileProvisioningStateSucceeded), // }, // } }
Output:
func (*AutoUpgradeProfilesClient) BeginDelete ¶
func (client *AutoUpgradeProfilesClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, autoUpgradeProfileName string, options *AutoUpgradeProfilesClientBeginDeleteOptions) (*runtime.Poller[AutoUpgradeProfilesClientDeleteResponse], error)
BeginDelete - Delete a AutoUpgradeProfile If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- autoUpgradeProfileName - The name of the AutoUpgradeProfile resource.
- options - AutoUpgradeProfilesClientBeginDeleteOptions contains the optional parameters for the AutoUpgradeProfilesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/AutoUpgradeProfiles_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewAutoUpgradeProfilesClient().BeginDelete(ctx, "rg1", "fleet1", "autoupgradeprofile1", &armcontainerservicefleet.AutoUpgradeProfilesClientBeginDeleteOptions{IfMatch: 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 (*AutoUpgradeProfilesClient) Get ¶
func (client *AutoUpgradeProfilesClient) Get(ctx context.Context, resourceGroupName string, fleetName string, autoUpgradeProfileName string, options *AutoUpgradeProfilesClientGetOptions) (AutoUpgradeProfilesClientGetResponse, error)
Get - Get a AutoUpgradeProfile If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- autoUpgradeProfileName - The name of the AutoUpgradeProfile resource.
- options - AutoUpgradeProfilesClientGetOptions contains the optional parameters for the AutoUpgradeProfilesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/AutoUpgradeProfiles_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewAutoUpgradeProfilesClient().Get(ctx, "rg1", "fleet1", "autoupgradeprofile1", 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.AutoUpgradeProfile = armcontainerservicefleet.AutoUpgradeProfile{ // Name: to.Ptr("autoupgradeprofile1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/autoUpgradeProfiles"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/autoUpgradeProfiles/autoupgradeprofile1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.AutoUpgradeProfileProperties{ // Channel: to.Ptr(armcontainerservicefleet.UpgradeChannelStable), // ProvisioningState: to.Ptr(armcontainerservicefleet.AutoUpgradeProfileProvisioningStateSucceeded), // }, // } }
Output:
func (*AutoUpgradeProfilesClient) NewListByFleetPager ¶
func (client *AutoUpgradeProfilesClient) NewListByFleetPager(resourceGroupName string, fleetName string, options *AutoUpgradeProfilesClientListByFleetOptions) *runtime.Pager[AutoUpgradeProfilesClientListByFleetResponse]
NewListByFleetPager - List AutoUpgradeProfile resources by Fleet
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - AutoUpgradeProfilesClientListByFleetOptions contains the optional parameters for the AutoUpgradeProfilesClient.NewListByFleetPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/AutoUpgradeProfiles_ListByFleet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewAutoUpgradeProfilesClient().NewListByFleetPager("rg1", "fleet1", nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.AutoUpgradeProfileListResult = armcontainerservicefleet.AutoUpgradeProfileListResult{ // Value: []*armcontainerservicefleet.AutoUpgradeProfile{ // { // Name: to.Ptr("autoupgradeprofile1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/autoUpgradeProfiles"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/autoUpgradeProfiles/autoupgradeprofile1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.AutoUpgradeProfileProperties{ // Channel: to.Ptr(armcontainerservicefleet.UpgradeChannelStable), // ProvisioningState: to.Ptr(armcontainerservicefleet.AutoUpgradeProfileProvisioningStateSucceeded), // }, // }}, // } } }
Output:
type AutoUpgradeProfilesClientBeginCreateOrUpdateOptions ¶
type AutoUpgradeProfilesClientBeginCreateOrUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // The request should only proceed if no entity matches this string. IfNoneMatch *string // Resumes the LRO from the provided token. ResumeToken string }
AutoUpgradeProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the AutoUpgradeProfilesClient.BeginCreateOrUpdate method.
type AutoUpgradeProfilesClientBeginDeleteOptions ¶
type AutoUpgradeProfilesClientBeginDeleteOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
AutoUpgradeProfilesClientBeginDeleteOptions contains the optional parameters for the AutoUpgradeProfilesClient.BeginDelete method.
type AutoUpgradeProfilesClientCreateOrUpdateResponse ¶
type AutoUpgradeProfilesClientCreateOrUpdateResponse struct { // The AutoUpgradeProfile resource. AutoUpgradeProfile }
AutoUpgradeProfilesClientCreateOrUpdateResponse contains the response from method AutoUpgradeProfilesClient.BeginCreateOrUpdate.
type AutoUpgradeProfilesClientDeleteResponse ¶
type AutoUpgradeProfilesClientDeleteResponse struct { }
AutoUpgradeProfilesClientDeleteResponse contains the response from method AutoUpgradeProfilesClient.BeginDelete.
type AutoUpgradeProfilesClientGetOptions ¶
type AutoUpgradeProfilesClientGetOptions struct { }
AutoUpgradeProfilesClientGetOptions contains the optional parameters for the AutoUpgradeProfilesClient.Get method.
type AutoUpgradeProfilesClientGetResponse ¶
type AutoUpgradeProfilesClientGetResponse struct { // The AutoUpgradeProfile resource. AutoUpgradeProfile }
AutoUpgradeProfilesClientGetResponse contains the response from method AutoUpgradeProfilesClient.Get.
type AutoUpgradeProfilesClientListByFleetOptions ¶
type AutoUpgradeProfilesClientListByFleetOptions struct { }
AutoUpgradeProfilesClientListByFleetOptions contains the optional parameters for the AutoUpgradeProfilesClient.NewListByFleetPager method.
type AutoUpgradeProfilesClientListByFleetResponse ¶
type AutoUpgradeProfilesClientListByFleetResponse struct { // The response of a AutoUpgradeProfile list operation. AutoUpgradeProfileListResult }
AutoUpgradeProfilesClientListByFleetResponse contains the response from method AutoUpgradeProfilesClient.NewListByFleetPager.
type ClientFactory ¶
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 ¶
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 - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ClientFactory) NewAutoUpgradeProfilesClient ¶
func (c *ClientFactory) NewAutoUpgradeProfilesClient() *AutoUpgradeProfilesClient
NewAutoUpgradeProfilesClient creates a new instance of AutoUpgradeProfilesClient.
func (*ClientFactory) NewFleetMembersClient ¶
func (c *ClientFactory) NewFleetMembersClient() *FleetMembersClient
NewFleetMembersClient creates a new instance of FleetMembersClient.
func (*ClientFactory) NewFleetUpdateStrategiesClient ¶
func (c *ClientFactory) NewFleetUpdateStrategiesClient() *FleetUpdateStrategiesClient
NewFleetUpdateStrategiesClient creates a new instance of FleetUpdateStrategiesClient.
func (*ClientFactory) NewFleetsClient ¶
func (c *ClientFactory) NewFleetsClient() *FleetsClient
NewFleetsClient creates a new instance of FleetsClient.
func (*ClientFactory) NewOperationsClient ¶
func (c *ClientFactory) NewOperationsClient() *OperationsClient
NewOperationsClient creates a new instance of OperationsClient.
func (*ClientFactory) NewUpdateRunsClient ¶
func (c *ClientFactory) NewUpdateRunsClient() *UpdateRunsClient
NewUpdateRunsClient creates a new instance of UpdateRunsClient.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
type ErrorAdditionalInfo ¶
type ErrorAdditionalInfo struct { // READ-ONLY; The additional info. Info any // READ-ONLY; The additional info type. Type *string }
ErrorAdditionalInfo - The resource management error additional info.
func (ErrorAdditionalInfo) MarshalJSON ¶
func (e ErrorAdditionalInfo) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorAdditionalInfo.
func (*ErrorAdditionalInfo) UnmarshalJSON ¶
func (e *ErrorAdditionalInfo) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorAdditionalInfo.
type ErrorDetail ¶
type ErrorDetail struct { // READ-ONLY; The error additional info. AdditionalInfo []*ErrorAdditionalInfo // READ-ONLY; The error code. Code *string // READ-ONLY; The error details. Details []*ErrorDetail // READ-ONLY; The error message. Message *string // READ-ONLY; The error target. Target *string }
ErrorDetail - The error detail.
func (ErrorDetail) MarshalJSON ¶
func (e ErrorDetail) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorDetail.
func (*ErrorDetail) UnmarshalJSON ¶
func (e *ErrorDetail) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorDetail.
type Fleet ¶
type Fleet struct { // REQUIRED; The geo-location where the resource lives Location *string // Managed identity. Identity *ManagedServiceIdentity // The resource-specific properties for this resource. Properties *FleetProperties // Resource tags. Tags map[string]*string // READ-ONLY; If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. // Entity tags are used for comparing two or more entities from the same requested resource. // HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range // (section 14.27) header fields. ETag *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; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
Fleet - The Fleet resource.
func (Fleet) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Fleet.
func (*Fleet) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Fleet.
type FleetCredentialResult ¶
type FleetCredentialResult struct { // READ-ONLY; The name of the credential. Name *string // READ-ONLY; Base64-encoded Kubernetes configuration file. Value []byte }
FleetCredentialResult - One credential result item.
func (FleetCredentialResult) MarshalJSON ¶
func (f FleetCredentialResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetCredentialResult.
func (*FleetCredentialResult) UnmarshalJSON ¶
func (f *FleetCredentialResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetCredentialResult.
type FleetCredentialResults ¶
type FleetCredentialResults struct { // READ-ONLY; Array of base64-encoded Kubernetes configuration files. Kubeconfigs []*FleetCredentialResult }
FleetCredentialResults - The Credential results response.
func (FleetCredentialResults) MarshalJSON ¶
func (f FleetCredentialResults) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetCredentialResults.
func (*FleetCredentialResults) UnmarshalJSON ¶
func (f *FleetCredentialResults) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetCredentialResults.
type FleetHubProfile ¶
type FleetHubProfile struct { // The access profile for the Fleet hub API server. APIServerAccessProfile *APIServerAccessProfile // The agent profile for the Fleet hub. AgentProfile *AgentProfile // DNS prefix used to create the FQDN for the Fleet hub. DNSPrefix *string // READ-ONLY; The FQDN of the Fleet hub. Fqdn *string // READ-ONLY; The Kubernetes version of the Fleet hub. KubernetesVersion *string // READ-ONLY; The Azure Portal FQDN of the Fleet hub. PortalFqdn *string }
FleetHubProfile - The FleetHubProfile configures the fleet hub.
func (FleetHubProfile) MarshalJSON ¶
func (f FleetHubProfile) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetHubProfile.
func (*FleetHubProfile) UnmarshalJSON ¶
func (f *FleetHubProfile) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetHubProfile.
type FleetListResult ¶
type FleetListResult struct { // REQUIRED; The Fleet items on this page Value []*Fleet // The link to the next page of items NextLink *string }
FleetListResult - The response of a Fleet list operation.
func (FleetListResult) MarshalJSON ¶
func (f FleetListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetListResult.
func (*FleetListResult) UnmarshalJSON ¶
func (f *FleetListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetListResult.
type FleetMember ¶
type FleetMember struct { // The resource-specific properties for this resource. Properties *FleetMemberProperties // READ-ONLY; If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. // Entity tags are used for comparing two or more entities from the same requested resource. // HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range // (section 14.27) header fields. ETag *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; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
FleetMember - A member of the Fleet. It contains a reference to an existing Kubernetes cluster on Azure.
func (FleetMember) MarshalJSON ¶
func (f FleetMember) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetMember.
func (*FleetMember) UnmarshalJSON ¶
func (f *FleetMember) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetMember.
type FleetMemberListResult ¶
type FleetMemberListResult struct { // REQUIRED; The FleetMember items on this page Value []*FleetMember // The link to the next page of items NextLink *string }
FleetMemberListResult - The response of a FleetMember list operation.
func (FleetMemberListResult) MarshalJSON ¶
func (f FleetMemberListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetMemberListResult.
func (*FleetMemberListResult) UnmarshalJSON ¶
func (f *FleetMemberListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetMemberListResult.
type FleetMemberProperties ¶
type FleetMemberProperties struct { // REQUIRED; The ARM resource id of the cluster that joins the Fleet. Must be a valid Azure resource id. e.g.: // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{clusterName}'. ClusterResourceID *string // The group this member belongs to for multi-cluster update management. Group *string // READ-ONLY; The status of the last operation. ProvisioningState *FleetMemberProvisioningState }
FleetMemberProperties - A member of the Fleet. It contains a reference to an existing Kubernetes cluster on Azure.
func (FleetMemberProperties) MarshalJSON ¶
func (f FleetMemberProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetMemberProperties.
func (*FleetMemberProperties) UnmarshalJSON ¶
func (f *FleetMemberProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetMemberProperties.
type FleetMemberProvisioningState ¶
type FleetMemberProvisioningState string
FleetMemberProvisioningState - The provisioning state of the last accepted operation.
const ( // FleetMemberProvisioningStateCanceled - Resource creation was canceled. FleetMemberProvisioningStateCanceled FleetMemberProvisioningState = "Canceled" // FleetMemberProvisioningStateFailed - Resource creation failed. FleetMemberProvisioningStateFailed FleetMemberProvisioningState = "Failed" // FleetMemberProvisioningStateJoining - The provisioning state of a member joining a fleet. FleetMemberProvisioningStateJoining FleetMemberProvisioningState = "Joining" // FleetMemberProvisioningStateLeaving - The provisioning state of a member leaving a fleet. FleetMemberProvisioningStateLeaving FleetMemberProvisioningState = "Leaving" // FleetMemberProvisioningStateSucceeded - Resource has been created. FleetMemberProvisioningStateSucceeded FleetMemberProvisioningState = "Succeeded" // FleetMemberProvisioningStateUpdating - The provisioning state of a member being updated. FleetMemberProvisioningStateUpdating FleetMemberProvisioningState = "Updating" )
func PossibleFleetMemberProvisioningStateValues ¶
func PossibleFleetMemberProvisioningStateValues() []FleetMemberProvisioningState
PossibleFleetMemberProvisioningStateValues returns the possible values for the FleetMemberProvisioningState const type.
type FleetMemberUpdate ¶
type FleetMemberUpdate struct { // The resource-specific properties for this resource. Properties *FleetMemberUpdateProperties }
FleetMemberUpdate - The type used for update operations of the FleetMember.
func (FleetMemberUpdate) MarshalJSON ¶
func (f FleetMemberUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetMemberUpdate.
func (*FleetMemberUpdate) UnmarshalJSON ¶
func (f *FleetMemberUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetMemberUpdate.
type FleetMemberUpdateProperties ¶
type FleetMemberUpdateProperties struct { // The group this member belongs to for multi-cluster update management. Group *string }
FleetMemberUpdateProperties - The updatable properties of the FleetMember.
func (FleetMemberUpdateProperties) MarshalJSON ¶
func (f FleetMemberUpdateProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetMemberUpdateProperties.
func (*FleetMemberUpdateProperties) UnmarshalJSON ¶
func (f *FleetMemberUpdateProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetMemberUpdateProperties.
type FleetMembersClient ¶
type FleetMembersClient struct {
// contains filtered or unexported fields
}
FleetMembersClient contains the methods for the FleetMembers group. Don't use this type directly, use NewFleetMembersClient() instead.
func NewFleetMembersClient ¶
func NewFleetMembersClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*FleetMembersClient, error)
NewFleetMembersClient creates a new instance of FleetMembersClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*FleetMembersClient) BeginCreate ¶
func (client *FleetMembersClient) BeginCreate(ctx context.Context, resourceGroupName string, fleetName string, fleetMemberName string, resource FleetMember, options *FleetMembersClientBeginCreateOptions) (*runtime.Poller[FleetMembersClientCreateResponse], error)
BeginCreate - Create a FleetMember If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- fleetMemberName - The name of the Fleet member resource.
- resource - Resource create parameters.
- options - FleetMembersClientBeginCreateOptions contains the optional parameters for the FleetMembersClient.BeginCreate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/FleetMembers_Create.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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetMembersClient().BeginCreate(ctx, "rg1", "fleet1", "member-1", armcontainerservicefleet.FleetMember{ Properties: &armcontainerservicefleet.FleetMemberProperties{ ClusterResourceID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/managedClusters/cluster-1"), }, }, &armcontainerservicefleet.FleetMembersClientBeginCreateOptions{IfMatch: nil, IfNoneMatch: nil, }) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.FleetMember = armcontainerservicefleet.FleetMember{ // Name: to.Ptr("member-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/members"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1/members/member-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetMemberProperties{ // ClusterResourceID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/managedClusters/cluster-1"), // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetMemberProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetMembersClient) BeginDelete ¶
func (client *FleetMembersClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, fleetMemberName string, options *FleetMembersClientBeginDeleteOptions) (*runtime.Poller[FleetMembersClientDeleteResponse], error)
BeginDelete - Delete a FleetMember If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- fleetMemberName - The name of the Fleet member resource.
- options - FleetMembersClientBeginDeleteOptions contains the optional parameters for the FleetMembersClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/FleetMembers_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetMembersClient().BeginDelete(ctx, "rg1", "fleet1", "member-1", &armcontainerservicefleet.FleetMembersClientBeginDeleteOptions{IfMatch: 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 (*FleetMembersClient) BeginUpdate ¶
func (client *FleetMembersClient) BeginUpdate(ctx context.Context, resourceGroupName string, fleetName string, fleetMemberName string, properties FleetMemberUpdate, options *FleetMembersClientBeginUpdateOptions) (*runtime.Poller[FleetMembersClientUpdateResponse], error)
BeginUpdate - Update a FleetMember If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- fleetMemberName - The name of the Fleet member resource.
- properties - The resource properties to be updated.
- options - FleetMembersClientBeginUpdateOptions contains the optional parameters for the FleetMembersClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/FleetMembers_Update.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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetMembersClient().BeginUpdate(ctx, "rg1", "fleet1", "member-1", armcontainerservicefleet.FleetMemberUpdate{ Properties: &armcontainerservicefleet.FleetMemberUpdateProperties{ Group: to.Ptr("staging"), }, }, &armcontainerservicefleet.FleetMembersClientBeginUpdateOptions{IfMatch: nil}) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.FleetMember = armcontainerservicefleet.FleetMember{ // Name: to.Ptr("member-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/members"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1/members/member-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetMemberProperties{ // ClusterResourceID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/managedClusters/cluster-1"), // Group: to.Ptr("staging"), // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetMemberProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetMembersClient) Get ¶
func (client *FleetMembersClient) Get(ctx context.Context, resourceGroupName string, fleetName string, fleetMemberName string, options *FleetMembersClientGetOptions) (FleetMembersClientGetResponse, error)
Get - Get a FleetMember If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- fleetMemberName - The name of the Fleet member resource.
- options - FleetMembersClientGetOptions contains the optional parameters for the FleetMembersClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/FleetMembers_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewFleetMembersClient().Get(ctx, "rg1", "fleet1", "member-1", 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.FleetMember = armcontainerservicefleet.FleetMember{ // Name: to.Ptr("member-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/members"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1/members/member-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("kd30rkdfo49="), // Properties: &armcontainerservicefleet.FleetMemberProperties{ // ClusterResourceID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/managedClusters/cluster-1"), // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetMemberProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetMembersClient) NewListByFleetPager ¶
func (client *FleetMembersClient) NewListByFleetPager(resourceGroupName string, fleetName string, options *FleetMembersClientListByFleetOptions) *runtime.Pager[FleetMembersClientListByFleetResponse]
NewListByFleetPager - List FleetMember resources by Fleet
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - FleetMembersClientListByFleetOptions contains the optional parameters for the FleetMembersClient.NewListByFleetPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/FleetMembers_ListByFleet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewFleetMembersClient().NewListByFleetPager("rg1", "fleet1", nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.FleetMemberListResult = armcontainerservicefleet.FleetMemberListResult{ // Value: []*armcontainerservicefleet.FleetMember{ // { // Name: to.Ptr("member-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/members"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1/members/member-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("kd30rkdfo49="), // Properties: &armcontainerservicefleet.FleetMemberProperties{ // ClusterResourceID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/managedClusters/cluster-1"), // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetMemberProvisioningStateSucceeded), // }, // }}, // } } }
Output:
type FleetMembersClientBeginCreateOptions ¶
type FleetMembersClientBeginCreateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // The request should only proceed if no entity matches this string. IfNoneMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetMembersClientBeginCreateOptions contains the optional parameters for the FleetMembersClient.BeginCreate method.
type FleetMembersClientBeginDeleteOptions ¶
type FleetMembersClientBeginDeleteOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetMembersClientBeginDeleteOptions contains the optional parameters for the FleetMembersClient.BeginDelete method.
type FleetMembersClientBeginUpdateOptions ¶
type FleetMembersClientBeginUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetMembersClientBeginUpdateOptions contains the optional parameters for the FleetMembersClient.BeginUpdate method.
type FleetMembersClientCreateResponse ¶
type FleetMembersClientCreateResponse struct { // A member of the Fleet. It contains a reference to an existing Kubernetes cluster on Azure. FleetMember }
FleetMembersClientCreateResponse contains the response from method FleetMembersClient.BeginCreate.
type FleetMembersClientDeleteResponse ¶
type FleetMembersClientDeleteResponse struct { }
FleetMembersClientDeleteResponse contains the response from method FleetMembersClient.BeginDelete.
type FleetMembersClientGetOptions ¶
type FleetMembersClientGetOptions struct { }
FleetMembersClientGetOptions contains the optional parameters for the FleetMembersClient.Get method.
type FleetMembersClientGetResponse ¶
type FleetMembersClientGetResponse struct { // A member of the Fleet. It contains a reference to an existing Kubernetes cluster on Azure. FleetMember }
FleetMembersClientGetResponse contains the response from method FleetMembersClient.Get.
type FleetMembersClientListByFleetOptions ¶
type FleetMembersClientListByFleetOptions struct { }
FleetMembersClientListByFleetOptions contains the optional parameters for the FleetMembersClient.NewListByFleetPager method.
type FleetMembersClientListByFleetResponse ¶
type FleetMembersClientListByFleetResponse struct { // The response of a FleetMember list operation. FleetMemberListResult }
FleetMembersClientListByFleetResponse contains the response from method FleetMembersClient.NewListByFleetPager.
type FleetMembersClientUpdateResponse ¶
type FleetMembersClientUpdateResponse struct { // A member of the Fleet. It contains a reference to an existing Kubernetes cluster on Azure. FleetMember }
FleetMembersClientUpdateResponse contains the response from method FleetMembersClient.BeginUpdate.
type FleetPatch ¶
type FleetPatch struct { // Managed identity. Identity *ManagedServiceIdentity // Resource tags. Tags map[string]*string }
FleetPatch - Properties of a Fleet that can be patched.
func (FleetPatch) MarshalJSON ¶
func (f FleetPatch) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetPatch.
func (*FleetPatch) UnmarshalJSON ¶
func (f *FleetPatch) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetPatch.
type FleetProperties ¶
type FleetProperties struct { // The FleetHubProfile configures the Fleet's hub. HubProfile *FleetHubProfile // READ-ONLY; The status of the last operation. ProvisioningState *FleetProvisioningState }
FleetProperties - Fleet properties.
func (FleetProperties) MarshalJSON ¶
func (f FleetProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetProperties.
func (*FleetProperties) UnmarshalJSON ¶
func (f *FleetProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetProperties.
type FleetProvisioningState ¶
type FleetProvisioningState string
FleetProvisioningState - The provisioning state of the last accepted operation.
const ( // FleetProvisioningStateCanceled - Resource creation was canceled. FleetProvisioningStateCanceled FleetProvisioningState = "Canceled" // FleetProvisioningStateCreating - The provisioning state of a fleet being created. FleetProvisioningStateCreating FleetProvisioningState = "Creating" // FleetProvisioningStateDeleting - The provisioning state of a fleet being deleted. FleetProvisioningStateDeleting FleetProvisioningState = "Deleting" // FleetProvisioningStateFailed - Resource creation failed. FleetProvisioningStateFailed FleetProvisioningState = "Failed" // FleetProvisioningStateSucceeded - Resource has been created. FleetProvisioningStateSucceeded FleetProvisioningState = "Succeeded" // FleetProvisioningStateUpdating - The provisioning state of a fleet being updated. FleetProvisioningStateUpdating FleetProvisioningState = "Updating" )
func PossibleFleetProvisioningStateValues ¶
func PossibleFleetProvisioningStateValues() []FleetProvisioningState
PossibleFleetProvisioningStateValues returns the possible values for the FleetProvisioningState const type.
type FleetUpdateStrategiesClient ¶
type FleetUpdateStrategiesClient struct {
// contains filtered or unexported fields
}
FleetUpdateStrategiesClient contains the methods for the FleetUpdateStrategies group. Don't use this type directly, use NewFleetUpdateStrategiesClient() instead.
func NewFleetUpdateStrategiesClient ¶
func NewFleetUpdateStrategiesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*FleetUpdateStrategiesClient, error)
NewFleetUpdateStrategiesClient creates a new instance of FleetUpdateStrategiesClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*FleetUpdateStrategiesClient) BeginCreateOrUpdate ¶
func (client *FleetUpdateStrategiesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, updateStrategyName string, resource FleetUpdateStrategy, options *FleetUpdateStrategiesClientBeginCreateOrUpdateOptions) (*runtime.Poller[FleetUpdateStrategiesClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - Create a FleetUpdateStrategy If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateStrategyName - The name of the UpdateStrategy resource.
- resource - Resource create parameters.
- options - FleetUpdateStrategiesClientBeginCreateOrUpdateOptions contains the optional parameters for the FleetUpdateStrategiesClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateStrategies_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetUpdateStrategiesClient().BeginCreateOrUpdate(ctx, "rg1", "fleet1", "strartegy1", armcontainerservicefleet.FleetUpdateStrategy{ Properties: &armcontainerservicefleet.FleetUpdateStrategyProperties{ Strategy: &armcontainerservicefleet.UpdateRunStrategy{ Stages: []*armcontainerservicefleet.UpdateStage{ { Name: to.Ptr("stage1"), AfterStageWaitInSeconds: to.Ptr[int32](3600), Groups: []*armcontainerservicefleet.UpdateGroup{ { Name: to.Ptr("group-a"), }}, }}, }, }, }, &armcontainerservicefleet.FleetUpdateStrategiesClientBeginCreateOrUpdateOptions{IfMatch: nil, IfNoneMatch: nil, }) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.FleetUpdateStrategy = armcontainerservicefleet.FleetUpdateStrategy{ // Name: to.Ptr("strategy1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateStrategies"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateStrategies/strategy1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.FleetUpdateStrategyProperties{ // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetUpdateStrategyProvisioningStateSucceeded), // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // } }
Output:
func (*FleetUpdateStrategiesClient) BeginDelete ¶
func (client *FleetUpdateStrategiesClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, updateStrategyName string, options *FleetUpdateStrategiesClientBeginDeleteOptions) (*runtime.Poller[FleetUpdateStrategiesClientDeleteResponse], error)
BeginDelete - Delete a FleetUpdateStrategy If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateStrategyName - The name of the UpdateStrategy resource.
- options - FleetUpdateStrategiesClientBeginDeleteOptions contains the optional parameters for the FleetUpdateStrategiesClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateStrategies_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetUpdateStrategiesClient().BeginDelete(ctx, "rg1", "fleet1", "strategy1", &armcontainerservicefleet.FleetUpdateStrategiesClientBeginDeleteOptions{IfMatch: 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 (*FleetUpdateStrategiesClient) Get ¶
func (client *FleetUpdateStrategiesClient) Get(ctx context.Context, resourceGroupName string, fleetName string, updateStrategyName string, options *FleetUpdateStrategiesClientGetOptions) (FleetUpdateStrategiesClientGetResponse, error)
Get - Get a FleetUpdateStrategy If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateStrategyName - The name of the UpdateStrategy resource.
- options - FleetUpdateStrategiesClientGetOptions contains the optional parameters for the FleetUpdateStrategiesClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateStrategies_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewFleetUpdateStrategiesClient().Get(ctx, "rg1", "fleet1", "strategy1", 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.FleetUpdateStrategy = armcontainerservicefleet.FleetUpdateStrategy{ // Name: to.Ptr("strategy1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateStrategies"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateStrategies/strategy1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.FleetUpdateStrategyProperties{ // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetUpdateStrategyProvisioningStateSucceeded), // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // } }
Output:
func (*FleetUpdateStrategiesClient) NewListByFleetPager ¶
func (client *FleetUpdateStrategiesClient) NewListByFleetPager(resourceGroupName string, fleetName string, options *FleetUpdateStrategiesClientListByFleetOptions) *runtime.Pager[FleetUpdateStrategiesClientListByFleetResponse]
NewListByFleetPager - List FleetUpdateStrategy resources by Fleet
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - FleetUpdateStrategiesClientListByFleetOptions contains the optional parameters for the FleetUpdateStrategiesClient.NewListByFleetPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateStrategies_ListByFleet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewFleetUpdateStrategiesClient().NewListByFleetPager("rg1", "fleet1", nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.FleetUpdateStrategyListResult = armcontainerservicefleet.FleetUpdateStrategyListResult{ // Value: []*armcontainerservicefleet.FleetUpdateStrategy{ // { // Name: to.Ptr("strategy1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateStrategies"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateStrategies/strategy1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.FleetUpdateStrategyProperties{ // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetUpdateStrategyProvisioningStateSucceeded), // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // }}, // } } }
Output:
type FleetUpdateStrategiesClientBeginCreateOrUpdateOptions ¶
type FleetUpdateStrategiesClientBeginCreateOrUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // The request should only proceed if no entity matches this string. IfNoneMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetUpdateStrategiesClientBeginCreateOrUpdateOptions contains the optional parameters for the FleetUpdateStrategiesClient.BeginCreateOrUpdate method.
type FleetUpdateStrategiesClientBeginDeleteOptions ¶
type FleetUpdateStrategiesClientBeginDeleteOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetUpdateStrategiesClientBeginDeleteOptions contains the optional parameters for the FleetUpdateStrategiesClient.BeginDelete method.
type FleetUpdateStrategiesClientCreateOrUpdateResponse ¶
type FleetUpdateStrategiesClientCreateOrUpdateResponse struct { // Defines a multi-stage process to perform update operations across members of a Fleet. FleetUpdateStrategy }
FleetUpdateStrategiesClientCreateOrUpdateResponse contains the response from method FleetUpdateStrategiesClient.BeginCreateOrUpdate.
type FleetUpdateStrategiesClientDeleteResponse ¶
type FleetUpdateStrategiesClientDeleteResponse struct { }
FleetUpdateStrategiesClientDeleteResponse contains the response from method FleetUpdateStrategiesClient.BeginDelete.
type FleetUpdateStrategiesClientGetOptions ¶
type FleetUpdateStrategiesClientGetOptions struct { }
FleetUpdateStrategiesClientGetOptions contains the optional parameters for the FleetUpdateStrategiesClient.Get method.
type FleetUpdateStrategiesClientGetResponse ¶
type FleetUpdateStrategiesClientGetResponse struct { // Defines a multi-stage process to perform update operations across members of a Fleet. FleetUpdateStrategy }
FleetUpdateStrategiesClientGetResponse contains the response from method FleetUpdateStrategiesClient.Get.
type FleetUpdateStrategiesClientListByFleetOptions ¶
type FleetUpdateStrategiesClientListByFleetOptions struct { }
FleetUpdateStrategiesClientListByFleetOptions contains the optional parameters for the FleetUpdateStrategiesClient.NewListByFleetPager method.
type FleetUpdateStrategiesClientListByFleetResponse ¶
type FleetUpdateStrategiesClientListByFleetResponse struct { // The response of a FleetUpdateStrategy list operation. FleetUpdateStrategyListResult }
FleetUpdateStrategiesClientListByFleetResponse contains the response from method FleetUpdateStrategiesClient.NewListByFleetPager.
type FleetUpdateStrategy ¶
type FleetUpdateStrategy struct { // The resource-specific properties for this resource. Properties *FleetUpdateStrategyProperties // READ-ONLY; If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. // Entity tags are used for comparing two or more entities from the same requested resource. // HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range // (section 14.27) header fields. ETag *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; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
FleetUpdateStrategy - Defines a multi-stage process to perform update operations across members of a Fleet.
func (FleetUpdateStrategy) MarshalJSON ¶
func (f FleetUpdateStrategy) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetUpdateStrategy.
func (*FleetUpdateStrategy) UnmarshalJSON ¶
func (f *FleetUpdateStrategy) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetUpdateStrategy.
type FleetUpdateStrategyListResult ¶
type FleetUpdateStrategyListResult struct { // REQUIRED; The FleetUpdateStrategy items on this page Value []*FleetUpdateStrategy // The link to the next page of items NextLink *string }
FleetUpdateStrategyListResult - The response of a FleetUpdateStrategy list operation.
func (FleetUpdateStrategyListResult) MarshalJSON ¶
func (f FleetUpdateStrategyListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetUpdateStrategyListResult.
func (*FleetUpdateStrategyListResult) UnmarshalJSON ¶
func (f *FleetUpdateStrategyListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetUpdateStrategyListResult.
type FleetUpdateStrategyProperties ¶
type FleetUpdateStrategyProperties struct { // REQUIRED; Defines the update sequence of the clusters. Strategy *UpdateRunStrategy // READ-ONLY; The provisioning state of the UpdateStrategy resource. ProvisioningState *FleetUpdateStrategyProvisioningState }
FleetUpdateStrategyProperties - The properties of the UpdateStrategy.
func (FleetUpdateStrategyProperties) MarshalJSON ¶
func (f FleetUpdateStrategyProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type FleetUpdateStrategyProperties.
func (*FleetUpdateStrategyProperties) UnmarshalJSON ¶
func (f *FleetUpdateStrategyProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type FleetUpdateStrategyProperties.
type FleetUpdateStrategyProvisioningState ¶
type FleetUpdateStrategyProvisioningState string
FleetUpdateStrategyProvisioningState - The provisioning state of the UpdateStrategy resource.
const ( // FleetUpdateStrategyProvisioningStateCanceled - Resource creation was canceled. FleetUpdateStrategyProvisioningStateCanceled FleetUpdateStrategyProvisioningState = "Canceled" // FleetUpdateStrategyProvisioningStateFailed - Resource creation failed. FleetUpdateStrategyProvisioningStateFailed FleetUpdateStrategyProvisioningState = "Failed" // FleetUpdateStrategyProvisioningStateSucceeded - Resource has been created. FleetUpdateStrategyProvisioningStateSucceeded FleetUpdateStrategyProvisioningState = "Succeeded" )
func PossibleFleetUpdateStrategyProvisioningStateValues ¶
func PossibleFleetUpdateStrategyProvisioningStateValues() []FleetUpdateStrategyProvisioningState
PossibleFleetUpdateStrategyProvisioningStateValues returns the possible values for the FleetUpdateStrategyProvisioningState const type.
type FleetsClient ¶
type FleetsClient struct {
// contains filtered or unexported fields
}
FleetsClient contains the methods for the Fleets group. Don't use this type directly, use NewFleetsClient() instead.
func NewFleetsClient ¶
func NewFleetsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*FleetsClient, error)
NewFleetsClient creates a new instance of FleetsClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*FleetsClient) BeginCreateOrUpdate ¶
func (client *FleetsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, resource Fleet, options *FleetsClientBeginCreateOrUpdateOptions) (*runtime.Poller[FleetsClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - Creates or updates a Fleet. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- resource - Resource create parameters.
- options - FleetsClientBeginCreateOrUpdateOptions contains the optional parameters for the FleetsClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetsClient().BeginCreateOrUpdate(ctx, "rg1", "fleet1", armcontainerservicefleet.Fleet{ Location: to.Ptr("East US"), Tags: map[string]*string{ "archv2": to.Ptr(""), "tier": to.Ptr("production"), }, Properties: &armcontainerservicefleet.FleetProperties{ HubProfile: &armcontainerservicefleet.FleetHubProfile{ AgentProfile: &armcontainerservicefleet.AgentProfile{ VMSize: to.Ptr("Standard_DS1"), }, DNSPrefix: to.Ptr("dnsprefix1"), }, }, }, &armcontainerservicefleet.FleetsClientBeginCreateOrUpdateOptions{IfMatch: nil, IfNoneMatch: nil, }) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.Fleet = armcontainerservicefleet.Fleet{ // Name: to.Ptr("fleet-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // Location: to.Ptr("East US"), // Tags: map[string]*string{ // "archv2": to.Ptr(""), // "tier": to.Ptr("production"), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetProperties{ // HubProfile: &armcontainerservicefleet.FleetHubProfile{ // AgentProfile: &armcontainerservicefleet.AgentProfile{ // VMSize: to.Ptr("Standard_DS1"), // }, // DNSPrefix: to.Ptr("dnsprefix1"), // Fqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // KubernetesVersion: to.Ptr("1.22.4"), // PortalFqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetsClient) BeginDelete ¶
func (client *FleetsClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, options *FleetsClientBeginDeleteOptions) (*runtime.Poller[FleetsClientDeleteResponse], error)
BeginDelete - Delete a Fleet If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - FleetsClientBeginDeleteOptions contains the optional parameters for the FleetsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetsClient().BeginDelete(ctx, "rg1", "fleet1", &armcontainerservicefleet.FleetsClientBeginDeleteOptions{IfMatch: 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 (*FleetsClient) BeginUpdate ¶
func (client *FleetsClient) BeginUpdate(ctx context.Context, resourceGroupName string, fleetName string, properties FleetPatch, options *FleetsClientBeginUpdateOptions) (*runtime.Poller[FleetsClientUpdateResponse], error)
BeginUpdate - Update a Fleet If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- properties - The resource properties to be updated.
- options - FleetsClientBeginUpdateOptions contains the optional parameters for the FleetsClient.BeginUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_PatchTags.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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewFleetsClient().BeginUpdate(ctx, "rg1", "fleet1", armcontainerservicefleet.FleetPatch{ Tags: map[string]*string{ "env": to.Ptr("prod"), "tier": to.Ptr("secure"), }, }, &armcontainerservicefleet.FleetsClientBeginUpdateOptions{IfMatch: to.Ptr("dfjkwelr7384")}) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.Fleet = armcontainerservicefleet.Fleet{ // Name: to.Ptr("fleet-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // Location: to.Ptr("East US"), // Tags: map[string]*string{ // "env": to.Ptr("prod"), // "tier": to.Ptr("secure"), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetProperties{ // HubProfile: &armcontainerservicefleet.FleetHubProfile{ // AgentProfile: &armcontainerservicefleet.AgentProfile{ // VMSize: to.Ptr("Standard_DS1"), // }, // DNSPrefix: to.Ptr("dnsprefix1"), // Fqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // KubernetesVersion: to.Ptr("1.22.4"), // PortalFqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetsClient) Get ¶
func (client *FleetsClient) Get(ctx context.Context, resourceGroupName string, fleetName string, options *FleetsClientGetOptions) (FleetsClientGetResponse, error)
Get - Gets a Fleet. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - FleetsClientGetOptions contains the optional parameters for the FleetsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewFleetsClient().Get(ctx, "rg1", "fleet1", 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.Fleet = armcontainerservicefleet.Fleet{ // Name: to.Ptr("fleet-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // Location: to.Ptr("East US"), // Tags: map[string]*string{ // "archv2": to.Ptr(""), // "tier": to.Ptr("production"), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetProperties{ // HubProfile: &armcontainerservicefleet.FleetHubProfile{ // AgentProfile: &armcontainerservicefleet.AgentProfile{ // VMSize: to.Ptr("Standard_DS1"), // }, // DNSPrefix: to.Ptr("dnsprefix1"), // Fqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // KubernetesVersion: to.Ptr("1.22.4"), // PortalFqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetProvisioningStateSucceeded), // }, // } }
Output:
func (*FleetsClient) ListCredentials ¶
func (client *FleetsClient) ListCredentials(ctx context.Context, resourceGroupName string, fleetName string, options *FleetsClientListCredentialsOptions) (FleetsClientListCredentialsResponse, error)
ListCredentials - Lists the user credentials of a Fleet. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - FleetsClientListCredentialsOptions contains the optional parameters for the FleetsClient.ListCredentials method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_ListCredentialsResult.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewFleetsClient().ListCredentials(ctx, "rg1", "fleet", 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.FleetCredentialResults = armcontainerservicefleet.FleetCredentialResults{ // Kubeconfigs: []*armcontainerservicefleet.FleetCredentialResult{ // { // Name: to.Ptr("credentialName1"), // Value: []byte("Y3JlZGVudGlhbFZhbHVlMQ=="), // }}, // } }
Output:
func (*FleetsClient) NewListByResourceGroupPager ¶
func (client *FleetsClient) NewListByResourceGroupPager(resourceGroupName string, options *FleetsClientListByResourceGroupOptions) *runtime.Pager[FleetsClientListByResourceGroupResponse]
NewListByResourceGroupPager - Lists fleets in the specified subscription and resource group.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- options - FleetsClientListByResourceGroupOptions contains the optional parameters for the FleetsClient.NewListByResourceGroupPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_ListByResourceGroup.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewFleetsClient().NewListByResourceGroupPager("rg1", nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.FleetListResult = armcontainerservicefleet.FleetListResult{ // Value: []*armcontainerservicefleet.Fleet{ // { // Name: to.Ptr("fleet1"), // Type: to.Ptr("Microsoft.ContainerService/fleets"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet-1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // Location: to.Ptr("East US"), // Tags: map[string]*string{ // "archv2": to.Ptr(""), // "tier": to.Ptr("production"), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetProperties{ // HubProfile: &armcontainerservicefleet.FleetHubProfile{ // AgentProfile: &armcontainerservicefleet.AgentProfile{ // VMSize: to.Ptr("Standard_DS1"), // }, // DNSPrefix: to.Ptr("dnsprefix1"), // Fqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // KubernetesVersion: to.Ptr("1.22.4"), // PortalFqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetProvisioningStateSucceeded), // }, // }}, // } } }
Output:
func (*FleetsClient) NewListBySubscriptionPager ¶
func (client *FleetsClient) NewListBySubscriptionPager(options *FleetsClientListBySubscriptionOptions) *runtime.Pager[FleetsClientListBySubscriptionResponse]
NewListBySubscriptionPager - Lists fleets in the specified subscription.
Generated from API version 2024-05-02-preview
- options - FleetsClientListBySubscriptionOptions contains the optional parameters for the FleetsClient.NewListBySubscriptionPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/Fleets_ListBySub.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewFleetsClient().NewListBySubscriptionPager(nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.FleetListResult = armcontainerservicefleet.FleetListResult{ // Value: []*armcontainerservicefleet.Fleet{ // { // Name: to.Ptr("fleet-1"), // Type: to.Ptr("Microsoft.ContainerService/fleets"), // ID: to.Ptr("/subscriptions/subid1/resourcegroups/rg1/providers/Microsoft.ContainerService/fleets/fleet1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // CreatedBy: to.Ptr("someUser"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2022-03-23T05:40:40.657Z"); return t}()), // LastModifiedBy: to.Ptr("someOtherUser"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // Location: to.Ptr("East US"), // Tags: map[string]*string{ // "archv2": to.Ptr(""), // "tier": to.Ptr("production"), // }, // ETag: to.Ptr("23ujdflewrj3="), // Properties: &armcontainerservicefleet.FleetProperties{ // HubProfile: &armcontainerservicefleet.FleetHubProfile{ // AgentProfile: &armcontainerservicefleet.AgentProfile{ // VMSize: to.Ptr("Standard_DS1"), // }, // DNSPrefix: to.Ptr("dnsprefix1"), // Fqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // KubernetesVersion: to.Ptr("1.22.4"), // PortalFqdn: to.Ptr("dnsprefix1-abcd1234.flt.eastus.azmk8s.io"), // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.FleetProvisioningStateSucceeded), // }, // }}, // } } }
Output:
type FleetsClientBeginCreateOrUpdateOptions ¶
type FleetsClientBeginCreateOrUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // The request should only proceed if no entity matches this string. IfNoneMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetsClientBeginCreateOrUpdateOptions contains the optional parameters for the FleetsClient.BeginCreateOrUpdate method.
type FleetsClientBeginDeleteOptions ¶
type FleetsClientBeginDeleteOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetsClientBeginDeleteOptions contains the optional parameters for the FleetsClient.BeginDelete method.
type FleetsClientBeginUpdateOptions ¶
type FleetsClientBeginUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
FleetsClientBeginUpdateOptions contains the optional parameters for the FleetsClient.BeginUpdate method.
type FleetsClientCreateOrUpdateResponse ¶
type FleetsClientCreateOrUpdateResponse struct { // The Fleet resource. Fleet }
FleetsClientCreateOrUpdateResponse contains the response from method FleetsClient.BeginCreateOrUpdate.
type FleetsClientDeleteResponse ¶
type FleetsClientDeleteResponse struct { }
FleetsClientDeleteResponse contains the response from method FleetsClient.BeginDelete.
type FleetsClientGetOptions ¶
type FleetsClientGetOptions struct { }
FleetsClientGetOptions contains the optional parameters for the FleetsClient.Get method.
type FleetsClientGetResponse ¶
type FleetsClientGetResponse struct { // The Fleet resource. Fleet }
FleetsClientGetResponse contains the response from method FleetsClient.Get.
type FleetsClientListByResourceGroupOptions ¶
type FleetsClientListByResourceGroupOptions struct { }
FleetsClientListByResourceGroupOptions contains the optional parameters for the FleetsClient.NewListByResourceGroupPager method.
type FleetsClientListByResourceGroupResponse ¶
type FleetsClientListByResourceGroupResponse struct { // The response of a Fleet list operation. FleetListResult }
FleetsClientListByResourceGroupResponse contains the response from method FleetsClient.NewListByResourceGroupPager.
type FleetsClientListBySubscriptionOptions ¶
type FleetsClientListBySubscriptionOptions struct { }
FleetsClientListBySubscriptionOptions contains the optional parameters for the FleetsClient.NewListBySubscriptionPager method.
type FleetsClientListBySubscriptionResponse ¶
type FleetsClientListBySubscriptionResponse struct { // The response of a Fleet list operation. FleetListResult }
FleetsClientListBySubscriptionResponse contains the response from method FleetsClient.NewListBySubscriptionPager.
type FleetsClientListCredentialsOptions ¶
type FleetsClientListCredentialsOptions struct { }
FleetsClientListCredentialsOptions contains the optional parameters for the FleetsClient.ListCredentials method.
type FleetsClientListCredentialsResponse ¶
type FleetsClientListCredentialsResponse struct { // The Credential results response. FleetCredentialResults }
FleetsClientListCredentialsResponse contains the response from method FleetsClient.ListCredentials.
type FleetsClientUpdateResponse ¶
type FleetsClientUpdateResponse struct { // The Fleet resource. Fleet }
FleetsClientUpdateResponse contains the response from method FleetsClient.BeginUpdate.
type ManagedClusterUpdate ¶
type ManagedClusterUpdate struct { // REQUIRED; The upgrade to apply to the ManagedClusters. Upgrade *ManagedClusterUpgradeSpec // The node image upgrade to be applied to the target nodes in update run. NodeImageSelection *NodeImageSelection }
ManagedClusterUpdate - The update to be applied to the ManagedClusters.
func (ManagedClusterUpdate) MarshalJSON ¶
func (m ManagedClusterUpdate) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedClusterUpdate.
func (*ManagedClusterUpdate) UnmarshalJSON ¶
func (m *ManagedClusterUpdate) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ManagedClusterUpdate.
type ManagedClusterUpgradeSpec ¶
type ManagedClusterUpgradeSpec struct { // REQUIRED; ManagedClusterUpgradeType is the type of upgrade to be applied. Type *ManagedClusterUpgradeType // The Kubernetes version to upgrade the member clusters to. KubernetesVersion *string }
ManagedClusterUpgradeSpec - The upgrade to apply to a ManagedCluster.
func (ManagedClusterUpgradeSpec) MarshalJSON ¶
func (m ManagedClusterUpgradeSpec) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedClusterUpgradeSpec.
func (*ManagedClusterUpgradeSpec) UnmarshalJSON ¶
func (m *ManagedClusterUpgradeSpec) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ManagedClusterUpgradeSpec.
type ManagedClusterUpgradeType ¶
type ManagedClusterUpgradeType string
ManagedClusterUpgradeType - The type of upgrade to perform when targeting ManagedClusters.
const ( // ManagedClusterUpgradeTypeControlPlaneOnly - ControlPlaneOnly upgrades only targets the KubernetesVersion of the ManagedClusters // and will not be applied to the AgentPool. Requires the ManagedClusterUpgradeSpec.KubernetesVersion property to be set. ManagedClusterUpgradeTypeControlPlaneOnly ManagedClusterUpgradeType = "ControlPlaneOnly" // ManagedClusterUpgradeTypeFull - Full upgrades the control plane and all agent pools of the target ManagedClusters. Requires // the ManagedClusterUpgradeSpec.KubernetesVersion property to be set. ManagedClusterUpgradeTypeFull ManagedClusterUpgradeType = "Full" // ManagedClusterUpgradeTypeNodeImageOnly - NodeImageOnly upgrades only the node images of the target ManagedClusters. Requires // the ManagedClusterUpgradeSpec.KubernetesVersion property to NOT be set. ManagedClusterUpgradeTypeNodeImageOnly ManagedClusterUpgradeType = "NodeImageOnly" )
func PossibleManagedClusterUpgradeTypeValues ¶
func PossibleManagedClusterUpgradeTypeValues() []ManagedClusterUpgradeType
PossibleManagedClusterUpgradeTypeValues returns the possible values for the ManagedClusterUpgradeType const type.
type ManagedServiceIdentity ¶
type ManagedServiceIdentity struct { // REQUIRED; Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed). Type *ManagedServiceIdentityType // The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM // resource ids in the form: // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. // The dictionary values can be empty objects ({}) in // requests. UserAssignedIdentities map[string]*UserAssignedIdentity // READ-ONLY; The service principal ID of the system assigned identity. This property will only be provided for a system assigned // identity. PrincipalID *string // READ-ONLY; The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity. TenantID *string }
ManagedServiceIdentity - Managed service identity (system assigned and/or user assigned identities)
func (ManagedServiceIdentity) MarshalJSON ¶
func (m ManagedServiceIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ManagedServiceIdentity.
func (*ManagedServiceIdentity) UnmarshalJSON ¶
func (m *ManagedServiceIdentity) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ManagedServiceIdentity.
type ManagedServiceIdentityType ¶
type ManagedServiceIdentityType string
ManagedServiceIdentityType - Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).
const ( ManagedServiceIdentityTypeNone ManagedServiceIdentityType = "None" ManagedServiceIdentityTypeSystemAssigned ManagedServiceIdentityType = "SystemAssigned" ManagedServiceIdentityTypeSystemAssignedUserAssigned ManagedServiceIdentityType = "SystemAssigned, UserAssigned" ManagedServiceIdentityTypeUserAssigned ManagedServiceIdentityType = "UserAssigned" )
func PossibleManagedServiceIdentityTypeValues ¶
func PossibleManagedServiceIdentityTypeValues() []ManagedServiceIdentityType
PossibleManagedServiceIdentityTypeValues returns the possible values for the ManagedServiceIdentityType const type.
type MemberUpdateStatus ¶
type MemberUpdateStatus struct { // READ-ONLY; The Azure resource id of the target Kubernetes cluster. ClusterResourceID *string // READ-ONLY; The status message after processing the member update operation. Message *string // READ-ONLY; The name of the FleetMember. Name *string // READ-ONLY; The operation resource id of the latest attempt to perform the operation. OperationID *string // READ-ONLY; The status of the MemberUpdate operation. Status *UpdateStatus }
MemberUpdateStatus - The status of a member update operation.
func (MemberUpdateStatus) MarshalJSON ¶
func (m MemberUpdateStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type MemberUpdateStatus.
func (*MemberUpdateStatus) UnmarshalJSON ¶
func (m *MemberUpdateStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type MemberUpdateStatus.
type NodeImageSelection ¶
type NodeImageSelection struct { // REQUIRED; The node image upgrade type. Type *NodeImageSelectionType // Custom node image versions to upgrade the nodes to. This field is required if node image selection type is Custom. Otherwise, // it must be empty. For each node image family (e.g., // 'AKSUbuntu-1804gen2containerd'), this field can contain at most one version (e.g., only one of 'AKSUbuntu-1804gen2containerd-2023.01.12' // or 'AKSUbuntu-1804gen2containerd-2023.02.12', not both). If the // nodes belong to a family without a matching image version in this field, they are not upgraded. CustomNodeImageVersions []*NodeImageVersion }
NodeImageSelection - The node image upgrade to be applied to the target nodes in update run.
func (NodeImageSelection) MarshalJSON ¶
func (n NodeImageSelection) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NodeImageSelection.
func (*NodeImageSelection) UnmarshalJSON ¶
func (n *NodeImageSelection) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NodeImageSelection.
type NodeImageSelectionStatus ¶
type NodeImageSelectionStatus struct { // READ-ONLY; The image versions to upgrade the nodes to. SelectedNodeImageVersions []*NodeImageVersion }
NodeImageSelectionStatus - The node image upgrade specs for the update run.
func (NodeImageSelectionStatus) MarshalJSON ¶
func (n NodeImageSelectionStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NodeImageSelectionStatus.
func (*NodeImageSelectionStatus) UnmarshalJSON ¶
func (n *NodeImageSelectionStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NodeImageSelectionStatus.
type NodeImageSelectionType ¶
type NodeImageSelectionType string
NodeImageSelectionType - The node image upgrade type.
const ( // NodeImageSelectionTypeConsistent - The image versions to upgrade nodes to are selected as described below: for each node // pool in managed clusters affected by the update run, the system selects the latest image version such that it is available // across all other node pools (in all other clusters) of the same image type. As a result, all node pools of the same image // type will be upgraded to the same image version. For example, if the latest image version for image type 'AKSUbuntu-1804gen2containerd' // is 'AKSUbuntu-1804gen2containerd-2021.10.12' for a node pool in cluster A in region X, and is 'AKSUbuntu-1804gen2containerd-2021.10.17' // for a node pool in cluster B in region Y, the system will upgrade both node pools to image version 'AKSUbuntu-1804gen2containerd-2021.10.12'. NodeImageSelectionTypeConsistent NodeImageSelectionType = "Consistent" // NodeImageSelectionTypeCustom - Upgrade the nodes to the custom image versions. When set, update run will use node image // versions provided in customNodeImageVersions to upgrade the nodes. If set, customNodeImageVersions must not be empty. NodeImageSelectionTypeCustom NodeImageSelectionType = "Custom" // NodeImageSelectionTypeLatest - Use the latest image version when upgrading nodes. Clusters may use different image versions // (e.g., 'AKSUbuntu-1804gen2containerd-2021.10.12' and 'AKSUbuntu-1804gen2containerd-2021.10.19') because, for example, the // latest available version is different in different regions. NodeImageSelectionTypeLatest NodeImageSelectionType = "Latest" )
func PossibleNodeImageSelectionTypeValues ¶
func PossibleNodeImageSelectionTypeValues() []NodeImageSelectionType
PossibleNodeImageSelectionTypeValues returns the possible values for the NodeImageSelectionType const type.
type NodeImageVersion ¶
type NodeImageVersion struct { // READ-ONLY; The image version to upgrade the nodes to (e.g., 'AKSUbuntu-1804gen2containerd-2022.12.13'). Version *string }
NodeImageVersion - The node upgrade image version.
func (NodeImageVersion) MarshalJSON ¶
func (n NodeImageVersion) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type NodeImageVersion.
func (*NodeImageVersion) UnmarshalJSON ¶
func (n *NodeImageVersion) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type NodeImageVersion.
type Operation ¶
type Operation struct { // Localized display information for this particular operation. Display *OperationDisplay // READ-ONLY; Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs. ActionType *ActionType // READ-ONLY; Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for ARM/control-plane // operations. IsDataAction *bool // READ-ONLY; The name of the operation, as per Resource-Based Access Control (RBAC). Examples: "Microsoft.Compute/virtualMachines/write", // "Microsoft.Compute/virtualMachines/capture/action" Name *string // READ-ONLY; The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default // value is "user,system" Origin *Origin }
Operation - Details of a REST API operation, returned from the Resource Provider Operations API
func (Operation) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Operation.
func (*Operation) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Operation.
type OperationDisplay ¶
type OperationDisplay struct { // READ-ONLY; The short, localized friendly description of the operation; suitable for tool tips and detailed views. Description *string // READ-ONLY; The concise, localized friendly name for the operation; suitable for dropdowns. E.g. "Create or Update Virtual // Machine", "Restart Virtual Machine". Operation *string // READ-ONLY; The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring Insights" or "Microsoft // Compute". Provider *string // READ-ONLY; The localized friendly name of the resource type related to this operation. E.g. "Virtual Machines" or "Job // Schedule Collections". Resource *string }
OperationDisplay - Localized display information for this particular operation.
func (OperationDisplay) MarshalJSON ¶
func (o OperationDisplay) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationDisplay.
func (*OperationDisplay) UnmarshalJSON ¶
func (o *OperationDisplay) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationDisplay.
type OperationListResult ¶
type OperationListResult struct { // READ-ONLY; URL to get the next set of operation list results (if there are any). NextLink *string // READ-ONLY; List of operations supported by the resource provider Value []*Operation }
OperationListResult - A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results.
func (OperationListResult) MarshalJSON ¶
func (o OperationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationListResult.
func (*OperationListResult) UnmarshalJSON ¶
func (o *OperationListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.
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) NewListPager ¶
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - List the operations for the provider
Generated from API version 2024-05-02-preview
- options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewOperationsClient().NewListPager(nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.OperationListResult = armcontainerservicefleet.OperationListResult{ // Value: []*armcontainerservicefleet.Operation{ // { // Name: to.Ptr("Microsoft.ContainerService/locations/operations/read"), // Display: &armcontainerservicefleet.OperationDisplay{ // Description: to.Ptr("Gets the status of an asynchronous operation"), // Operation: to.Ptr("Get Operation"), // Provider: to.Ptr("Microsoft Container Service"), // Resource: to.Ptr("Operation"), // }, // Origin: to.Ptr(armcontainerservicefleet.OriginUserSystem), // }}, // } } }
Output:
type OperationsClientListOptions ¶
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct { // A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of results. OperationListResult }
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
type Origin ¶
type Origin string
Origin - The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default value is "user,system"
func PossibleOriginValues ¶
func PossibleOriginValues() []Origin
PossibleOriginValues returns the possible values for the Origin const type.
type SkipProperties ¶
type SkipProperties struct { // REQUIRED; The targets to skip. Targets []*SkipTarget }
SkipProperties - The properties of a skip operation containing multiple skip requests.
func (SkipProperties) MarshalJSON ¶
func (s SkipProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SkipProperties.
func (*SkipProperties) UnmarshalJSON ¶
func (s *SkipProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SkipProperties.
type SkipTarget ¶
type SkipTarget struct { // REQUIRED; The skip target's name. To skip a member/group/stage, use the member/group/stage's name; Tp skip an after stage // wait, use the parent stage's name. Name *string // REQUIRED; The skip target type. Type *TargetType }
SkipTarget - The definition of a single skip request.
func (SkipTarget) MarshalJSON ¶
func (s SkipTarget) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SkipTarget.
func (*SkipTarget) UnmarshalJSON ¶
func (s *SkipTarget) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SkipTarget.
type SystemData ¶
type SystemData struct { // The timestamp of resource creation (UTC). CreatedAt *time.Time // The identity that created the resource. CreatedBy *string // The type of identity that created the resource. CreatedByType *CreatedByType // The timestamp of resource last modification (UTC) LastModifiedAt *time.Time // The identity that last modified the resource. LastModifiedBy *string // The type of identity that last modified the resource. LastModifiedByType *CreatedByType }
SystemData - Metadata pertaining to creation and last modification of the resource.
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.
type TargetType ¶
type TargetType string
TargetType - The target type of a skip request.
const ( // TargetTypeAfterStageWait - Skip the update of the after stage wait of a certain stage. TargetTypeAfterStageWait TargetType = "AfterStageWait" // TargetTypeGroup - Skip the update of a group. TargetTypeGroup TargetType = "Group" // TargetTypeMember - Skip the update of a member. TargetTypeMember TargetType = "Member" // TargetTypeStage - Skip the update of an entire stage including the after stage wait. TargetTypeStage TargetType = "Stage" )
func PossibleTargetTypeValues ¶
func PossibleTargetTypeValues() []TargetType
PossibleTargetTypeValues returns the possible values for the TargetType const type.
type UpdateGroup ¶
type UpdateGroup struct { // REQUIRED; Name of the group. It must match a group name of an existing fleet member. Name *string }
UpdateGroup - A group to be updated.
func (UpdateGroup) MarshalJSON ¶
func (u UpdateGroup) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateGroup.
func (*UpdateGroup) UnmarshalJSON ¶
func (u *UpdateGroup) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateGroup.
type UpdateGroupStatus ¶
type UpdateGroupStatus struct { // READ-ONLY; The list of member this UpdateGroup updates. Members []*MemberUpdateStatus // READ-ONLY; The name of the UpdateGroup. Name *string // READ-ONLY; The status of the UpdateGroup. Status *UpdateStatus }
UpdateGroupStatus - The status of a UpdateGroup.
func (UpdateGroupStatus) MarshalJSON ¶
func (u UpdateGroupStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateGroupStatus.
func (*UpdateGroupStatus) UnmarshalJSON ¶
func (u *UpdateGroupStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateGroupStatus.
type UpdateRun ¶
type UpdateRun struct { // The resource-specific properties for this resource. Properties *UpdateRunProperties // READ-ONLY; If eTag is provided in the response body, it may also be provided as a header per the normal etag convention. // Entity tags are used for comparing two or more entities from the same requested resource. // HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range // (section 14.27) header fields. ETag *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; Azure Resource Manager metadata containing createdBy and modifiedBy information. SystemData *SystemData // READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" Type *string }
UpdateRun - A multi-stage process to perform update operations across members of a Fleet.
func (UpdateRun) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type UpdateRun.
func (*UpdateRun) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateRun.
type UpdateRunListResult ¶
type UpdateRunListResult struct { // REQUIRED; The UpdateRun items on this page Value []*UpdateRun // The link to the next page of items NextLink *string }
UpdateRunListResult - The response of a UpdateRun list operation.
func (UpdateRunListResult) MarshalJSON ¶
func (u UpdateRunListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateRunListResult.
func (*UpdateRunListResult) UnmarshalJSON ¶
func (u *UpdateRunListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateRunListResult.
type UpdateRunProperties ¶
type UpdateRunProperties struct { // REQUIRED; The update to be applied to all clusters in the UpdateRun. The managedClusterUpdate can be modified until the // run is started. ManagedClusterUpdate *ManagedClusterUpdate // The strategy defines the order in which the clusters will be updated. If not set, all members will be updated sequentially. // The UpdateRun status will show a single UpdateStage and a single UpdateGroup // targeting all members. The strategy of the UpdateRun can be modified until the run is started. Strategy *UpdateRunStrategy // The resource id of the FleetUpdateStrategy resource to reference. // When creating a new run, there are three ways to define a strategy for the run: // 1. Define a new strategy in place: Set the "strategy" field. // 2. Use an existing strategy: Set the "updateStrategyId" field. (since 2023-08-15-preview) // 3. Use the default strategy to update all the members one by one: Leave both "updateStrategyId" and "strategy" unset. (since // 2023-08-15-preview) // Setting both "updateStrategyId" and "strategy" is invalid. // UpdateRuns created by "updateStrategyId" snapshot the referenced UpdateStrategy at the time of creation and store it in // the "strategy" field. Subsequent changes to the referenced FleetUpdateStrategy // resource do not propagate. UpdateRunStrategy changes can be made directly on the "strategy" field before launching the // UpdateRun. UpdateStrategyID *string // READ-ONLY; The provisioning state of the UpdateRun resource. ProvisioningState *UpdateRunProvisioningState // READ-ONLY; The status of the UpdateRun. Status *UpdateRunStatus }
UpdateRunProperties - The properties of the UpdateRun.
func (UpdateRunProperties) MarshalJSON ¶
func (u UpdateRunProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateRunProperties.
func (*UpdateRunProperties) UnmarshalJSON ¶
func (u *UpdateRunProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateRunProperties.
type UpdateRunProvisioningState ¶
type UpdateRunProvisioningState string
UpdateRunProvisioningState - The provisioning state of the UpdateRun resource.
const ( // UpdateRunProvisioningStateCanceled - Resource creation was canceled. UpdateRunProvisioningStateCanceled UpdateRunProvisioningState = "Canceled" // UpdateRunProvisioningStateFailed - Resource creation failed. UpdateRunProvisioningStateFailed UpdateRunProvisioningState = "Failed" // UpdateRunProvisioningStateSucceeded - Resource has been created. UpdateRunProvisioningStateSucceeded UpdateRunProvisioningState = "Succeeded" )
func PossibleUpdateRunProvisioningStateValues ¶
func PossibleUpdateRunProvisioningStateValues() []UpdateRunProvisioningState
PossibleUpdateRunProvisioningStateValues returns the possible values for the UpdateRunProvisioningState const type.
type UpdateRunStatus ¶
type UpdateRunStatus struct { // READ-ONLY; The node image upgrade specs for the update run. It is only set in update run when NodeImageSelection.type is // Consistent. NodeImageSelection *NodeImageSelectionStatus // READ-ONLY; The stages composing an update run. Stages are run sequentially withing an UpdateRun. Stages []*UpdateStageStatus // READ-ONLY; The status of the UpdateRun. Status *UpdateStatus }
UpdateRunStatus - The status of a UpdateRun.
func (UpdateRunStatus) MarshalJSON ¶
func (u UpdateRunStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateRunStatus.
func (*UpdateRunStatus) UnmarshalJSON ¶
func (u *UpdateRunStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateRunStatus.
type UpdateRunStrategy ¶
type UpdateRunStrategy struct { // REQUIRED; The list of stages that compose this update run. Min size: 1. Stages []*UpdateStage }
UpdateRunStrategy - Defines the update sequence of the clusters via stages and groups. Stages within a run are executed sequentially one after another. Groups within a stage are executed in parallel. Member clusters within a group are updated sequentially one after another. A valid strategy contains no duplicate groups within or across stages.
func (UpdateRunStrategy) MarshalJSON ¶
func (u UpdateRunStrategy) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateRunStrategy.
func (*UpdateRunStrategy) UnmarshalJSON ¶
func (u *UpdateRunStrategy) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateRunStrategy.
type UpdateRunsClient ¶
type UpdateRunsClient struct {
// contains filtered or unexported fields
}
UpdateRunsClient contains the methods for the UpdateRuns group. Don't use this type directly, use NewUpdateRunsClient() instead.
func NewUpdateRunsClient ¶
func NewUpdateRunsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*UpdateRunsClient, error)
NewUpdateRunsClient creates a new instance of UpdateRunsClient with the specified values.
- subscriptionID - The ID of the target subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*UpdateRunsClient) BeginCreateOrUpdate ¶
func (client *UpdateRunsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, resource UpdateRun, options *UpdateRunsClientBeginCreateOrUpdateOptions) (*runtime.Poller[UpdateRunsClientCreateOrUpdateResponse], error)
BeginCreateOrUpdate - Create a UpdateRun If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- resource - Resource create parameters.
- options - UpdateRunsClientBeginCreateOrUpdateOptions contains the optional parameters for the UpdateRunsClient.BeginCreateOrUpdate method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewUpdateRunsClient().BeginCreateOrUpdate(ctx, "rg1", "fleet1", "run1", armcontainerservicefleet.UpdateRun{ Properties: &armcontainerservicefleet.UpdateRunProperties{ ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), }, Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), KubernetesVersion: to.Ptr("1.26.1"), }, }, Strategy: &armcontainerservicefleet.UpdateRunStrategy{ Stages: []*armcontainerservicefleet.UpdateStage{ { Name: to.Ptr("stage1"), AfterStageWaitInSeconds: to.Ptr[int32](3600), Groups: []*armcontainerservicefleet.UpdateGroup{ { Name: to.Ptr("group-a"), }}, }}, }, UpdateStrategyID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateStrategies/strategy1"), }, }, &armcontainerservicefleet.UpdateRunsClientBeginCreateOrUpdateOptions{IfMatch: nil, IfNoneMatch: nil, }) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.UpdateRun = armcontainerservicefleet.UpdateRun{ // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // UpdateStrategyID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateStrategies/strategy1"), // }, // } }
Output:
func (*UpdateRunsClient) BeginDelete ¶
func (client *UpdateRunsClient) BeginDelete(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, options *UpdateRunsClientBeginDeleteOptions) (*runtime.Poller[UpdateRunsClientDeleteResponse], error)
BeginDelete - Delete a UpdateRun If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- options - UpdateRunsClientBeginDeleteOptions contains the optional parameters for the UpdateRunsClient.BeginDelete method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewUpdateRunsClient().BeginDelete(ctx, "rg1", "fleet1", "run1", &armcontainerservicefleet.UpdateRunsClientBeginDeleteOptions{IfMatch: 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 (*UpdateRunsClient) BeginSkip ¶
func (client *UpdateRunsClient) BeginSkip(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, body SkipProperties, options *UpdateRunsClientBeginSkipOptions) (*runtime.Poller[UpdateRunsClientSkipResponse], error)
BeginSkip - Skips one or a combination of member/group/stage/afterStageWait(s) of an update run. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- body - The content of the action request
- options - UpdateRunsClientBeginSkipOptions contains the optional parameters for the UpdateRunsClient.BeginSkip method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_Skip.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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewUpdateRunsClient().BeginSkip(ctx, "rg1", "fleet1", "run1", armcontainerservicefleet.SkipProperties{ Targets: []*armcontainerservicefleet.SkipTarget{ { Name: to.Ptr("member-one"), Type: to.Ptr(armcontainerservicefleet.TargetTypeMember), }, { Name: to.Ptr("stage1"), Type: to.Ptr(armcontainerservicefleet.TargetTypeAfterStageWait), }}, }, &armcontainerservicefleet.UpdateRunsClientBeginSkipOptions{IfMatch: nil}) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.UpdateRun = armcontainerservicefleet.UpdateRun{ // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:09:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateSkipped), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster-1"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateSkipped), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateSkipped), // }, // }, // { // Name: to.Ptr("group-b"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-two"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster-2"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }, // { // Name: to.Ptr("group-b"), // }}, // }}, // }, // }, // } }
Output:
func (*UpdateRunsClient) BeginStart ¶
func (client *UpdateRunsClient) BeginStart(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, options *UpdateRunsClientBeginStartOptions) (*runtime.Poller[UpdateRunsClientStartResponse], error)
BeginStart - Starts an UpdateRun. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- options - UpdateRunsClientBeginStartOptions contains the optional parameters for the UpdateRunsClient.BeginStart method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_Start.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewUpdateRunsClient().BeginStart(ctx, "rg1", "fleet1", "run1", &armcontainerservicefleet.UpdateRunsClientBeginStartOptions{IfMatch: nil}) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.UpdateRun = armcontainerservicefleet.UpdateRun{ // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:09:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateRunning), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // } }
Output:
func (*UpdateRunsClient) BeginStop ¶
func (client *UpdateRunsClient) BeginStop(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, options *UpdateRunsClientBeginStopOptions) (*runtime.Poller[UpdateRunsClientStopResponse], error)
BeginStop - Stops an UpdateRun. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- options - UpdateRunsClientBeginStopOptions contains the optional parameters for the UpdateRunsClient.BeginStop method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_Stop.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } poller, err := clientFactory.NewUpdateRunsClient().BeginStop(ctx, "rg1", "fleet1", "run1", &armcontainerservicefleet.UpdateRunsClientBeginStopOptions{IfMatch: nil}) if err != nil { log.Fatalf("failed to finish the request: %v", err) } res, err := poller.PollUntilDone(ctx, nil) if err != nil { log.Fatalf("failed to pull the result: %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.UpdateRun = armcontainerservicefleet.UpdateRun{ // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:09:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateStopping), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateStopping), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateStopping), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // StartTime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // State: to.Ptr(armcontainerservicefleet.UpdateStateStopping), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // } }
Output:
func (*UpdateRunsClient) Get ¶
func (client *UpdateRunsClient) Get(ctx context.Context, resourceGroupName string, fleetName string, updateRunName string, options *UpdateRunsClientGetOptions) (UpdateRunsClientGetResponse, error)
Get - Get a UpdateRun If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- updateRunName - The name of the UpdateRun resource.
- options - UpdateRunsClientGetOptions contains the optional parameters for the UpdateRunsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_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/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewUpdateRunsClient().Get(ctx, "rg1", "fleet1", "run1", 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.UpdateRun = armcontainerservicefleet.UpdateRun{ // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // } }
Output:
func (*UpdateRunsClient) NewListByFleetPager ¶
func (client *UpdateRunsClient) NewListByFleetPager(resourceGroupName string, fleetName string, options *UpdateRunsClientListByFleetOptions) *runtime.Pager[UpdateRunsClientListByFleetResponse]
NewListByFleetPager - List UpdateRun resources by Fleet
Generated from API version 2024-05-02-preview
- resourceGroupName - The name of the resource group. The name is case insensitive.
- fleetName - The name of the Fleet resource.
- options - UpdateRunsClientListByFleetOptions contains the optional parameters for the UpdateRunsClient.NewListByFleetPager method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/ad60d7f8eba124edc6999677c55aba2184e303b0/specification/containerservice/resource-manager/Microsoft.ContainerService/fleet/preview/2024-05-02-preview/examples/UpdateRuns_ListByFleet.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservicefleet/armcontainerservicefleet" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armcontainerservicefleet.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } pager := clientFactory.NewUpdateRunsClient().NewListByFleetPager("rg1", "fleet1", nil) for pager.More() { page, err := pager.NextPage(ctx) if err != nil { log.Fatalf("failed to advance page: %v", err) } for _, v := range page.Value { // You could use page here. We use blank identifier for just demo purposes. _ = v } // If the HTTP response code is 200 as defined in example definition, your page structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // page.UpdateRunListResult = armcontainerservicefleet.UpdateRunListResult{ // Value: []*armcontainerservicefleet.UpdateRun{ // { // Name: to.Ptr("run1"), // Type: to.Ptr("Microsoft.ContainerService/fleets/updateRuns"), // ID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.ContainerService/fleets/myFleet/updateRuns/run1"), // SystemData: &armcontainerservicefleet.SystemData{ // CreatedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // CreatedBy: to.Ptr("@contoso.com"), // CreatedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // LastModifiedAt: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2023-03-01T01:10:08.395Z"); return t}()), // LastModifiedBy: to.Ptr("@contoso.com"), // LastModifiedByType: to.Ptr(armcontainerservicefleet.CreatedByTypeUser), // }, // ETag: to.Ptr("\"EtagValue\""), // Properties: &armcontainerservicefleet.UpdateRunProperties{ // ManagedClusterUpdate: &armcontainerservicefleet.ManagedClusterUpdate{ // NodeImageSelection: &armcontainerservicefleet.NodeImageSelection{ // Type: to.Ptr(armcontainerservicefleet.NodeImageSelectionTypeLatest), // }, // Upgrade: &armcontainerservicefleet.ManagedClusterUpgradeSpec{ // Type: to.Ptr(armcontainerservicefleet.ManagedClusterUpgradeTypeFull), // KubernetesVersion: to.Ptr("1.26.1"), // }, // }, // ProvisioningState: to.Ptr(armcontainerservicefleet.UpdateRunProvisioningStateSucceeded), // Status: &armcontainerservicefleet.UpdateRunStatus{ // Stages: []*armcontainerservicefleet.UpdateStageStatus{ // { // Name: to.Ptr("stage1"), // AfterStageWaitStatus: &armcontainerservicefleet.WaitStatus{ // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // WaitDurationInSeconds: to.Ptr[int32](3600), // }, // Groups: []*armcontainerservicefleet.UpdateGroupStatus{ // { // Name: to.Ptr("group-a"), // Members: []*armcontainerservicefleet.MemberUpdateStatus{ // { // Name: to.Ptr("member-one"), // ClusterResourceID: to.Ptr("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myClusters/providers/Microsoft.ContainerService/managedClusters/myCluster"), // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }}, // Status: &armcontainerservicefleet.UpdateStatus{ // State: to.Ptr(armcontainerservicefleet.UpdateStateNotStarted), // }, // }, // Strategy: &armcontainerservicefleet.UpdateRunStrategy{ // Stages: []*armcontainerservicefleet.UpdateStage{ // { // Name: to.Ptr("stage1"), // AfterStageWaitInSeconds: to.Ptr[int32](3600), // Groups: []*armcontainerservicefleet.UpdateGroup{ // { // Name: to.Ptr("group-a"), // }}, // }}, // }, // }, // }}, // } } }
Output:
type UpdateRunsClientBeginCreateOrUpdateOptions ¶
type UpdateRunsClientBeginCreateOrUpdateOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // The request should only proceed if no entity matches this string. IfNoneMatch *string // Resumes the LRO from the provided token. ResumeToken string }
UpdateRunsClientBeginCreateOrUpdateOptions contains the optional parameters for the UpdateRunsClient.BeginCreateOrUpdate method.
type UpdateRunsClientBeginDeleteOptions ¶
type UpdateRunsClientBeginDeleteOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
UpdateRunsClientBeginDeleteOptions contains the optional parameters for the UpdateRunsClient.BeginDelete method.
type UpdateRunsClientBeginSkipOptions ¶
type UpdateRunsClientBeginSkipOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
UpdateRunsClientBeginSkipOptions contains the optional parameters for the UpdateRunsClient.BeginSkip method.
type UpdateRunsClientBeginStartOptions ¶
type UpdateRunsClientBeginStartOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
UpdateRunsClientBeginStartOptions contains the optional parameters for the UpdateRunsClient.BeginStart method.
type UpdateRunsClientBeginStopOptions ¶
type UpdateRunsClientBeginStopOptions struct { // The request should only proceed if an entity matches this string. IfMatch *string // Resumes the LRO from the provided token. ResumeToken string }
UpdateRunsClientBeginStopOptions contains the optional parameters for the UpdateRunsClient.BeginStop method.
type UpdateRunsClientCreateOrUpdateResponse ¶
type UpdateRunsClientCreateOrUpdateResponse struct { // A multi-stage process to perform update operations across members of a Fleet. UpdateRun }
UpdateRunsClientCreateOrUpdateResponse contains the response from method UpdateRunsClient.BeginCreateOrUpdate.
type UpdateRunsClientDeleteResponse ¶
type UpdateRunsClientDeleteResponse struct { }
UpdateRunsClientDeleteResponse contains the response from method UpdateRunsClient.BeginDelete.
type UpdateRunsClientGetOptions ¶
type UpdateRunsClientGetOptions struct { }
UpdateRunsClientGetOptions contains the optional parameters for the UpdateRunsClient.Get method.
type UpdateRunsClientGetResponse ¶
type UpdateRunsClientGetResponse struct { // A multi-stage process to perform update operations across members of a Fleet. UpdateRun }
UpdateRunsClientGetResponse contains the response from method UpdateRunsClient.Get.
type UpdateRunsClientListByFleetOptions ¶
type UpdateRunsClientListByFleetOptions struct { }
UpdateRunsClientListByFleetOptions contains the optional parameters for the UpdateRunsClient.NewListByFleetPager method.
type UpdateRunsClientListByFleetResponse ¶
type UpdateRunsClientListByFleetResponse struct { // The response of a UpdateRun list operation. UpdateRunListResult }
UpdateRunsClientListByFleetResponse contains the response from method UpdateRunsClient.NewListByFleetPager.
type UpdateRunsClientSkipResponse ¶
type UpdateRunsClientSkipResponse struct { // A multi-stage process to perform update operations across members of a Fleet. UpdateRun }
UpdateRunsClientSkipResponse contains the response from method UpdateRunsClient.BeginSkip.
type UpdateRunsClientStartResponse ¶
type UpdateRunsClientStartResponse struct { // A multi-stage process to perform update operations across members of a Fleet. UpdateRun }
UpdateRunsClientStartResponse contains the response from method UpdateRunsClient.BeginStart.
type UpdateRunsClientStopResponse ¶
type UpdateRunsClientStopResponse struct { // A multi-stage process to perform update operations across members of a Fleet. UpdateRun }
UpdateRunsClientStopResponse contains the response from method UpdateRunsClient.BeginStop.
type UpdateStage ¶
type UpdateStage struct { // REQUIRED; The name of the stage. Must be unique within the UpdateRun. Name *string // The time in seconds to wait at the end of this stage before starting the next one. Defaults to 0 seconds if unspecified. AfterStageWaitInSeconds *int32 // Defines the groups to be executed in parallel in this stage. Duplicate groups are not allowed. Min size: 1. Groups []*UpdateGroup }
UpdateStage - Defines a stage which contains the groups to update and the steps to take (e.g., wait for a time period) before starting the next stage.
func (UpdateStage) MarshalJSON ¶
func (u UpdateStage) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateStage.
func (*UpdateStage) UnmarshalJSON ¶
func (u *UpdateStage) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateStage.
type UpdateStageStatus ¶
type UpdateStageStatus struct { // READ-ONLY; The status of the wait period configured on the UpdateStage. AfterStageWaitStatus *WaitStatus // READ-ONLY; The list of groups to be updated as part of this UpdateStage. Groups []*UpdateGroupStatus // READ-ONLY; The name of the UpdateStage. Name *string // READ-ONLY; The status of the UpdateStage. Status *UpdateStatus }
UpdateStageStatus - The status of a UpdateStage.
func (UpdateStageStatus) MarshalJSON ¶
func (u UpdateStageStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateStageStatus.
func (*UpdateStageStatus) UnmarshalJSON ¶
func (u *UpdateStageStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateStageStatus.
type UpdateState ¶
type UpdateState string
UpdateState - The state of the UpdateRun, UpdateStage, UpdateGroup, or MemberUpdate.
const ( // UpdateStateCompleted - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that has completed. UpdateStateCompleted UpdateState = "Completed" // UpdateStateFailed - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that has failed. UpdateStateFailed UpdateState = "Failed" // UpdateStateNotStarted - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that has not been started. UpdateStateNotStarted UpdateState = "NotStarted" // UpdateStateRunning - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that is running. UpdateStateRunning UpdateState = "Running" // UpdateStateSkipped - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that has been skipped. UpdateStateSkipped UpdateState = "Skipped" // UpdateStateStopped - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that has stopped. UpdateStateStopped UpdateState = "Stopped" // UpdateStateStopping - The state of an UpdateRun/UpdateStage/UpdateGroup/MemberUpdate that is being stopped. UpdateStateStopping UpdateState = "Stopping" )
func PossibleUpdateStateValues ¶
func PossibleUpdateStateValues() []UpdateState
PossibleUpdateStateValues returns the possible values for the UpdateState const type.
type UpdateStatus ¶
type UpdateStatus struct { // READ-ONLY; The time the operation or group was completed. CompletedTime *time.Time // READ-ONLY; The error details when a failure is encountered. Error *ErrorDetail // READ-ONLY; The time the operation or group was started. StartTime *time.Time // READ-ONLY; The State of the operation or group. State *UpdateState }
UpdateStatus - The status for an operation or group of operations.
func (UpdateStatus) MarshalJSON ¶
func (u UpdateStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UpdateStatus.
func (*UpdateStatus) UnmarshalJSON ¶
func (u *UpdateStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UpdateStatus.
type UpgradeChannel ¶
type UpgradeChannel string
UpgradeChannel - Configuration of how auto upgrade will be run.
const ( // UpgradeChannelNodeImage - Upgrade node image version of the clusters. UpgradeChannelNodeImage UpgradeChannel = "NodeImage" // UpgradeChannelRapid - Upgrades the clusters kubernetes version to the latest supported patch release on the latest supported // minor version. UpgradeChannelRapid UpgradeChannel = "Rapid" // UpgradeChannelStable - Upgrades the clusters kubernetes version to the latest supported patch release on minor version // N-1, where N is the latest supported minor version. // For example, if a cluster runs version 1.17.7 and versions 1.17.9, 1.18.4, 1.18.6, and 1.19.1 are available, the cluster // upgrades to 1.18.6. UpgradeChannelStable UpgradeChannel = "Stable" )
func PossibleUpgradeChannelValues ¶
func PossibleUpgradeChannelValues() []UpgradeChannel
PossibleUpgradeChannelValues returns the possible values for the UpgradeChannel const type.
type UserAssignedIdentity ¶
type UserAssignedIdentity struct { // READ-ONLY; The client ID of the assigned identity. ClientID *string // READ-ONLY; The principal ID of the assigned identity. PrincipalID *string }
UserAssignedIdentity - User assigned identity properties
func (UserAssignedIdentity) MarshalJSON ¶
func (u UserAssignedIdentity) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type UserAssignedIdentity.
func (*UserAssignedIdentity) UnmarshalJSON ¶
func (u *UserAssignedIdentity) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type UserAssignedIdentity.
type WaitStatus ¶
type WaitStatus struct { // READ-ONLY; The status of the wait duration. Status *UpdateStatus // READ-ONLY; The wait duration configured in seconds. WaitDurationInSeconds *int32 }
WaitStatus - The status of the wait duration.
func (WaitStatus) MarshalJSON ¶
func (w WaitStatus) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type WaitStatus.
func (*WaitStatus) UnmarshalJSON ¶
func (w *WaitStatus) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type WaitStatus.