Class DBBackupRestoreClient

java.lang.Object
com.salesforce.multicloudj.dbbackuprestore.client.DBBackupRestoreClient
All Implemented Interfaces:
AutoCloseable

public class DBBackupRestoreClient extends Object implements AutoCloseable
Client for performing database backup and restore operations across multiple cloud providers. This class provides a cloud-agnostic interface for backup and restore operations.
Since:
0.2.25
  • Constructor Details

    • DBBackupRestoreClient

      public DBBackupRestoreClient(AbstractDBBackupRestore dbBackupRestore)
      Creates a new DBBackupRestoreClient wrapping the given driver.
      Parameters:
      dbBackupRestore - the database backup restore driver implementation
  • Method Details

    • builder

      public static DBBackupRestoreClient.DBBackupRestoreClientBuilder builder(String providerId)
      Creates a new builder for constructing a DBBackupRestoreClient.
      Parameters:
      providerId - the cloud provider identifier
      Returns:
      a new ClientBuilder instance
    • listBackups

      public List<Backup> listBackups()
      Lists all available backups for the current table.
      Returns:
      a list of Backup objects representing available backups
    • getBackup

      public Backup getBackup(String backupId)
      Gets details of a specific backup by its ID.
      Parameters:
      backupId - the unique identifier of the backup
      Returns:
      the Backup object with full metadata
    • restoreBackup

      public String restoreBackup(RestoreRequest request)
      Restores a table from a backup. The restore operation may take time depending on the backup size and is async request.
      Parameters:
      request - the restore request containing restore configuration
      Returns:
      the unique identifier of the restore operation for status tracking
    • getRestoreJob

      public Restore getRestoreJob(String restoreId)
      Gets details of a specific restore operation by its ID.
      Parameters:
      restoreId - the unique identifier of the restore operation
      Returns:
      the Restore object with full metadata
    • close

      public void close() throws Exception
      Specified by:
      close in interface AutoCloseable
      Throws:
      Exception