pub struct CreateProtectionGroup { /* private fields */ }
Expand description
Fluent builder constructing a request to CreateProtectionGroup
.
Creates a grouping of protected resources so they can be handled as a collective. This resource grouping improves the accuracy of detection and reduces false positives.
Implementations§
source§impl CreateProtectionGroup
impl CreateProtectionGroup
sourcepub async fn customize(
self
) -> Result<CustomizableOperation<CreateProtectionGroup, AwsResponseRetryClassifier>, SdkError<CreateProtectionGroupError>>
pub async fn customize(
self
) -> Result<CustomizableOperation<CreateProtectionGroup, AwsResponseRetryClassifier>, SdkError<CreateProtectionGroupError>>
Consume this builder, creating a customizable operation that can be modified before being sent. The operation’s inner http::Request can be modified as well.
sourcepub async fn send(
self
) -> Result<CreateProtectionGroupOutput, SdkError<CreateProtectionGroupError>>
pub async fn send(
self
) -> Result<CreateProtectionGroupOutput, SdkError<CreateProtectionGroupError>>
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 protection_group_id(self, input: impl Into<String>) -> Self
pub fn protection_group_id(self, input: impl Into<String>) -> Self
The name of the protection group. You use this to identify the protection group in lists and to manage the protection group, for example to update, delete, or describe it.
sourcepub fn set_protection_group_id(self, input: Option<String>) -> Self
pub fn set_protection_group_id(self, input: Option<String>) -> Self
The name of the protection group. You use this to identify the protection group in lists and to manage the protection group, for example to update, delete, or describe it.
sourcepub fn aggregation(self, input: ProtectionGroupAggregation) -> Self
pub fn aggregation(self, input: ProtectionGroupAggregation) -> Self
Defines how Shield combines resource data for the group in order to detect, mitigate, and report events.
-
Sum - Use the total traffic across the group. This is a good choice for most cases. Examples include Elastic IP addresses for EC2 instances that scale manually or automatically.
-
Mean - Use the average of the traffic across the group. This is a good choice for resources that share traffic uniformly. Examples include accelerators and load balancers.
-
Max - Use the highest traffic from each resource. This is useful for resources that don't share traffic and for resources that share that traffic in a non-uniform way. Examples include Amazon CloudFront and origin resources for CloudFront distributions.
sourcepub fn set_aggregation(self, input: Option<ProtectionGroupAggregation>) -> Self
pub fn set_aggregation(self, input: Option<ProtectionGroupAggregation>) -> Self
Defines how Shield combines resource data for the group in order to detect, mitigate, and report events.
-
Sum - Use the total traffic across the group. This is a good choice for most cases. Examples include Elastic IP addresses for EC2 instances that scale manually or automatically.
-
Mean - Use the average of the traffic across the group. This is a good choice for resources that share traffic uniformly. Examples include accelerators and load balancers.
-
Max - Use the highest traffic from each resource. This is useful for resources that don't share traffic and for resources that share that traffic in a non-uniform way. Examples include Amazon CloudFront and origin resources for CloudFront distributions.
sourcepub fn pattern(self, input: ProtectionGroupPattern) -> Self
pub fn pattern(self, input: ProtectionGroupPattern) -> Self
The criteria to use to choose the protected resources for inclusion in the group. You can include all resources that have protections, provide a list of resource Amazon Resource Names (ARNs), or include all resources of a specified resource type.
sourcepub fn set_pattern(self, input: Option<ProtectionGroupPattern>) -> Self
pub fn set_pattern(self, input: Option<ProtectionGroupPattern>) -> Self
The criteria to use to choose the protected resources for inclusion in the group. You can include all resources that have protections, provide a list of resource Amazon Resource Names (ARNs), or include all resources of a specified resource type.
sourcepub fn resource_type(self, input: ProtectedResourceType) -> Self
pub fn resource_type(self, input: ProtectedResourceType) -> Self
The resource type to include in the protection group. All protected resources of this type are included in the protection group. Newly protected resources of this type are automatically added to the group. You must set this when you set Pattern
to BY_RESOURCE_TYPE
and you must not set it for any other Pattern
setting.
sourcepub fn set_resource_type(self, input: Option<ProtectedResourceType>) -> Self
pub fn set_resource_type(self, input: Option<ProtectedResourceType>) -> Self
The resource type to include in the protection group. All protected resources of this type are included in the protection group. Newly protected resources of this type are automatically added to the group. You must set this when you set Pattern
to BY_RESOURCE_TYPE
and you must not set it for any other Pattern
setting.
sourcepub fn members(self, input: impl Into<String>) -> Self
pub fn members(self, input: impl Into<String>) -> Self
Appends an item to Members
.
To override the contents of this collection use set_members
.
The Amazon Resource Names (ARNs) of the resources to include in the protection group. You must set this when you set Pattern
to ARBITRARY
and you must not set it for any other Pattern
setting.
sourcepub fn set_members(self, input: Option<Vec<String>>) -> Self
pub fn set_members(self, input: Option<Vec<String>>) -> Self
The Amazon Resource Names (ARNs) of the resources to include in the protection group. You must set this when you set Pattern
to ARBITRARY
and you must not set it for any other Pattern
setting.
Appends an item to Tags
.
To override the contents of this collection use set_tags
.
One or more tag key-value pairs for the protection group.
One or more tag key-value pairs for the protection group.
Trait Implementations§
source§impl Clone for CreateProtectionGroup
impl Clone for CreateProtectionGroup
source§fn clone(&self) -> CreateProtectionGroup
fn clone(&self) -> CreateProtectionGroup
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more