#[non_exhaustive]pub struct MysqlSourceConfig {
pub include_objects: Option<MysqlRdbms>,
pub exclude_objects: Option<MysqlRdbms>,
pub max_concurrent_cdc_tasks: i32,
pub max_concurrent_backfill_tasks: i32,
pub cdc_method: Option<CdcMethod>,
/* private fields */
}Expand description
MySQL source configuration
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.include_objects: Option<MysqlRdbms>MySQL objects to retrieve from the source.
exclude_objects: Option<MysqlRdbms>MySQL objects to exclude from the stream.
max_concurrent_cdc_tasks: i32Maximum number of concurrent CDC tasks. The number should be non negative. If not set (or set to 0), the system’s default value will be used.
max_concurrent_backfill_tasks: i32Maximum number of concurrent backfill tasks. The number should be non negative. If not set (or set to 0), the system’s default value will be used.
cdc_method: Option<CdcMethod>The CDC method to use for the stream.
Implementations§
Source§impl MysqlSourceConfig
impl MysqlSourceConfig
Sourcepub fn set_include_objects<T>(self, v: T) -> Selfwhere
T: Into<MysqlRdbms>,
pub fn set_include_objects<T>(self, v: T) -> Selfwhere
T: Into<MysqlRdbms>,
Sets the value of include_objects.
§Example
use google_cloud_datastream_v1::model::MysqlRdbms;
let x = MysqlSourceConfig::new().set_include_objects(MysqlRdbms::default()/* use setters */);Sourcepub fn set_or_clear_include_objects<T>(self, v: Option<T>) -> Selfwhere
T: Into<MysqlRdbms>,
pub fn set_or_clear_include_objects<T>(self, v: Option<T>) -> Selfwhere
T: Into<MysqlRdbms>,
Sets or clears the value of include_objects.
§Example
use google_cloud_datastream_v1::model::MysqlRdbms;
let x = MysqlSourceConfig::new().set_or_clear_include_objects(Some(MysqlRdbms::default()/* use setters */));
let x = MysqlSourceConfig::new().set_or_clear_include_objects(None::<MysqlRdbms>);Sourcepub fn set_exclude_objects<T>(self, v: T) -> Selfwhere
T: Into<MysqlRdbms>,
pub fn set_exclude_objects<T>(self, v: T) -> Selfwhere
T: Into<MysqlRdbms>,
Sets the value of exclude_objects.
§Example
use google_cloud_datastream_v1::model::MysqlRdbms;
let x = MysqlSourceConfig::new().set_exclude_objects(MysqlRdbms::default()/* use setters */);Sourcepub fn set_or_clear_exclude_objects<T>(self, v: Option<T>) -> Selfwhere
T: Into<MysqlRdbms>,
pub fn set_or_clear_exclude_objects<T>(self, v: Option<T>) -> Selfwhere
T: Into<MysqlRdbms>,
Sets or clears the value of exclude_objects.
§Example
use google_cloud_datastream_v1::model::MysqlRdbms;
let x = MysqlSourceConfig::new().set_or_clear_exclude_objects(Some(MysqlRdbms::default()/* use setters */));
let x = MysqlSourceConfig::new().set_or_clear_exclude_objects(None::<MysqlRdbms>);Sourcepub fn set_max_concurrent_cdc_tasks<T: Into<i32>>(self, v: T) -> Self
pub fn set_max_concurrent_cdc_tasks<T: Into<i32>>(self, v: T) -> Self
Sets the value of max_concurrent_cdc_tasks.
§Example
let x = MysqlSourceConfig::new().set_max_concurrent_cdc_tasks(42);Sourcepub fn set_max_concurrent_backfill_tasks<T: Into<i32>>(self, v: T) -> Self
pub fn set_max_concurrent_backfill_tasks<T: Into<i32>>(self, v: T) -> Self
Sets the value of max_concurrent_backfill_tasks.
§Example
let x = MysqlSourceConfig::new().set_max_concurrent_backfill_tasks(42);Sourcepub fn set_cdc_method<T: Into<Option<CdcMethod>>>(self, v: T) -> Self
pub fn set_cdc_method<T: Into<Option<CdcMethod>>>(self, v: T) -> Self
Sets the value of cdc_method.
Note that all the setters affecting cdc_method are mutually
exclusive.
§Example
use google_cloud_datastream_v1::model::mysql_source_config::BinaryLogPosition;
let x = MysqlSourceConfig::new().set_cdc_method(Some(
google_cloud_datastream_v1::model::mysql_source_config::CdcMethod::BinaryLogPosition(BinaryLogPosition::default().into())));Sourcepub fn binary_log_position(&self) -> Option<&Box<BinaryLogPosition>>
pub fn binary_log_position(&self) -> Option<&Box<BinaryLogPosition>>
The value of cdc_method
if it holds a BinaryLogPosition, None if the field is not set or
holds a different branch.
Sourcepub fn set_binary_log_position<T: Into<Box<BinaryLogPosition>>>(
self,
v: T,
) -> Self
pub fn set_binary_log_position<T: Into<Box<BinaryLogPosition>>>( self, v: T, ) -> Self
Sets the value of cdc_method
to hold a BinaryLogPosition.
Note that all the setters affecting cdc_method are
mutually exclusive.
§Example
use google_cloud_datastream_v1::model::mysql_source_config::BinaryLogPosition;
let x = MysqlSourceConfig::new().set_binary_log_position(BinaryLogPosition::default()/* use setters */);
assert!(x.binary_log_position().is_some());
assert!(x.gtid().is_none());Sourcepub fn gtid(&self) -> Option<&Box<Gtid>>
pub fn gtid(&self) -> Option<&Box<Gtid>>
The value of cdc_method
if it holds a Gtid, None if the field is not set or
holds a different branch.
Sourcepub fn set_gtid<T: Into<Box<Gtid>>>(self, v: T) -> Self
pub fn set_gtid<T: Into<Box<Gtid>>>(self, v: T) -> Self
Sets the value of cdc_method
to hold a Gtid.
Note that all the setters affecting cdc_method are
mutually exclusive.
§Example
use google_cloud_datastream_v1::model::mysql_source_config::Gtid;
let x = MysqlSourceConfig::new().set_gtid(Gtid::default()/* use setters */);
assert!(x.gtid().is_some());
assert!(x.binary_log_position().is_none());Trait Implementations§
Source§impl Clone for MysqlSourceConfig
impl Clone for MysqlSourceConfig
Source§fn clone(&self) -> MysqlSourceConfig
fn clone(&self) -> MysqlSourceConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MysqlSourceConfig
impl Debug for MysqlSourceConfig
Source§impl Default for MysqlSourceConfig
impl Default for MysqlSourceConfig
Source§fn default() -> MysqlSourceConfig
fn default() -> MysqlSourceConfig
Source§impl Message for MysqlSourceConfig
impl Message for MysqlSourceConfig
Source§impl PartialEq for MysqlSourceConfig
impl PartialEq for MysqlSourceConfig
impl StructuralPartialEq for MysqlSourceConfig
Auto Trait Implementations§
impl Freeze for MysqlSourceConfig
impl RefUnwindSafe for MysqlSourceConfig
impl Send for MysqlSourceConfig
impl Sync for MysqlSourceConfig
impl Unpin for MysqlSourceConfig
impl UnsafeUnpin for MysqlSourceConfig
impl UnwindSafe for MysqlSourceConfig
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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