Struct aws_sdk_cloudsearch::model::ScalingParameters
source · #[non_exhaustive]pub struct ScalingParameters { /* private fields */ }Expand description
The desired instance type and desired number of replicas of each index partition.
Implementations§
source§impl ScalingParameters
impl ScalingParameters
sourcepub fn desired_instance_type(&self) -> Option<&PartitionInstanceType>
pub fn desired_instance_type(&self) -> Option<&PartitionInstanceType>
The instance type that you want to preconfigure for your domain. For example, search.m1.small.
sourcepub fn desired_replication_count(&self) -> i32
pub fn desired_replication_count(&self) -> i32
The number of replicas you want to preconfigure for each index partition.
sourcepub fn desired_partition_count(&self) -> i32
pub fn desired_partition_count(&self) -> i32
The number of partitions you want to preconfigure for your domain. Only valid when you select m2.2xlarge as the desired instance type.
source§impl ScalingParameters
impl ScalingParameters
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture ScalingParameters.
Examples found in repository?
src/xml_deser.rs (line 2748)
2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799
pub fn deser_structure_crate_model_scaling_parameters(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::ScalingParameters, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::ScalingParameters::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("DesiredInstanceType") /* DesiredInstanceType com.amazonaws.cloudsearch#ScalingParameters$DesiredInstanceType */ => {
let var_102 =
Some(
Result::<crate::model::PartitionInstanceType, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::PartitionInstanceType::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_desired_instance_type(var_102);
}
,
s if s.matches("DesiredReplicationCount") /* DesiredReplicationCount com.amazonaws.cloudsearch#ScalingParameters$DesiredReplicationCount */ => {
let var_103 =
Some(
{
<i32 as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (integer: `com.amazonaws.cloudsearch#UIntValue`)"))
}
?
)
;
builder = builder.set_desired_replication_count(var_103);
}
,
s if s.matches("DesiredPartitionCount") /* DesiredPartitionCount com.amazonaws.cloudsearch#ScalingParameters$DesiredPartitionCount */ => {
let var_104 =
Some(
{
<i32 as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (integer: `com.amazonaws.cloudsearch#UIntValue`)"))
}
?
)
;
builder = builder.set_desired_partition_count(var_104);
}
,
_ => {}
}
}
Ok(builder.build())
}Trait Implementations§
source§impl Clone for ScalingParameters
impl Clone for ScalingParameters
source§fn clone(&self) -> ScalingParameters
fn clone(&self) -> ScalingParameters
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more