Index
DatabaseAdmin
(interface)Backup
(message)Backup.State
(enum)BackupInfo
(message)BackupSchedule
(message)BackupScheduleSpec
(message)ChangeQuorumMetadata
(message)ChangeQuorumRequest
(message)CopyBackupEncryptionConfig
(message)CopyBackupEncryptionConfig.EncryptionType
(enum)CopyBackupMetadata
(message)CopyBackupRequest
(message)CreateBackupEncryptionConfig
(message)CreateBackupEncryptionConfig.EncryptionType
(enum)CreateBackupMetadata
(message)CreateBackupRequest
(message)CreateBackupScheduleRequest
(message)CreateDatabaseMetadata
(message)CreateDatabaseRequest
(message)CrontabSpec
(message)Database
(message)Database.State
(enum)DatabaseDialect
(enum)DatabaseRole
(message)DdlStatementActionInfo
(message)DeleteBackupRequest
(message)DeleteBackupScheduleRequest
(message)DropDatabaseRequest
(message)EncryptionConfig
(message)EncryptionInfo
(message)EncryptionInfo.Type
(enum)FullBackupSpec
(message)GetBackupRequest
(message)GetBackupScheduleRequest
(message)GetDatabaseDdlRequest
(message)GetDatabaseDdlResponse
(message)GetDatabaseRequest
(message)IncrementalBackupSpec
(message)ListBackupOperationsRequest
(message)ListBackupOperationsResponse
(message)ListBackupSchedulesRequest
(message)ListBackupSchedulesResponse
(message)ListBackupsRequest
(message)ListBackupsResponse
(message)ListDatabaseOperationsRequest
(message)ListDatabaseOperationsResponse
(message)ListDatabaseRolesRequest
(message)ListDatabaseRolesResponse
(message)ListDatabasesRequest
(message)ListDatabasesResponse
(message)OperationProgress
(message)OptimizeRestoredDatabaseMetadata
(message)QuorumInfo
(message)QuorumInfo.Initiator
(enum)QuorumType
(message)QuorumType.DualRegionQuorum
(message)QuorumType.SingleRegionQuorum
(message)RestoreDatabaseEncryptionConfig
(message)RestoreDatabaseEncryptionConfig.EncryptionType
(enum)RestoreDatabaseMetadata
(message)RestoreDatabaseRequest
(message)RestoreInfo
(message)RestoreSourceType
(enum)UpdateBackupRequest
(message)UpdateBackupScheduleRequest
(message)UpdateDatabaseDdlMetadata
(message)UpdateDatabaseDdlRequest
(message)UpdateDatabaseMetadata
(message)UpdateDatabaseRequest
(message)
DatabaseAdmin
Cloud Spanner Database Admin API
The Cloud Spanner Database Admin API can be used to: * create, drop, and list databases * update the schema of pre-existing databases * create, delete, copy and list backups for a database * restore a database from an existing backup
ChangeQuorum |
---|
Initiates a background operation to change the quorum of a database from dual-region mode to single-region mode or vice versa. The returned long-running operation has a name of the format Authorization requires
|
CopyBackup |
---|
Starts copying a Cloud Spanner Backup. The returned backup long-running operation will have a name of the format
|
CreateBackup |
---|
Starts creating a new Cloud Spanner Backup. The returned backup long-running operation will have a name of the format
|
CreateBackupSchedule |
---|
Creates a new backup schedule.
|
CreateDatabase |
---|
Creates a new Spanner database and starts to prepare it for serving. The returned long-running operation will have a name of the format
|
DeleteBackup |
---|
Deletes a pending or completed
|
DeleteBackupSchedule |
---|
Deletes a backup schedule.
|
DropDatabase |
---|
Drops (aka deletes) a Cloud Spanner database. Completed backups for the database will be retained according to their
|
GetBackup |
---|
Gets metadata on a pending or completed
|
GetBackupSchedule |
---|
Gets backup schedule for the input schedule name.
|
GetDatabase |
---|
Gets the state of a Cloud Spanner database.
|
GetDatabaseDdl |
---|
Returns the schema of a Cloud Spanner database as a list of formatted DDL statements. This method does not show pending schema updates, those may be queried using the
|
GetIamPolicy |
---|
Gets the access control policy for a database or backup resource. Returns an empty policy if a database or backup exists but does not have a policy set. Authorization requires
|
ListBackupOperations |
---|
Lists the backup long-running operations in the given instance. A backup operation has a name of the form
|
ListBackupSchedules |
---|
Lists all the backup schedules for the database.
|
ListBackups |
---|
Lists completed and pending backups. Backups returned are ordered by
|
ListDatabaseOperations |
---|
Lists database longrunning-operations. A database operation has a name of the form
|
ListDatabaseRoles |
---|
Lists Cloud Spanner database roles.
|
ListDatabases |
---|
Lists Cloud Spanner databases.
|
RestoreDatabase |
---|
Create a new database by restoring from a completed backup. The new database must be in the same project and in an instance with the same instance configuration as the instance containing the backup. The returned database long-running operation has a name of the format
|
SetIamPolicy |
---|
Sets the access control policy on a database or backup resource. Replaces any existing policy. Authorization requires
|
TestIamPermissions |
---|
Returns permissions that the caller has on the specified database or backup resource. Attempting this RPC on a non-existent Cloud Spanner database will result in a NOT_FOUND error if the user has
|
UpdateBackup |
---|
Updates a pending or completed
|
UpdateBackupSchedule |
---|
Updates a backup schedule.
|
UpdateDatabase |
---|
Updates a Cloud Spanner database. The returned long-running operation can be used to track the progress of updating the database. If the named database does not exist, returns While the operation is pending:
Upon completion of the returned operation:
The returned long-running operation will have a name of the format
|
UpdateDatabaseDdl |
---|
Updates the schema of a Cloud Spanner database by creating/altering/dropping tables, columns, indexes, etc. The returned long-running operation will have a name of the format
|
Backup
A backup of a Cloud Spanner database.
Fields | |
---|---|
database |
Required for the |
version_ |
The backup will contain an externally consistent copy of the database at the timestamp specified by |
expire_ |
Required for the |
name |
Output only for the A globally unique identifier for the backup which cannot be changed. Values are of the form The backup is stored in the location(s) specified in the instance configuration of the instance containing the backup, identified by the prefix of the backup name of the form |
create_ |
Output only. The time the |
size_ |
Output only. Size of the backup in bytes. For a backup in an incremental backup chain, this is the sum of the |
freeable_ |
Output only. The number of bytes that will be freed by deleting this backup. This value will be zero if, for example, this backup is part of an incremental backup chain and younger backups in the chain require that we keep its data. For backups not in an incremental backup chain, this is always the size of the backup. This value may change if backups on the same chain get created, deleted or expired. |
exclusive_ |
Output only. For a backup in an incremental backup chain, this is the storage space needed to keep the data that has changed since the previous backup. For all other backups, this is always the size of the backup. This value may change if backups on the same chain get deleted or expired. This field can be used to calculate the total storage space used by a set of backups. For example, the total space used by all backups of a database can be computed by summing up this field. |
state |
Output only. The current state of the backup. |
referencing_ |
Output only. The names of the restored databases that reference the backup. The database names are of the form |
encryption_ |
Output only. The encryption information for the backup. |
encryption_ |
Output only. The encryption information for the backup, whether it is protected by one or more KMS keys. The information includes all Cloud KMS key versions used to encrypt the backup. The |
database_ |
Output only. The database dialect information for the backup. |
referencing_ |
Output only. The names of the destination backups being created by copying this source backup. The backup names are of the form |
max_ |
Output only. The max allowed expiration time of the backup, with microseconds granularity. A backup's expiration time can be configured in multiple APIs: CreateBackup, UpdateBackup, CopyBackup. When updating or copying an existing backup, the expiration time specified must be less than |
backup_ |
Output only. List of backup schedule URIs that are associated with creating this backup. This is only applicable for scheduled backups, and is empty for on-demand backups. To optimize for storage, whenever possible, multiple schedules are collapsed together to create one backup. In such cases, this field captures the list of all backup schedule URIs that are associated with creating this backup. If collapsing is not done, then this field captures the single backup schedule URI associated with creating this backup. |
incremental_ |
Output only. Populated only for backups in an incremental backup chain. Backups share the same chain id if and only if they belong to the same incremental backup chain. Use this field to determine which backups are part of the same incremental backup chain. The ordering of backups in the chain can be determined by ordering the backup |
oldest_ |
Output only. Data deleted at a time older than this is guaranteed not to be retained in order to support this backup. For a backup in an incremental backup chain, this is the version time of the oldest backup that exists or ever existed in the chain. For all other backups, this is the version time of the backup. This field can be used to understand what data is being retained by the backup system. |
State
Indicates the current state of the backup.
Enums | |
---|---|
STATE_UNSPECIFIED |
Not specified. |
CREATING |
The pending backup is still being created. Operations on the backup may fail with FAILED_PRECONDITION in this state. |
READY |
The backup is complete and ready for use. |
BackupInfo
Information about a backup.
Fields | |
---|---|
backup |
Name of the backup. |
version_ |
The backup contains an externally consistent copy of |
create_ |
The time the |
source_ |
Name of the database the backup was created from. |
BackupSchedule
BackupSchedule expresses the automated backup creation specification for a Spanner database.
Fields | |
---|---|
name |
Identifier. Output only for the |
spec |
Optional. The schedule specification based on which the backup creations are triggered. |
retention_ |
Optional. The retention duration of a backup that must be at least 6 hours and at most 366 days. The backup is eligible to be automatically deleted once the retention period has elapsed. |
encryption_ |
Optional. The encryption configuration that will be used to encrypt the backup. If this field is not specified, the backup will use the same encryption configuration as the database. |
update_ |
Output only. The timestamp at which the schedule was last updated. If the schedule has never been updated, this field contains the timestamp when the schedule was first created. |
Union field backup_type_spec . Required. Backup type spec determines the type of backup that is created by the backup schedule. Currently, only full backups are supported. backup_type_spec can be only one of the following: |
|
full_ |
The schedule creates only full backups. |
incremental_ |
The schedule creates incremental backup chains. |
BackupScheduleSpec
Defines specifications of the backup schedule.
Fields | |
---|---|
Union field schedule_spec . Required. schedule_spec can be only one of the following: |
|
cron_ |
Cron style schedule specification. |
ChangeQuorumMetadata
Metadata type for the long-running operation returned by ChangeQuorum
.
Fields | |
---|---|
request |
The request for |
start_ |
Time the request was received. |
end_ |
If set, the time at which this operation failed or was completed successfully. |
ChangeQuorumRequest
The request for ChangeQuorum
.
Fields | |
---|---|
name |
Required. Name of the database in which to apply Authorization requires the following IAM permission on the specified resource
|
quorum_ |
Required. The type of this quorum. |
etag |
Optional. The etag is the hash of the The etag is used for optimistic concurrency control as a way to help prevent simultaneous change quorum requests that could create a race condition. |
CopyBackupEncryptionConfig
Encryption configuration for the copied backup.
Fields | |
---|---|
encryption_ |
Required. The encryption type of the backup. |
kms_ |
Optional. The Cloud KMS key that will be used to protect the backup. This field should be set only when |
kms_ |
Optional. Specifies the KMS configuration for the one or more keys used to protect the backup. Values are of the form The keys referenced by
|
EncryptionType
Encryption types for the backup.
Enums | |
---|---|
ENCRYPTION_TYPE_UNSPECIFIED |
Unspecified. Do not use. |
USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION |
This is the default option for CopyBackup when encryption_config is not specified. For example, if the source backup is using Customer_Managed_Encryption , the backup will be using the same Cloud KMS key as the source backup. |
GOOGLE_DEFAULT_ENCRYPTION |
Use Google default encryption. |
CUSTOMER_MANAGED_ENCRYPTION |
Use customer managed encryption. If specified, either kms_key_name or kms_key_names must contain valid Cloud KMS key(s). |
CopyBackupMetadata
Metadata type for the operation returned by CopyBackup
.
Fields | |
---|---|
name |
The name of the backup being created through the copy operation. Values are of the form |
source_ |
The name of the source backup that is being copied. Values are of the form |
progress |
The progress of the |
cancel_ |
The time at which cancellation of CopyBackup operation was received. |
CopyBackupRequest
The request for CopyBackup
.
Fields | |
---|---|
parent |
Required. The name of the destination instance that will contain the backup copy. Values are of the form: Authorization requires the following IAM permission on the specified resource
|
backup_ |
Required. The id of the backup copy. The |
source_ |
Required. The source backup to be copied. The source backup needs to be in READY state for it to be copied. Once CopyBackup is in progress, the source backup cannot be deleted or cleaned up on expiration until CopyBackup is finished. Values are of the form: Authorization requires the following IAM permission on the specified resource
|
expire_ |
Required. The expiration time of the backup in microsecond granularity. The expiration time must be at least 6 hours and at most 366 days from the |
encryption_ |
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 source backup by default, namely |
CreateBackupEncryptionConfig
Encryption configuration for the backup to create.
Fields | |
---|---|
encryption_ |
Required. The encryption type of the backup. |
kms_ |
Optional. The Cloud KMS key that will be used to protect the backup. This field should be set only when |
kms_ |
Optional. Specifies the KMS configuration for the one or more keys used to protect the backup. Values are of the form The keys referenced by
|
EncryptionType
Encryption types for the backup.
Enums | |
---|---|
ENCRYPTION_TYPE_UNSPECIFIED |
Unspecified. Do not use. |
USE_DATABASE_ENCRYPTION |
Use the same encryption configuration as the database. This is the default option when encryption_config is empty. For example, if the database is using Customer_Managed_Encryption , the backup will be using the same Cloud KMS key as the database. |
GOOGLE_DEFAULT_ENCRYPTION |
Use Google default encryption. |
CUSTOMER_MANAGED_ENCRYPTION |
Use customer managed encryption. If specified, kms_key_name must contain a valid Cloud KMS key. |
CreateBackupMetadata
Metadata type for the operation returned by CreateBackup
.
Fields | |
---|---|
name |
The name of the backup being created. |
database |
The name of the database the backup is created from. |
progress |
The progress of the |
cancel_ |
The time at which cancellation of this operation was received. |
CreateBackupRequest
The request for CreateBackup
.
Fields | |
---|---|
parent |
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 Authorization requires the following IAM permission on the specified resource
|
backup_ |
Required. The id of the backup to be created. The |
backup |
Required. The backup to create. |
encryption_ |
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 |
CreateBackupScheduleRequest
The request for CreateBackupSchedule
.
Fields | |
---|---|
parent |
Required. The name of the database that this backup schedule applies to. Authorization requires one or more of the following IAM permissions on the specified resource
|
backup_ |
Required. The Id to use for the backup schedule. The |
backup_ |
Required. The backup schedule to create. |
CreateDatabaseMetadata
Metadata type for the operation returned by CreateDatabase
.
Fields | |
---|---|
database |
The database being created. |
CreateDatabaseRequest
The request for CreateDatabase
.
Fields | |
---|---|
parent |
Required. The name of the instance that will serve the new database. Values are of the form Authorization requires the following IAM permission on the specified resource
|
create_ |
Required. A |
extra_ |
Optional. A list of DDL statements to run inside the newly created database. Statements can create tables, indexes, etc. These statements execute atomically with the creation of the database: if there is an error in any statement, the database is not created. |
encryption_ |
Optional. The encryption configuration for the database. If this field is not specified, Cloud Spanner will encrypt/decrypt all data at rest using Google default encryption. |
database_ |
Optional. The dialect of the Cloud Spanner Database. |
proto_ |
Optional. Proto descriptors used by
For more details, see protobuffer self description. |
CrontabSpec
CrontabSpec can be used to specify the version time and frequency at which the backup should be created.
Fields | |
---|---|
text |
Required. Textual representation of the crontab. User can customize the backup frequency and the backup version time using the cron expression. The version time must be in UTC timzeone. The backup will contain an externally consistent copy of the database at the version time. Allowed frequencies are 12 hour, 1 day, 1 week and 1 month. Examples of valid cron specifications: * |
time_ |
Output only. The time zone of the times in |
creation_ |
Output only. Schedule backups will contain an externally consistent copy of the database at the version time specified in |
Database
A Cloud Spanner database.
Fields | |
---|---|
name |
Required. The name of the database. Values are of the form |
state |
Output only. The current database state. |
create_ |
Output only. If exists, the time at which the database creation started. |
restore_ |
Output only. Applicable only for restored databases. Contains information about the restore source. |
encryption_ |
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty. |
encryption_ |
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as all Cloud KMS key versions that are in use. The For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field. |
version_ |
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using |
earliest_ |
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery. |
default_ |
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty. |
database_ |
Output only. The dialect of the Cloud Spanner Database. |
enable_ |
Optional. Whether drop protection is enabled for this database. Defaults to false, if not set. For more details, please see how to prevent accidental database deletion. |
reconciling |
Output only. If true, the database is being updated. If false, there are no ongoing update operations for the database. |
quorum_ |
Output only. Applicable only for databases that use dual-region instance configurations. Contains information about the quorum. |
State
Indicates the current state of the database.
Enums | |
---|---|
STATE_UNSPECIFIED |
Not specified. |
CREATING |
The database is still being created. Operations on the database may fail with FAILED_PRECONDITION in this state. |
READY |
The database is fully created and ready for use. |
READY_OPTIMIZING |
The database is fully created and ready for use, but is still being optimized for performance and cannot handle full load. In this state, the database still references the backup it was restore from, preventing the backup from being deleted. When optimizations are complete, the full performance of the database will be restored, and the database will transition to |
DatabaseDialect
Indicates the dialect type of a database.
Enums | |
---|---|
DATABASE_DIALECT_UNSPECIFIED |
Default value. This value will create a database with the GOOGLE_STANDARD_SQL dialect. |
GOOGLE_STANDARD_SQL |
GoogleSQL supported SQL. |
POSTGRESQL |
PostgreSQL supported SQL. |
DatabaseRole
A Cloud Spanner database role.
Fields | |
---|---|
name |
Required. The name of the database role. Values are of the form |
DdlStatementActionInfo
Action information extracted from a DDL statement. This proto is used to display the brief info of the DDL statement for the operation UpdateDatabaseDdl
.
Fields | |
---|---|
action |
The action for the DDL statement, e.g. CREATE, ALTER, DROP, GRANT, etc. This field is a non-empty string. |
entity_ |
The entity type for the DDL statement, e.g. TABLE, INDEX, VIEW, etc. This field can be empty string for some DDL statement, e.g. for statement "ANALYZE", |
entity_ |
The entity name(s) being operated on the DDL statement. E.g. 1. For statement "CREATE TABLE t1(...)", |
DeleteBackupRequest
The request for DeleteBackup
.
Fields | |
---|---|
name |
Required. Name of the backup to delete. Values are of the form Authorization requires the following IAM permission on the specified resource
|
DeleteBackupScheduleRequest
The request for DeleteBackupSchedule
.
Fields | |
---|---|
name |
Required. The name of the schedule to delete. Values are of the form Authorization requires the following IAM permission on the specified resource
|
DropDatabaseRequest
The request for DropDatabase
.
Fields | |
---|---|
database |
Required. The database to be dropped. Authorization requires the following IAM permission on the specified resource
|
EncryptionConfig
Encryption configuration for a Cloud Spanner database.
Fields | |
---|---|
kms_ |
The Cloud KMS key to be used for encrypting and decrypting the database. Values are of the form |
kms_ |
Specifies the KMS configuration for one or more keys used to encrypt the database. Values are of the form The keys referenced by
|
EncryptionInfo
Encryption information for a Cloud Spanner database or backup.
Fields | |
---|---|
encryption_ |
Output only. The type of encryption. |
encryption_ |
Output only. If present, the status of a recent encrypt/decrypt call on underlying data for this database or backup. Regardless of status, data is always encrypted at rest. |
kms_ |
Output only. A Cloud KMS key version that is being used to protect the database or backup. |
Type
Possible encryption types.
Enums | |
---|---|
TYPE_UNSPECIFIED |
Encryption type was not specified, though data at rest remains encrypted. |
GOOGLE_DEFAULT_ENCRYPTION |
The data is encrypted at rest with a key that is fully managed by Google. No key version or status will be populated. This is the default state. |
CUSTOMER_MANAGED_ENCRYPTION |
The data is encrypted at rest with a key that is managed by the customer. The active version of the key. kms_key_version will be populated, and encryption_status may be populated. |
FullBackupSpec
This type has no fields.
The specification for full backups. A full backup stores the entire contents of the database at a given version time.
GetBackupRequest
The request for GetBackup
.
Fields | |
---|---|
name |
Required. Name of the backup. Values are of the form Authorization requires the following IAM permission on the specified resource
|
GetBackupScheduleRequest
The request for GetBackupSchedule
.
Fields | |
---|---|
name |
Required. The name of the schedule to retrieve. Values are of the form Authorization requires the following IAM permission on the specified resource
|
GetDatabaseDdlRequest
The request for GetDatabaseDdl
.
Fields | |
---|---|
database |
Required. The database whose schema we wish to get. Values are of the form Authorization requires the following IAM permission on the specified resource
|
GetDatabaseDdlResponse
The response for GetDatabaseDdl
.
Fields | |
---|---|
statements[] |
A list of formatted DDL statements defining the schema of the database specified in the request. |
proto_ |
Proto descriptors stored in the database. Contains a protobuf-serialized google.protobuf.FileDescriptorSet. For more details, see protobuffer self description. |
GetDatabaseRequest
The request for GetDatabase
.
Fields | |
---|---|
name |
Required. The name of the requested database. Values are of the form Authorization requires the following IAM permission on the specified resource
|
IncrementalBackupSpec
This type has no fields.
The specification for incremental backup chains. An incremental backup stores the delta of changes between a previous backup and the database contents at a given version time. An incremental backup chain consists of a full backup and zero or more successive incremental backups. The first backup created for an incremental backup chain is always a full backup.
ListBackupOperationsRequest
The request for ListBackupOperations
.
Fields | |
---|---|
parent |
Required. The instance of the backup operations. Values are of the form Authorization requires the following IAM permission on the specified resource
|
filter |
An expression that filters the list of returned backup operations. A filter expression consists of a field name, a comparison operator, and a value for filtering. The value must be a string, a number, or a boolean. The comparison operator must be one of: The following fields in the operation are eligible for filtering:
You can combine multiple expressions by enclosing each expression in parentheses. By default, expressions are combined with AND logic, but you can specify AND, OR, and NOT logic explicitly. Here are a few examples:
|
page_ |
Number of operations to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
If non-empty, |
ListBackupOperationsResponse
The response for ListBackupOperations
.
Fields | |
---|---|
operations[] |
The list of matching backup long-running operations. Each operation's name will be prefixed by the backup's name. The operation's metadata field type |
next_ |
|
ListBackupSchedulesRequest
The request for ListBackupSchedules
.
Fields | |
---|---|
parent |
Required. Database is the parent resource whose backup schedules should be listed. Values are of the form projects/ Authorization requires the following IAM permission on the specified resource
|
page_ |
Optional. Number of backup schedules to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
Optional. If non-empty, |
ListBackupSchedulesResponse
The response for ListBackupSchedules
.
Fields | |
---|---|
backup_ |
The list of backup schedules for a database. |
next_ |
|
ListBackupsRequest
The request for ListBackups
.
Fields | |
---|---|
parent |
Required. The instance to list backups from. Values are of the form Authorization requires the following IAM permission on the specified resource
|
filter |
An expression that filters the list of returned backups. A filter expression consists of a field name, a comparison operator, and a value for filtering. The value must be a string, a number, or a boolean. The comparison operator must be one of: The following fields in the
You can combine multiple expressions by enclosing each expression in parentheses. By default, expressions are combined with AND logic, but you can specify AND, OR, and NOT logic explicitly. Here are a few examples:
|
page_ |
Number of backups to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
If non-empty, |
ListBackupsResponse
The response for ListBackups
.
Fields | |
---|---|
backups[] |
The list of matching backups. Backups returned are ordered by |
next_ |
|
ListDatabaseOperationsRequest
The request for ListDatabaseOperations
.
Fields | |
---|---|
parent |
Required. The instance of the database operations. Values are of the form Authorization requires the following IAM permission on the specified resource
|
filter |
An expression that filters the list of returned operations. A filter expression consists of a field name, a comparison operator, and a value for filtering. The value must be a string, a number, or a boolean. The comparison operator must be one of: The following fields in the operation are eligible for filtering:
You can combine multiple expressions by enclosing each expression in parentheses. By default, expressions are combined with AND logic. However, you can specify AND, OR, and NOT logic explicitly. Here are a few examples:
|
page_ |
Number of operations to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
If non-empty, |
ListDatabaseOperationsResponse
The response for ListDatabaseOperations
.
Fields | |
---|---|
operations[] |
The list of matching database long-running operations. Each operation's name will be prefixed by the database's name. The operation's metadata field type |
next_ |
|
ListDatabaseRolesRequest
The request for ListDatabaseRoles
.
Fields | |
---|---|
parent |
Required. The database whose roles should be listed. Values are of the form Authorization requires the following IAM permission on the specified resource
|
page_ |
Number of database roles to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
If non-empty, |
ListDatabaseRolesResponse
The response for ListDatabaseRoles
.
Fields | |
---|---|
database_ |
Database roles that matched the request. |
next_ |
|
ListDatabasesRequest
The request for ListDatabases
.
Fields | |
---|---|
parent |
Required. The instance whose databases should be listed. Values are of the form Authorization requires the following IAM permission on the specified resource
|
page_ |
Number of databases to be returned in the response. If 0 or less, defaults to the server's maximum allowed page size. |
page_ |
If non-empty, |
ListDatabasesResponse
The response for ListDatabases
.
Fields | |
---|---|
databases[] |
Databases that matched the request. |
next_ |
|
OperationProgress
Encapsulates progress related information for a Cloud Spanner long running operation.
Fields | |
---|---|
progress_ |
Percent completion of the operation. Values are between 0 and 100 inclusive. |
start_ |
Time the request was received. |
end_ |
If set, the time at which this operation failed or was completed successfully. |
OptimizeRestoredDatabaseMetadata
Metadata type for the long-running operation used to track the progress of optimizations performed on a newly restored database. This long-running operation is automatically created by the system after the successful completion of a database restore, and cannot be cancelled.
Fields | |
---|---|
name |
Name of the restored database being optimized. |
progress |
The progress of the post-restore optimizations. |
QuorumInfo
Information about the dual-region quorum.
Fields | |
---|---|
quorum_ |
Output only. The type of this quorum. See |
initiator |
Output only. Whether this |
start_ |
Output only. The timestamp when the request was triggered. |
etag |
Output only. The etag is used for optimistic concurrency control as a way to help prevent simultaneous |
Initiator
Describes who initiated ChangeQuorum
.
Enums | |
---|---|
INITIATOR_UNSPECIFIED |
Unspecified. |
GOOGLE |
ChangeQuorum initiated by Google. |
USER |
ChangeQuorum initiated by User. |
QuorumType
Information about the database quorum type. This only applies to dual-region instance configs.
Fields | |
---|---|
Union field type . The type of quorum. type can be only one of the following: |
|
single_ |
Single-region quorum type. |
dual_ |
Dual-region quorum type. |
DualRegionQuorum
This type has no fields.
Message type for a dual-region quorum. Currently this type has no options.
SingleRegionQuorum
Message type for a single-region quorum.
Fields | |
---|---|
serving_ |
Required. The location of the serving region, e.g. "us-central1". The location must be one of the regions within the dual-region instance configuration of your database. The list of valid locations is available using the [GetInstanceConfig][InstanceAdmin.GetInstanceConfig] API. This should only be used if you plan to change quorum to the single-region quorum type. |
RestoreDatabaseEncryptionConfig
Encryption configuration for the restored database.
Fields | |
---|---|
encryption_ |
Required. The encryption type of the restored database. |
kms_ |
Optional. The Cloud KMS key that will be used to encrypt/decrypt the restored database. This field should be set only when |
kms_ |
Optional. Specifies the KMS configuration for one or more keys used to encrypt the database. Values have the form The keys referenced by
|
EncryptionType
Encryption types for the database to be restored.
Enums | |
---|---|
ENCRYPTION_TYPE_UNSPECIFIED |
Unspecified. Do not use. |
USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION |
This is the default option when encryption_config is not specified. |
GOOGLE_DEFAULT_ENCRYPTION |
Use Google default encryption. |
CUSTOMER_MANAGED_ENCRYPTION |
Use customer managed encryption. If specified, kms_key_name must must contain a valid Cloud KMS key. |
RestoreDatabaseMetadata
Metadata type for the long-running operation returned by RestoreDatabase
.
Fields | |
---|---|
name |
Name of the database being created and restored to. |
source_ |
The type of the restore source. |
progress |
The progress of the |
cancel_ |
The time at which cancellation of this operation was received. |
optimize_ |
If exists, the name of the long-running operation that will be used to track the post-restore optimization process to optimize the performance of the restored database, and remove the dependency on the restore source. The name is of the form |
Union field source_info . Information about the source used to restore the database, as specified by source in RestoreDatabaseRequest . source_info can be only one of the following: |
|
backup_ |
Information about the backup used to restore the database. |
RestoreDatabaseRequest
The request for RestoreDatabase
.
Fields | |
---|---|
parent |
Required. The name of the instance in which to create the restored database. This instance must be in the same project and have the same instance configuration as the instance containing the source backup. Values are of the form Authorization requires the following IAM permission on the specified resource
|
database_ |
Required. The id of the database to create and restore to. This database must not already exist. The |
encryption_ |
Optional. An encryption configuration describing the encryption type and key resources in Cloud KMS used to encrypt/decrypt the database to restore to. If this field is not specified, the restored database will use the same encryption configuration as the backup by default, namely |
Union field source . Required. The source from which to restore. source can be only one of the following: |
|
backup |
Name of the backup from which to restore. Values are of the form Authorization requires the following IAM permission on the specified resource
|
RestoreInfo
Information about the database restore.
Fields | |
---|---|
source_ |
The type of the restore source. |
Union field source_info . Information about the source used to restore the database. source_info can be only one of the following: |
|
backup_ |
Information about the backup used to restore the database. The backup may no longer exist. |
RestoreSourceType
Indicates the type of the restore source.
Enums | |
---|---|
TYPE_UNSPECIFIED |
No restore associated. |
BACKUP |
A backup was used as the source of the restore. |
UpdateBackupRequest
The request for UpdateBackup
.
Fields | |
---|---|
backup |
Required. The backup to update. Authorization requires the following IAM permission on the specified resource
|
update_ |
Required. A mask specifying which fields (e.g. |
UpdateBackupScheduleRequest
The request for UpdateBackupScheduleRequest
.
Fields | |
---|---|
backup_ |
Required. The backup schedule to update. Authorization requires the following IAM permission on the specified resource
|
update_ |
Required. A mask specifying which fields in the BackupSchedule resource should be updated. This mask is relative to the BackupSchedule resource, not to the request message. The field mask must always be specified; this prevents any future fields from being erased accidentally. |
UpdateDatabaseDdlMetadata
Metadata type for the operation returned by UpdateDatabaseDdl
.
Fields | |
---|---|
database |
The database being modified. |
statements[] |
For an update this list contains all the statements. For an individual statement, this list contains only that statement. |
commit_ |
Reports the commit timestamps of all statements that have succeeded so far, where |
throttled |
Output only. When true, indicates that the operation is throttled e.g. due to resource constraints. When resources become available the operation will resume and this field will be false again. |
progress[] |
The progress of the |
actions[] |
The brief action info for the DDL statements. |
UpdateDatabaseDdlRequest
Enqueues the given DDL statements to be applied, in order but not necessarily all at once, to the database schema at some point (or points) in the future. The server checks that the statements are executable (syntactically valid, name tables that exist, etc.) before enqueueing them, but they may still fail upon later execution (e.g., if a statement from another batch of statements is applied first and it conflicts in some way, or if there is some data-related problem like a NULL
value in a column to which NOT NULL
would be added). If a statement fails, all subsequent statements in the batch are automatically cancelled.
Each batch of statements is assigned a name which can be used with the Operations
API to monitor progress. See the operation_id
field for more details.
Fields | |
---|---|
database |
Required. The database to update. Authorization requires the following IAM permission on the specified resource
|
statements[] |
Required. DDL statements to be applied to the database. |
operation_ |
If empty, the new update request is assigned an automatically-generated operation ID. Otherwise, Specifying an explicit operation ID simplifies determining whether the statements were executed in the event that the
|
proto_ |
Optional. Proto descriptors used by CREATE/ALTER PROTO BUNDLE statements. Contains a protobuf-serialized google.protobuf.FileDescriptorSet. To generate it, install and run
For more details, see protobuffer self description. |
UpdateDatabaseMetadata
Metadata type for the operation returned by UpdateDatabase
.
Fields | |
---|---|
request |
The request for |
progress |
The progress of the |
cancel_ |
The time at which this operation was cancelled. If set, this operation is in the process of undoing itself (which is best-effort). |
UpdateDatabaseRequest
The request for UpdateDatabase
.
Fields | |
---|---|
database |
Required. The database to update. The Authorization requires the following IAM permission on the specified resource
|
update_ |
Required. The list of fields to update. Currently, only |