AWS SDK

AWS SDK

rev. e063993ca0ab793f44c575dbe707d50a5e3e2406

Files changed:

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index.rs

@@ -1,0 +22,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_replica_global_secondary_index(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ReplicaGlobalSecondaryIndex,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    {
    7         -
        object.key("IndexName").string(input.index_name.as_str());
    8         -
    }
    9         -
    if let Some(var_1) = &input.provisioned_throughput_override {
   10         -
        #[allow(unused_mut)]
   11         -
        let mut object_2 = object.key("ProvisionedThroughputOverride").start_object();
   12         -
        crate::protocol_serde::shape_provisioned_throughput_override::ser_provisioned_throughput_override(&mut object_2, var_1)?;
   13         -
        object_2.finish();
   14         -
    }
   15         -
    if let Some(var_3) = &input.on_demand_throughput_override {
   16         -
        #[allow(unused_mut)]
   17         -
        let mut object_4 = object.key("OnDemandThroughputOverride").start_object();
   18         -
        crate::protocol_serde::shape_on_demand_throughput_override::ser_on_demand_throughput_override(&mut object_4, var_3)?;
   19         -
        object_4.finish();
   20         -
    }
   21         -
    Ok(())
   22         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_auto_scaling_description.rs

@@ -1,0 +60,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_auto_scaling_description<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<crate::types::ReplicaGlobalSecondaryIndexAutoScalingDescription>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   15         -
            #[allow(unused_mut)]
   16         -
            let mut builder = crate::types::builders::ReplicaGlobalSecondaryIndexAutoScalingDescriptionBuilder::default();
   17         -
            loop {
   18         -
                match tokens.next().transpose()? {
   19         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   20         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   21         -
                        "IndexName" => {
   22         -
                            builder = builder.set_index_name(
   23         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   24         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   25         -
                                    .transpose()?,
   26         -
                            );
   27         -
                        }
   28         -
                        "IndexStatus" => {
   29         -
                            builder = builder.set_index_status(
   30         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   31         -
                                    .map(|s| s.to_unescaped().map(|u| crate::types::IndexStatus::from(u.as_ref())))
   32         -
                                    .transpose()?,
   33         -
                            );
   34         -
                        }
   35         -
                        "ProvisionedReadCapacityAutoScalingSettings" => {
   36         -
                            builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
   37         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   38         -
                            );
   39         -
                        }
   40         -
                        "ProvisionedWriteCapacityAutoScalingSettings" => {
   41         -
                            builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
   42         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   43         -
                            );
   44         -
                        }
   45         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   46         -
                    },
   47         -
                    other => {
   48         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   49         -
                            "expected object key or end object, found: {other:?}"
   50         -
                        )))
   51         -
                    }
   52         -
                }
   53         -
            }
   54         -
            Ok(Some(builder.build()))
   55         -
        }
   56         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   57         -
            "expected start object or null",
   58         -
        )),
   59         -
    }
   60         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_auto_scaling_description_list.rs

@@ -1,0 +42,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_auto_scaling_description_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<::std::vec::Vec<crate::types::ReplicaGlobalSecondaryIndexAutoScalingDescription>>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   15         -
            let mut items = Vec::new();
   16         -
            loop {
   17         -
                match tokens.peek() {
   18         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   19         -
                        tokens.next().transpose().unwrap();
   20         -
                        break;
   21         -
                    }
   22         -
                    _ => {
   23         -
                        let value =
   24         -
                            crate::protocol_serde::shape_replica_global_secondary_index_auto_scaling_description::de_replica_global_secondary_index_auto_scaling_description(tokens, _value)?
   25         -
                        ;
   26         -
                        if let Some(value) = value {
   27         -
                            items.push(value);
   28         -
                        } else {
   29         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   30         -
                                "dense list cannot contain null values",
   31         -
                            ));
   32         -
                        }
   33         -
                    }
   34         -
                }
   35         -
            }
   36         -
            Ok(Some(items))
   37         -
        }
   38         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   39         -
            "expected start array or null",
   40         -
        )),
   41         -
    }
   42         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_auto_scaling_update.rs

@@ -1,0 +16,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_replica_global_secondary_index_auto_scaling_update(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ReplicaGlobalSecondaryIndexAutoScalingUpdate,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.index_name {
    7         -
        object.key("IndexName").string(var_1.as_str());
    8         -
    }
    9         -
    if let Some(var_2) = &input.provisioned_read_capacity_auto_scaling_update {
   10         -
        #[allow(unused_mut)]
   11         -
        let mut object_3 = object.key("ProvisionedReadCapacityAutoScalingUpdate").start_object();
   12         -
        crate::protocol_serde::shape_auto_scaling_settings_update::ser_auto_scaling_settings_update(&mut object_3, var_2)?;
   13         -
        object_3.finish();
   14         -
    }
   15         -
    Ok(())
   16         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_description.rs

@@ -1,0 +55,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_description<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::ReplicaGlobalSecondaryIndexDescription>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::ReplicaGlobalSecondaryIndexDescriptionBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "IndexName" => {
   19         -
                            builder = builder.set_index_name(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "ProvisionedThroughputOverride" => {
   26         -
                            builder = builder.set_provisioned_throughput_override(
   27         -
                                crate::protocol_serde::shape_provisioned_throughput_override::de_provisioned_throughput_override(tokens, _value)?,
   28         -
                            );
   29         -
                        }
   30         -
                        "OnDemandThroughputOverride" => {
   31         -
                            builder = builder.set_on_demand_throughput_override(
   32         -
                                crate::protocol_serde::shape_on_demand_throughput_override::de_on_demand_throughput_override(tokens, _value)?,
   33         -
                            );
   34         -
                        }
   35         -
                        "WarmThroughput" => {
   36         -
                            builder = builder.set_warm_throughput(
   37         -
                                    crate::protocol_serde::shape_global_secondary_index_warm_throughput_description::de_global_secondary_index_warm_throughput_description(tokens, _value)?
   38         -
                                );
   39         -
                        }
   40         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   41         -
                    },
   42         -
                    other => {
   43         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   44         -
                            "expected object key or end object, found: {other:?}"
   45         -
                        )))
   46         -
                    }
   47         -
                }
   48         -
            }
   49         -
            Ok(Some(builder.build()))
   50         -
        }
   51         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   52         -
            "expected start object or null",
   53         -
        )),
   54         -
    }
   55         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_description_list.rs

@@ -1,0 +43,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_description_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<::std::vec::Vec<crate::types::ReplicaGlobalSecondaryIndexDescription>>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   15         -
            let mut items = Vec::new();
   16         -
            loop {
   17         -
                match tokens.peek() {
   18         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   19         -
                        tokens.next().transpose().unwrap();
   20         -
                        break;
   21         -
                    }
   22         -
                    _ => {
   23         -
                        let value =
   24         -
                            crate::protocol_serde::shape_replica_global_secondary_index_description::de_replica_global_secondary_index_description(
   25         -
                                tokens, _value,
   26         -
                            )?;
   27         -
                        if let Some(value) = value {
   28         -
                            items.push(value);
   29         -
                        } else {
   30         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
                                "dense list cannot contain null values",
   32         -
                            ));
   33         -
                        }
   34         -
                    }
   35         -
                }
   36         -
            }
   37         -
            Ok(Some(items))
   38         -
        }
   39         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   40         -
            "expected start array or null",
   41         -
        )),
   42         -
    }
   43         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_settings_description.rs

@@ -1,0 +78,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_settings_description<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<crate::types::ReplicaGlobalSecondaryIndexSettingsDescription>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   15         -
            #[allow(unused_mut)]
   16         -
            let mut builder = crate::types::builders::ReplicaGlobalSecondaryIndexSettingsDescriptionBuilder::default();
   17         -
            loop {
   18         -
                match tokens.next().transpose()? {
   19         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   20         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   21         -
                        "IndexName" => {
   22         -
                            builder = builder.set_index_name(
   23         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   24         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   25         -
                                    .transpose()?,
   26         -
                            );
   27         -
                        }
   28         -
                        "IndexStatus" => {
   29         -
                            builder = builder.set_index_status(
   30         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   31         -
                                    .map(|s| s.to_unescaped().map(|u| crate::types::IndexStatus::from(u.as_ref())))
   32         -
                                    .transpose()?,
   33         -
                            );
   34         -
                        }
   35         -
                        "ProvisionedReadCapacityUnits" => {
   36         -
                            builder = builder.set_provisioned_read_capacity_units(
   37         -
                                ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
   38         -
                                    .map(i64::try_from)
   39         -
                                    .transpose()?,
   40         -
                            );
   41         -
                        }
   42         -
                        "ProvisionedReadCapacityAutoScalingSettings" => {
   43         -
                            builder = builder.set_provisioned_read_capacity_auto_scaling_settings(
   44         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   45         -
                            );
   46         -
                        }
   47         -
                        "ProvisionedWriteCapacityUnits" => {
   48         -
                            builder = builder.set_provisioned_write_capacity_units(
   49         -
                                ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
   50         -
                                    .map(i64::try_from)
   51         -
                                    .transpose()?,
   52         -
                            );
   53         -
                        }
   54         -
                        "ProvisionedWriteCapacityAutoScalingSettings" => {
   55         -
                            builder = builder.set_provisioned_write_capacity_auto_scaling_settings(
   56         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   57         -
                            );
   58         -
                        }
   59         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   60         -
                    },
   61         -
                    other => {
   62         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   63         -
                            "expected object key or end object, found: {other:?}"
   64         -
                        )))
   65         -
                    }
   66         -
                }
   67         -
            }
   68         -
            Ok(Some(
   69         -
                crate::serde_util::replica_global_secondary_index_settings_description_correct_errors(builder)
   70         -
                    .build()
   71         -
                    .map_err(|err| ::aws_smithy_json::deserialize::error::DeserializeError::custom_source("Response was invalid", err))?,
   72         -
            ))
   73         -
        }
   74         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   75         -
            "expected start object or null",
   76         -
        )),
   77         -
    }
   78         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_settings_description_list.rs

@@ -1,0 +42,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_global_secondary_index_settings_description_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<
    6         -
    Option<::std::vec::Vec<crate::types::ReplicaGlobalSecondaryIndexSettingsDescription>>,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
>
    9         -
where
   10         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   11         -
{
   12         -
    match tokens.next().transpose()? {
   13         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   14         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   15         -
            let mut items = Vec::new();
   16         -
            loop {
   17         -
                match tokens.peek() {
   18         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   19         -
                        tokens.next().transpose().unwrap();
   20         -
                        break;
   21         -
                    }
   22         -
                    _ => {
   23         -
                        let value =
   24         -
                            crate::protocol_serde::shape_replica_global_secondary_index_settings_description::de_replica_global_secondary_index_settings_description(tokens, _value)?
   25         -
                        ;
   26         -
                        if let Some(value) = value {
   27         -
                            items.push(value);
   28         -
                        } else {
   29         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   30         -
                                "dense list cannot contain null values",
   31         -
                            ));
   32         -
                        }
   33         -
                    }
   34         -
                }
   35         -
            }
   36         -
            Ok(Some(items))
   37         -
        }
   38         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   39         -
            "expected start array or null",
   40         -
        )),
   41         -
    }
   42         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_global_secondary_index_settings_update.rs

@@ -1,0 +22,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_replica_global_secondary_index_settings_update(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ReplicaGlobalSecondaryIndexSettingsUpdate,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    {
    7         -
        object.key("IndexName").string(input.index_name.as_str());
    8         -
    }
    9         -
    if let Some(var_1) = &input.provisioned_read_capacity_units {
   10         -
        object.key("ProvisionedReadCapacityUnits").number(
   11         -
            #[allow(clippy::useless_conversion)]
   12         -
            ::aws_smithy_types::Number::NegInt((*var_1).into()),
   13         -
        );
   14         -
    }
   15         -
    if let Some(var_2) = &input.provisioned_read_capacity_auto_scaling_settings_update {
   16         -
        #[allow(unused_mut)]
   17         -
        let mut object_3 = object.key("ProvisionedReadCapacityAutoScalingSettingsUpdate").start_object();
   18         -
        crate::protocol_serde::shape_auto_scaling_settings_update::ser_auto_scaling_settings_update(&mut object_3, var_2)?;
   19         -
        object_3.finish();
   20         -
    }
   21         -
    Ok(())
   22         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_list.rs

@@ -1,0 +37,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<crate::types::Replica>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = crate::protocol_serde::shape_replica::de_replica(tokens, _value)?;
   21         -
                        if let Some(value) = value {
   22         -
                            items.push(value);
   23         -
                        } else {
   24         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   25         -
                                "dense list cannot contain null values",
   26         -
                            ));
   27         -
                        }
   28         -
                    }
   29         -
                }
   30         -
            }
   31         -
            Ok(Some(items))
   32         -
        }
   33         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "expected start array or null",
   35         -
        )),
   36         -
    }
   37         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_not_found_exception.rs

@@ -1,0 +35,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_not_found_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::ReplicaNotFoundExceptionBuilder,
    5         -
) -> ::std::result::Result<crate::types::error::builders::ReplicaNotFoundExceptionBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
    6         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
    7         -
    let tokens = &mut tokens_owned;
    8         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
    9         -
    loop {
   10         -
        match tokens.next().transpose()? {
   11         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   12         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   13         -
                "message" => {
   14         -
                    builder = builder.set_message(
   15         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   16         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   17         -
                            .transpose()?,
   18         -
                    );
   19         -
                }
   20         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   21         -
            },
   22         -
            other => {
   23         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   24         -
                    "expected object key or end object, found: {other:?}"
   25         -
                )))
   26         -
            }
   27         -
        }
   28         -
    }
   29         -
    if tokens.next().is_some() {
   30         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   31         -
            "found more JSON tokens after completing parsing",
   32         -
        ));
   33         -
    }
   34         -
    Ok(builder)
   35         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_settings_description.rs

@@ -1,0 +90,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_settings_description<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::ReplicaSettingsDescription>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::ReplicaSettingsDescriptionBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "RegionName" => {
   19         -
                            builder = builder.set_region_name(
   20         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   21         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   22         -
                                    .transpose()?,
   23         -
                            );
   24         -
                        }
   25         -
                        "ReplicaStatus" => {
   26         -
                            builder = builder.set_replica_status(
   27         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   28         -
                                    .map(|s| s.to_unescaped().map(|u| crate::types::ReplicaStatus::from(u.as_ref())))
   29         -
                                    .transpose()?,
   30         -
                            );
   31         -
                        }
   32         -
                        "ReplicaBillingModeSummary" => {
   33         -
                            builder = builder.set_replica_billing_mode_summary(
   34         -
                                crate::protocol_serde::shape_billing_mode_summary::de_billing_mode_summary(tokens, _value)?,
   35         -
                            );
   36         -
                        }
   37         -
                        "ReplicaProvisionedReadCapacityUnits" => {
   38         -
                            builder = builder.set_replica_provisioned_read_capacity_units(
   39         -
                                ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
   40         -
                                    .map(i64::try_from)
   41         -
                                    .transpose()?,
   42         -
                            );
   43         -
                        }
   44         -
                        "ReplicaProvisionedReadCapacityAutoScalingSettings" => {
   45         -
                            builder = builder.set_replica_provisioned_read_capacity_auto_scaling_settings(
   46         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   47         -
                            );
   48         -
                        }
   49         -
                        "ReplicaProvisionedWriteCapacityUnits" => {
   50         -
                            builder = builder.set_replica_provisioned_write_capacity_units(
   51         -
                                ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
   52         -
                                    .map(i64::try_from)
   53         -
                                    .transpose()?,
   54         -
                            );
   55         -
                        }
   56         -
                        "ReplicaProvisionedWriteCapacityAutoScalingSettings" => {
   57         -
                            builder = builder.set_replica_provisioned_write_capacity_auto_scaling_settings(
   58         -
                                crate::protocol_serde::shape_auto_scaling_settings_description::de_auto_scaling_settings_description(tokens, _value)?,
   59         -
                            );
   60         -
                        }
   61         -
                        "ReplicaGlobalSecondaryIndexSettings" => {
   62         -
                            builder = builder.set_replica_global_secondary_index_settings(
   63         -
                                    crate::protocol_serde::shape_replica_global_secondary_index_settings_description_list::de_replica_global_secondary_index_settings_description_list(tokens, _value)?
   64         -
                                );
   65         -
                        }
   66         -
                        "ReplicaTableClassSummary" => {
   67         -
                            builder = builder.set_replica_table_class_summary(
   68         -
                                crate::protocol_serde::shape_table_class_summary::de_table_class_summary(tokens, _value)?,
   69         -
                            );
   70         -
                        }
   71         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   72         -
                    },
   73         -
                    other => {
   74         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   75         -
                            "expected object key or end object, found: {other:?}"
   76         -
                        )))
   77         -
                    }
   78         -
                }
   79         -
            }
   80         -
            Ok(Some(
   81         -
                crate::serde_util::replica_settings_description_correct_errors(builder)
   82         -
                    .build()
   83         -
                    .map_err(|err| ::aws_smithy_json::deserialize::error::DeserializeError::custom_source("Response was invalid", err))?,
   84         -
            ))
   85         -
        }
   86         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   87         -
            "expected start object or null",
   88         -
        )),
   89         -
    }
   90         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_settings_description_list.rs

@@ -1,0 +37,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replica_settings_description_list<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<::std::vec::Vec<crate::types::ReplicaSettingsDescription>>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartArray { .. }) => {
   12         -
            let mut items = Vec::new();
   13         -
            loop {
   14         -
                match tokens.peek() {
   15         -
                    Some(Ok(::aws_smithy_json::deserialize::Token::EndArray { .. })) => {
   16         -
                        tokens.next().transpose().unwrap();
   17         -
                        break;
   18         -
                    }
   19         -
                    _ => {
   20         -
                        let value = crate::protocol_serde::shape_replica_settings_description::de_replica_settings_description(tokens, _value)?;
   21         -
                        if let Some(value) = value {
   22         -
                            items.push(value);
   23         -
                        } else {
   24         -
                            return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   25         -
                                "dense list cannot contain null values",
   26         -
                            ));
   27         -
                        }
   28         -
                    }
   29         -
                }
   30         -
            }
   31         -
            Ok(Some(items))
   32         -
        }
   33         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "expected start array or null",
   35         -
        )),
   36         -
    }
   37         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_settings_update.rs

@@ -1,0 +40,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_replica_settings_update(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ReplicaSettingsUpdate,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    {
    7         -
        object.key("RegionName").string(input.region_name.as_str());
    8         -
    }
    9         -
    if let Some(var_1) = &input.replica_provisioned_read_capacity_units {
   10         -
        object.key("ReplicaProvisionedReadCapacityUnits").number(
   11         -
            #[allow(clippy::useless_conversion)]
   12         -
            ::aws_smithy_types::Number::NegInt((*var_1).into()),
   13         -
        );
   14         -
    }
   15         -
    if let Some(var_2) = &input.replica_provisioned_read_capacity_auto_scaling_settings_update {
   16         -
        #[allow(unused_mut)]
   17         -
        let mut object_3 = object.key("ReplicaProvisionedReadCapacityAutoScalingSettingsUpdate").start_object();
   18         -
        crate::protocol_serde::shape_auto_scaling_settings_update::ser_auto_scaling_settings_update(&mut object_3, var_2)?;
   19         -
        object_3.finish();
   20         -
    }
   21         -
    if let Some(var_4) = &input.replica_global_secondary_index_settings_update {
   22         -
        let mut array_5 = object.key("ReplicaGlobalSecondaryIndexSettingsUpdate").start_array();
   23         -
        for item_6 in var_4 {
   24         -
            {
   25         -
                #[allow(unused_mut)]
   26         -
                let mut object_7 = array_5.value().start_object();
   27         -
                crate::protocol_serde::shape_replica_global_secondary_index_settings_update::ser_replica_global_secondary_index_settings_update(
   28         -
                    &mut object_7,
   29         -
                    item_6,
   30         -
                )?;
   31         -
                object_7.finish();
   32         -
            }
   33         -
        }
   34         -
        array_5.finish();
   35         -
    }
   36         -
    if let Some(var_8) = &input.replica_table_class {
   37         -
        object.key("ReplicaTableClass").string(var_8.as_str());
   38         -
    }
   39         -
    Ok(())
   40         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replica_update.rs

@@ -1,0 +19,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_replica_update(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ReplicaUpdate,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.create {
    7         -
        #[allow(unused_mut)]
    8         -
        let mut object_2 = object.key("Create").start_object();
    9         -
        crate::protocol_serde::shape_create_replica_action::ser_create_replica_action(&mut object_2, var_1)?;
   10         -
        object_2.finish();
   11         -
    }
   12         -
    if let Some(var_3) = &input.delete {
   13         -
        #[allow(unused_mut)]
   14         -
        let mut object_4 = object.key("Delete").start_object();
   15         -
        crate::protocol_serde::shape_delete_replica_action::ser_delete_replica_action(&mut object_4, var_3)?;
   16         -
        object_4.finish();
   17         -
    }
   18         -
    Ok(())
   19         -
}

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/protocol_serde/shape_replicated_write_conflict_exception.rs

@@ -1,0 +38,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_replicated_write_conflict_exception_json_err(
    3         -
    _value: &[u8],
    4         -
    mut builder: crate::types::error::builders::ReplicatedWriteConflictExceptionBuilder,
    5         -
) -> ::std::result::Result<
    6         -
    crate::types::error::builders::ReplicatedWriteConflictExceptionBuilder,
    7         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
    8         -
> {
    9         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
   10         -
    let tokens = &mut tokens_owned;
   11         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
   12         -
    loop {
   13         -
        match tokens.next().transpose()? {
   14         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   15         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   16         -
                "message" => {
   17         -
                    builder = builder.set_message(
   18         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   19         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   20         -
                            .transpose()?,
   21         -
                    );
   22         -
                }
   23         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   24         -
            },
   25         -
            other => {
   26         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   27         -
                    "expected object key or end object, found: {other:?}"
   28         -
                )))
   29         -
            }
   30         -
        }
   31         -
    }
   32         -
    if tokens.next().is_some() {
   33         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   34         -
            "found more JSON tokens after completing parsing",
   35         -
        ));
   36         -
    }
   37         -
    Ok(builder)
   38         -
}