Cloud Spanner V1 Client - Class CreateBackupRequest (1.80.0)

Reference documentation and code samples for the Cloud Spanner V1 Client class CreateBackupRequest.

The request for CreateBackup.

Generated from protobuf message google.spanner.admin.database.v1.CreateBackupRequest

Namespace

Google \ Cloud \ Spanner \ Admin \ Database \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ parent string

Required. The name of the instance in which the backup will be created. This must be the same instance that contains the database the backup will be created from. The backup will be stored in the location(s) specified in the instance configuration of this instance. Values are of the form projects/<project>/instances/<instance>.

↳ backup_id string

Required. The id of the backup to be created. The backup_id appended to parent forms the full backup name of the form projects/<project>/instances/<instance>/backups/<backup_id>.

↳ backup Google\Cloud\Spanner\Admin\Database\V1\Backup

Required. The backup to create.

↳ encryption_config Google\Cloud\Spanner\Admin\Database\V1\CreateBackupEncryptionConfig

Optional. The encryption configuration used to encrypt the backup. If this field is not specified, the backup will use the same encryption configuration as the database by default, namely encryption_type = USE_DATABASE_ENCRYPTION.

getParent

Required. The name of the instance in which the backup will be created. This must be the same instance that contains the database the backup will be created from. The backup will be stored in the location(s) specified in the instance configuration of this instance. Values are of the form projects/<project>/instances/<instance>.

Returns
Type Description
string

setParent

Required. The name of the instance in which the backup will be created. This must be the same instance that contains the database the backup will be created from. The backup will be stored in the location(s) specified in the instance configuration of this instance. Values are of the form projects/<project>/instances/<instance>.

Parameter
Name Description
var string
Returns
Type Description
$this

getBackupId

Required. The id of the backup to be created. The backup_id appended to parent forms the full backup name of the form projects/<project>/instances/<instance>/backups/<backup_id>.

Returns
Type Description
string

setBackupId

Required. The id of the backup to be created. The backup_id appended to parent forms the full backup name of the form projects/<project>/instances/<instance>/backups/<backup_id>.

Parameter
Name Description
var string
Returns
Type Description
$this

getBackup

Required. The backup to create.

Returns
Type Description
Google\Cloud\Spanner\Admin\Database\V1\Backup|null

hasBackup

clearBackup

setBackup

Required. The backup to create.

Parameter
Name Description
var Google\Cloud\Spanner\Admin\Database\V1\Backup
Returns
Type Description
$this

getEncryptionConfig

Optional. The encryption configuration used to encrypt the backup. If this field is not specified, the backup will use the same encryption configuration as the database by default, namely encryption_type = USE_DATABASE_ENCRYPTION.

Returns
Type Description
Google\Cloud\Spanner\Admin\Database\V1\CreateBackupEncryptionConfig|null

hasEncryptionConfig

clearEncryptionConfig

setEncryptionConfig

Optional. The encryption configuration used to encrypt the backup. If this field is not specified, the backup will use the same encryption configuration as the database by default, namely encryption_type = USE_DATABASE_ENCRYPTION.

Parameter
Name Description
var Google\Cloud\Spanner\Admin\Database\V1\CreateBackupEncryptionConfig
Returns
Type Description
$this

static::build

Parameters
Name Description
parent string

Required. The name of the instance in which the backup will be created. This must be the same instance that contains the database the backup will be created from. The backup will be stored in the location(s) specified in the instance configuration of this instance. Values are of the form projects/<project>/instances/<instance>. Please see Google\Cloud\Spanner\Admin\Database\V1\DatabaseAdminClient::instanceName() for help formatting this field.

backup Google\Cloud\Spanner\Admin\Database\V1\Backup

Required. The backup to create.

backupId string

Required. The id of the backup to be created. The backup_id appended to parent forms the full backup name of the form projects/<project>/instances/<instance>/backups/<backup_id>.

Returns
Type Description
Google\Cloud\Spanner\Admin\Database\V1\CreateBackupRequest