#[non_exhaustive]pub struct ReplicaConfiguration {
pub kind: String,
pub mysql_replica_configuration: Option<MySqlReplicaConfiguration>,
pub failover_target: Option<BoolValue>,
pub cascadable_replica: Option<BoolValue>,
/* private fields */
}
Expand description
Read-replica configuration for connecting to the primary instance.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.kind: String
This is always sql#replicaConfiguration
.
mysql_replica_configuration: Option<MySqlReplicaConfiguration>
MySQL specific configuration when replicating from a MySQL on-premises
primary instance. Replication configuration information such as the
username, password, certificates, and keys are not stored in the instance
metadata. The configuration information is used only to set up the
replication connection and is stored by MySQL in a file named
master.info
in the data directory.
failover_target: Option<BoolValue>
Specifies if the replica is the failover target. If the field is set to
true
, the replica will be designated as a failover replica. In case the
primary instance fails, the replica instance will be promoted as the new
primary instance. Only one replica can be specified as failover target, and
the replica has to be in different zone with the primary instance.
cascadable_replica: Option<BoolValue>
Optional. Specifies if a SQL Server replica is a cascadable replica. A cascadable replica is a SQL Server cross region replica that supports replica(s) under it.
Implementations§
Source§impl ReplicaConfiguration
impl ReplicaConfiguration
pub fn new() -> Self
Sourcepub fn set_mysql_replica_configuration<T>(self, v: T) -> Selfwhere
T: Into<MySqlReplicaConfiguration>,
pub fn set_mysql_replica_configuration<T>(self, v: T) -> Selfwhere
T: Into<MySqlReplicaConfiguration>,
Sets the value of mysql_replica_configuration.
Sourcepub fn set_or_clear_mysql_replica_configuration<T>(self, v: Option<T>) -> Selfwhere
T: Into<MySqlReplicaConfiguration>,
pub fn set_or_clear_mysql_replica_configuration<T>(self, v: Option<T>) -> Selfwhere
T: Into<MySqlReplicaConfiguration>,
Sets or clears the value of mysql_replica_configuration.
Sourcepub fn set_failover_target<T>(self, v: T) -> Self
pub fn set_failover_target<T>(self, v: T) -> Self
Sets the value of failover_target.
Sourcepub fn set_or_clear_failover_target<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_failover_target<T>(self, v: Option<T>) -> Self
Sets or clears the value of failover_target.
Sourcepub fn set_cascadable_replica<T>(self, v: T) -> Self
pub fn set_cascadable_replica<T>(self, v: T) -> Self
Sets the value of cascadable_replica.
Sourcepub fn set_or_clear_cascadable_replica<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_cascadable_replica<T>(self, v: Option<T>) -> Self
Sets or clears the value of cascadable_replica.
Trait Implementations§
Source§impl Clone for ReplicaConfiguration
impl Clone for ReplicaConfiguration
Source§fn clone(&self) -> ReplicaConfiguration
fn clone(&self) -> ReplicaConfiguration
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more