crossregionrestore

package
v0.20230829.1225856 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2023 License: MPL-2.0 Imports: 10 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/recoveryservicesbackup/2023-01-15/crossregionrestore Documentation

The crossregionrestore SDK allows for interaction with the Azure Resource Manager Service recoveryservicesbackup (API Version 2023-01-15).

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/recoveryservicesbackup/2023-01-15/crossregionrestore"

Client Initialization

client := crossregionrestore.NewCrossRegionRestoreClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: CrossRegionRestoreClient.Trigger

ctx := context.TODO()
id := crossregionrestore.NewLocationID("12345678-1234-9876-4563-123456789012", "locationValue")

payload := crossregionrestore.CrossRegionRestoreRequest{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForCopyOptions

func PossibleValuesForCopyOptions() []string

func PossibleValuesForOverwriteOptions

func PossibleValuesForOverwriteOptions() []string

func PossibleValuesForRecoveryMode

func PossibleValuesForRecoveryMode() []string

func PossibleValuesForRecoveryType

func PossibleValuesForRecoveryType() []string

func PossibleValuesForRestoreRequestType

func PossibleValuesForRestoreRequestType() []string

func PossibleValuesForSQLDataDirectoryType

func PossibleValuesForSQLDataDirectoryType() []string

func ValidateLocationID

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

ValidateLocationID checks that 'input' can be parsed as a Location ID

Types

type AzureFileShareRestoreRequest

type AzureFileShareRestoreRequest struct {
	CopyOptions        *CopyOptions          `json:"copyOptions,omitempty"`
	RecoveryType       *RecoveryType         `json:"recoveryType,omitempty"`
	RestoreFileSpecs   *[]RestoreFileSpecs   `json:"restoreFileSpecs,omitempty"`
	RestoreRequestType *RestoreRequestType   `json:"restoreRequestType,omitempty"`
	SourceResourceId   *string               `json:"sourceResourceId,omitempty"`
	TargetDetails      *TargetAFSRestoreInfo `json:"targetDetails,omitempty"`
}

func (AzureFileShareRestoreRequest) MarshalJSON

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

type AzureWorkloadPointInTimeRestoreRequest

type AzureWorkloadPointInTimeRestoreRequest struct {
	PointInTime            *string            `json:"pointInTime,omitempty"`
	PropertyBag            *map[string]string `json:"propertyBag,omitempty"`
	RecoveryMode           *RecoveryMode      `json:"recoveryMode,omitempty"`
	RecoveryType           *RecoveryType      `json:"recoveryType,omitempty"`
	SourceResourceId       *string            `json:"sourceResourceId,omitempty"`
	TargetInfo             *TargetRestoreInfo `json:"targetInfo,omitempty"`
	TargetVirtualMachineId *string            `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadPointInTimeRestoreRequest) MarshalJSON

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

type AzureWorkloadRestoreRequest

type AzureWorkloadRestoreRequest struct {
	PropertyBag            *map[string]string `json:"propertyBag,omitempty"`
	RecoveryMode           *RecoveryMode      `json:"recoveryMode,omitempty"`
	RecoveryType           *RecoveryType      `json:"recoveryType,omitempty"`
	SourceResourceId       *string            `json:"sourceResourceId,omitempty"`
	TargetInfo             *TargetRestoreInfo `json:"targetInfo,omitempty"`
	TargetVirtualMachineId *string            `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadRestoreRequest) MarshalJSON

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

type AzureWorkloadSAPHanaPointInTimeRestoreRequest

type AzureWorkloadSAPHanaPointInTimeRestoreRequest struct {
	PointInTime            *string            `json:"pointInTime,omitempty"`
	PropertyBag            *map[string]string `json:"propertyBag,omitempty"`
	RecoveryMode           *RecoveryMode      `json:"recoveryMode,omitempty"`
	RecoveryType           *RecoveryType      `json:"recoveryType,omitempty"`
	SourceResourceId       *string            `json:"sourceResourceId,omitempty"`
	TargetInfo             *TargetRestoreInfo `json:"targetInfo,omitempty"`
	TargetVirtualMachineId *string            `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadSAPHanaPointInTimeRestoreRequest) MarshalJSON

type AzureWorkloadSAPHanaRestoreRequest

type AzureWorkloadSAPHanaRestoreRequest struct {
	PropertyBag            *map[string]string `json:"propertyBag,omitempty"`
	RecoveryMode           *RecoveryMode      `json:"recoveryMode,omitempty"`
	RecoveryType           *RecoveryType      `json:"recoveryType,omitempty"`
	SourceResourceId       *string            `json:"sourceResourceId,omitempty"`
	TargetInfo             *TargetRestoreInfo `json:"targetInfo,omitempty"`
	TargetVirtualMachineId *string            `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadSAPHanaRestoreRequest) MarshalJSON

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

type AzureWorkloadSQLPointInTimeRestoreRequest

type AzureWorkloadSQLPointInTimeRestoreRequest struct {
	AlternateDirectoryPaths          *[]SQLDataDirectoryMapping `json:"alternateDirectoryPaths,omitempty"`
	IsNonRecoverable                 *bool                      `json:"isNonRecoverable,omitempty"`
	PointInTime                      *string                    `json:"pointInTime,omitempty"`
	PropertyBag                      *map[string]string         `json:"propertyBag,omitempty"`
	RecoveryMode                     *RecoveryMode              `json:"recoveryMode,omitempty"`
	RecoveryType                     *RecoveryType              `json:"recoveryType,omitempty"`
	ShouldUseAlternateTargetLocation *bool                      `json:"shouldUseAlternateTargetLocation,omitempty"`
	SourceResourceId                 *string                    `json:"sourceResourceId,omitempty"`
	TargetInfo                       *TargetRestoreInfo         `json:"targetInfo,omitempty"`
	TargetVirtualMachineId           *string                    `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadSQLPointInTimeRestoreRequest) MarshalJSON

type AzureWorkloadSQLRestoreRequest

type AzureWorkloadSQLRestoreRequest struct {
	AlternateDirectoryPaths          *[]SQLDataDirectoryMapping `json:"alternateDirectoryPaths,omitempty"`
	IsNonRecoverable                 *bool                      `json:"isNonRecoverable,omitempty"`
	PropertyBag                      *map[string]string         `json:"propertyBag,omitempty"`
	RecoveryMode                     *RecoveryMode              `json:"recoveryMode,omitempty"`
	RecoveryType                     *RecoveryType              `json:"recoveryType,omitempty"`
	ShouldUseAlternateTargetLocation *bool                      `json:"shouldUseAlternateTargetLocation,omitempty"`
	SourceResourceId                 *string                    `json:"sourceResourceId,omitempty"`
	TargetInfo                       *TargetRestoreInfo         `json:"targetInfo,omitempty"`
	TargetVirtualMachineId           *string                    `json:"targetVirtualMachineId,omitempty"`
}

func (AzureWorkloadSQLRestoreRequest) MarshalJSON

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

type CopyOptions

type CopyOptions string
const (
	CopyOptionsCreateCopy     CopyOptions = "CreateCopy"
	CopyOptionsFailOnConflict CopyOptions = "FailOnConflict"
	CopyOptionsInvalid        CopyOptions = "Invalid"
	CopyOptionsOverwrite      CopyOptions = "Overwrite"
	CopyOptionsSkip           CopyOptions = "Skip"
)

type CrossRegionRestoreClient

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

func NewCrossRegionRestoreClientWithBaseURI

func NewCrossRegionRestoreClientWithBaseURI(endpoint string) CrossRegionRestoreClient

func (CrossRegionRestoreClient) Trigger

Trigger ...

func (CrossRegionRestoreClient) TriggerThenPoll

TriggerThenPoll performs Trigger then polls until it's completed

type CrossRegionRestoreRequest

type CrossRegionRestoreRequest struct {
	CrossRegionRestoreAccessDetails CrrAccessToken `json:"crossRegionRestoreAccessDetails"`
	RestoreRequest                  RestoreRequest `json:"restoreRequest"`
}

func (*CrossRegionRestoreRequest) UnmarshalJSON

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

type CrrAccessToken

type CrrAccessToken interface {
}

type EncryptionDetails

type EncryptionDetails struct {
	EncryptionEnabled *bool   `json:"encryptionEnabled,omitempty"`
	KekUrl            *string `json:"kekUrl,omitempty"`
	KekVaultId        *string `json:"kekVaultId,omitempty"`
	SecretKeyUrl      *string `json:"secretKeyUrl,omitempty"`
	SecretKeyVaultId  *string `json:"secretKeyVaultId,omitempty"`
}

type IaasVMRestoreRequest

type IaasVMRestoreRequest struct {
	AffinityGroup                *string                      `json:"affinityGroup,omitempty"`
	CreateNewCloudService        *bool                        `json:"createNewCloudService,omitempty"`
	DiskEncryptionSetId          *string                      `json:"diskEncryptionSetId,omitempty"`
	EncryptionDetails            *EncryptionDetails           `json:"encryptionDetails,omitempty"`
	IdentityBasedRestoreDetails  *IdentityBasedRestoreDetails `json:"identityBasedRestoreDetails,omitempty"`
	IdentityInfo                 *IdentityInfo                `json:"identityInfo,omitempty"`
	OriginalStorageAccountOption *bool                        `json:"originalStorageAccountOption,omitempty"`
	RecoveryPointId              *string                      `json:"recoveryPointId,omitempty"`
	RecoveryType                 *RecoveryType                `json:"recoveryType,omitempty"`
	Region                       *string                      `json:"region,omitempty"`
	RestoreDiskLunList           *[]int64                     `json:"restoreDiskLunList,omitempty"`
	RestoreWithManagedDisks      *bool                        `json:"restoreWithManagedDisks,omitempty"`
	SourceResourceId             *string                      `json:"sourceResourceId,omitempty"`
	StorageAccountId             *string                      `json:"storageAccountId,omitempty"`
	SubnetId                     *string                      `json:"subnetId,omitempty"`
	TargetDomainNameId           *string                      `json:"targetDomainNameId,omitempty"`
	TargetResourceGroupId        *string                      `json:"targetResourceGroupId,omitempty"`
	TargetVirtualMachineId       *string                      `json:"targetVirtualMachineId,omitempty"`
	VirtualNetworkId             *string                      `json:"virtualNetworkId,omitempty"`
	Zones                        *zones.Schema                `json:"zones,omitempty"`
}

func (IaasVMRestoreRequest) MarshalJSON

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

type IdentityBasedRestoreDetails

type IdentityBasedRestoreDetails struct {
	ObjectType             *string `json:"objectType,omitempty"`
	TargetStorageAccountId *string `json:"targetStorageAccountId,omitempty"`
}

type IdentityInfo

type IdentityInfo struct {
	IsSystemAssignedIdentity  *bool   `json:"isSystemAssignedIdentity,omitempty"`
	ManagedIdentityResourceId *string `json:"managedIdentityResourceId,omitempty"`
}

type LocationId

type LocationId struct {
	SubscriptionId string
	LocationName   string
}

LocationId is a struct representing the Resource ID for a Location

func NewLocationID

func NewLocationID(subscriptionId string, locationName string) LocationId

NewLocationID returns a new LocationId struct

func ParseLocationID

func ParseLocationID(input string) (*LocationId, error)

ParseLocationID parses 'input' into a LocationId

func ParseLocationIDInsensitively

func ParseLocationIDInsensitively(input string) (*LocationId, error)

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

func (LocationId) ID

func (id LocationId) ID() string

ID returns the formatted Location ID

func (LocationId) Segments

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

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

func (LocationId) String

func (id LocationId) String() string

String returns a human-readable description of this Location ID

type OverwriteOptions

type OverwriteOptions string
const (
	OverwriteOptionsFailOnConflict OverwriteOptions = "FailOnConflict"
	OverwriteOptionsInvalid        OverwriteOptions = "Invalid"
	OverwriteOptionsOverwrite      OverwriteOptions = "Overwrite"
)

type RawCrrAccessTokenImpl added in v0.20230807.1063129

type RawCrrAccessTokenImpl struct {
	Type   string
	Values map[string]interface{}
}

RawModeOfTransitImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RawRestoreRequestImpl added in v0.20230807.1063129

type RawRestoreRequestImpl struct {
	Type   string
	Values map[string]interface{}
}

RawModeOfTransitImpl is returned when the Discriminated Value doesn't match any of the defined types NOTE: this should only be used when a type isn't defined for this type of Object (as a workaround) and is used only for Deserialization (e.g. this cannot be used as a Request Payload).

type RecoveryMode

type RecoveryMode string
const (
	RecoveryModeFileRecovery     RecoveryMode = "FileRecovery"
	RecoveryModeInvalid          RecoveryMode = "Invalid"
	RecoveryModeWorkloadRecovery RecoveryMode = "WorkloadRecovery"
)

type RecoveryType

type RecoveryType string
const (
	RecoveryTypeAlternateLocation RecoveryType = "AlternateLocation"
	RecoveryTypeInvalid           RecoveryType = "Invalid"
	RecoveryTypeOffline           RecoveryType = "Offline"
	RecoveryTypeOriginalLocation  RecoveryType = "OriginalLocation"
	RecoveryTypeRestoreDisks      RecoveryType = "RestoreDisks"
)

type RestoreFileSpecs

type RestoreFileSpecs struct {
	FileSpecType     *string `json:"fileSpecType,omitempty"`
	Path             *string `json:"path,omitempty"`
	TargetFolderPath *string `json:"targetFolderPath,omitempty"`
}

type RestoreRequest

type RestoreRequest interface {
}

type RestoreRequestType

type RestoreRequestType string
const (
	RestoreRequestTypeFullShareRestore RestoreRequestType = "FullShareRestore"
	RestoreRequestTypeInvalid          RestoreRequestType = "Invalid"
	RestoreRequestTypeItemLevelRestore RestoreRequestType = "ItemLevelRestore"
)

type SQLDataDirectoryMapping

type SQLDataDirectoryMapping struct {
	MappingType       *SQLDataDirectoryType `json:"mappingType,omitempty"`
	SourceLogicalName *string               `json:"sourceLogicalName,omitempty"`
	SourcePath        *string               `json:"sourcePath,omitempty"`
	TargetPath        *string               `json:"targetPath,omitempty"`
}

type SQLDataDirectoryType

type SQLDataDirectoryType string
const (
	SQLDataDirectoryTypeData    SQLDataDirectoryType = "Data"
	SQLDataDirectoryTypeInvalid SQLDataDirectoryType = "Invalid"
	SQLDataDirectoryTypeLog     SQLDataDirectoryType = "Log"
)

type TargetAFSRestoreInfo

type TargetAFSRestoreInfo struct {
	Name             *string `json:"name,omitempty"`
	TargetResourceId *string `json:"targetResourceId,omitempty"`
}

type TargetRestoreInfo

type TargetRestoreInfo struct {
	ContainerId                   *string           `json:"containerId,omitempty"`
	DatabaseName                  *string           `json:"databaseName,omitempty"`
	OverwriteOption               *OverwriteOptions `json:"overwriteOption,omitempty"`
	TargetDirectoryForFileRestore *string           `json:"targetDirectoryForFileRestore,omitempty"`
}

type TriggerOperationResponse

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

type WorkloadCrrAccessToken

type WorkloadCrrAccessToken struct {
	ContainerId                                 *string `json:"containerId,omitempty"`
	PolicyId                                    *string `json:"policyId,omitempty"`
	PolicyName                                  *string `json:"policyName,omitempty"`
	ProtectableObjectContainerHostOsName        *string `json:"protectableObjectContainerHostOsName,omitempty"`
	ProtectableObjectFriendlyName               *string `json:"protectableObjectFriendlyName,omitempty"`
	ProtectableObjectParentLogicalContainerName *string `json:"protectableObjectParentLogicalContainerName,omitempty"`
	ProtectableObjectProtectionState            *string `json:"protectableObjectProtectionState,omitempty"`
	ProtectableObjectUniqueName                 *string `json:"protectableObjectUniqueName,omitempty"`
	ProtectableObjectWorkloadType               *string `json:"protectableObjectWorkloadType,omitempty"`

	// Fields inherited from CrrAccessToken
	AccessTokenString          *string            `json:"accessTokenString,omitempty"`
	BMSActiveRegion            *string            `json:"bMSActiveRegion,omitempty"`
	BackupManagementType       *string            `json:"backupManagementType,omitempty"`
	ContainerName              *string            `json:"containerName,omitempty"`
	ContainerType              *string            `json:"containerType,omitempty"`
	CoordinatorServiceStampId  *string            `json:"coordinatorServiceStampId,omitempty"`
	CoordinatorServiceStampUri *string            `json:"coordinatorServiceStampUri,omitempty"`
	DatasourceContainerName    *string            `json:"datasourceContainerName,omitempty"`
	DatasourceId               *string            `json:"datasourceId,omitempty"`
	DatasourceName             *string            `json:"datasourceName,omitempty"`
	DatasourceType             *string            `json:"datasourceType,omitempty"`
	ProtectionContainerId      *int64             `json:"protectionContainerId,omitempty"`
	ProtectionServiceStampId   *string            `json:"protectionServiceStampId,omitempty"`
	ProtectionServiceStampUri  *string            `json:"protectionServiceStampUri,omitempty"`
	RecoveryPointId            *string            `json:"recoveryPointId,omitempty"`
	RecoveryPointTime          *string            `json:"recoveryPointTime,omitempty"`
	ResourceGroupName          *string            `json:"resourceGroupName,omitempty"`
	ResourceId                 *string            `json:"resourceId,omitempty"`
	ResourceName               *string            `json:"resourceName,omitempty"`
	RpIsManagedVirtualMachine  *bool              `json:"rpIsManagedVirtualMachine,omitempty"`
	RpOriginalSAOption         *bool              `json:"rpOriginalSAOption,omitempty"`
	RpTierInformation          *map[string]string `json:"rpTierInformation,omitempty"`
	RpVMSizeDescription        *string            `json:"rpVMSizeDescription,omitempty"`
	SubscriptionId             *string            `json:"subscriptionId,omitempty"`
	TokenExtendedInformation   *string            `json:"tokenExtendedInformation,omitempty"`
}

func (WorkloadCrrAccessToken) MarshalJSON

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

Jump to

Keyboard shortcuts

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