#[non_exhaustive]pub struct ModelMonitoringAlertConfig {
pub enable_logging: bool,
pub notification_channels: Vec<String>,
pub alert: Option<Alert>,
/* private fields */
}job-service only.Expand description
The alert config for model monitoring.
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.enable_logging: boolDump the anomalies to Cloud Logging. The anomalies will be put to json payload encoded from proto ModelMonitoringStatsAnomalies. This can be further synced to Pub/Sub or any other services supported by Cloud Logging.
notification_channels: Vec<String>Resource names of the NotificationChannels to send alert.
Must be of the format
projects/<project_id_or_number>/notificationChannels/<channel_id>
alert: Option<Alert>Implementations§
Source§impl ModelMonitoringAlertConfig
impl ModelMonitoringAlertConfig
Sourcepub fn set_enable_logging<T: Into<bool>>(self, v: T) -> Self
pub fn set_enable_logging<T: Into<bool>>(self, v: T) -> Self
Sets the value of enable_logging.
§Example
let x = ModelMonitoringAlertConfig::new().set_enable_logging(true);Sourcepub fn set_notification_channels<T, V>(self, v: T) -> Self
pub fn set_notification_channels<T, V>(self, v: T) -> Self
Sets the value of notification_channels.
§Example
let x = ModelMonitoringAlertConfig::new().set_notification_channels(["a", "b", "c"]);Sourcepub fn set_alert<T: Into<Option<Alert>>>(self, v: T) -> Self
pub fn set_alert<T: Into<Option<Alert>>>(self, v: T) -> Self
Sets the value of alert.
Note that all the setters affecting alert are mutually
exclusive.
§Example
use google_cloud_aiplatform_v1::model::model_monitoring_alert_config::EmailAlertConfig;
let x = ModelMonitoringAlertConfig::new().set_alert(Some(
google_cloud_aiplatform_v1::model::model_monitoring_alert_config::Alert::EmailAlertConfig(EmailAlertConfig::default().into())));Sourcepub fn email_alert_config(&self) -> Option<&Box<EmailAlertConfig>>
pub fn email_alert_config(&self) -> Option<&Box<EmailAlertConfig>>
The value of alert
if it holds a EmailAlertConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_email_alert_config<T: Into<Box<EmailAlertConfig>>>(
self,
v: T,
) -> Self
pub fn set_email_alert_config<T: Into<Box<EmailAlertConfig>>>( self, v: T, ) -> Self
Sets the value of alert
to hold a EmailAlertConfig.
Note that all the setters affecting alert are
mutually exclusive.
§Example
use google_cloud_aiplatform_v1::model::model_monitoring_alert_config::EmailAlertConfig;
let x = ModelMonitoringAlertConfig::new().set_email_alert_config(EmailAlertConfig::default()/* use setters */);
assert!(x.email_alert_config().is_some());Trait Implementations§
Source§impl Clone for ModelMonitoringAlertConfig
impl Clone for ModelMonitoringAlertConfig
Source§fn clone(&self) -> ModelMonitoringAlertConfig
fn clone(&self) -> ModelMonitoringAlertConfig
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 ModelMonitoringAlertConfig
impl Debug for ModelMonitoringAlertConfig
Source§impl Default for ModelMonitoringAlertConfig
impl Default for ModelMonitoringAlertConfig
Source§fn default() -> ModelMonitoringAlertConfig
fn default() -> ModelMonitoringAlertConfig
Source§impl Message for ModelMonitoringAlertConfig
impl Message for ModelMonitoringAlertConfig
impl StructuralPartialEq for ModelMonitoringAlertConfig
Auto Trait Implementations§
impl Freeze for ModelMonitoringAlertConfig
impl RefUnwindSafe for ModelMonitoringAlertConfig
impl Send for ModelMonitoringAlertConfig
impl Sync for ModelMonitoringAlertConfig
impl Unpin for ModelMonitoringAlertConfig
impl UnsafeUnpin for ModelMonitoringAlertConfig
impl UnwindSafe for ModelMonitoringAlertConfig
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