createBackup
Creates a database backup, containing a snapshot of existing objects, at the remote file store accessible via the data sink specified bydatasinkName.Parameters:request-Requestobject containing the parameters for the operation.Returns:Responseobject containing the results of the operation.Throws:GPUdbException- if an error occurs during the operation.createBackup
public CreateBackupResponse createBackup(String backupName, String backupType, Map<String, String> backupObjectsMap, String datasinkName, Map<String, String> options) throws GPUdbException Creates a database backup, containing a snapshot of existing objects, at the remote file store accessible via the data sink specified bydatasinkName.Parameters:backupName- Name for this backup. If the backup already exists, only an incremental or differential backup can be made, unlessRECREATEis set toTRUE.backupType- Type of snapshot to create. Supported values:DIFFERENTIAL: Snapshot of changes in the database objects and data since the last full snapshot.FULL: Snapshot of the given database objects and data.INCREMENTAL: Snapshot of changes in the database objects and data since the last snapshot of any kind.
backupObjectsMap- Map of objects to be captured in the backup; must be specified when creating a full snapshot and left unspecified when creating an incremental or differential snapshot.ALL: All object types and data contained in the given schema(s).CATALOG: Data Lake catalog that is external to the database.CONTEXT: Context(s).CREDENTIAL: Credential(s).DATASINK: Data sink(s).DATASOURCE: Data source(s).DIRECTORY: KiFS File directory(ies).FUNCTION_ENVIRONMENT: Python UDF function environment(s).GRAPH: Graph definition(s). Source table(s), if applicable, are required in order to restore graph objects.MONITOR: Table monitor(s) / SQL stream(s).RESOURCE_GROUP: Resource group(s).ROLE: Role(s), role members (roles or users, recursively), and associated permissions.STORED_PROCEDURE: SQL procedure(s).TABLE: Table(s) and SQL view(s). Active subscriptions on any tables to be backed up will be temporarily suspended while the backup is active.USER: User(s) (internal and external) and associated permissions.USER_DEFINED_FUNCTION: UDF(s).
Map.datasinkName- Data sink through which the backup will be stored.options- Optional parameters.BLOCK_TABLE_MUTATIONS: Whether or not to block all mutations on target tables while they are being backed up. Supported values:TRUE: Block all mutations on target tables while they are being backed up.FALSE: Only block mutations on a target table at the point a disk eviction is necessary.
FALSE.CHECKSUM: Whether or not to calculate checksums for backup files. Supported values:The default value isFALSE.COMMENT: Comments to store with this backup.DDL_ONLY: Whether or not, for tables, to only backup DDL and not table data. Supported values:The default value isFALSE.DELETE_INTERMEDIATE_BACKUPS: Whether or not to delete any intermediate snapshots when thebackupTypeis set toDIFFERENTIAL. Supported values:The default value isFALSE.DRY_RUN: Whether or not to perform a dry run of a backup operation. Supported values:The default value isFALSE.MAX_INCREMENTAL_BACKUPS_TO_KEEP: Maximum number of incremental snapshots to keep. The default value is ‘-1’.RECREATE: Whether or not to replace an existing backup object with a new backup with a full snapshot, if one already exists. Supported values:The default value isFALSE.
Map.Returns:Responseobject containing the results of the operation.Throws:GPUdbException- if an error occurs during the operation.