#[non_exhaustive]pub struct UpdateServiceRequest {
pub name: String,
pub service: Option<Service>,
pub update_mask: Option<FieldMask>,
pub migrate_traffic: bool,
/* private fields */
}Expand description
Request message for Services.UpdateService.
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: StringName of the resource to update. Example: apps/myapp/services/default.
service: Option<Service>A Service resource containing the updated service. Only fields set in the field mask will be updated.
update_mask: Option<FieldMask>Required. Standard field mask for the set of fields to be updated.
migrate_traffic: boolSet to true to gradually shift traffic to one or more versions that you
specify. By default, traffic is shifted immediately.
For gradual traffic migration, the target versions
must be located within instances that are configured for both
warmup requests
and
automatic scaling.
You must specify the
shardBy
field in the Service resource. Gradual traffic migration is not
supported in the App Engine flexible environment. For examples, see
Migrating and Splitting Traffic.
Implementations§
Source§impl UpdateServiceRequest
impl UpdateServiceRequest
pub fn new() -> Self
Sourcepub fn set_service<T>(self, v: T) -> Self
pub fn set_service<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_service<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_service<T>(self, v: Option<T>) -> Self
Sourcepub fn set_update_mask<T>(self, v: T) -> Self
pub fn set_update_mask<T>(self, v: T) -> Self
Sets the value of update_mask.
§Example
use wkt::FieldMask;
let x = UpdateServiceRequest::new().set_update_mask(FieldMask::default()/* use setters */);Sourcepub fn set_or_clear_update_mask<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_mask<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_mask.
§Example
use wkt::FieldMask;
let x = UpdateServiceRequest::new().set_or_clear_update_mask(Some(FieldMask::default()/* use setters */));
let x = UpdateServiceRequest::new().set_or_clear_update_mask(None::<FieldMask>);Sourcepub fn set_migrate_traffic<T: Into<bool>>(self, v: T) -> Self
pub fn set_migrate_traffic<T: Into<bool>>(self, v: T) -> Self
Sets the value of migrate_traffic.
§Example
let x = UpdateServiceRequest::new().set_migrate_traffic(true);Trait Implementations§
Source§impl Clone for UpdateServiceRequest
impl Clone for UpdateServiceRequest
Source§fn clone(&self) -> UpdateServiceRequest
fn clone(&self) -> UpdateServiceRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more