#[non_exhaustive]pub struct Stream {Show 14 fields
pub name: String,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub labels: HashMap<String, String>,
pub display_name: String,
pub source_config: Option<SourceConfig>,
pub destination_config: Option<DestinationConfig>,
pub state: State,
pub errors: Vec<Error>,
pub customer_managed_encryption_key: Option<String>,
pub last_recovery_time: Option<Timestamp>,
pub satisfies_pzs: Option<bool>,
pub satisfies_pzi: Option<bool>,
pub backfill_strategy: Option<BackfillStrategy>,
/* private fields */
}Expand description
A resource representing streaming data from a source to a destination.
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.name: StringOutput only. Identifier. The stream’s name.
create_time: Option<Timestamp>Output only. The creation time of the stream.
update_time: Option<Timestamp>Output only. The last update time of the stream.
labels: HashMap<String, String>Labels.
display_name: StringRequired. Display name.
source_config: Option<SourceConfig>Required. Source connection profile configuration.
destination_config: Option<DestinationConfig>Required. Destination connection profile configuration.
state: StateThe state of the stream.
errors: Vec<Error>Output only. Errors on the Stream.
customer_managed_encryption_key: Option<String>Immutable. A reference to a KMS encryption key. If provided, it will be used to encrypt the data. If left blank, data will be encrypted using an internal Stream-specific encryption key provisioned through KMS.
last_recovery_time: Option<Timestamp>Output only. If the stream was recovered, the time of the last recovery. Note: This field is currently experimental.
satisfies_pzs: Option<bool>Output only. Reserved for future use.
satisfies_pzi: Option<bool>Output only. Reserved for future use.
backfill_strategy: Option<BackfillStrategy>Stream backfill strategy.
Implementations§
Source§impl Stream
impl Stream
Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_create_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_or_clear_create_time(Some(Timestamp::default()/* use setters */));
let x = Stream::new().set_or_clear_create_time(None::<Timestamp>);Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_update_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_or_clear_update_time(Some(Timestamp::default()/* use setters */));
let x = Stream::new().set_or_clear_update_time(None::<Timestamp>);Sourcepub fn set_labels<T, K, V>(self, v: T) -> Self
pub fn set_labels<T, K, V>(self, v: T) -> Self
Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_source_config<T>(self, v: T) -> Selfwhere
T: Into<SourceConfig>,
pub fn set_source_config<T>(self, v: T) -> Selfwhere
T: Into<SourceConfig>,
Sets the value of source_config.
§Example
use google_cloud_datastream_v1::model::SourceConfig;
let x = Stream::new().set_source_config(SourceConfig::default()/* use setters */);Sourcepub fn set_or_clear_source_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<SourceConfig>,
pub fn set_or_clear_source_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<SourceConfig>,
Sets or clears the value of source_config.
§Example
use google_cloud_datastream_v1::model::SourceConfig;
let x = Stream::new().set_or_clear_source_config(Some(SourceConfig::default()/* use setters */));
let x = Stream::new().set_or_clear_source_config(None::<SourceConfig>);Sourcepub fn set_destination_config<T>(self, v: T) -> Selfwhere
T: Into<DestinationConfig>,
pub fn set_destination_config<T>(self, v: T) -> Selfwhere
T: Into<DestinationConfig>,
Sets the value of destination_config.
§Example
use google_cloud_datastream_v1::model::DestinationConfig;
let x = Stream::new().set_destination_config(DestinationConfig::default()/* use setters */);Sourcepub fn set_or_clear_destination_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestinationConfig>,
pub fn set_or_clear_destination_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestinationConfig>,
Sets or clears the value of destination_config.
§Example
use google_cloud_datastream_v1::model::DestinationConfig;
let x = Stream::new().set_or_clear_destination_config(Some(DestinationConfig::default()/* use setters */));
let x = Stream::new().set_or_clear_destination_config(None::<DestinationConfig>);Sourcepub fn set_errors<T, V>(self, v: T) -> Self
pub fn set_errors<T, V>(self, v: T) -> Self
Sourcepub fn set_customer_managed_encryption_key<T>(self, v: T) -> Self
pub fn set_customer_managed_encryption_key<T>(self, v: T) -> Self
Sets the value of customer_managed_encryption_key.
§Example
let x = Stream::new().set_customer_managed_encryption_key("example");Sourcepub fn set_or_clear_customer_managed_encryption_key<T>(
self,
v: Option<T>,
) -> Self
pub fn set_or_clear_customer_managed_encryption_key<T>( self, v: Option<T>, ) -> Self
Sets or clears the value of customer_managed_encryption_key.
§Example
let x = Stream::new().set_or_clear_customer_managed_encryption_key(Some("example"));
let x = Stream::new().set_or_clear_customer_managed_encryption_key(None::<String>);Sourcepub fn set_last_recovery_time<T>(self, v: T) -> Self
pub fn set_last_recovery_time<T>(self, v: T) -> Self
Sets the value of last_recovery_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_last_recovery_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_last_recovery_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_last_recovery_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of last_recovery_time.
§Example
use wkt::Timestamp;
let x = Stream::new().set_or_clear_last_recovery_time(Some(Timestamp::default()/* use setters */));
let x = Stream::new().set_or_clear_last_recovery_time(None::<Timestamp>);Sourcepub fn set_satisfies_pzs<T>(self, v: T) -> Self
pub fn set_satisfies_pzs<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_satisfies_pzs<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_satisfies_pzs<T>(self, v: Option<T>) -> Self
Sets or clears the value of satisfies_pzs.
§Example
let x = Stream::new().set_or_clear_satisfies_pzs(Some(false));
let x = Stream::new().set_or_clear_satisfies_pzs(None::<bool>);Sourcepub fn set_satisfies_pzi<T>(self, v: T) -> Self
pub fn set_satisfies_pzi<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_satisfies_pzi<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_satisfies_pzi<T>(self, v: Option<T>) -> Self
Sets or clears the value of satisfies_pzi.
§Example
let x = Stream::new().set_or_clear_satisfies_pzi(Some(false));
let x = Stream::new().set_or_clear_satisfies_pzi(None::<bool>);Sourcepub fn set_backfill_strategy<T: Into<Option<BackfillStrategy>>>(
self,
v: T,
) -> Self
pub fn set_backfill_strategy<T: Into<Option<BackfillStrategy>>>( self, v: T, ) -> Self
Sets the value of backfill_strategy.
Note that all the setters affecting backfill_strategy are mutually
exclusive.
§Example
use google_cloud_datastream_v1::model::stream::BackfillAllStrategy;
let x = Stream::new().set_backfill_strategy(Some(
google_cloud_datastream_v1::model::stream::BackfillStrategy::BackfillAll(BackfillAllStrategy::default().into())));Sourcepub fn backfill_all(&self) -> Option<&Box<BackfillAllStrategy>>
pub fn backfill_all(&self) -> Option<&Box<BackfillAllStrategy>>
The value of backfill_strategy
if it holds a BackfillAll, None if the field is not set or
holds a different branch.
Sourcepub fn set_backfill_all<T: Into<Box<BackfillAllStrategy>>>(self, v: T) -> Self
pub fn set_backfill_all<T: Into<Box<BackfillAllStrategy>>>(self, v: T) -> Self
Sets the value of backfill_strategy
to hold a BackfillAll.
Note that all the setters affecting backfill_strategy are
mutually exclusive.
§Example
use google_cloud_datastream_v1::model::stream::BackfillAllStrategy;
let x = Stream::new().set_backfill_all(BackfillAllStrategy::default()/* use setters */);
assert!(x.backfill_all().is_some());
assert!(x.backfill_none().is_none());Sourcepub fn backfill_none(&self) -> Option<&Box<BackfillNoneStrategy>>
pub fn backfill_none(&self) -> Option<&Box<BackfillNoneStrategy>>
The value of backfill_strategy
if it holds a BackfillNone, None if the field is not set or
holds a different branch.
Sourcepub fn set_backfill_none<T: Into<Box<BackfillNoneStrategy>>>(self, v: T) -> Self
pub fn set_backfill_none<T: Into<Box<BackfillNoneStrategy>>>(self, v: T) -> Self
Sets the value of backfill_strategy
to hold a BackfillNone.
Note that all the setters affecting backfill_strategy are
mutually exclusive.
§Example
use google_cloud_datastream_v1::model::stream::BackfillNoneStrategy;
let x = Stream::new().set_backfill_none(BackfillNoneStrategy::default()/* use setters */);
assert!(x.backfill_none().is_some());
assert!(x.backfill_all().is_none());Trait Implementations§
impl StructuralPartialEq for Stream
Auto Trait Implementations§
impl Freeze for Stream
impl RefUnwindSafe for Stream
impl Send for Stream
impl Sync for Stream
impl Unpin for Stream
impl UnsafeUnpin for Stream
impl UnwindSafe for Stream
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