pub struct Backup {Show 22 fields
pub name: String,
pub kind: String,
pub self_link: String,
pub type: i32,
pub description: String,
pub instance: String,
pub location: String,
pub backup_interval: Option<Interval>,
pub state: i32,
pub error: Option<OperationError>,
pub kms_key: String,
pub kms_key_version: String,
pub backup_kind: i32,
pub time_zone: String,
pub database_version: i32,
pub max_chargeable_bytes: Option<i64>,
pub instance_deletion_time: Option<Timestamp>,
pub instance_settings: Option<DatabaseInstance>,
pub backup_run: String,
pub satisfies_pzs: Option<bool>,
pub satisfies_pzi: Option<bool>,
pub expiration: Option<Expiration>,
}Expand description
A backup resource.
Fields§
§name: StringOutput only. The resource name of the backup. Format: projects/{project}/backups/{backup}.
kind: StringOutput only. This is always sql#backup.
self_link: StringOutput only. The URI of this resource.
type: i32Output only. The type of this backup. The type can be “AUTOMATED”, “ON_DEMAND” or “FINAL”.
description: StringThe description of this backup.
instance: StringThe name of the source database instance.
location: StringThe storage location of the backups. The location can be multi-regional.
backup_interval: Option<Interval>Output only. This output contains the following values: start_time: All database writes up to this time are available. end_time: Any database writes after this time aren’t available.
state: i32Output only. The status of this backup.
error: Option<OperationError>Output only. Information about why the backup operation fails (for example, when the backup state fails).
kms_key: StringOutput only. This output contains the encryption configuration for a backup and the resource name of the KMS key for disk encryption.
kms_key_version: StringOutput only. This output contains the encryption status for a backup and the version of the KMS key that’s used to encrypt the Cloud SQL instance.
backup_kind: i32Output only. Specifies the kind of backup, PHYSICAL or DEFAULT_SNAPSHOT.
time_zone: StringOutput only. This output contains a backup time zone. If a Cloud SQL for SQL Server instance has a different time zone from the backup’s time zone, then the restore to the instance doesn’t happen.
database_version: i32Output only. The database version of the instance of at the time this backup was made.
max_chargeable_bytes: Option<i64>Output only. The maximum chargeable bytes for the backup.
instance_deletion_time: Option<Timestamp>Optional. Output only. Timestamp in UTC of when the instance associated with this backup is deleted.
instance_settings: Option<DatabaseInstance>Optional. Output only. The instance setting of the source instance that’s associated with this backup.
backup_run: StringOutput only. The mapping to backup run resource used for IAM validations.
satisfies_pzs: Option<bool>Output only. This status indicates whether the backup satisfies PZS.
The status is reserved for future use.
satisfies_pzi: Option<bool>Output only. This status indicates whether the backup satisfies PZI.
The status is reserved for future use.
expiration: Option<Expiration>Implementations§
Source§impl Backup
impl Backup
Sourcepub fn type(&self) -> SqlBackupType
pub fn type(&self) -> SqlBackupType
Returns the enum value of type, or the default if the field is set to an invalid enum value.
Sourcepub fn set_type(&mut self, value: SqlBackupType)
pub fn set_type(&mut self, value: SqlBackupType)
Sets type to the provided enum value.
Sourcepub fn state(&self) -> SqlBackupState
pub fn state(&self) -> SqlBackupState
Returns the enum value of state, or the default if the field is set to an invalid enum value.
Sourcepub fn set_state(&mut self, value: SqlBackupState)
pub fn set_state(&mut self, value: SqlBackupState)
Sets state to the provided enum value.
Sourcepub fn backup_kind(&self) -> SqlBackupKind
pub fn backup_kind(&self) -> SqlBackupKind
Returns the enum value of backup_kind, or the default if the field is set to an invalid enum value.
Sourcepub fn set_backup_kind(&mut self, value: SqlBackupKind)
pub fn set_backup_kind(&mut self, value: SqlBackupKind)
Sets backup_kind to the provided enum value.
Sourcepub fn database_version(&self) -> SqlDatabaseVersion
pub fn database_version(&self) -> SqlDatabaseVersion
Returns the enum value of database_version, or the default if the field is set to an invalid enum value.
Sourcepub fn set_database_version(&mut self, value: SqlDatabaseVersion)
pub fn set_database_version(&mut self, value: SqlDatabaseVersion)
Sets database_version to the provided enum value.
Sourcepub fn max_chargeable_bytes(&self) -> i64
pub fn max_chargeable_bytes(&self) -> i64
Returns the value of max_chargeable_bytes, or the default value if max_chargeable_bytes is unset.
Trait Implementations§
Source§impl Message for Backup
impl Message for Backup
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.impl StructuralPartialEq for Backup
Auto Trait Implementations§
impl Freeze for Backup
impl RefUnwindSafe for Backup
impl Send for Backup
impl Sync for Backup
impl Unpin for Backup
impl UnwindSafe for Backup
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request