AWS SDK

AWS SDK

rev. ec7b2441254af868911fccffe8d8dca83aff0045 (ignoring whitespace)

Files changed:

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_global_table_settings/_describe_global_table_settings_input.rs

@@ -1,1 +108,120 @@
   17     17   
    "com.amazonaws.dynamodb.synthetic",
   18     18   
    "DescribeGlobalTableSettingsInput",
   19     19   
);
   20     20   
static DESCRIBEGLOBALTABLESETTINGSINPUT_MEMBER_GLOBAL_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   21     21   
    ::aws_smithy_schema::ShapeId::from_static(
   22     22   
        "com.amazonaws.dynamodb.synthetic#DescribeGlobalTableSettingsInput$GlobalTableName",
   23     23   
        "com.amazonaws.dynamodb.synthetic",
   24     24   
        "DescribeGlobalTableSettingsInput",
   25     25   
    ),
   26     26   
    ::aws_smithy_schema::ShapeType::String,
   27         -
    "global_table_name",
          27  +
    "GlobalTableName",
   28     28   
    0,
   29     29   
);
   30     30   
static DESCRIBEGLOBALTABLESETTINGSINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   31     31   
    DESCRIBEGLOBALTABLESETTINGSINPUT_SCHEMA_ID,
   32     32   
    ::aws_smithy_schema::ShapeType::Structure,
   33     33   
    &[&DESCRIBEGLOBALTABLESETTINGSINPUT_MEMBER_GLOBAL_TABLE_NAME],
   34     34   
);
   35     35   
impl DescribeGlobalTableSettingsInput {
   36     36   
    /// The schema for this shape.
   37     37   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEGLOBALTABLESETTINGSINPUT_SCHEMA;
   38     38   
}
   39     39   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeGlobalTableSettingsInput {
   40     40   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   41     41   
    fn serialize_members(
   42     42   
        &self,
   43     43   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   44     44   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   45     45   
        if let Some(ref val) = self.global_table_name {
   46     46   
            ser.write_string(&DESCRIBEGLOBALTABLESETTINGSINPUT_MEMBER_GLOBAL_TABLE_NAME, val)?;
   47     47   
        }
   48     48   
        Ok(())
   49     49   
    }
   50     50   
}
   51     51   
impl DescribeGlobalTableSettingsInput {
   52     52   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   53         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   54         -
        deserializer: &mut D,
          53  +
    pub fn deserialize(
          54  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   55     55   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   56     56   
        #[allow(unused_variables, unused_mut)]
   57     57   
        let mut builder = Self::builder();
   58     58   
        #[allow(
   59     59   
            unused_variables,
   60     60   
            unreachable_code,
   61     61   
            clippy::single_match,
   62     62   
            clippy::match_single_binding,
   63     63   
            clippy::diverging_sub_expression
   64     64   
        )]
   65         -
        deserializer.read_struct(&DESCRIBEGLOBALTABLESETTINGSINPUT_SCHEMA, (), |_, member, deser| {
          65  +
        deserializer.read_struct(&DESCRIBEGLOBALTABLESETTINGSINPUT_SCHEMA, &mut |member, deser| {
   66     66   
            match member.member_index() {
   67     67   
                Some(0) => {
   68     68   
                    builder.global_table_name = Some(deser.read_string(member)?);
   69     69   
                }
   70     70   
                _ => {}
   71     71   
            }
   72     72   
            Ok(())
   73     73   
        })?;
          74  +
        builder.global_table_name = builder.global_table_name.or(Some(String::new()));
   74     75   
        builder
   75     76   
            .build()
   76     77   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   77     78   
    }
   78     79   
}
          80  +
impl DescribeGlobalTableSettingsInput {
          81  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          82  +
    pub fn deserialize_with_response(
          83  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          84  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          85  +
        _status: u16,
          86  +
        _body: &[u8],
          87  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          88  +
        Self::deserialize(deserializer)
          89  +
    }
          90  +
}
   79     91   
impl DescribeGlobalTableSettingsInput {
   80     92   
    /// Creates a new builder-style object to manufacture [`DescribeGlobalTableSettingsInput`](crate::operation::describe_global_table_settings::DescribeGlobalTableSettingsInput).
   81     93   
    pub fn builder() -> crate::operation::describe_global_table_settings::builders::DescribeGlobalTableSettingsInputBuilder {
   82     94   
        crate::operation::describe_global_table_settings::builders::DescribeGlobalTableSettingsInputBuilder::default()
   83     95   
    }
   84     96   
}
   85     97   
   86     98   
/// A builder for [`DescribeGlobalTableSettingsInput`](crate::operation::describe_global_table_settings::DescribeGlobalTableSettingsInput).
   87     99   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   88    100   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_global_table_settings/_describe_global_table_settings_output.rs

@@ -6,6 +143,195 @@
   26     26   
    "com.amazonaws.dynamodb.synthetic",
   27     27   
    "DescribeGlobalTableSettingsOutput",
   28     28   
);
   29     29   
static DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_GLOBAL_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   30     30   
    ::aws_smithy_schema::ShapeId::from_static(
   31     31   
        "com.amazonaws.dynamodb.synthetic#DescribeGlobalTableSettingsOutput$GlobalTableName",
   32     32   
        "com.amazonaws.dynamodb.synthetic",
   33     33   
        "DescribeGlobalTableSettingsOutput",
   34     34   
    ),
   35     35   
    ::aws_smithy_schema::ShapeType::String,
   36         -
    "global_table_name",
          36  +
    "GlobalTableName",
   37     37   
    0,
   38     38   
);
   39     39   
static DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_REPLICA_SETTINGS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   40     40   
    ::aws_smithy_schema::ShapeId::from_static(
   41     41   
        "com.amazonaws.dynamodb.synthetic#DescribeGlobalTableSettingsOutput$ReplicaSettings",
   42     42   
        "com.amazonaws.dynamodb.synthetic",
   43     43   
        "DescribeGlobalTableSettingsOutput",
   44     44   
    ),
   45     45   
    ::aws_smithy_schema::ShapeType::List,
   46         -
    "replica_settings",
          46  +
    "ReplicaSettings",
   47     47   
    1,
   48     48   
);
          49  +
static DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          50  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          51  +
    ::aws_smithy_schema::ShapeType::String,
          52  +
    "request_id",
          53  +
    2,
          54  +
)
          55  +
.with_http_header("x-amzn-requestid");
   49     56   
static DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   50     57   
    DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA_ID,
   51     58   
    ::aws_smithy_schema::ShapeType::Structure,
   52     59   
    &[
   53     60   
        &DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_GLOBAL_TABLE_NAME,
   54     61   
        &DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_REPLICA_SETTINGS,
          62  +
        &DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER__REQUEST_ID,
   55     63   
    ],
   56     64   
);
   57     65   
impl DescribeGlobalTableSettingsOutput {
   58     66   
    /// The schema for this shape.
   59     67   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA;
   60     68   
}
   61     69   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeGlobalTableSettingsOutput {
   62     70   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   63     71   
    fn serialize_members(
   64     72   
        &self,
   65     73   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   66     74   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   67     75   
        if let Some(ref val) = self.global_table_name {
   68     76   
            ser.write_string(&DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_GLOBAL_TABLE_NAME, val)?;
   69     77   
        }
   70     78   
        if let Some(ref val) = self.replica_settings {
   71     79   
            ser.write_list(
   72     80   
                &DESCRIBEGLOBALTABLESETTINGSOUTPUT_MEMBER_REPLICA_SETTINGS,
   73     81   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
   74     82   
                    for item in val {
   75     83   
                        ser.write_struct(crate::types::ReplicaSettingsDescription::SCHEMA, item)?;
   76     84   
                    }
   77     85   
                    Ok(())
   78     86   
                },
   79     87   
            )?;
   80     88   
        }
   81     89   
        Ok(())
   82     90   
    }
   83     91   
}
   84     92   
impl DescribeGlobalTableSettingsOutput {
   85     93   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   86         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   87         -
        deserializer: &mut D,
          94  +
    pub fn deserialize(
          95  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   88     96   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   89     97   
        #[allow(unused_variables, unused_mut)]
   90     98   
        let mut builder = Self::builder();
   91     99   
        #[allow(
   92    100   
            unused_variables,
   93    101   
            unreachable_code,
   94    102   
            clippy::single_match,
   95    103   
            clippy::match_single_binding,
   96    104   
            clippy::diverging_sub_expression
   97    105   
        )]
   98         -
        deserializer.read_struct(&DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA, (), |_, member, deser| {
         106  +
        deserializer.read_struct(&DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA, &mut |member, deser| {
   99    107   
            match member.member_index() {
  100    108   
                Some(0) => {
  101    109   
                    builder.global_table_name = Some(deser.read_string(member)?);
  102    110   
                }
  103    111   
                Some(1) => {
  104    112   
                    builder.replica_settings = Some({
  105         -
                        let container = if let Some(cap) = deser.container_size() {
  106         -
                            Vec::with_capacity(cap)
  107         -
                        } else {
  108         -
                            Vec::new()
  109         -
                        };
  110         -
                        deser.read_list(member, container, |mut list, deser| {
  111         -
                            list.push(crate::types::ReplicaSettingsDescription::deserialize(deser)?);
  112         -
                            Ok(list)
  113         -
                        })?
         113  +
                        let mut container = Vec::new();
         114  +
                        deser.read_list(member, &mut |deser| {
         115  +
                            container.push(crate::types::ReplicaSettingsDescription::deserialize(deser)?);
         116  +
                            Ok(())
         117  +
                        })?;
         118  +
                        container
         119  +
                    });
         120  +
                }
         121  +
                Some(2) => {
         122  +
                    builder._request_id = Some(deser.read_string(member)?);
         123  +
                }
         124  +
                _ => {}
         125  +
            }
         126  +
            Ok(())
         127  +
        })?;
         128  +
        Ok(builder.build())
         129  +
    }
         130  +
}
         131  +
impl DescribeGlobalTableSettingsOutput {
         132  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         133  +
    /// Header-bound members are read directly from headers, avoiding runtime
         134  +
    /// member iteration overhead. Body members are read via the deserializer.
         135  +
    pub fn deserialize_with_response(
         136  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         137  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         138  +
        _status: u16,
         139  +
        _body: &[u8],
         140  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         141  +
        #[allow(unused_variables, unused_mut)]
         142  +
        let mut builder = Self::builder();
         143  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         144  +
            builder._request_id = Some(val.to_string());
         145  +
        }
         146  +
        #[allow(
         147  +
            unused_variables,
         148  +
            unreachable_code,
         149  +
            clippy::single_match,
         150  +
            clippy::match_single_binding,
         151  +
            clippy::diverging_sub_expression
         152  +
        )]
         153  +
        deserializer.read_struct(&DESCRIBEGLOBALTABLESETTINGSOUTPUT_SCHEMA, &mut |member, deser| {
         154  +
            match member.member_index() {
         155  +
                Some(0) => {
         156  +
                    builder.global_table_name = Some(deser.read_string(member)?);
         157  +
                }
         158  +
                Some(1) => {
         159  +
                    builder.replica_settings = Some({
         160  +
                        let mut container = Vec::new();
         161  +
                        deser.read_list(member, &mut |deser| {
         162  +
                            container.push(crate::types::ReplicaSettingsDescription::deserialize(deser)?);
         163  +
                            Ok(())
         164  +
                        })?;
         165  +
                        container
  114    166   
                    });
  115    167   
                }
  116    168   
                _ => {}
  117    169   
            }
  118    170   
            Ok(())
  119    171   
        })?;
  120    172   
        Ok(builder.build())
  121    173   
    }
  122    174   
}
  123    175   
impl ::aws_types::request_id::RequestId for DescribeGlobalTableSettingsOutput {

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_import.rs

@@ -1,1 +40,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `DescribeImport`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct DescribeImport;
    6      6   
impl DescribeImport {
    7      7   
    /// Creates a new `DescribeImport`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_import::DescribeImportInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_import::DescribeImportOutput::SCHEMA;
   11     15   
    pub(crate) async fn orchestrate(
   12     16   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     17   
        input: crate::operation::describe_import::DescribeImportInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::describe_import::DescribeImportOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::describe_import::DescribeImportError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -118,122 +245,286 @@
  138    142   
                crate::operation::describe_import::DescribeImportError,
  139    143   
            >::new());
  140    144   
  141    145   
        ::std::borrow::Cow::Owned(rcb)
  142    146   
    }
  143    147   
}
  144    148   
  145    149   
#[derive(Debug)]
  146    150   
struct DescribeImportResponseDeserializer;
  147    151   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for DescribeImportResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         152  +
    fn deserialize_nonstreaming_with_config(
  149    153   
        &self,
  150    154   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         155  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    156   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    157   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153         -
        let headers = response.headers();
  154         -
        let body = response.body().bytes().expect("body loaded");
  155    158   
        #[allow(unused_mut)]
  156    159   
        let mut force_error = false;
  157    160   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158         -
        let parse_result = if !success && status != 200 || force_error {
  159         -
            crate::protocol_serde::shape_describe_import::de_describe_import_http_error(status, headers, body)
  160         -
        } else {
  161         -
            crate::protocol_serde::shape_describe_import::de_describe_import_http_response(status, headers, body)
         161  +
        if !success && status != 200 || force_error {
         162  +
            let headers = response.headers();
         163  +
            let body = response.body().bytes().expect("body loaded");
         164  +
            #[allow(unused_mut)]
         165  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         166  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         167  +
            })?;
         168  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         169  +
            let generic = generic_builder.build();
         170  +
            let error_code = match generic.code() {
         171  +
                ::std::option::Option::Some(code) => code,
         172  +
                ::std::option::Option::None => {
         173  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         174  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(crate::operation::describe_import::DescribeImportError::unhandled(
         175  +
                            generic,
         176  +
                        )),
         177  +
                    ))
         178  +
                }
         179  +
            };
         180  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         181  +
            let protocol = _cfg
         182  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         183  +
                .expect("a SharedClientProtocol is required");
         184  +
            let err = match error_code {
         185  +
                "ImportNotFoundException" => crate::operation::describe_import::DescribeImportError::ImportNotFoundException({
         186  +
                    let mut tmp = match protocol
         187  +
                        .deserialize_response(response, crate::types::error::ImportNotFoundException::SCHEMA, _cfg)
         188  +
                        .and_then(|mut deser| {
         189  +
                            crate::types::error::ImportNotFoundException::deserialize_with_response(
         190  +
                                &mut *deser,
         191  +
                                response.headers(),
         192  +
                                response.status().into(),
         193  +
                                body,
         194  +
                            )
         195  +
                        }) {
         196  +
                        ::std::result::Result::Ok(val) => val,
         197  +
                        ::std::result::Result::Err(e) => {
         198  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         199  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         200  +
                            ))
         201  +
                        }
         202  +
                    };
         203  +
                    tmp.meta = generic;
         204  +
                    if tmp.message.is_none() {
         205  +
                        tmp.message = _error_message;
         206  +
                    }
         207  +
                    tmp
         208  +
                }),
         209  +
                _ => crate::operation::describe_import::DescribeImportError::generic(generic),
  162    210   
            };
  163         -
        crate::protocol_serde::type_erase_result(parse_result)
         211  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         212  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         213  +
            ))
         214  +
        } else {
         215  +
            let protocol = _cfg
         216  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         217  +
                .expect("a SharedClientProtocol is required");
         218  +
            let mut deser = protocol
         219  +
                .deserialize_response(response, DescribeImport::OUTPUT_SCHEMA, _cfg)
         220  +
                .map_err(|e| {
         221  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         222  +
                })?;
         223  +
            let body = response.body().bytes().expect("body loaded");
         224  +
            let output = crate::operation::describe_import::DescribeImportOutput::deserialize_with_response(
         225  +
                &mut *deser,
         226  +
                response.headers(),
         227  +
                response.status().into(),
         228  +
                body,
         229  +
            )
         230  +
            .map_err(|e| {
         231  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         232  +
            })?;
         233  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         234  +
        }
  164    235   
    }
  165    236   
}
  166    237   
#[derive(Debug)]
  167    238   
struct DescribeImportRequestSerializer;
  168    239   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for DescribeImportRequestSerializer {
  169    240   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  170    241   
    fn serialize_input(
  171    242   
        &self,
  172    243   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  173    244   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  174    245   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  175    246   
        let input = input
  176    247   
            .downcast::<crate::operation::describe_import::DescribeImportInput>()
  177    248   
            .expect("correct type");
  178         -
        let _header_serialization_settings = _cfg
  179         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  180         -
            .cloned()
  181         -
            .unwrap_or_default();
  182         -
        let mut request_builder = {
  183         -
            #[allow(clippy::uninlined_format_args)]
  184         -
            fn uri_base(
  185         -
                _input: &crate::operation::describe_import::DescribeImportInput,
  186         -
                output: &mut ::std::string::String,
  187         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  188         -
                use ::std::fmt::Write as _;
  189         -
                ::std::write!(output, "/").expect("formatting should succeed");
  190         -
                ::std::result::Result::Ok(())
  191         -
            }
  192         -
            #[allow(clippy::unnecessary_wraps)]
  193         -
            fn update_http_builder(
  194         -
                input: &crate::operation::describe_import::DescribeImportInput,
  195         -
                builder: ::http_1x::request::Builder,
  196         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  197         -
                let mut uri = ::std::string::String::new();
  198         -
                uri_base(input, &mut uri)?;
  199         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  200         -
            }
  201         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  202         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.0");
  203         -
            builder = _header_serialization_settings.set_default_header(
  204         -
                builder,
  205         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  206         -
                "DynamoDB_20120810.DescribeImport",
  207         -
            );
  208         -
            builder
  209         -
        };
  210         -
        let body = ::aws_smithy_types::body::SdkBody::from(crate::protocol_serde::shape_describe_import::ser_describe_import_input(&input)?);
  211         -
        if let Some(content_length) = body.content_length() {
  212         -
            let content_length = content_length.to_string();
  213         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  214         -
        }
  215         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         249  +
        let protocol = _cfg
         250  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         251  +
            .expect("a SharedClientProtocol is required");
         252  +
        let mut request = protocol
         253  +
            .serialize_request(&input, DescribeImport::INPUT_SCHEMA, "", _cfg)
         254  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         255  +
         256  +
        return ::std::result::Result::Ok(request);
  216    257   
    }
  217    258   
}
  218    259   
#[derive(Debug)]
  219    260   
struct DescribeImportEndpointParamsInterceptor;
  220    261   
  221    262   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for DescribeImportEndpointParamsInterceptor {
  222    263   
    fn name(&self) -> &'static str {
  223    264   
        "DescribeImportEndpointParamsInterceptor"
  224    265   
    }
  225    266   

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_import/_describe_import_input.rs

@@ -1,1 +108,120 @@
   17     17   
    "com.amazonaws.dynamodb.synthetic",
   18     18   
    "DescribeImportInput",
   19     19   
);
   20     20   
static DESCRIBEIMPORTINPUT_MEMBER_IMPORT_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   21     21   
    ::aws_smithy_schema::ShapeId::from_static(
   22     22   
        "com.amazonaws.dynamodb.synthetic#DescribeImportInput$ImportArn",
   23     23   
        "com.amazonaws.dynamodb.synthetic",
   24     24   
        "DescribeImportInput",
   25     25   
    ),
   26     26   
    ::aws_smithy_schema::ShapeType::String,
   27         -
    "import_arn",
          27  +
    "ImportArn",
   28     28   
    0,
   29     29   
);
   30     30   
static DESCRIBEIMPORTINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   31     31   
    DESCRIBEIMPORTINPUT_SCHEMA_ID,
   32     32   
    ::aws_smithy_schema::ShapeType::Structure,
   33     33   
    &[&DESCRIBEIMPORTINPUT_MEMBER_IMPORT_ARN],
   34     34   
);
   35     35   
impl DescribeImportInput {
   36     36   
    /// The schema for this shape.
   37     37   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEIMPORTINPUT_SCHEMA;
   38     38   
}
   39     39   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeImportInput {
   40     40   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   41     41   
    fn serialize_members(
   42     42   
        &self,
   43     43   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   44     44   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   45     45   
        if let Some(ref val) = self.import_arn {
   46     46   
            ser.write_string(&DESCRIBEIMPORTINPUT_MEMBER_IMPORT_ARN, val)?;
   47     47   
        }
   48     48   
        Ok(())
   49     49   
    }
   50     50   
}
   51     51   
impl DescribeImportInput {
   52     52   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   53         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   54         -
        deserializer: &mut D,
          53  +
    pub fn deserialize(
          54  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   55     55   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   56     56   
        #[allow(unused_variables, unused_mut)]
   57     57   
        let mut builder = Self::builder();
   58     58   
        #[allow(
   59     59   
            unused_variables,
   60     60   
            unreachable_code,
   61     61   
            clippy::single_match,
   62     62   
            clippy::match_single_binding,
   63     63   
            clippy::diverging_sub_expression
   64     64   
        )]
   65         -
        deserializer.read_struct(&DESCRIBEIMPORTINPUT_SCHEMA, (), |_, member, deser| {
          65  +
        deserializer.read_struct(&DESCRIBEIMPORTINPUT_SCHEMA, &mut |member, deser| {
   66     66   
            match member.member_index() {
   67     67   
                Some(0) => {
   68     68   
                    builder.import_arn = Some(deser.read_string(member)?);
   69     69   
                }
   70     70   
                _ => {}
   71     71   
            }
   72     72   
            Ok(())
   73     73   
        })?;
          74  +
        builder.import_arn = builder.import_arn.or(Some(String::new()));
   74     75   
        builder
   75     76   
            .build()
   76     77   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   77     78   
    }
   78     79   
}
          80  +
impl DescribeImportInput {
          81  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          82  +
    pub fn deserialize_with_response(
          83  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          84  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          85  +
        _status: u16,
          86  +
        _body: &[u8],
          87  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          88  +
        Self::deserialize(deserializer)
          89  +
    }
          90  +
}
   79     91   
impl DescribeImportInput {
   80     92   
    /// Creates a new builder-style object to manufacture [`DescribeImportInput`](crate::operation::describe_import::DescribeImportInput).
   81     93   
    pub fn builder() -> crate::operation::describe_import::builders::DescribeImportInputBuilder {
   82     94   
        crate::operation::describe_import::builders::DescribeImportInputBuilder::default()
   83     95   
    }
   84     96   
}
   85     97   
   86     98   
/// A builder for [`DescribeImportInput`](crate::operation::describe_import::DescribeImportInput).
   87     99   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   88    100   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_import/_describe_import_output.rs

@@ -1,1 +96,143 @@
   18     18   
    "com.amazonaws.dynamodb.synthetic",
   19     19   
    "DescribeImportOutput",
   20     20   
);
   21     21   
static DESCRIBEIMPORTOUTPUT_MEMBER_IMPORT_TABLE_DESCRIPTION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   22     22   
    ::aws_smithy_schema::ShapeId::from_static(
   23     23   
        "com.amazonaws.dynamodb.synthetic#DescribeImportOutput$ImportTableDescription",
   24     24   
        "com.amazonaws.dynamodb.synthetic",
   25     25   
        "DescribeImportOutput",
   26     26   
    ),
   27     27   
    ::aws_smithy_schema::ShapeType::Structure,
   28         -
    "import_table_description",
          28  +
    "ImportTableDescription",
   29     29   
    0,
   30     30   
);
          31  +
static DESCRIBEIMPORTOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          32  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          33  +
    ::aws_smithy_schema::ShapeType::String,
          34  +
    "request_id",
          35  +
    1,
          36  +
)
          37  +
.with_http_header("x-amzn-requestid");
   31     38   
static DESCRIBEIMPORTOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   32     39   
    DESCRIBEIMPORTOUTPUT_SCHEMA_ID,
   33     40   
    ::aws_smithy_schema::ShapeType::Structure,
   34         -
    &[&DESCRIBEIMPORTOUTPUT_MEMBER_IMPORT_TABLE_DESCRIPTION],
          41  +
    &[
          42  +
        &DESCRIBEIMPORTOUTPUT_MEMBER_IMPORT_TABLE_DESCRIPTION,
          43  +
        &DESCRIBEIMPORTOUTPUT_MEMBER__REQUEST_ID,
          44  +
    ],
   35     45   
);
   36     46   
impl DescribeImportOutput {
   37     47   
    /// The schema for this shape.
   38     48   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEIMPORTOUTPUT_SCHEMA;
   39     49   
}
   40     50   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeImportOutput {
   41     51   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   42     52   
    fn serialize_members(
   43     53   
        &self,
   44     54   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   45     55   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   46     56   
        if let Some(ref val) = self.import_table_description {
   47     57   
            ser.write_struct(&DESCRIBEIMPORTOUTPUT_MEMBER_IMPORT_TABLE_DESCRIPTION, val)?;
   48     58   
        }
   49     59   
        Ok(())
   50     60   
    }
   51     61   
}
   52     62   
impl DescribeImportOutput {
   53     63   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   54         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   55         -
        deserializer: &mut D,
          64  +
    pub fn deserialize(
          65  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   56     66   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   57     67   
        #[allow(unused_variables, unused_mut)]
   58     68   
        let mut builder = Self::builder();
   59     69   
        #[allow(
   60     70   
            unused_variables,
   61     71   
            unreachable_code,
   62     72   
            clippy::single_match,
   63     73   
            clippy::match_single_binding,
   64     74   
            clippy::diverging_sub_expression
   65     75   
        )]
   66         -
        deserializer.read_struct(&DESCRIBEIMPORTOUTPUT_SCHEMA, (), |_, member, deser| {
          76  +
        deserializer.read_struct(&DESCRIBEIMPORTOUTPUT_SCHEMA, &mut |member, deser| {
          77  +
            match member.member_index() {
          78  +
                Some(0) => {
          79  +
                    builder.import_table_description = Some(crate::types::ImportTableDescription::deserialize(deser)?);
          80  +
                }
          81  +
                Some(1) => {
          82  +
                    builder._request_id = Some(deser.read_string(member)?);
          83  +
                }
          84  +
                _ => {}
          85  +
            }
          86  +
            Ok(())
          87  +
        })?;
          88  +
        Ok(builder.build())
          89  +
    }
          90  +
}
          91  +
impl DescribeImportOutput {
          92  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          93  +
    /// Header-bound members are read directly from headers, avoiding runtime
          94  +
    /// member iteration overhead. Body members are read via the deserializer.
          95  +
    pub fn deserialize_with_response(
          96  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          97  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          98  +
        _status: u16,
          99  +
        _body: &[u8],
         100  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         101  +
        #[allow(unused_variables, unused_mut)]
         102  +
        let mut builder = Self::builder();
         103  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         104  +
            builder._request_id = Some(val.to_string());
         105  +
        }
         106  +
        #[allow(
         107  +
            unused_variables,
         108  +
            unreachable_code,
         109  +
            clippy::single_match,
         110  +
            clippy::match_single_binding,
         111  +
            clippy::diverging_sub_expression
         112  +
        )]
         113  +
        deserializer.read_struct(&DESCRIBEIMPORTOUTPUT_SCHEMA, &mut |member, deser| {
   67    114   
            match member.member_index() {
   68    115   
                Some(0) => {
   69    116   
                    builder.import_table_description = Some(crate::types::ImportTableDescription::deserialize(deser)?);
   70    117   
                }
   71    118   
                _ => {}
   72    119   
            }
   73    120   
            Ok(())
   74    121   
        })?;
   75    122   
        Ok(builder.build())
   76    123   
    }

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_kinesis_streaming_destination.rs

@@ -1,1 +40,46 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `DescribeKinesisStreamingDestination`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct DescribeKinesisStreamingDestination;
    6      6   
impl DescribeKinesisStreamingDestination {
    7      7   
    /// Creates a new `DescribeKinesisStreamingDestination`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          13  +
        crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput::SCHEMA;
          14  +
    /// The schema for this operation's output shape.
          15  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          16  +
        crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationOutput::SCHEMA;
   11     17   
    pub(crate) async fn orchestrate(
   12     18   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     19   
        input: crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput,
   14     20   
    ) -> ::std::result::Result<
   15     21   
        crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationOutput,
   16     22   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     23   
            crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError,
   18     24   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     25   
        >,
   20     26   
    > {
@@ -124,130 +257,349 @@
  144    150   
                crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError,
  145    151   
            >::new());
  146    152   
  147    153   
        ::std::borrow::Cow::Owned(rcb)
  148    154   
    }
  149    155   
}
  150    156   
  151    157   
#[derive(Debug)]
  152    158   
struct DescribeKinesisStreamingDestinationResponseDeserializer;
  153    159   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for DescribeKinesisStreamingDestinationResponseDeserializer {
  154         -
    fn deserialize_nonstreaming(
         160  +
    fn deserialize_nonstreaming_with_config(
  155    161   
        &self,
  156    162   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         163  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  157    164   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  158    165   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  159         -
        let headers = response.headers();
  160         -
        let body = response.body().bytes().expect("body loaded");
  161    166   
        #[allow(unused_mut)]
  162    167   
        let mut force_error = false;
  163    168   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  164         -
        let parse_result = if !success && status != 200 || force_error {
  165         -
            crate::protocol_serde::shape_describe_kinesis_streaming_destination::de_describe_kinesis_streaming_destination_http_error(
  166         -
                status, headers, body,
         169  +
        if !success && status != 200 || force_error {
         170  +
            let headers = response.headers();
         171  +
            let body = response.body().bytes().expect("body loaded");
         172  +
            #[allow(unused_mut)]
         173  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         174  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         175  +
            })?;
         176  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         177  +
            let generic = generic_builder.build();
         178  +
            let error_code = match generic.code() {
         179  +
                ::std::option::Option::Some(code) => code,
         180  +
                ::std::option::Option::None => {
         181  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         182  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(
         183  +
                            crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError::unhandled(generic),
         184  +
                        ),
         185  +
                    ))
         186  +
                }
         187  +
            };
         188  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         189  +
            let protocol = _cfg
         190  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         191  +
                .expect("a SharedClientProtocol is required");
         192  +
            let err = match error_code {
         193  +
                "InternalServerError" => {
         194  +
                    crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError::InternalServerError({
         195  +
                        let mut tmp = match protocol
         196  +
                            .deserialize_response(response, crate::types::error::InternalServerError::SCHEMA, _cfg)
         197  +
                            .and_then(|mut deser| {
         198  +
                                crate::types::error::InternalServerError::deserialize_with_response(
         199  +
                                    &mut *deser,
         200  +
                                    response.headers(),
         201  +
                                    response.status().into(),
         202  +
                                    body,
  167    203   
                                )
  168         -
        } else {
  169         -
            crate::protocol_serde::shape_describe_kinesis_streaming_destination::de_describe_kinesis_streaming_destination_http_response(
  170         -
                status, headers, body,
         204  +
                            }) {
         205  +
                            ::std::result::Result::Ok(val) => val,
         206  +
                            ::std::result::Result::Err(e) => {
         207  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         208  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         209  +
                                ))
         210  +
                            }
         211  +
                        };
         212  +
                        tmp.meta = generic;
         213  +
                        if tmp.message.is_none() {
         214  +
                            tmp.message = _error_message;
         215  +
                        }
         216  +
                        tmp
         217  +
                    })
         218  +
                }
         219  +
                "InvalidEndpointException" => {
         220  +
                    crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError::InvalidEndpointException({
         221  +
                        let mut tmp = match protocol
         222  +
                            .deserialize_response(response, crate::types::error::InvalidEndpointException::SCHEMA, _cfg)
         223  +
                            .and_then(|mut deser| {
         224  +
                                crate::types::error::InvalidEndpointException::deserialize_with_response(
         225  +
                                    &mut *deser,
         226  +
                                    response.headers(),
         227  +
                                    response.status().into(),
         228  +
                                    body,
  171    229   
                                )
         230  +
                            }) {
         231  +
                            ::std::result::Result::Ok(val) => val,
         232  +
                            ::std::result::Result::Err(e) => {
         233  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         234  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         235  +
                                ))
         236  +
                            }
  172    237   
                        };
  173         -
        crate::protocol_serde::type_erase_result(parse_result)
         238  +
                        tmp.meta = generic;
         239  +
                        if tmp.message.is_none() {
         240  +
                            tmp.message = _error_message;
         241  +
                        }
         242  +
                        tmp
         243  +
                    })
         244  +
                }
         245  +
                "ResourceNotFoundException" => {
         246  +
                    crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError::ResourceNotFoundException({
         247  +
                        let mut tmp = match protocol
         248  +
                            .deserialize_response(response, crate::types::error::ResourceNotFoundException::SCHEMA, _cfg)
         249  +
                            .and_then(|mut deser| {
         250  +
                                crate::types::error::ResourceNotFoundException::deserialize_with_response(
         251  +
                                    &mut *deser,
         252  +
                                    response.headers(),
         253  +
                                    response.status().into(),
         254  +
                                    body,
         255  +
                                )
         256  +
                            }) {
         257  +
                            ::std::result::Result::Ok(val) => val,
         258  +
                            ::std::result::Result::Err(e) => {
         259  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         260  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         261  +
                                ))
         262  +
                            }
         263  +
                        };
         264  +
                        tmp.meta = generic;
         265  +
                        if tmp.message.is_none() {
         266  +
                            tmp.message = _error_message;
         267  +
                        }
         268  +
                        tmp
         269  +
                    })
         270  +
                }
         271  +
                _ => crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationError::generic(generic),
         272  +
            };
         273  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         274  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         275  +
            ))
         276  +
        } else {
         277  +
            let protocol = _cfg
         278  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         279  +
                .expect("a SharedClientProtocol is required");
         280  +
            let mut deser = protocol
         281  +
                .deserialize_response(response, DescribeKinesisStreamingDestination::OUTPUT_SCHEMA, _cfg)
         282  +
                .map_err(|e| {
         283  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         284  +
                })?;
         285  +
            let body = response.body().bytes().expect("body loaded");
         286  +
            let output =
         287  +
                crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationOutput::deserialize_with_response(
         288  +
                    &mut *deser,
         289  +
                    response.headers(),
         290  +
                    response.status().into(),
         291  +
                    body,
         292  +
                )
         293  +
                .map_err(|e| {
         294  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         295  +
                })?;
         296  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         297  +
        }
  174    298   
    }
  175    299   
}
  176    300   
#[derive(Debug)]
  177    301   
struct DescribeKinesisStreamingDestinationRequestSerializer;
  178    302   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for DescribeKinesisStreamingDestinationRequestSerializer {
  179    303   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  180    304   
    fn serialize_input(
  181    305   
        &self,
  182    306   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  183    307   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  184    308   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  185    309   
        let input = input
  186    310   
            .downcast::<crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput>()
  187    311   
            .expect("correct type");
  188         -
        let _header_serialization_settings = _cfg
  189         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  190         -
            .cloned()
  191         -
            .unwrap_or_default();
  192         -
        let mut request_builder = {
  193         -
            #[allow(clippy::uninlined_format_args)]
  194         -
            fn uri_base(
  195         -
                _input: &crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput,
  196         -
                output: &mut ::std::string::String,
  197         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  198         -
                use ::std::fmt::Write as _;
  199         -
                ::std::write!(output, "/").expect("formatting should succeed");
  200         -
                ::std::result::Result::Ok(())
  201         -
            }
  202         -
            #[allow(clippy::unnecessary_wraps)]
  203         -
            fn update_http_builder(
  204         -
                input: &crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput,
  205         -
                builder: ::http_1x::request::Builder,
  206         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  207         -
                let mut uri = ::std::string::String::new();
  208         -
                uri_base(input, &mut uri)?;
  209         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  210         -
            }
  211         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  212         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.0");
  213         -
            builder = _header_serialization_settings.set_default_header(
  214         -
                builder,
  215         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  216         -
                "DynamoDB_20120810.DescribeKinesisStreamingDestination",
  217         -
            );
  218         -
            builder
  219         -
        };
  220         -
        let body = ::aws_smithy_types::body::SdkBody::from(
  221         -
            crate::protocol_serde::shape_describe_kinesis_streaming_destination::ser_describe_kinesis_streaming_destination_input(&input)?,
  222         -
        );
  223         -
        if let Some(content_length) = body.content_length() {
  224         -
            let content_length = content_length.to_string();
  225         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  226         -
        }
  227         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         312  +
        let protocol = _cfg
         313  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         314  +
            .expect("a SharedClientProtocol is required");
         315  +
        let mut request = protocol
         316  +
            .serialize_request(&input, DescribeKinesisStreamingDestination::INPUT_SCHEMA, "", _cfg)
         317  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         318  +
         319  +
        return ::std::result::Result::Ok(request);
  228    320   
    }
  229    321   
}
  230    322   
#[derive(Debug)]
  231    323   
struct DescribeKinesisStreamingDestinationEndpointParamsInterceptor;
  232    324   
  233    325   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for DescribeKinesisStreamingDestinationEndpointParamsInterceptor {
  234    326   
    fn name(&self) -> &'static str {
  235    327   
        "DescribeKinesisStreamingDestinationEndpointParamsInterceptor"
  236    328   
    }
  237    329   

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_kinesis_streaming_destination/_describe_kinesis_streaming_destination_input.rs

@@ -1,1 +108,120 @@
   17     17   
    "com.amazonaws.dynamodb.synthetic",
   18     18   
    "DescribeKinesisStreamingDestinationInput",
   19     19   
);
   20     20   
static DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_MEMBER_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   21     21   
    ::aws_smithy_schema::ShapeId::from_static(
   22     22   
        "com.amazonaws.dynamodb.synthetic#DescribeKinesisStreamingDestinationInput$TableName",
   23     23   
        "com.amazonaws.dynamodb.synthetic",
   24     24   
        "DescribeKinesisStreamingDestinationInput",
   25     25   
    ),
   26     26   
    ::aws_smithy_schema::ShapeType::String,
   27         -
    "table_name",
          27  +
    "TableName",
   28     28   
    0,
   29     29   
);
   30     30   
static DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   31     31   
    DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_SCHEMA_ID,
   32     32   
    ::aws_smithy_schema::ShapeType::Structure,
   33     33   
    &[&DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_MEMBER_TABLE_NAME],
   34     34   
);
   35     35   
impl DescribeKinesisStreamingDestinationInput {
   36     36   
    /// The schema for this shape.
   37     37   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_SCHEMA;
   38     38   
}
   39     39   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeKinesisStreamingDestinationInput {
   40     40   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   41     41   
    fn serialize_members(
   42     42   
        &self,
   43     43   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   44     44   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   45     45   
        if let Some(ref val) = self.table_name {
   46     46   
            ser.write_string(&DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_MEMBER_TABLE_NAME, val)?;
   47     47   
        }
   48     48   
        Ok(())
   49     49   
    }
   50     50   
}
   51     51   
impl DescribeKinesisStreamingDestinationInput {
   52     52   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   53         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   54         -
        deserializer: &mut D,
          53  +
    pub fn deserialize(
          54  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   55     55   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   56     56   
        #[allow(unused_variables, unused_mut)]
   57     57   
        let mut builder = Self::builder();
   58     58   
        #[allow(
   59     59   
            unused_variables,
   60     60   
            unreachable_code,
   61     61   
            clippy::single_match,
   62     62   
            clippy::match_single_binding,
   63     63   
            clippy::diverging_sub_expression
   64     64   
        )]
   65         -
        deserializer.read_struct(&DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_SCHEMA, (), |_, member, deser| {
          65  +
        deserializer.read_struct(&DESCRIBEKINESISSTREAMINGDESTINATIONINPUT_SCHEMA, &mut |member, deser| {
   66     66   
            match member.member_index() {
   67     67   
                Some(0) => {
   68     68   
                    builder.table_name = Some(deser.read_string(member)?);
   69     69   
                }
   70     70   
                _ => {}
   71     71   
            }
   72     72   
            Ok(())
   73     73   
        })?;
          74  +
        builder.table_name = builder.table_name.or(Some(String::new()));
   74     75   
        builder
   75     76   
            .build()
   76     77   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   77     78   
    }
   78     79   
}
          80  +
impl DescribeKinesisStreamingDestinationInput {
          81  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          82  +
    pub fn deserialize_with_response(
          83  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          84  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          85  +
        _status: u16,
          86  +
        _body: &[u8],
          87  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          88  +
        Self::deserialize(deserializer)
          89  +
    }
          90  +
}
   79     91   
impl DescribeKinesisStreamingDestinationInput {
   80     92   
    /// Creates a new builder-style object to manufacture [`DescribeKinesisStreamingDestinationInput`](crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput).
   81     93   
    pub fn builder() -> crate::operation::describe_kinesis_streaming_destination::builders::DescribeKinesisStreamingDestinationInputBuilder {
   82     94   
        crate::operation::describe_kinesis_streaming_destination::builders::DescribeKinesisStreamingDestinationInputBuilder::default()
   83     95   
    }
   84     96   
}
   85     97   
   86     98   
/// A builder for [`DescribeKinesisStreamingDestinationInput`](crate::operation::describe_kinesis_streaming_destination::DescribeKinesisStreamingDestinationInput).
   87     99   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   88    100   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_kinesis_streaming_destination/_describe_kinesis_streaming_destination_output.rs

@@ -6,6 +144,196 @@
   26     26   
    "com.amazonaws.dynamodb.synthetic",
   27     27   
    "DescribeKinesisStreamingDestinationOutput",
   28     28   
);
   29     29   
static DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   30     30   
    ::aws_smithy_schema::ShapeId::from_static(
   31     31   
        "com.amazonaws.dynamodb.synthetic#DescribeKinesisStreamingDestinationOutput$TableName",
   32     32   
        "com.amazonaws.dynamodb.synthetic",
   33     33   
        "DescribeKinesisStreamingDestinationOutput",
   34     34   
    ),
   35     35   
    ::aws_smithy_schema::ShapeType::String,
   36         -
    "table_name",
          36  +
    "TableName",
   37     37   
    0,
   38     38   
);
   39     39   
static DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_KINESIS_DATA_STREAM_DESTINATIONS: ::aws_smithy_schema::Schema =
   40     40   
    ::aws_smithy_schema::Schema::new_member(
   41     41   
        ::aws_smithy_schema::ShapeId::from_static(
   42     42   
            "com.amazonaws.dynamodb.synthetic#DescribeKinesisStreamingDestinationOutput$KinesisDataStreamDestinations",
   43     43   
            "com.amazonaws.dynamodb.synthetic",
   44     44   
            "DescribeKinesisStreamingDestinationOutput",
   45     45   
        ),
   46     46   
        ::aws_smithy_schema::ShapeType::List,
   47         -
        "kinesis_data_stream_destinations",
          47  +
        "KinesisDataStreamDestinations",
   48     48   
        1,
   49     49   
    );
          50  +
static DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          51  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          52  +
    ::aws_smithy_schema::ShapeType::String,
          53  +
    "request_id",
          54  +
    2,
          55  +
)
          56  +
.with_http_header("x-amzn-requestid");
   50     57   
static DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   51     58   
    DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA_ID,
   52     59   
    ::aws_smithy_schema::ShapeType::Structure,
   53     60   
    &[
   54     61   
        &DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_TABLE_NAME,
   55     62   
        &DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_KINESIS_DATA_STREAM_DESTINATIONS,
          63  +
        &DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER__REQUEST_ID,
   56     64   
    ],
   57     65   
);
   58     66   
impl DescribeKinesisStreamingDestinationOutput {
   59     67   
    /// The schema for this shape.
   60     68   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA;
   61     69   
}
   62     70   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeKinesisStreamingDestinationOutput {
   63     71   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   64     72   
    fn serialize_members(
   65     73   
        &self,
   66     74   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   67     75   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   68     76   
        if let Some(ref val) = self.table_name {
   69     77   
            ser.write_string(&DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_TABLE_NAME, val)?;
   70     78   
        }
   71     79   
        if let Some(ref val) = self.kinesis_data_stream_destinations {
   72     80   
            ser.write_list(
   73     81   
                &DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_MEMBER_KINESIS_DATA_STREAM_DESTINATIONS,
   74     82   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
   75     83   
                    for item in val {
   76     84   
                        ser.write_struct(crate::types::KinesisDataStreamDestination::SCHEMA, item)?;
   77     85   
                    }
   78     86   
                    Ok(())
   79     87   
                },
   80     88   
            )?;
   81     89   
        }
   82     90   
        Ok(())
   83     91   
    }
   84     92   
}
   85     93   
impl DescribeKinesisStreamingDestinationOutput {
   86     94   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   87         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   88         -
        deserializer: &mut D,
          95  +
    pub fn deserialize(
          96  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   89     97   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   90     98   
        #[allow(unused_variables, unused_mut)]
   91     99   
        let mut builder = Self::builder();
   92    100   
        #[allow(
   93    101   
            unused_variables,
   94    102   
            unreachable_code,
   95    103   
            clippy::single_match,
   96    104   
            clippy::match_single_binding,
   97    105   
            clippy::diverging_sub_expression
   98    106   
        )]
   99         -
        deserializer.read_struct(&DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA, (), |_, member, deser| {
         107  +
        deserializer.read_struct(&DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA, &mut |member, deser| {
  100    108   
            match member.member_index() {
  101    109   
                Some(0) => {
  102    110   
                    builder.table_name = Some(deser.read_string(member)?);
  103    111   
                }
  104    112   
                Some(1) => {
  105    113   
                    builder.kinesis_data_stream_destinations = Some({
  106         -
                        let container = if let Some(cap) = deser.container_size() {
  107         -
                            Vec::with_capacity(cap)
  108         -
                        } else {
  109         -
                            Vec::new()
  110         -
                        };
  111         -
                        deser.read_list(member, container, |mut list, deser| {
  112         -
                            list.push(crate::types::KinesisDataStreamDestination::deserialize(deser)?);
  113         -
                            Ok(list)
  114         -
                        })?
         114  +
                        let mut container = Vec::new();
         115  +
                        deser.read_list(member, &mut |deser| {
         116  +
                            container.push(crate::types::KinesisDataStreamDestination::deserialize(deser)?);
         117  +
                            Ok(())
         118  +
                        })?;
         119  +
                        container
         120  +
                    });
         121  +
                }
         122  +
                Some(2) => {
         123  +
                    builder._request_id = Some(deser.read_string(member)?);
         124  +
                }
         125  +
                _ => {}
         126  +
            }
         127  +
            Ok(())
         128  +
        })?;
         129  +
        Ok(builder.build())
         130  +
    }
         131  +
}
         132  +
impl DescribeKinesisStreamingDestinationOutput {
         133  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         134  +
    /// Header-bound members are read directly from headers, avoiding runtime
         135  +
    /// member iteration overhead. Body members are read via the deserializer.
         136  +
    pub fn deserialize_with_response(
         137  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         138  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         139  +
        _status: u16,
         140  +
        _body: &[u8],
         141  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         142  +
        #[allow(unused_variables, unused_mut)]
         143  +
        let mut builder = Self::builder();
         144  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         145  +
            builder._request_id = Some(val.to_string());
         146  +
        }
         147  +
        #[allow(
         148  +
            unused_variables,
         149  +
            unreachable_code,
         150  +
            clippy::single_match,
         151  +
            clippy::match_single_binding,
         152  +
            clippy::diverging_sub_expression
         153  +
        )]
         154  +
        deserializer.read_struct(&DESCRIBEKINESISSTREAMINGDESTINATIONOUTPUT_SCHEMA, &mut |member, deser| {
         155  +
            match member.member_index() {
         156  +
                Some(0) => {
         157  +
                    builder.table_name = Some(deser.read_string(member)?);
         158  +
                }
         159  +
                Some(1) => {
         160  +
                    builder.kinesis_data_stream_destinations = Some({
         161  +
                        let mut container = Vec::new();
         162  +
                        deser.read_list(member, &mut |deser| {
         163  +
                            container.push(crate::types::KinesisDataStreamDestination::deserialize(deser)?);
         164  +
                            Ok(())
         165  +
                        })?;
         166  +
                        container
  115    167   
                    });
  116    168   
                }
  117    169   
                _ => {}
  118    170   
            }
  119    171   
            Ok(())
  120    172   
        })?;
  121    173   
        Ok(builder.build())
  122    174   
    }
  123    175   
}
  124    176   
impl ::aws_types::request_id::RequestId for DescribeKinesisStreamingDestinationOutput {

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_limits.rs

@@ -1,1 +40,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `DescribeLimits`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct DescribeLimits;
    6      6   
impl DescribeLimits {
    7      7   
    /// Creates a new `DescribeLimits`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_limits::DescribeLimitsInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_limits::DescribeLimitsOutput::SCHEMA;
   11     15   
    pub(crate) async fn orchestrate(
   12     16   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     17   
        input: crate::operation::describe_limits::DescribeLimitsInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::describe_limits::DescribeLimitsOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::describe_limits::DescribeLimitsError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -118,122 +242,310 @@
  138    142   
                crate::operation::describe_limits::DescribeLimitsError,
  139    143   
            >::new());
  140    144   
  141    145   
        ::std::borrow::Cow::Owned(rcb)
  142    146   
    }
  143    147   
}
  144    148   
  145    149   
#[derive(Debug)]
  146    150   
struct DescribeLimitsResponseDeserializer;
  147    151   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for DescribeLimitsResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         152  +
    fn deserialize_nonstreaming_with_config(
  149    153   
        &self,
  150    154   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         155  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    156   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    157   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153         -
        let headers = response.headers();
  154         -
        let body = response.body().bytes().expect("body loaded");
  155    158   
        #[allow(unused_mut)]
  156    159   
        let mut force_error = false;
  157    160   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158         -
        let parse_result = if !success && status != 200 || force_error {
  159         -
            crate::protocol_serde::shape_describe_limits::de_describe_limits_http_error(status, headers, body)
  160         -
        } else {
  161         -
            crate::protocol_serde::shape_describe_limits::de_describe_limits_http_response(status, headers, body)
         161  +
        if !success && status != 200 || force_error {
         162  +
            let headers = response.headers();
         163  +
            let body = response.body().bytes().expect("body loaded");
         164  +
            #[allow(unused_mut)]
         165  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         166  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         167  +
            })?;
         168  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         169  +
            let generic = generic_builder.build();
         170  +
            let error_code = match generic.code() {
         171  +
                ::std::option::Option::Some(code) => code,
         172  +
                ::std::option::Option::None => {
         173  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         174  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(crate::operation::describe_limits::DescribeLimitsError::unhandled(
         175  +
                            generic,
         176  +
                        )),
         177  +
                    ))
         178  +
                }
         179  +
            };
         180  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         181  +
            let protocol = _cfg
         182  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         183  +
                .expect("a SharedClientProtocol is required");
         184  +
            let err = match error_code {
         185  +
                "InternalServerError" => crate::operation::describe_limits::DescribeLimitsError::InternalServerError({
         186  +
                    let mut tmp = match protocol
         187  +
                        .deserialize_response(response, crate::types::error::InternalServerError::SCHEMA, _cfg)
         188  +
                        .and_then(|mut deser| {
         189  +
                            crate::types::error::InternalServerError::deserialize_with_response(
         190  +
                                &mut *deser,
         191  +
                                response.headers(),
         192  +
                                response.status().into(),
         193  +
                                body,
         194  +
                            )
         195  +
                        }) {
         196  +
                        ::std::result::Result::Ok(val) => val,
         197  +
                        ::std::result::Result::Err(e) => {
         198  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         199  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         200  +
                            ))
         201  +
                        }
         202  +
                    };
         203  +
                    tmp.meta = generic;
         204  +
                    if tmp.message.is_none() {
         205  +
                        tmp.message = _error_message;
         206  +
                    }
         207  +
                    tmp
         208  +
                }),
         209  +
                "InvalidEndpointException" => crate::operation::describe_limits::DescribeLimitsError::InvalidEndpointException({
         210  +
                    let mut tmp = match protocol
         211  +
                        .deserialize_response(response, crate::types::error::InvalidEndpointException::SCHEMA, _cfg)
         212  +
                        .and_then(|mut deser| {
         213  +
                            crate::types::error::InvalidEndpointException::deserialize_with_response(
         214  +
                                &mut *deser,
         215  +
                                response.headers(),
         216  +
                                response.status().into(),
         217  +
                                body,
         218  +
                            )
         219  +
                        }) {
         220  +
                        ::std::result::Result::Ok(val) => val,
         221  +
                        ::std::result::Result::Err(e) => {
         222  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         223  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         224  +
                            ))
         225  +
                        }
  162    226   
                    };
  163         -
        crate::protocol_serde::type_erase_result(parse_result)
         227  +
                    tmp.meta = generic;
         228  +
                    if tmp.message.is_none() {
         229  +
                        tmp.message = _error_message;
         230  +
                    }
         231  +
                    tmp
         232  +
                }),
         233  +
                _ => crate::operation::describe_limits::DescribeLimitsError::generic(generic),
         234  +
            };
         235  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         236  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         237  +
            ))
         238  +
        } else {
         239  +
            let protocol = _cfg
         240  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         241  +
                .expect("a SharedClientProtocol is required");
         242  +
            let mut deser = protocol
         243  +
                .deserialize_response(response, DescribeLimits::OUTPUT_SCHEMA, _cfg)
         244  +
                .map_err(|e| {
         245  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         246  +
                })?;
         247  +
            let body = response.body().bytes().expect("body loaded");
         248  +
            let output = crate::operation::describe_limits::DescribeLimitsOutput::deserialize_with_response(
         249  +
                &mut *deser,
         250  +
                response.headers(),
         251  +
                response.status().into(),
         252  +
                body,
         253  +
            )
         254  +
            .map_err(|e| {
         255  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         256  +
            })?;
         257  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         258  +
        }
  164    259   
    }
  165    260   
}
  166    261   
#[derive(Debug)]
  167    262   
struct DescribeLimitsRequestSerializer;
  168    263   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for DescribeLimitsRequestSerializer {
  169    264   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  170    265   
    fn serialize_input(
  171    266   
        &self,
  172    267   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  173    268   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  174    269   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  175    270   
        let input = input
  176    271   
            .downcast::<crate::operation::describe_limits::DescribeLimitsInput>()
  177    272   
            .expect("correct type");
  178         -
        let _header_serialization_settings = _cfg
  179         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  180         -
            .cloned()
  181         -
            .unwrap_or_default();
  182         -
        let mut request_builder = {
  183         -
            #[allow(clippy::uninlined_format_args)]
  184         -
            fn uri_base(
  185         -
                _input: &crate::operation::describe_limits::DescribeLimitsInput,
  186         -
                output: &mut ::std::string::String,
  187         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  188         -
                use ::std::fmt::Write as _;
  189         -
                ::std::write!(output, "/").expect("formatting should succeed");
  190         -
                ::std::result::Result::Ok(())
  191         -
            }
  192         -
            #[allow(clippy::unnecessary_wraps)]
  193         -
            fn update_http_builder(
  194         -
                input: &crate::operation::describe_limits::DescribeLimitsInput,
  195         -
                builder: ::http_1x::request::Builder,
  196         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  197         -
                let mut uri = ::std::string::String::new();
  198         -
                uri_base(input, &mut uri)?;
  199         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  200         -
            }
  201         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  202         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.0");
  203         -
            builder = _header_serialization_settings.set_default_header(
  204         -
                builder,
  205         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  206         -
                "DynamoDB_20120810.DescribeLimits",
  207         -
            );
  208         -
            builder
  209         -
        };
  210         -
        let body = ::aws_smithy_types::body::SdkBody::from(crate::protocol_serde::shape_describe_limits::ser_describe_limits_input(&input)?);
         273  +
        let protocol = _cfg
         274  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         275  +
            .expect("a SharedClientProtocol is required");
         276  +
        let mut request = protocol
         277  +
            .serialize_request(&input, DescribeLimits::INPUT_SCHEMA, "", _cfg)
         278  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
  211    279   
  212         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         280  +
        return ::std::result::Result::Ok(request);
  213    281   
    }
  214    282   
}
  215    283   
#[derive(Debug)]
  216    284   
struct DescribeLimitsEndpointParamsInterceptor;
  217    285   
  218    286   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for DescribeLimitsEndpointParamsInterceptor {
  219    287   
    fn name(&self) -> &'static str {
  220    288   
        "DescribeLimitsEndpointParamsInterceptor"
  221    289   
    }
  222    290   

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_limits/_describe_limits_input.rs

@@ -1,1 +70,83 @@
   19     19   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   20     20   
    fn serialize_members(
   21     21   
        &self,
   22     22   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   23     23   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   24     24   
        Ok(())
   25     25   
    }
   26     26   
}
   27     27   
impl DescribeLimitsInput {
   28     28   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   29         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   30         -
        deserializer: &mut D,
          29  +
    pub fn deserialize(
          30  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   31     31   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   32     32   
        #[allow(unused_variables, unused_mut)]
   33     33   
        let mut builder = Self::builder();
   34     34   
        #[allow(
   35     35   
            unused_variables,
   36     36   
            unreachable_code,
   37     37   
            clippy::single_match,
   38     38   
            clippy::match_single_binding,
   39     39   
            clippy::diverging_sub_expression
   40     40   
        )]
   41         -
        deserializer.read_struct(&DESCRIBELIMITSINPUT_SCHEMA, (), |_, member, deser| {
          41  +
        deserializer.read_struct(&DESCRIBELIMITSINPUT_SCHEMA, &mut |member, deser| {
   42     42   
            match member.member_index() {
   43     43   
                _ => {}
   44     44   
            }
   45     45   
            Ok(())
   46     46   
        })?;
   47     47   
        builder
   48     48   
            .build()
   49     49   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   50     50   
    }
   51     51   
}
          52  +
impl DescribeLimitsInput {
          53  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          54  +
    pub fn deserialize_with_response(
          55  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          56  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          57  +
        _status: u16,
          58  +
        _body: &[u8],
          59  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          60  +
        Self::builder()
          61  +
            .build()
          62  +
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
          63  +
    }
          64  +
}
   52     65   
impl DescribeLimitsInput {
   53     66   
    /// Creates a new builder-style object to manufacture [`DescribeLimitsInput`](crate::operation::describe_limits::DescribeLimitsInput).
   54     67   
    pub fn builder() -> crate::operation::describe_limits::builders::DescribeLimitsInputBuilder {
   55     68   
        crate::operation::describe_limits::builders::DescribeLimitsInputBuilder::default()
   56     69   
    }
   57     70   
}
   58     71   
   59     72   
/// A builder for [`DescribeLimitsInput`](crate::operation::describe_limits::DescribeLimitsInput).
   60     73   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   61     74   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_limits/_describe_limits_output.rs

@@ -17,17 +159,213 @@
   37     37   
    "com.amazonaws.dynamodb.synthetic",
   38     38   
    "DescribeLimitsOutput",
   39     39   
);
   40     40   
static DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_READ_CAPACITY_UNITS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   41     41   
    ::aws_smithy_schema::ShapeId::from_static(
   42     42   
        "com.amazonaws.dynamodb.synthetic#DescribeLimitsOutput$AccountMaxReadCapacityUnits",
   43     43   
        "com.amazonaws.dynamodb.synthetic",
   44     44   
        "DescribeLimitsOutput",
   45     45   
    ),
   46     46   
    ::aws_smithy_schema::ShapeType::Long,
   47         -
    "account_max_read_capacity_units",
          47  +
    "AccountMaxReadCapacityUnits",
   48     48   
    0,
   49     49   
);
   50     50   
static DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_WRITE_CAPACITY_UNITS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   51     51   
    ::aws_smithy_schema::ShapeId::from_static(
   52     52   
        "com.amazonaws.dynamodb.synthetic#DescribeLimitsOutput$AccountMaxWriteCapacityUnits",
   53     53   
        "com.amazonaws.dynamodb.synthetic",
   54     54   
        "DescribeLimitsOutput",
   55     55   
    ),
   56     56   
    ::aws_smithy_schema::ShapeType::Long,
   57         -
    "account_max_write_capacity_units",
          57  +
    "AccountMaxWriteCapacityUnits",
   58     58   
    1,
   59     59   
);
   60     60   
static DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_READ_CAPACITY_UNITS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   61     61   
    ::aws_smithy_schema::ShapeId::from_static(
   62     62   
        "com.amazonaws.dynamodb.synthetic#DescribeLimitsOutput$TableMaxReadCapacityUnits",
   63     63   
        "com.amazonaws.dynamodb.synthetic",
   64     64   
        "DescribeLimitsOutput",
   65     65   
    ),
   66     66   
    ::aws_smithy_schema::ShapeType::Long,
   67         -
    "table_max_read_capacity_units",
          67  +
    "TableMaxReadCapacityUnits",
   68     68   
    2,
   69     69   
);
   70     70   
static DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_WRITE_CAPACITY_UNITS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   71     71   
    ::aws_smithy_schema::ShapeId::from_static(
   72     72   
        "com.amazonaws.dynamodb.synthetic#DescribeLimitsOutput$TableMaxWriteCapacityUnits",
   73     73   
        "com.amazonaws.dynamodb.synthetic",
   74     74   
        "DescribeLimitsOutput",
   75     75   
    ),
   76     76   
    ::aws_smithy_schema::ShapeType::Long,
   77         -
    "table_max_write_capacity_units",
          77  +
    "TableMaxWriteCapacityUnits",
   78     78   
    3,
   79     79   
);
          80  +
static DESCRIBELIMITSOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          81  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          82  +
    ::aws_smithy_schema::ShapeType::String,
          83  +
    "request_id",
          84  +
    4,
          85  +
)
          86  +
.with_http_header("x-amzn-requestid");
   80     87   
static DESCRIBELIMITSOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   81     88   
    DESCRIBELIMITSOUTPUT_SCHEMA_ID,
   82     89   
    ::aws_smithy_schema::ShapeType::Structure,
   83     90   
    &[
   84     91   
        &DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_READ_CAPACITY_UNITS,
   85     92   
        &DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_WRITE_CAPACITY_UNITS,
   86     93   
        &DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_READ_CAPACITY_UNITS,
   87     94   
        &DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_WRITE_CAPACITY_UNITS,
          95  +
        &DESCRIBELIMITSOUTPUT_MEMBER__REQUEST_ID,
   88     96   
    ],
   89     97   
);
   90     98   
impl DescribeLimitsOutput {
   91     99   
    /// The schema for this shape.
   92    100   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBELIMITSOUTPUT_SCHEMA;
   93    101   
}
   94    102   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeLimitsOutput {
   95    103   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   96    104   
    fn serialize_members(
   97    105   
        &self,
   98    106   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   99    107   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
  100    108   
        if let Some(ref val) = self.account_max_read_capacity_units {
  101    109   
            ser.write_long(&DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_READ_CAPACITY_UNITS, *val)?;
  102    110   
        }
  103    111   
        if let Some(ref val) = self.account_max_write_capacity_units {
  104    112   
            ser.write_long(&DESCRIBELIMITSOUTPUT_MEMBER_ACCOUNT_MAX_WRITE_CAPACITY_UNITS, *val)?;
  105    113   
        }
  106    114   
        if let Some(ref val) = self.table_max_read_capacity_units {
  107    115   
            ser.write_long(&DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_READ_CAPACITY_UNITS, *val)?;
  108    116   
        }
  109    117   
        if let Some(ref val) = self.table_max_write_capacity_units {
  110    118   
            ser.write_long(&DESCRIBELIMITSOUTPUT_MEMBER_TABLE_MAX_WRITE_CAPACITY_UNITS, *val)?;
  111    119   
        }
  112    120   
        Ok(())
  113    121   
    }
  114    122   
}
  115    123   
impl DescribeLimitsOutput {
  116    124   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  117         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  118         -
        deserializer: &mut D,
         125  +
    pub fn deserialize(
         126  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  119    127   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  120    128   
        #[allow(unused_variables, unused_mut)]
  121    129   
        let mut builder = Self::builder();
  122    130   
        #[allow(
  123    131   
            unused_variables,
  124    132   
            unreachable_code,
  125    133   
            clippy::single_match,
  126    134   
            clippy::match_single_binding,
  127    135   
            clippy::diverging_sub_expression
  128    136   
        )]
  129         -
        deserializer.read_struct(&DESCRIBELIMITSOUTPUT_SCHEMA, (), |_, member, deser| {
         137  +
        deserializer.read_struct(&DESCRIBELIMITSOUTPUT_SCHEMA, &mut |member, deser| {
         138  +
            match member.member_index() {
         139  +
                Some(0) => {
         140  +
                    builder.account_max_read_capacity_units = Some(deser.read_long(member)?);
         141  +
                }
         142  +
                Some(1) => {
         143  +
                    builder.account_max_write_capacity_units = Some(deser.read_long(member)?);
         144  +
                }
         145  +
                Some(2) => {
         146  +
                    builder.table_max_read_capacity_units = Some(deser.read_long(member)?);
         147  +
                }
         148  +
                Some(3) => {
         149  +
                    builder.table_max_write_capacity_units = Some(deser.read_long(member)?);
         150  +
                }
         151  +
                Some(4) => {
         152  +
                    builder._request_id = Some(deser.read_string(member)?);
         153  +
                }
         154  +
                _ => {}
         155  +
            }
         156  +
            Ok(())
         157  +
        })?;
         158  +
        Ok(builder.build())
         159  +
    }
         160  +
}
         161  +
impl DescribeLimitsOutput {
         162  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         163  +
    /// Header-bound members are read directly from headers, avoiding runtime
         164  +
    /// member iteration overhead. Body members are read via the deserializer.
         165  +
    pub fn deserialize_with_response(
         166  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         167  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         168  +
        _status: u16,
         169  +
        _body: &[u8],
         170  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         171  +
        #[allow(unused_variables, unused_mut)]
         172  +
        let mut builder = Self::builder();
         173  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         174  +
            builder._request_id = Some(val.to_string());
         175  +
        }
         176  +
        #[allow(
         177  +
            unused_variables,
         178  +
            unreachable_code,
         179  +
            clippy::single_match,
         180  +
            clippy::match_single_binding,
         181  +
            clippy::diverging_sub_expression
         182  +
        )]
         183  +
        deserializer.read_struct(&DESCRIBELIMITSOUTPUT_SCHEMA, &mut |member, deser| {
  130    184   
            match member.member_index() {
  131    185   
                Some(0) => {
  132    186   
                    builder.account_max_read_capacity_units = Some(deser.read_long(member)?);
  133    187   
                }
  134    188   
                Some(1) => {
  135    189   
                    builder.account_max_write_capacity_units = Some(deser.read_long(member)?);
  136    190   
                }
  137    191   
                Some(2) => {
  138    192   
                    builder.table_max_read_capacity_units = Some(deser.read_long(member)?);
  139    193   
                }

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/describe_table.rs

@@ -1,1 +40,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `DescribeTable`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct DescribeTable;
    6      6   
impl DescribeTable {
    7      7   
    /// Creates a new `DescribeTable`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_table::DescribeTableInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::describe_table::DescribeTableOutput::SCHEMA;
   11     15   
    pub(crate) async fn orchestrate(
   12     16   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     17   
        input: crate::operation::describe_table::DescribeTableInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::describe_table::DescribeTableOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::describe_table::DescribeTableError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -115,119 +242,327 @@
  135    139   
                crate::operation::describe_table::DescribeTableError,
  136    140   
            >::new());
  137    141   
  138    142   
        ::std::borrow::Cow::Owned(rcb)
  139    143   
    }
  140    144   
}
  141    145   
  142    146   
#[derive(Debug)]
  143    147   
struct DescribeTableResponseDeserializer;
  144    148   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for DescribeTableResponseDeserializer {
  145         -
    fn deserialize_nonstreaming(
         149  +
    fn deserialize_nonstreaming_with_config(
  146    150   
        &self,
  147    151   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         152  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  148    153   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  149    154   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  150         -
        let headers = response.headers();
  151         -
        let body = response.body().bytes().expect("body loaded");
  152    155   
        #[allow(unused_mut)]
  153    156   
        let mut force_error = false;
  154    157   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  155         -
        let parse_result = if !success && status != 200 || force_error {
  156         -
            crate::protocol_serde::shape_describe_table::de_describe_table_http_error(status, headers, body)
  157         -
        } else {
  158         -
            crate::protocol_serde::shape_describe_table::de_describe_table_http_response(status, headers, body)
         158  +
        if !success && status != 200 || force_error {
         159  +
            let headers = response.headers();
         160  +
            let body = response.body().bytes().expect("body loaded");
         161  +
            #[allow(unused_mut)]
         162  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         163  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         164  +
            })?;
         165  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         166  +
            let generic = generic_builder.build();
         167  +
            let error_code = match generic.code() {
         168  +
                ::std::option::Option::Some(code) => code,
         169  +
                ::std::option::Option::None => {
         170  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         171  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(crate::operation::describe_table::DescribeTableError::unhandled(generic)),
         172  +
                    ))
         173  +
                }
         174  +
            };
         175  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         176  +
            let protocol = _cfg
         177  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         178  +
                .expect("a SharedClientProtocol is required");
         179  +
            let err = match error_code {
         180  +
                "InternalServerError" => crate::operation::describe_table::DescribeTableError::InternalServerError({
         181  +
                    let mut tmp = match protocol
         182  +
                        .deserialize_response(response, crate::types::error::InternalServerError::SCHEMA, _cfg)
         183  +
                        .and_then(|mut deser| {
         184  +
                            crate::types::error::InternalServerError::deserialize_with_response(
         185  +
                                &mut *deser,
         186  +
                                response.headers(),
         187  +
                                response.status().into(),
         188  +
                                body,
         189  +
                            )
         190  +
                        }) {
         191  +
                        ::std::result::Result::Ok(val) => val,
         192  +
                        ::std::result::Result::Err(e) => {
         193  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         194  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         195  +
                            ))
         196  +
                        }
         197  +
                    };
         198  +
                    tmp.meta = generic;
         199  +
                    if tmp.message.is_none() {
         200  +
                        tmp.message = _error_message;
         201  +
                    }
         202  +
                    tmp
         203  +
                }),
         204  +
                "InvalidEndpointException" => crate::operation::describe_table::DescribeTableError::InvalidEndpointException({
         205  +
                    let mut tmp = match protocol
         206  +
                        .deserialize_response(response, crate::types::error::InvalidEndpointException::SCHEMA, _cfg)
         207  +
                        .and_then(|mut deser| {
         208  +
                            crate::types::error::InvalidEndpointException::deserialize_with_response(
         209  +
                                &mut *deser,
         210  +
                                response.headers(),
         211  +
                                response.status().into(),
         212  +
                                body,
         213  +
                            )
         214  +
                        }) {
         215  +
                        ::std::result::Result::Ok(val) => val,
         216  +
                        ::std::result::Result::Err(e) => {
         217  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         218  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         219  +
                            ))
         220  +
                        }
         221  +
                    };
         222  +
                    tmp.meta = generic;
         223  +
                    if tmp.message.is_none() {
         224  +
                        tmp.message = _error_message;
         225  +
                    }
         226  +
                    tmp
         227  +
                }),
         228  +
                "ResourceNotFoundException" => crate::operation::describe_table::DescribeTableError::ResourceNotFoundException({
         229  +
                    let mut tmp = match protocol
         230  +
                        .deserialize_response(response, crate::types::error::ResourceNotFoundException::SCHEMA, _cfg)
         231  +
                        .and_then(|mut deser| {
         232  +
                            crate::types::error::ResourceNotFoundException::deserialize_with_response(
         233  +
                                &mut *deser,
         234  +
                                response.headers(),
         235  +
                                response.status().into(),
         236  +
                                body,
         237  +
                            )
         238  +
                        }) {
         239  +
                        ::std::result::Result::Ok(val) => val,
         240  +
                        ::std::result::Result::Err(e) => {
         241  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         242  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         243  +
                            ))
         244  +
                        }
         245  +
                    };
         246  +
                    tmp.meta = generic;
         247  +
                    if tmp.message.is_none() {
         248  +
                        tmp.message = _error_message;
         249  +
                    }
         250  +
                    tmp
         251  +
                }),
         252  +
                _ => crate::operation::describe_table::DescribeTableError::generic(generic),
  159    253   
            };
  160         -
        crate::protocol_serde::type_erase_result(parse_result)
         254  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         255  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         256  +
            ))
         257  +
        } else {
         258  +
            let protocol = _cfg
         259  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         260  +
                .expect("a SharedClientProtocol is required");
         261  +
            let mut deser = protocol.deserialize_response(response, DescribeTable::OUTPUT_SCHEMA, _cfg).map_err(|e| {
         262  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         263  +
            })?;
         264  +
            let body = response.body().bytes().expect("body loaded");
         265  +
            let output = crate::operation::describe_table::DescribeTableOutput::deserialize_with_response(
         266  +
                &mut *deser,
         267  +
                response.headers(),
         268  +
                response.status().into(),
         269  +
                body,
         270  +
            )
         271  +
            .map_err(|e| {
         272  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         273  +
            })?;
         274  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         275  +
        }
  161    276   
    }
  162    277   
}
  163    278   
#[derive(Debug)]
  164    279   
struct DescribeTableRequestSerializer;
  165    280   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for DescribeTableRequestSerializer {
  166    281   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  167    282   
    fn serialize_input(
  168    283   
        &self,
  169    284   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  170    285   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  171    286   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  172    287   
        let input = input
  173    288   
            .downcast::<crate::operation::describe_table::DescribeTableInput>()
  174    289   
            .expect("correct type");
  175         -
        let _header_serialization_settings = _cfg
  176         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  177         -
            .cloned()
  178         -
            .unwrap_or_default();
  179         -
        let mut request_builder = {
  180         -
            #[allow(clippy::uninlined_format_args)]
  181         -
            fn uri_base(
  182         -
                _input: &crate::operation::describe_table::DescribeTableInput,
  183         -
                output: &mut ::std::string::String,
  184         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  185         -
                use ::std::fmt::Write as _;
  186         -
                ::std::write!(output, "/").expect("formatting should succeed");
  187         -
                ::std::result::Result::Ok(())
  188         -
            }
  189         -
            #[allow(clippy::unnecessary_wraps)]
  190         -
            fn update_http_builder(
  191         -
                input: &crate::operation::describe_table::DescribeTableInput,
  192         -
                builder: ::http_1x::request::Builder,
  193         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  194         -
                let mut uri = ::std::string::String::new();
  195         -
                uri_base(input, &mut uri)?;
  196         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  197         -
            }
  198         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  199         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.0");
  200         -
            builder = _header_serialization_settings.set_default_header(
  201         -
                builder,
  202         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  203         -
                "DynamoDB_20120810.DescribeTable",
  204         -
            );
  205         -
            builder
  206         -
        };
  207         -
        let body = ::aws_smithy_types::body::SdkBody::from(crate::protocol_serde::shape_describe_table::ser_describe_table_input(&input)?);
  208         -
        if let Some(content_length) = body.content_length() {
  209         -
            let content_length = content_length.to_string();
  210         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  211         -
        }
  212         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         290  +
        let protocol = _cfg
         291  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         292  +
            .expect("a SharedClientProtocol is required");
         293  +
        let mut request = protocol
         294  +
            .serialize_request(&input, DescribeTable::INPUT_SCHEMA, "", _cfg)
         295  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         296  +
         297  +
        return ::std::result::Result::Ok(request);
  213    298   
    }
  214    299   
}
  215    300   
#[derive(Debug)]
  216    301   
struct DescribeTableEndpointParamsInterceptor;
  217    302   
  218    303   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for DescribeTableEndpointParamsInterceptor {
  219    304   
    fn name(&self) -> &'static str {
  220    305   
        "DescribeTableEndpointParamsInterceptor"
  221    306   
    }
  222    307