Class AzureWorkloadSqlRestoreRequest

Direct Known Subclasses:
AzureWorkloadSqlPointInTimeRestoreRequest, AzureWorkloadSqlRestoreWithRehydrateRequest

public class AzureWorkloadSqlRestoreRequest extends AzureWorkloadRestoreRequest
AzureWorkload SQL -specific restore. Specifically for full/diff restore.
  • Constructor Details

    • AzureWorkloadSqlRestoreRequest

      public AzureWorkloadSqlRestoreRequest()
      Creates an instance of AzureWorkloadSqlRestoreRequest class.
  • Method Details

    • shouldUseAlternateTargetLocation

      public Boolean shouldUseAlternateTargetLocation()
      Get the shouldUseAlternateTargetLocation property: Default option set to true. If this is set to false, alternate data directory must be provided.
      Returns:
      the shouldUseAlternateTargetLocation value.
    • withShouldUseAlternateTargetLocation

      public AzureWorkloadSqlRestoreRequest withShouldUseAlternateTargetLocation(Boolean shouldUseAlternateTargetLocation)
      Set the shouldUseAlternateTargetLocation property: Default option set to true. If this is set to false, alternate data directory must be provided.
      Parameters:
      shouldUseAlternateTargetLocation - the shouldUseAlternateTargetLocation value to set.
      Returns:
      the AzureWorkloadSqlRestoreRequest object itself.
    • isNonRecoverable

      public Boolean isNonRecoverable()
      Get the isNonRecoverable property: SQL specific property where user can chose to set no-recovery when restore operation is tried.
      Returns:
      the isNonRecoverable value.
    • withIsNonRecoverable

      public AzureWorkloadSqlRestoreRequest withIsNonRecoverable(Boolean isNonRecoverable)
      Set the isNonRecoverable property: SQL specific property where user can chose to set no-recovery when restore operation is tried.
      Parameters:
      isNonRecoverable - the isNonRecoverable value to set.
      Returns:
      the AzureWorkloadSqlRestoreRequest object itself.
    • alternateDirectoryPaths

      public List<SqlDataDirectoryMapping> alternateDirectoryPaths()
      Get the alternateDirectoryPaths property: Data directory details.
      Returns:
      the alternateDirectoryPaths value.
    • withAlternateDirectoryPaths

      public AzureWorkloadSqlRestoreRequest withAlternateDirectoryPaths(List<SqlDataDirectoryMapping> alternateDirectoryPaths)
      Set the alternateDirectoryPaths property: Data directory details.
      Parameters:
      alternateDirectoryPaths - the alternateDirectoryPaths value to set.
      Returns:
      the AzureWorkloadSqlRestoreRequest object itself.
    • withRecoveryType

      public AzureWorkloadSqlRestoreRequest withRecoveryType(RecoveryType recoveryType)
      Set the recoveryType property: Type of this recovery.
      Overrides:
      withRecoveryType in class AzureWorkloadRestoreRequest
      Parameters:
      recoveryType - the recoveryType value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • withSourceResourceId

      public AzureWorkloadSqlRestoreRequest withSourceResourceId(String sourceResourceId)
      Set the sourceResourceId property: Fully qualified ARM ID of the VM on which workload that was running is being recovered.
      Overrides:
      withSourceResourceId in class AzureWorkloadRestoreRequest
      Parameters:
      sourceResourceId - the sourceResourceId value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • withPropertyBag

      public AzureWorkloadSqlRestoreRequest withPropertyBag(Map<String,String> propertyBag)
      Set the propertyBag property: Workload specific property bag.
      Overrides:
      withPropertyBag in class AzureWorkloadRestoreRequest
      Parameters:
      propertyBag - the propertyBag value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • withTargetInfo

      public AzureWorkloadSqlRestoreRequest withTargetInfo(TargetRestoreInfo targetInfo)
      Set the targetInfo property: Details of target database.
      Overrides:
      withTargetInfo in class AzureWorkloadRestoreRequest
      Parameters:
      targetInfo - the targetInfo value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • withRecoveryMode

      public AzureWorkloadSqlRestoreRequest withRecoveryMode(RecoveryMode recoveryMode)
      Set the recoveryMode property: Defines whether the current recovery mode is file restore or database restore.
      Overrides:
      withRecoveryMode in class AzureWorkloadRestoreRequest
      Parameters:
      recoveryMode - the recoveryMode value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • withTargetVirtualMachineId

      public AzureWorkloadSqlRestoreRequest withTargetVirtualMachineId(String targetVirtualMachineId)
      Set the targetVirtualMachineId property: This is the complete ARM Id of the target VM For e.g. /subscriptions/{subId}/resourcegroups/{rg}/provider/Microsoft.Compute/virtualmachines/{vm}.
      Overrides:
      withTargetVirtualMachineId in class AzureWorkloadRestoreRequest
      Parameters:
      targetVirtualMachineId - the targetVirtualMachineId value to set.
      Returns:
      the AzureWorkloadRestoreRequest object itself.
    • validate

      public void validate()
      Validates the instance.
      Overrides:
      validate in class AzureWorkloadRestoreRequest
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.