#[non_exhaustive]pub struct NotificationEndpointGrpcSettings {
pub authority: Option<String>,
pub endpoint: Option<String>,
pub payload_name: Option<String>,
pub resend_interval: Option<Duration>,
pub retry_duration_sec: Option<u32>,
/* private fields */
}region-notification-endpoints only.Expand description
Represents a gRPC setting that describes one gRPC notification endpoint and the retry duration attempting to send notification to this endpoint.
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.Optional. If specified, this field is used to set the authority header by the sender of notifications. See https://tools.ietf.org/html/rfc7540#section-8.1.2.3
endpoint: Option<String>Endpoint to which gRPC notifications are sent. This must be a valid gRPCLB DNS name.
payload_name: Option<String>Optional. If specified, this field is used to populate the “name” field in gRPC requests.
resend_interval: Option<Duration>Optional. This field is used to configure how often to send a full update of all non-healthy backends. If unspecified, full updates are not sent. If specified, must be in the range between 600 seconds to 3600 seconds. Nanos are disallowed. Can only be set for regional notification endpoints.
retry_duration_sec: Option<u32>How much time (in seconds) is spent attempting notification retries until a successful response is received. Default is 30s. Limit is 20m (1200s). Must be a positive number.
Implementations§
Source§impl NotificationEndpointGrpcSettings
impl NotificationEndpointGrpcSettings
pub fn new() -> Self
Sourcepub fn set_endpoint<T>(self, v: T) -> Self
pub fn set_endpoint<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_endpoint<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_endpoint<T>(self, v: Option<T>) -> Self
Sourcepub fn set_payload_name<T>(self, v: T) -> Self
pub fn set_payload_name<T>(self, v: T) -> Self
Sets the value of payload_name.
§Example
let x = NotificationEndpointGrpcSettings::new().set_payload_name("example");Sourcepub fn set_or_clear_payload_name<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_payload_name<T>(self, v: Option<T>) -> Self
Sets or clears the value of payload_name.
§Example
let x = NotificationEndpointGrpcSettings::new().set_or_clear_payload_name(Some("example"));
let x = NotificationEndpointGrpcSettings::new().set_or_clear_payload_name(None::<String>);Sourcepub fn set_resend_interval<T>(self, v: T) -> Self
pub fn set_resend_interval<T>(self, v: T) -> Self
Sets the value of resend_interval.
§Example
use google_cloud_compute_v1::model::Duration;
let x = NotificationEndpointGrpcSettings::new().set_resend_interval(Duration::default()/* use setters */);Sourcepub fn set_or_clear_resend_interval<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_resend_interval<T>(self, v: Option<T>) -> Self
Sets or clears the value of resend_interval.
§Example
use google_cloud_compute_v1::model::Duration;
let x = NotificationEndpointGrpcSettings::new().set_or_clear_resend_interval(Some(Duration::default()/* use setters */));
let x = NotificationEndpointGrpcSettings::new().set_or_clear_resend_interval(None::<Duration>);Sourcepub fn set_retry_duration_sec<T>(self, v: T) -> Self
pub fn set_retry_duration_sec<T>(self, v: T) -> Self
Sets the value of retry_duration_sec.
§Example
let x = NotificationEndpointGrpcSettings::new().set_retry_duration_sec(42_u32);Sourcepub fn set_or_clear_retry_duration_sec<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_retry_duration_sec<T>(self, v: Option<T>) -> Self
Sets or clears the value of retry_duration_sec.
§Example
let x = NotificationEndpointGrpcSettings::new().set_or_clear_retry_duration_sec(Some(42_u32));
let x = NotificationEndpointGrpcSettings::new().set_or_clear_retry_duration_sec(None::<u32>);Trait Implementations§
Source§impl Clone for NotificationEndpointGrpcSettings
impl Clone for NotificationEndpointGrpcSettings
Source§fn clone(&self) -> NotificationEndpointGrpcSettings
fn clone(&self) -> NotificationEndpointGrpcSettings
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for NotificationEndpointGrpcSettings
impl Default for NotificationEndpointGrpcSettings
Source§fn default() -> NotificationEndpointGrpcSettings
fn default() -> NotificationEndpointGrpcSettings
Source§impl PartialEq for NotificationEndpointGrpcSettings
impl PartialEq for NotificationEndpointGrpcSettings
Source§fn eq(&self, other: &NotificationEndpointGrpcSettings) -> bool
fn eq(&self, other: &NotificationEndpointGrpcSettings) -> bool
self and other values to be equal, and is used by ==.