Class DefaultBackupJobProvider

java.lang.Object
com.morpheusdata.core.backup.DefaultBackupJobProvider
All Implemented Interfaces:
BackupJobProvider

public class DefaultBackupJobProvider extends Object implements BackupJobProvider
The Default backup job provider which delegates the backup operations back to morpheus. Use this as the backup job provider in a backup provider when the provider does not have the concept of scheduled batch backup operations, or it is desired for morpheus to handle the scheduling and running of batch backup operations.
Since:
0.13.4
  • Constructor Details

  • Method Details

    • configureBackupJob

      public ServiceResponse configureBackupJob(BackupJob backupJobModel, Map config, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      configureBackupJob in interface BackupJobProvider
      Parameters:
      backupJobModel - the backup job to apply the configuration changes to
      config - the configuration supplied by external inputs.
      opts - optional parameters used for configuration.
      Returns:
      a ServiceResponse object. A ServiceResponse with a false success will indicate a failed configuration and will halt the backup creation process.
    • validateBackupJob

      public ServiceResponse validateBackupJob(BackupJob backupJobModel, Map config, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      validateBackupJob in interface BackupJobProvider
      Parameters:
      backupJobModel - the backup job to validate
      config - the original configuration supplied by external inputs.
      opts - optional parameters used for
      Returns:
      a ServiceResponse object. The errors field of the ServiceResponse is used to send validation results back to the interface in the format of errors['fieldName'] = 'validation message' . The msg property can be used to send generic validation text that is not related to a specific field on the model. A ServiceResponse with any items in the errors list or a success value of 'false' will halt the backup job creation process.
    • createBackupJob

      public ServiceResponse createBackupJob(BackupJob backupJobModel, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      createBackupJob in interface BackupJobProvider
      Parameters:
      backupJobModel - the fully configured and validated backup job
      opts - additional options used during backup job creation
      Returns:
      a ServiceResponse object. A ServiceResponse with a success value of 'false' will indicate the creation on the external system failed and will halt any further processing in Morpheus.
    • cloneBackupJob

      public ServiceResponse cloneBackupJob(BackupJob sourceBackupJobModel, BackupJob backupJobModel, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      cloneBackupJob in interface BackupJobProvider
      Parameters:
      sourceBackupJobModel - the source backup job for cloning
      backupJobModel - the backup job that will be associated to the cloned backup job. The externalId of the backup job should be set with the ID of the cloned job result.
      opts - additional options used during backup job clone
      Returns:
      a ServiceResponse object. A ServiceResponse with a success value of 'false' will indicate the clone on the external system failed and will halt any further processing in Morpheus.
    • addToBackupJob

      public ServiceResponse addToBackupJob(BackupJob backupJobModel, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      addToBackupJob in interface BackupJobProvider
      Parameters:
      backupJobModel - the backup job receiving the additional backup
      opts - additional options
      Returns:
      a ServiceResponse object. A ServiceResponse with a success value of 'false' will indicate the operation on the external system failed and will halt any further processing in Morpheus.
    • deleteBackupJob

      public ServiceResponse deleteBackupJob(BackupJob backupJobModel, Map opts)
      There is no additional work to be done, allow morpheus to complete the internal process.
      Specified by:
      deleteBackupJob in interface BackupJobProvider
      Parameters:
      backupJobModel - the backup job to be removed
      opts - additional options
      Returns:
      a ServiceResponse object. A ServiceResponse with a success value of 'false' will indicate the operation on the external system failed and will halt any further processing in Morpheus.
    • executeBackupJob

      public ServiceResponse executeBackupJob(BackupJob backupJob, Map opts)
      Trigger the execution of all backups with the job through morpheus backup services.
      Specified by:
      executeBackupJob in interface BackupJobProvider
      Parameters:
      backupJob - backup job to be executed
      opts - optional parameters for the job execution process
      Returns:
      ServiceResponse containing the success or failure of the job execution process