replicas

package
v0.20241111.1164443 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2024 License: MPL-2.0 Imports: 14 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/mongocluster/2024-07-01/replicas Documentation

The replicas SDK allows for interaction with Azure Resource Manager mongocluster (API Version 2024-07-01).

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

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/mongocluster/2024-07-01/replicas"

Client Initialization

client := replicas.NewReplicasClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ReplicasClient.ListByParent

ctx := context.TODO()
id := replicas.NewMongoClusterID("12345678-1234-9876-4563-123456789012", "example-resource-group", "mongoClusterName")

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForCreateMode

func PossibleValuesForCreateMode() []string

func PossibleValuesForHighAvailabilityMode

func PossibleValuesForHighAvailabilityMode() []string

func PossibleValuesForMongoClusterStatus

func PossibleValuesForMongoClusterStatus() []string

func PossibleValuesForPreviewFeature

func PossibleValuesForPreviewFeature() []string

func PossibleValuesForPrivateEndpointConnectionProvisioningState

func PossibleValuesForPrivateEndpointConnectionProvisioningState() []string

func PossibleValuesForPrivateEndpointServiceConnectionStatus

func PossibleValuesForPrivateEndpointServiceConnectionStatus() []string

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func PossibleValuesForPublicNetworkAccess

func PossibleValuesForPublicNetworkAccess() []string

func PossibleValuesForReplicationRole

func PossibleValuesForReplicationRole() []string

func PossibleValuesForReplicationState

func PossibleValuesForReplicationState() []string

func ValidateMongoClusterID

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

ValidateMongoClusterID checks that 'input' can be parsed as a Mongo Cluster ID

Types

type AdministratorProperties

type AdministratorProperties struct {
	Password *string `json:"password,omitempty"`
	UserName *string `json:"userName,omitempty"`
}

type BackupProperties

type BackupProperties struct {
	EarliestRestoreTime *string `json:"earliestRestoreTime,omitempty"`
}

type ComputeProperties

type ComputeProperties struct {
	Tier *string `json:"tier,omitempty"`
}

type CreateMode

type CreateMode string
const (
	CreateModeDefault            CreateMode = "Default"
	CreateModeGeoReplica         CreateMode = "GeoReplica"
	CreateModePointInTimeRestore CreateMode = "PointInTimeRestore"
	CreateModeReplica            CreateMode = "Replica"
)

func (*CreateMode) UnmarshalJSON

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

type HighAvailabilityMode

type HighAvailabilityMode string
const (
	HighAvailabilityModeDisabled               HighAvailabilityMode = "Disabled"
	HighAvailabilityModeSameZone               HighAvailabilityMode = "SameZone"
	HighAvailabilityModeZoneRedundantPreferred HighAvailabilityMode = "ZoneRedundantPreferred"
)

func (*HighAvailabilityMode) UnmarshalJSON

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

type HighAvailabilityProperties

type HighAvailabilityProperties struct {
	TargetMode *HighAvailabilityMode `json:"targetMode,omitempty"`
}

type ListByParentCompleteResult

type ListByParentCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Replica
}

type ListByParentCustomPager

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

type ListByParentOperationResponse

type ListByParentOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Replica
}

type MongoClusterId

type MongoClusterId struct {
	SubscriptionId    string
	ResourceGroupName string
	MongoClusterName  string
}

MongoClusterId is a struct representing the Resource ID for a Mongo Cluster

func NewMongoClusterID

func NewMongoClusterID(subscriptionId string, resourceGroupName string, mongoClusterName string) MongoClusterId

NewMongoClusterID returns a new MongoClusterId struct

func ParseMongoClusterID

func ParseMongoClusterID(input string) (*MongoClusterId, error)

ParseMongoClusterID parses 'input' into a MongoClusterId

func ParseMongoClusterIDInsensitively

func ParseMongoClusterIDInsensitively(input string) (*MongoClusterId, error)

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

func (*MongoClusterId) FromParseResult

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

func (MongoClusterId) ID

func (id MongoClusterId) ID() string

ID returns the formatted Mongo Cluster ID

func (MongoClusterId) Segments

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

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

func (MongoClusterId) String

func (id MongoClusterId) String() string

String returns a human-readable description of this Mongo Cluster ID

type MongoClusterProperties

type MongoClusterProperties struct {
	Administrator              *AdministratorProperties       `json:"administrator,omitempty"`
	Backup                     *BackupProperties              `json:"backup,omitempty"`
	ClusterStatus              *MongoClusterStatus            `json:"clusterStatus,omitempty"`
	Compute                    *ComputeProperties             `json:"compute,omitempty"`
	ConnectionString           *string                        `json:"connectionString,omitempty"`
	CreateMode                 *CreateMode                    `json:"createMode,omitempty"`
	HighAvailability           *HighAvailabilityProperties    `json:"highAvailability,omitempty"`
	InfrastructureVersion      *string                        `json:"infrastructureVersion,omitempty"`
	PreviewFeatures            *[]PreviewFeature              `json:"previewFeatures,omitempty"`
	PrivateEndpointConnections *[]PrivateEndpointConnection   `json:"privateEndpointConnections,omitempty"`
	ProvisioningState          *ProvisioningState             `json:"provisioningState,omitempty"`
	PublicNetworkAccess        *PublicNetworkAccess           `json:"publicNetworkAccess,omitempty"`
	Replica                    *ReplicationProperties         `json:"replica,omitempty"`
	ReplicaParameters          *MongoClusterReplicaParameters `json:"replicaParameters,omitempty"`
	RestoreParameters          *MongoClusterRestoreParameters `json:"restoreParameters,omitempty"`
	ServerVersion              *string                        `json:"serverVersion,omitempty"`
	Sharding                   *ShardingProperties            `json:"sharding,omitempty"`
	Storage                    *StorageProperties             `json:"storage,omitempty"`
}

type MongoClusterReplicaParameters

type MongoClusterReplicaParameters struct {
	SourceLocation   string `json:"sourceLocation"`
	SourceResourceId string `json:"sourceResourceId"`
}

type MongoClusterRestoreParameters

type MongoClusterRestoreParameters struct {
	PointInTimeUTC   *string `json:"pointInTimeUTC,omitempty"`
	SourceResourceId *string `json:"sourceResourceId,omitempty"`
}

func (*MongoClusterRestoreParameters) GetPointInTimeUTCAsTime

func (o *MongoClusterRestoreParameters) GetPointInTimeUTCAsTime() (*time.Time, error)

func (*MongoClusterRestoreParameters) SetPointInTimeUTCAsTime

func (o *MongoClusterRestoreParameters) SetPointInTimeUTCAsTime(input time.Time)

type MongoClusterStatus

type MongoClusterStatus string
const (
	MongoClusterStatusDropping     MongoClusterStatus = "Dropping"
	MongoClusterStatusProvisioning MongoClusterStatus = "Provisioning"
	MongoClusterStatusReady        MongoClusterStatus = "Ready"
	MongoClusterStatusStarting     MongoClusterStatus = "Starting"
	MongoClusterStatusStopped      MongoClusterStatus = "Stopped"
	MongoClusterStatusStopping     MongoClusterStatus = "Stopping"
	MongoClusterStatusUpdating     MongoClusterStatus = "Updating"
)

func (*MongoClusterStatus) UnmarshalJSON

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

type PreviewFeature

type PreviewFeature string
const (
	PreviewFeatureGeoReplicas PreviewFeature = "GeoReplicas"
)

func (*PreviewFeature) UnmarshalJSON

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

type PrivateEndpoint

type PrivateEndpoint struct {
	Id *string `json:"id,omitempty"`
}

type PrivateEndpointConnection

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

type PrivateEndpointConnectionProperties

type PrivateEndpointConnectionProperties struct {
	GroupIds                          *[]string                                   `json:"groupIds,omitempty"`
	PrivateEndpoint                   *PrivateEndpoint                            `json:"privateEndpoint,omitempty"`
	PrivateLinkServiceConnectionState PrivateLinkServiceConnectionState           `json:"privateLinkServiceConnectionState"`
	ProvisioningState                 *PrivateEndpointConnectionProvisioningState `json:"provisioningState,omitempty"`
}

type PrivateEndpointConnectionProvisioningState

type PrivateEndpointConnectionProvisioningState string
const (
	PrivateEndpointConnectionProvisioningStateCreating  PrivateEndpointConnectionProvisioningState = "Creating"
	PrivateEndpointConnectionProvisioningStateDeleting  PrivateEndpointConnectionProvisioningState = "Deleting"
	PrivateEndpointConnectionProvisioningStateFailed    PrivateEndpointConnectionProvisioningState = "Failed"
	PrivateEndpointConnectionProvisioningStateSucceeded PrivateEndpointConnectionProvisioningState = "Succeeded"
)

func (*PrivateEndpointConnectionProvisioningState) UnmarshalJSON

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

type PrivateEndpointServiceConnectionStatus

type PrivateEndpointServiceConnectionStatus string
const (
	PrivateEndpointServiceConnectionStatusApproved PrivateEndpointServiceConnectionStatus = "Approved"
	PrivateEndpointServiceConnectionStatusPending  PrivateEndpointServiceConnectionStatus = "Pending"
	PrivateEndpointServiceConnectionStatusRejected PrivateEndpointServiceConnectionStatus = "Rejected"
)

func (*PrivateEndpointServiceConnectionStatus) UnmarshalJSON

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

type PrivateLinkServiceConnectionState

type PrivateLinkServiceConnectionState struct {
	ActionsRequired *string                                 `json:"actionsRequired,omitempty"`
	Description     *string                                 `json:"description,omitempty"`
	Status          *PrivateEndpointServiceConnectionStatus `json:"status,omitempty"`
}

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateCanceled   ProvisioningState = "Canceled"
	ProvisioningStateDropping   ProvisioningState = "Dropping"
	ProvisioningStateFailed     ProvisioningState = "Failed"
	ProvisioningStateInProgress ProvisioningState = "InProgress"
	ProvisioningStateSucceeded  ProvisioningState = "Succeeded"
	ProvisioningStateUpdating   ProvisioningState = "Updating"
)

func (*ProvisioningState) UnmarshalJSON

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

type PublicNetworkAccess

type PublicNetworkAccess string
const (
	PublicNetworkAccessDisabled PublicNetworkAccess = "Disabled"
	PublicNetworkAccessEnabled  PublicNetworkAccess = "Enabled"
)

func (*PublicNetworkAccess) UnmarshalJSON

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

type Replica

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

type ReplicaOperationPredicate

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

func (ReplicaOperationPredicate) Matches

func (p ReplicaOperationPredicate) Matches(input Replica) bool

type ReplicasClient

type ReplicasClient struct {
	Client *resourcemanager.Client
}

func NewReplicasClientWithBaseURI

func NewReplicasClientWithBaseURI(sdkApi sdkEnv.Api) (*ReplicasClient, error)

func (ReplicasClient) ListByParent

func (c ReplicasClient) ListByParent(ctx context.Context, id MongoClusterId) (result ListByParentOperationResponse, err error)

ListByParent ...

func (ReplicasClient) ListByParentComplete

func (c ReplicasClient) ListByParentComplete(ctx context.Context, id MongoClusterId) (ListByParentCompleteResult, error)

ListByParentComplete retrieves all the results into a single object

func (ReplicasClient) ListByParentCompleteMatchingPredicate

func (c ReplicasClient) ListByParentCompleteMatchingPredicate(ctx context.Context, id MongoClusterId, predicate ReplicaOperationPredicate) (result ListByParentCompleteResult, err error)

ListByParentCompleteMatchingPredicate retrieves all the results and then applies the predicate

type ReplicationProperties

type ReplicationProperties struct {
	ReplicationState *ReplicationState `json:"replicationState,omitempty"`
	Role             *ReplicationRole  `json:"role,omitempty"`
	SourceResourceId *string           `json:"sourceResourceId,omitempty"`
}

type ReplicationRole

type ReplicationRole string
const (
	ReplicationRoleAsyncReplica    ReplicationRole = "AsyncReplica"
	ReplicationRoleGeoAsyncReplica ReplicationRole = "GeoAsyncReplica"
	ReplicationRolePrimary         ReplicationRole = "Primary"
)

func (*ReplicationRole) UnmarshalJSON

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

type ReplicationState

type ReplicationState string
const (
	ReplicationStateActive        ReplicationState = "Active"
	ReplicationStateBroken        ReplicationState = "Broken"
	ReplicationStateCatchup       ReplicationState = "Catchup"
	ReplicationStateProvisioning  ReplicationState = "Provisioning"
	ReplicationStateReconfiguring ReplicationState = "Reconfiguring"
	ReplicationStateUpdating      ReplicationState = "Updating"
)

func (*ReplicationState) UnmarshalJSON

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

type ShardingProperties

type ShardingProperties struct {
	ShardCount *int64 `json:"shardCount,omitempty"`
}

type StorageProperties

type StorageProperties struct {
	SizeGb *int64 `json:"sizeGb,omitempty"`
}

Jump to

Keyboard shortcuts

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