Struct aws_sdk_autoscaling::operation::set_instance_protection::builders::SetInstanceProtectionFluentBuilder
source · pub struct SetInstanceProtectionFluentBuilder { /* private fields */ }Expand description
Fluent builder constructing a request to SetInstanceProtection.
Updates the instance protection settings of the specified instances. This operation cannot be called on instances in a warm pool.
For more information about preventing instances that are part of an Auto Scaling group from terminating on scale in, see Using instance scale-in protection in the Amazon EC2 Auto Scaling User Guide.
If you exceed your maximum limit of instance IDs, which is 50 per Auto Scaling group, the call fails.
Implementations§
source§impl SetInstanceProtectionFluentBuilder
impl SetInstanceProtectionFluentBuilder
sourcepub fn as_input(&self) -> &SetInstanceProtectionInputBuilder
pub fn as_input(&self) -> &SetInstanceProtectionInputBuilder
Access the SetInstanceProtection as a reference.
sourcepub async fn send(
self
) -> Result<SetInstanceProtectionOutput, SdkError<SetInstanceProtectionError, HttpResponse>>
pub async fn send( self ) -> Result<SetInstanceProtectionOutput, SdkError<SetInstanceProtectionError, HttpResponse>>
Sends the request and returns the response.
If an error occurs, an SdkError will be returned with additional details that
can be matched against.
By default, any retryable failures will be retried twice. Retry behavior is configurable with the RetryConfig, which can be set when configuring the client.
sourcepub fn customize(
self
) -> CustomizableOperation<SetInstanceProtectionOutput, SetInstanceProtectionError, Self>
pub fn customize( self ) -> CustomizableOperation<SetInstanceProtectionOutput, SetInstanceProtectionError, Self>
Consumes this builder, creating a customizable operation that can be modified before being sent.
sourcepub fn instance_ids(self, input: impl Into<String>) -> Self
pub fn instance_ids(self, input: impl Into<String>) -> Self
Appends an item to InstanceIds.
To override the contents of this collection use set_instance_ids.
One or more instance IDs. You can specify up to 50 instances.
sourcepub fn set_instance_ids(self, input: Option<Vec<String>>) -> Self
pub fn set_instance_ids(self, input: Option<Vec<String>>) -> Self
One or more instance IDs. You can specify up to 50 instances.
sourcepub fn get_instance_ids(&self) -> &Option<Vec<String>>
pub fn get_instance_ids(&self) -> &Option<Vec<String>>
One or more instance IDs. You can specify up to 50 instances.
sourcepub fn auto_scaling_group_name(self, input: impl Into<String>) -> Self
pub fn auto_scaling_group_name(self, input: impl Into<String>) -> Self
The name of the Auto Scaling group.
sourcepub fn set_auto_scaling_group_name(self, input: Option<String>) -> Self
pub fn set_auto_scaling_group_name(self, input: Option<String>) -> Self
The name of the Auto Scaling group.
sourcepub fn get_auto_scaling_group_name(&self) -> &Option<String>
pub fn get_auto_scaling_group_name(&self) -> &Option<String>
The name of the Auto Scaling group.
sourcepub fn protected_from_scale_in(self, input: bool) -> Self
pub fn protected_from_scale_in(self, input: bool) -> Self
Indicates whether the instance is protected from termination by Amazon EC2 Auto Scaling when scaling in.
sourcepub fn set_protected_from_scale_in(self, input: Option<bool>) -> Self
pub fn set_protected_from_scale_in(self, input: Option<bool>) -> Self
Indicates whether the instance is protected from termination by Amazon EC2 Auto Scaling when scaling in.
sourcepub fn get_protected_from_scale_in(&self) -> &Option<bool>
pub fn get_protected_from_scale_in(&self) -> &Option<bool>
Indicates whether the instance is protected from termination by Amazon EC2 Auto Scaling when scaling in.
Trait Implementations§
source§impl Clone for SetInstanceProtectionFluentBuilder
impl Clone for SetInstanceProtectionFluentBuilder
source§fn clone(&self) -> SetInstanceProtectionFluentBuilder
fn clone(&self) -> SetInstanceProtectionFluentBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more