Struct aws_sdk_computeoptimizer::types::PreferredResource
source · #[non_exhaustive]pub struct PreferredResource {
pub name: Option<PreferredResourceName>,
pub include_list: Option<Vec<String>>,
pub exclude_list: Option<Vec<String>>,
}
Expand description
The preference to control which resource type values are considered when generating rightsizing recommendations. You can specify this preference as a combination of include and exclude lists. You must specify either an includeList
or excludeList
. If the preference is an empty set of resource type values, an error occurs. For more information, see Rightsizing recommendation preferences in the Compute Optimizer User Guide.
-
This preference is only available for the Amazon EC2 instance and Auto Scaling group resource types.
-
Compute Optimizer only supports the customization of
Ec2InstanceTypes
.
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: Option<PreferredResourceName>
The type of preferred resource to customize.
Compute Optimizer only supports the customization of Ec2InstanceTypes
.
include_list: Option<Vec<String>>
The preferred resource type values to include in the recommendation candidates. You can specify the exact resource type value, such as m5.large, or use wild card expressions, such as m5. If this isn’t specified, all supported resources are included by default. You can specify up to 1000 values in this list.
exclude_list: Option<Vec<String>>
The preferred resource type values to exclude from the recommendation candidates. If this isn’t specified, all supported resources are included by default. You can specify up to 1000 values in this list.
Implementations§
source§impl PreferredResource
impl PreferredResource
sourcepub fn name(&self) -> Option<&PreferredResourceName>
pub fn name(&self) -> Option<&PreferredResourceName>
The type of preferred resource to customize.
Compute Optimizer only supports the customization of Ec2InstanceTypes
.
sourcepub fn include_list(&self) -> &[String]
pub fn include_list(&self) -> &[String]
The preferred resource type values to include in the recommendation candidates. You can specify the exact resource type value, such as m5.large, or use wild card expressions, such as m5. If this isn’t specified, all supported resources are included by default. You can specify up to 1000 values in this list.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .include_list.is_none()
.
sourcepub fn exclude_list(&self) -> &[String]
pub fn exclude_list(&self) -> &[String]
The preferred resource type values to exclude from the recommendation candidates. If this isn’t specified, all supported resources are included by default. You can specify up to 1000 values in this list.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .exclude_list.is_none()
.
source§impl PreferredResource
impl PreferredResource
sourcepub fn builder() -> PreferredResourceBuilder
pub fn builder() -> PreferredResourceBuilder
Creates a new builder-style object to manufacture PreferredResource
.
Trait Implementations§
source§impl Clone for PreferredResource
impl Clone for PreferredResource
source§fn clone(&self) -> PreferredResource
fn clone(&self) -> PreferredResource
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for PreferredResource
impl Debug for PreferredResource
source§impl PartialEq for PreferredResource
impl PartialEq for PreferredResource
source§fn eq(&self, other: &PreferredResource) -> bool
fn eq(&self, other: &PreferredResource) -> bool
self
and other
values to be equal, and is used
by ==
.