AWS SDK

AWS SDK

rev. 96f5a1b4ad139d2f1ad1e8e40f300e1cd1ff574c

Files changed:

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

@@ -304,304 +524,524 @@
  324    324   
    "com.amazonaws.dynamodb.synthetic",
  325    325   
    "QueryInput",
  326    326   
);
  327    327   
static QUERYINPUT_MEMBER_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  328    328   
    ::aws_smithy_schema::ShapeId::from_static(
  329    329   
        "com.amazonaws.dynamodb.synthetic#QueryInput$TableName",
  330    330   
        "com.amazonaws.dynamodb.synthetic",
  331    331   
        "QueryInput",
  332    332   
    ),
  333    333   
    ::aws_smithy_schema::ShapeType::String,
  334         -
    "table_name",
         334  +
    "TableName",
  335    335   
    0,
  336    336   
);
  337    337   
static QUERYINPUT_MEMBER_INDEX_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  338    338   
    ::aws_smithy_schema::ShapeId::from_static(
  339    339   
        "com.amazonaws.dynamodb.synthetic#QueryInput$IndexName",
  340    340   
        "com.amazonaws.dynamodb.synthetic",
  341    341   
        "QueryInput",
  342    342   
    ),
  343    343   
    ::aws_smithy_schema::ShapeType::String,
  344         -
    "index_name",
         344  +
    "IndexName",
  345    345   
    1,
  346    346   
);
  347    347   
static QUERYINPUT_MEMBER_SELECT: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  348    348   
    ::aws_smithy_schema::ShapeId::from_static(
  349    349   
        "com.amazonaws.dynamodb.synthetic#QueryInput$Select",
  350    350   
        "com.amazonaws.dynamodb.synthetic",
  351    351   
        "QueryInput",
  352    352   
    ),
  353    353   
    ::aws_smithy_schema::ShapeType::String,
  354         -
    "select",
         354  +
    "Select",
  355    355   
    2,
  356    356   
);
  357    357   
static QUERYINPUT_MEMBER_ATTRIBUTES_TO_GET: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  358    358   
    ::aws_smithy_schema::ShapeId::from_static(
  359    359   
        "com.amazonaws.dynamodb.synthetic#QueryInput$AttributesToGet",
  360    360   
        "com.amazonaws.dynamodb.synthetic",
  361    361   
        "QueryInput",
  362    362   
    ),
  363    363   
    ::aws_smithy_schema::ShapeType::List,
  364         -
    "attributes_to_get",
         364  +
    "AttributesToGet",
  365    365   
    3,
  366    366   
);
  367    367   
static QUERYINPUT_MEMBER_LIMIT: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  368    368   
    ::aws_smithy_schema::ShapeId::from_static(
  369    369   
        "com.amazonaws.dynamodb.synthetic#QueryInput$Limit",
  370    370   
        "com.amazonaws.dynamodb.synthetic",
  371    371   
        "QueryInput",
  372    372   
    ),
  373    373   
    ::aws_smithy_schema::ShapeType::Integer,
  374         -
    "limit",
         374  +
    "Limit",
  375    375   
    4,
  376    376   
);
  377    377   
static QUERYINPUT_MEMBER_CONSISTENT_READ: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  378    378   
    ::aws_smithy_schema::ShapeId::from_static(
  379    379   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ConsistentRead",
  380    380   
        "com.amazonaws.dynamodb.synthetic",
  381    381   
        "QueryInput",
  382    382   
    ),
  383    383   
    ::aws_smithy_schema::ShapeType::Boolean,
  384         -
    "consistent_read",
         384  +
    "ConsistentRead",
  385    385   
    5,
  386    386   
);
  387    387   
static QUERYINPUT_MEMBER_KEY_CONDITIONS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  388    388   
    ::aws_smithy_schema::ShapeId::from_static(
  389    389   
        "com.amazonaws.dynamodb.synthetic#QueryInput$KeyConditions",
  390    390   
        "com.amazonaws.dynamodb.synthetic",
  391    391   
        "QueryInput",
  392    392   
    ),
  393    393   
    ::aws_smithy_schema::ShapeType::Map,
  394         -
    "key_conditions",
         394  +
    "KeyConditions",
  395    395   
    6,
  396    396   
);
  397    397   
static QUERYINPUT_MEMBER_QUERY_FILTER: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  398    398   
    ::aws_smithy_schema::ShapeId::from_static(
  399    399   
        "com.amazonaws.dynamodb.synthetic#QueryInput$QueryFilter",
  400    400   
        "com.amazonaws.dynamodb.synthetic",
  401    401   
        "QueryInput",
  402    402   
    ),
  403    403   
    ::aws_smithy_schema::ShapeType::Map,
  404         -
    "query_filter",
         404  +
    "QueryFilter",
  405    405   
    7,
  406    406   
);
  407    407   
static QUERYINPUT_MEMBER_CONDITIONAL_OPERATOR: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  408    408   
    ::aws_smithy_schema::ShapeId::from_static(
  409    409   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ConditionalOperator",
  410    410   
        "com.amazonaws.dynamodb.synthetic",
  411    411   
        "QueryInput",
  412    412   
    ),
  413    413   
    ::aws_smithy_schema::ShapeType::String,
  414         -
    "conditional_operator",
         414  +
    "ConditionalOperator",
  415    415   
    8,
  416    416   
);
  417    417   
static QUERYINPUT_MEMBER_SCAN_INDEX_FORWARD: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  418    418   
    ::aws_smithy_schema::ShapeId::from_static(
  419    419   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ScanIndexForward",
  420    420   
        "com.amazonaws.dynamodb.synthetic",
  421    421   
        "QueryInput",
  422    422   
    ),
  423    423   
    ::aws_smithy_schema::ShapeType::Boolean,
  424         -
    "scan_index_forward",
         424  +
    "ScanIndexForward",
  425    425   
    9,
  426    426   
);
  427    427   
static QUERYINPUT_MEMBER_EXCLUSIVE_START_KEY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  428    428   
    ::aws_smithy_schema::ShapeId::from_static(
  429    429   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ExclusiveStartKey",
  430    430   
        "com.amazonaws.dynamodb.synthetic",
  431    431   
        "QueryInput",
  432    432   
    ),
  433    433   
    ::aws_smithy_schema::ShapeType::Map,
  434         -
    "exclusive_start_key",
         434  +
    "ExclusiveStartKey",
  435    435   
    10,
  436    436   
);
  437    437   
static QUERYINPUT_MEMBER_RETURN_CONSUMED_CAPACITY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  438    438   
    ::aws_smithy_schema::ShapeId::from_static(
  439    439   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ReturnConsumedCapacity",
  440    440   
        "com.amazonaws.dynamodb.synthetic",
  441    441   
        "QueryInput",
  442    442   
    ),
  443    443   
    ::aws_smithy_schema::ShapeType::String,
  444         -
    "return_consumed_capacity",
         444  +
    "ReturnConsumedCapacity",
  445    445   
    11,
  446    446   
);
  447    447   
static QUERYINPUT_MEMBER_PROJECTION_EXPRESSION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  448    448   
    ::aws_smithy_schema::ShapeId::from_static(
  449    449   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ProjectionExpression",
  450    450   
        "com.amazonaws.dynamodb.synthetic",
  451    451   
        "QueryInput",
  452    452   
    ),
  453    453   
    ::aws_smithy_schema::ShapeType::String,
  454         -
    "projection_expression",
         454  +
    "ProjectionExpression",
  455    455   
    12,
  456    456   
);
  457    457   
static QUERYINPUT_MEMBER_FILTER_EXPRESSION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  458    458   
    ::aws_smithy_schema::ShapeId::from_static(
  459    459   
        "com.amazonaws.dynamodb.synthetic#QueryInput$FilterExpression",
  460    460   
        "com.amazonaws.dynamodb.synthetic",
  461    461   
        "QueryInput",
  462    462   
    ),
  463    463   
    ::aws_smithy_schema::ShapeType::String,
  464         -
    "filter_expression",
         464  +
    "FilterExpression",
  465    465   
    13,
  466    466   
);
  467    467   
static QUERYINPUT_MEMBER_KEY_CONDITION_EXPRESSION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  468    468   
    ::aws_smithy_schema::ShapeId::from_static(
  469    469   
        "com.amazonaws.dynamodb.synthetic#QueryInput$KeyConditionExpression",
  470    470   
        "com.amazonaws.dynamodb.synthetic",
  471    471   
        "QueryInput",
  472    472   
    ),
  473    473   
    ::aws_smithy_schema::ShapeType::String,
  474         -
    "key_condition_expression",
         474  +
    "KeyConditionExpression",
  475    475   
    14,
  476    476   
);
  477    477   
static QUERYINPUT_MEMBER_EXPRESSION_ATTRIBUTE_NAMES: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  478    478   
    ::aws_smithy_schema::ShapeId::from_static(
  479    479   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ExpressionAttributeNames",
  480    480   
        "com.amazonaws.dynamodb.synthetic",
  481    481   
        "QueryInput",
  482    482   
    ),
  483    483   
    ::aws_smithy_schema::ShapeType::Map,
  484         -
    "expression_attribute_names",
         484  +
    "ExpressionAttributeNames",
  485    485   
    15,
  486    486   
);
  487    487   
static QUERYINPUT_MEMBER_EXPRESSION_ATTRIBUTE_VALUES: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  488    488   
    ::aws_smithy_schema::ShapeId::from_static(
  489    489   
        "com.amazonaws.dynamodb.synthetic#QueryInput$ExpressionAttributeValues",
  490    490   
        "com.amazonaws.dynamodb.synthetic",
  491    491   
        "QueryInput",
  492    492   
    ),
  493    493   
    ::aws_smithy_schema::ShapeType::Map,
  494         -
    "expression_attribute_values",
         494  +
    "ExpressionAttributeValues",
  495    495   
    16,
  496    496   
);
  497    497   
static QUERYINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  498    498   
    QUERYINPUT_SCHEMA_ID,
  499    499   
    ::aws_smithy_schema::ShapeType::Structure,
  500    500   
    &[
  501    501   
        &QUERYINPUT_MEMBER_TABLE_NAME,
  502    502   
        &QUERYINPUT_MEMBER_INDEX_NAME,
  503    503   
        &QUERYINPUT_MEMBER_SELECT,
  504    504   
        &QUERYINPUT_MEMBER_ATTRIBUTES_TO_GET,
@@ -562,562 +802,782 @@
  582    582   
        }
  583    583   
        if let Some(ref val) = self.scan_index_forward {
  584    584   
            ser.write_boolean(&QUERYINPUT_MEMBER_SCAN_INDEX_FORWARD, *val)?;
  585    585   
        }
  586    586   
        if let Some(ref val) = self.exclusive_start_key {
  587    587   
            ser.write_map(
  588    588   
                &QUERYINPUT_MEMBER_EXCLUSIVE_START_KEY,
  589    589   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
  590    590   
                    for (key, value) in val {
  591    591   
                        ser.write_string(&::aws_smithy_schema::prelude::STRING, key)?;
  592         -
                        todo!("schema: unsupported map value type");
         592  +
                        ser.write_struct(crate::types::AttributeValue::SCHEMA, value)?;
  593    593   
                    }
  594    594   
                    Ok(())
  595    595   
                },
  596    596   
            )?;
  597    597   
        }
  598    598   
        if let Some(ref val) = self.return_consumed_capacity {
  599    599   
            ser.write_string(&QUERYINPUT_MEMBER_RETURN_CONSUMED_CAPACITY, val.as_str())?;
  600    600   
        }
  601    601   
        if let Some(ref val) = self.projection_expression {
  602    602   
            ser.write_string(&QUERYINPUT_MEMBER_PROJECTION_EXPRESSION, val)?;
  603    603   
        }
  604    604   
        if let Some(ref val) = self.filter_expression {
  605    605   
            ser.write_string(&QUERYINPUT_MEMBER_FILTER_EXPRESSION, val)?;
  606    606   
        }
  607    607   
        if let Some(ref val) = self.key_condition_expression {
  608    608   
            ser.write_string(&QUERYINPUT_MEMBER_KEY_CONDITION_EXPRESSION, val)?;
  609    609   
        }
  610    610   
        if let Some(ref val) = self.expression_attribute_names {
  611    611   
            ser.write_map(
  612    612   
                &QUERYINPUT_MEMBER_EXPRESSION_ATTRIBUTE_NAMES,
  613    613   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
  614    614   
                    for (key, value) in val {
  615    615   
                        ser.write_string(&::aws_smithy_schema::prelude::STRING, key)?;
  616    616   
                        ser.write_string(&::aws_smithy_schema::prelude::STRING, value)?;
  617    617   
                    }
  618    618   
                    Ok(())
  619    619   
                },
  620    620   
            )?;
  621    621   
        }
  622    622   
        if let Some(ref val) = self.expression_attribute_values {
  623    623   
            ser.write_map(
  624    624   
                &QUERYINPUT_MEMBER_EXPRESSION_ATTRIBUTE_VALUES,
  625    625   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
  626    626   
                    for (key, value) in val {
  627    627   
                        ser.write_string(&::aws_smithy_schema::prelude::STRING, key)?;
  628         -
                        todo!("schema: unsupported map value type");
         628  +
                        ser.write_struct(crate::types::AttributeValue::SCHEMA, value)?;
  629    629   
                    }
  630    630   
                    Ok(())
  631    631   
                },
  632    632   
            )?;
  633    633   
        }
  634    634   
        Ok(())
  635    635   
    }
  636    636   
}
  637    637   
impl QueryInput {
  638    638   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  639         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  640         -
        deserializer: &mut D,
         639  +
    pub fn deserialize(
         640  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  641    641   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  642    642   
        #[allow(unused_variables, unused_mut)]
  643    643   
        let mut builder = Self::builder();
  644    644   
        #[allow(
  645    645   
            unused_variables,
  646    646   
            unreachable_code,
  647    647   
            clippy::single_match,
  648    648   
            clippy::match_single_binding,
  649    649   
            clippy::diverging_sub_expression
  650    650   
        )]
  651         -
        deserializer.read_struct(&QUERYINPUT_SCHEMA, (), |_, member, deser| {
         651  +
        deserializer.read_struct(&QUERYINPUT_SCHEMA, &mut |member, deser| {
  652    652   
            match member.member_index() {
  653    653   
                Some(0) => {
  654    654   
                    builder.table_name = Some(deser.read_string(member)?);
  655    655   
                }
  656    656   
                Some(1) => {
  657    657   
                    builder.index_name = Some(deser.read_string(member)?);
  658    658   
                }
  659    659   
                Some(2) => {
  660    660   
                    builder.select = Some(crate::types::Select::from(deser.read_string(member)?.as_str()));
  661    661   
                }
  662    662   
                Some(3) => {
  663         -
                    builder.attributes_to_get = Some({
  664         -
                        let container = if let Some(cap) = deser.container_size() {
  665         -
                            Vec::with_capacity(cap)
  666         -
                        } else {
  667         -
                            Vec::new()
  668         -
                        };
  669         -
                        deser.read_list(member, container, |mut list, deser| {
  670         -
                            list.push(deser.read_string(member)?);
  671         -
                            Ok(list)
  672         -
                        })?
  673         -
                    });
         663  +
                    builder.attributes_to_get = Some(deser.read_string_list(member)?);
  674    664   
                }
  675    665   
                Some(4) => {
  676    666   
                    builder.limit = Some(deser.read_integer(member)?);
  677    667   
                }
  678    668   
                Some(5) => {
  679    669   
                    builder.consistent_read = Some(deser.read_boolean(member)?);
  680    670   
                }
  681    671   
                Some(6) => {
  682    672   
                    builder.key_conditions = Some({
  683         -
                        let container = if let Some(cap) = deser.container_size() {
  684         -
                            std::collections::HashMap::with_capacity(cap)
  685         -
                        } else {
  686         -
                            std::collections::HashMap::new()
  687         -
                        };
  688         -
                        deser.read_map(member, container, |mut map, key, deser| {
  689         -
                            map.insert(key, crate::types::Condition::deserialize(deser)?);
  690         -
                            Ok(map)
  691         -
                        })?
         673  +
                        let mut container = std::collections::HashMap::new();
         674  +
                        deser.read_map(member, &mut |key, deser| {
         675  +
                            container.insert(key, crate::types::Condition::deserialize(deser)?);
         676  +
                            Ok(())
         677  +
                        })?;
         678  +
                        container
  692    679   
                    });
  693    680   
                }
  694    681   
                Some(7) => {
  695    682   
                    builder.query_filter = Some({
  696         -
                        let container = if let Some(cap) = deser.container_size() {
  697         -
                            std::collections::HashMap::with_capacity(cap)
  698         -
                        } else {
  699         -
                            std::collections::HashMap::new()
  700         -
                        };
  701         -
                        deser.read_map(member, container, |mut map, key, deser| {
  702         -
                            map.insert(key, crate::types::Condition::deserialize(deser)?);
  703         -
                            Ok(map)
  704         -
                        })?
         683  +
                        let mut container = std::collections::HashMap::new();
         684  +
                        deser.read_map(member, &mut |key, deser| {
         685  +
                            container.insert(key, crate::types::Condition::deserialize(deser)?);
         686  +
                            Ok(())
         687  +
                        })?;
         688  +
                        container
  705    689   
                    });
  706    690   
                }
  707    691   
                Some(8) => {
  708    692   
                    builder.conditional_operator = Some(crate::types::ConditionalOperator::from(deser.read_string(member)?.as_str()));
  709    693   
                }
  710    694   
                Some(9) => {
  711    695   
                    builder.scan_index_forward = Some(deser.read_boolean(member)?);
  712    696   
                }
  713    697   
                Some(10) => {
  714    698   
                    builder.exclusive_start_key = Some({
  715         -
                        let container = if let Some(cap) = deser.container_size() {
  716         -
                            std::collections::HashMap::with_capacity(cap)
  717         -
                        } else {
  718         -
                            std::collections::HashMap::new()
  719         -
                        };
  720         -
                        deser.read_map(member, container, |mut map, key, deser| {
  721         -
                            map.insert(key, todo!("deserialize nested aggregate"));
  722         -
                            Ok(map)
  723         -
                        })?
         699  +
                        let mut container = std::collections::HashMap::new();
         700  +
                        deser.read_map(member, &mut |key, deser| {
         701  +
                            container.insert(key, crate::types::AttributeValue::deserialize(deser)?);
         702  +
                            Ok(())
         703  +
                        })?;
         704  +
                        container
  724    705   
                    });
  725    706   
                }
  726    707   
                Some(11) => {
  727    708   
                    builder.return_consumed_capacity = Some(crate::types::ReturnConsumedCapacity::from(deser.read_string(member)?.as_str()));
  728    709   
                }
  729    710   
                Some(12) => {
  730    711   
                    builder.projection_expression = Some(deser.read_string(member)?);
  731    712   
                }
  732    713   
                Some(13) => {
  733    714   
                    builder.filter_expression = Some(deser.read_string(member)?);
  734    715   
                }
  735    716   
                Some(14) => {
  736    717   
                    builder.key_condition_expression = Some(deser.read_string(member)?);
  737    718   
                }
  738    719   
                Some(15) => {
  739         -
                    builder.expression_attribute_names = Some({
  740         -
                        let container = if let Some(cap) = deser.container_size() {
  741         -
                            std::collections::HashMap::with_capacity(cap)
  742         -
                        } else {
  743         -
                            std::collections::HashMap::new()
  744         -
                        };
  745         -
                        deser.read_map(member, container, |mut map, key, deser| {
  746         -
                            map.insert(key, deser.read_string(member)?);
  747         -
                            Ok(map)
  748         -
                        })?
  749         -
                    });
         720  +
                    builder.expression_attribute_names = Some(deser.read_string_string_map(member)?);
  750    721   
                }
  751    722   
                Some(16) => {
  752    723   
                    builder.expression_attribute_values = Some({
  753         -
                        let container = if let Some(cap) = deser.container_size() {
  754         -
                            std::collections::HashMap::with_capacity(cap)
  755         -
                        } else {
  756         -
                            std::collections::HashMap::new()
  757         -
                        };
  758         -
                        deser.read_map(member, container, |mut map, key, deser| {
  759         -
                            map.insert(key, todo!("deserialize nested aggregate"));
  760         -
                            Ok(map)
  761         -
                        })?
         724  +
                        let mut container = std::collections::HashMap::new();
         725  +
                        deser.read_map(member, &mut |key, deser| {
         726  +
                            container.insert(key, crate::types::AttributeValue::deserialize(deser)?);
         727  +
                            Ok(())
         728  +
                        })?;
         729  +
                        container
  762    730   
                    });
  763    731   
                }
  764    732   
                _ => {}
  765    733   
            }
  766    734   
            Ok(())
  767    735   
        })?;
         736  +
        builder.table_name = builder.table_name.or(Some(String::new()));
  768    737   
        builder
  769    738   
            .build()
  770    739   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  771    740   
    }
  772    741   
}
         742  +
impl QueryInput {
         743  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         744  +
    pub fn deserialize_with_response(
         745  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         746  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         747  +
        _status: u16,
         748  +
        _body: &[u8],
         749  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         750  +
        Self::deserialize(deserializer)
         751  +
    }
         752  +
}
  773    753   
impl QueryInput {
  774    754   
    /// Creates a new builder-style object to manufacture [`QueryInput`](crate::operation::query::QueryInput).
  775    755   
    pub fn builder() -> crate::operation::query::builders::QueryInputBuilder {
  776    756   
        crate::operation::query::builders::QueryInputBuilder::default()
  777    757   
    }
  778    758   
}
  779    759   
  780    760   
/// A builder for [`QueryInput`](crate::operation::query::QueryInput).
  781    761   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  782    762   
#[non_exhaustive]

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

@@ -35,35 +238,328 @@
   55     55   
    "com.amazonaws.dynamodb.synthetic",
   56     56   
    "QueryOutput",
   57     57   
);
   58     58   
static QUERYOUTPUT_MEMBER_ITEMS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   59     59   
    ::aws_smithy_schema::ShapeId::from_static(
   60     60   
        "com.amazonaws.dynamodb.synthetic#QueryOutput$Items",
   61     61   
        "com.amazonaws.dynamodb.synthetic",
   62     62   
        "QueryOutput",
   63     63   
    ),
   64     64   
    ::aws_smithy_schema::ShapeType::List,
   65         -
    "items",
          65  +
    "Items",
   66     66   
    0,
   67     67   
);
   68     68   
static QUERYOUTPUT_MEMBER_COUNT: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   69     69   
    ::aws_smithy_schema::ShapeId::from_static(
   70     70   
        "com.amazonaws.dynamodb.synthetic#QueryOutput$Count",
   71     71   
        "com.amazonaws.dynamodb.synthetic",
   72     72   
        "QueryOutput",
   73     73   
    ),
   74     74   
    ::aws_smithy_schema::ShapeType::Integer,
   75         -
    "count",
          75  +
    "Count",
   76     76   
    1,
   77     77   
);
   78     78   
static QUERYOUTPUT_MEMBER_SCANNED_COUNT: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   79     79   
    ::aws_smithy_schema::ShapeId::from_static(
   80     80   
        "com.amazonaws.dynamodb.synthetic#QueryOutput$ScannedCount",
   81     81   
        "com.amazonaws.dynamodb.synthetic",
   82     82   
        "QueryOutput",
   83     83   
    ),
   84     84   
    ::aws_smithy_schema::ShapeType::Integer,
   85         -
    "scanned_count",
          85  +
    "ScannedCount",
   86     86   
    2,
   87     87   
);
   88     88   
static QUERYOUTPUT_MEMBER_LAST_EVALUATED_KEY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   89     89   
    ::aws_smithy_schema::ShapeId::from_static(
   90     90   
        "com.amazonaws.dynamodb.synthetic#QueryOutput$LastEvaluatedKey",
   91     91   
        "com.amazonaws.dynamodb.synthetic",
   92     92   
        "QueryOutput",
   93     93   
    ),
   94     94   
    ::aws_smithy_schema::ShapeType::Map,
   95         -
    "last_evaluated_key",
          95  +
    "LastEvaluatedKey",
   96     96   
    3,
   97     97   
);
   98     98   
static QUERYOUTPUT_MEMBER_CONSUMED_CAPACITY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   99     99   
    ::aws_smithy_schema::ShapeId::from_static(
  100    100   
        "com.amazonaws.dynamodb.synthetic#QueryOutput$ConsumedCapacity",
  101    101   
        "com.amazonaws.dynamodb.synthetic",
  102    102   
        "QueryOutput",
  103    103   
    ),
  104    104   
    ::aws_smithy_schema::ShapeType::Structure,
  105         -
    "consumed_capacity",
         105  +
    "ConsumedCapacity",
  106    106   
    4,
  107    107   
);
         108  +
static QUERYOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
         109  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
         110  +
    ::aws_smithy_schema::ShapeType::String,
         111  +
    "request_id",
         112  +
    5,
         113  +
)
         114  +
.with_http_header("x-amzn-requestid");
  108    115   
static QUERYOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  109    116   
    QUERYOUTPUT_SCHEMA_ID,
  110    117   
    ::aws_smithy_schema::ShapeType::Structure,
  111    118   
    &[
  112    119   
        &QUERYOUTPUT_MEMBER_ITEMS,
  113    120   
        &QUERYOUTPUT_MEMBER_COUNT,
  114    121   
        &QUERYOUTPUT_MEMBER_SCANNED_COUNT,
  115    122   
        &QUERYOUTPUT_MEMBER_LAST_EVALUATED_KEY,
  116    123   
        &QUERYOUTPUT_MEMBER_CONSUMED_CAPACITY,
         124  +
        &QUERYOUTPUT_MEMBER__REQUEST_ID,
  117    125   
    ],
  118    126   
);
  119    127   
impl QueryOutput {
  120    128   
    /// The schema for this shape.
  121    129   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &QUERYOUTPUT_SCHEMA;
  122    130   
}
  123    131   
impl ::aws_smithy_schema::serde::SerializableStruct for QueryOutput {
  124    132   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
  125    133   
    fn serialize_members(
  126    134   
        &self,
  127    135   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
  128    136   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
  129    137   
        if let Some(ref val) = self.items {
  130    138   
            ser.write_list(&QUERYOUTPUT_MEMBER_ITEMS, &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
  131    139   
                for item in val {
  132         -
                    todo!("schema: unsupported list element type");
         140  +
                    ser.write_map(
         141  +
                        &::aws_smithy_schema::prelude::DOCUMENT,
         142  +
                        &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
         143  +
                            for (key, value) in item {
         144  +
                                ser.write_string(&::aws_smithy_schema::prelude::STRING, key)?;
         145  +
                                ser.write_struct(crate::types::AttributeValue::SCHEMA, value)?;
         146  +
                            }
         147  +
                            Ok(())
         148  +
                        },
         149  +
                    )?;
  133    150   
                }
  134    151   
                Ok(())
  135    152   
            })?;
  136    153   
        }
  137    154   
        {
  138    155   
            let val = &self.count;
  139    156   
            ser.write_integer(&QUERYOUTPUT_MEMBER_COUNT, *val)?;
  140    157   
        }
  141    158   
        {
  142    159   
            let val = &self.scanned_count;
  143    160   
            ser.write_integer(&QUERYOUTPUT_MEMBER_SCANNED_COUNT, *val)?;
  144    161   
        }
  145    162   
        if let Some(ref val) = self.last_evaluated_key {
  146    163   
            ser.write_map(
  147    164   
                &QUERYOUTPUT_MEMBER_LAST_EVALUATED_KEY,
  148    165   
                &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
  149    166   
                    for (key, value) in val {
  150    167   
                        ser.write_string(&::aws_smithy_schema::prelude::STRING, key)?;
  151         -
                        todo!("schema: unsupported map value type");
         168  +
                        ser.write_struct(crate::types::AttributeValue::SCHEMA, value)?;
  152    169   
                    }
  153    170   
                    Ok(())
  154    171   
                },
  155    172   
            )?;
  156    173   
        }
  157    174   
        if let Some(ref val) = self.consumed_capacity {
  158    175   
            ser.write_struct(&QUERYOUTPUT_MEMBER_CONSUMED_CAPACITY, val)?;
  159    176   
        }
  160    177   
        Ok(())
  161    178   
    }
  162    179   
}
  163    180   
impl QueryOutput {
  164    181   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  165         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  166         -
        deserializer: &mut D,
         182  +
    pub fn deserialize(
         183  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  167    184   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  168    185   
        #[allow(unused_variables, unused_mut)]
  169    186   
        let mut builder = Self::builder();
  170    187   
        #[allow(
  171    188   
            unused_variables,
  172    189   
            unreachable_code,
  173    190   
            clippy::single_match,
  174    191   
            clippy::match_single_binding,
  175    192   
            clippy::diverging_sub_expression
  176    193   
        )]
  177         -
        deserializer.read_struct(&QUERYOUTPUT_SCHEMA, (), |_, member, deser| {
         194  +
        deserializer.read_struct(&QUERYOUTPUT_SCHEMA, &mut |member, deser| {
  178    195   
            match member.member_index() {
  179    196   
                Some(0) => {
  180    197   
                    builder.items = Some({
  181         -
                        let container = if let Some(cap) = deser.container_size() {
  182         -
                            Vec::with_capacity(cap)
  183         -
                        } else {
  184         -
                            Vec::new()
  185         -
                        };
  186         -
                        deser.read_list(member, container, |mut list, deser| {
  187         -
                            list.push(todo!("deserialize nested aggregate"));
  188         -
                            Ok(list)
  189         -
                        })?
         198  +
                        let mut container = Vec::new();
         199  +
                        deser.read_list(member, &mut |deser| {
         200  +
                            container.push({
         201  +
                                let mut map = ::std::collections::HashMap::new();
         202  +
                                deser.read_map(member, &mut |key, deser| {
         203  +
                                    let value = crate::types::AttributeValue::deserialize(deser)?;
         204  +
                                    map.insert(key, value);
         205  +
                                    Ok(())
         206  +
                                })?;
         207  +
                                map
         208  +
                            });
         209  +
                            Ok(())
         210  +
                        })?;
         211  +
                        container
  190    212   
                    });
  191    213   
                }
  192    214   
                Some(1) => {
  193    215   
                    builder.count = Some(deser.read_integer(member)?);
  194    216   
                }
  195    217   
                Some(2) => {
  196    218   
                    builder.scanned_count = Some(deser.read_integer(member)?);
  197    219   
                }
  198    220   
                Some(3) => {
  199    221   
                    builder.last_evaluated_key = Some({
  200         -
                        let container = if let Some(cap) = deser.container_size() {
  201         -
                            std::collections::HashMap::with_capacity(cap)
  202         -
                        } else {
  203         -
                            std::collections::HashMap::new()
  204         -
                        };
  205         -
                        deser.read_map(member, container, |mut map, key, deser| {
  206         -
                            map.insert(key, todo!("deserialize nested aggregate"));
  207         -
                            Ok(map)
  208         -
                        })?
         222  +
                        let mut container = std::collections::HashMap::new();
         223  +
                        deser.read_map(member, &mut |key, deser| {
         224  +
                            container.insert(key, crate::types::AttributeValue::deserialize(deser)?);
         225  +
                            Ok(())
         226  +
                        })?;
         227  +
                        container
         228  +
                    });
         229  +
                }
         230  +
                Some(4) => {
         231  +
                    builder.consumed_capacity = Some(crate::types::ConsumedCapacity::deserialize(deser)?);
         232  +
                }
         233  +
                Some(5) => {
         234  +
                    builder._request_id = Some(deser.read_string(member)?);
         235  +
                }
         236  +
                _ => {}
         237  +
            }
         238  +
            Ok(())
         239  +
        })?;
         240  +
        Ok(builder.build())
         241  +
    }
         242  +
}
         243  +
impl QueryOutput {
         244  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         245  +
    /// Header-bound members are read directly from headers, avoiding runtime
         246  +
    /// member iteration overhead. Body members are read via the deserializer.
         247  +
    pub fn deserialize_with_response(
         248  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         249  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         250  +
        _status: u16,
         251  +
        _body: &[u8],
         252  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         253  +
        #[allow(unused_variables, unused_mut)]
         254  +
        let mut builder = Self::builder();
         255  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         256  +
            builder._request_id = Some(val.to_string());
         257  +
        }
         258  +
        #[allow(
         259  +
            unused_variables,
         260  +
            unreachable_code,
         261  +
            clippy::single_match,
         262  +
            clippy::match_single_binding,
         263  +
            clippy::diverging_sub_expression
         264  +
        )]
         265  +
        deserializer.read_struct(&QUERYOUTPUT_SCHEMA, &mut |member, deser| {
         266  +
            match member.member_index() {
         267  +
                Some(0) => {
         268  +
                    builder.items = Some({
         269  +
                        let mut container = Vec::new();
         270  +
                        deser.read_list(member, &mut |deser| {
         271  +
                            container.push({
         272  +
                                let mut map = ::std::collections::HashMap::new();
         273  +
                                deser.read_map(member, &mut |key, deser| {
         274  +
                                    let value = crate::types::AttributeValue::deserialize(deser)?;
         275  +
                                    map.insert(key, value);
         276  +
                                    Ok(())
         277  +
                                })?;
         278  +
                                map
         279  +
                            });
         280  +
                            Ok(())
         281  +
                        })?;
         282  +
                        container
         283  +
                    });
         284  +
                }
         285  +
                Some(1) => {
         286  +
                    builder.count = Some(deser.read_integer(member)?);
         287  +
                }
         288  +
                Some(2) => {
         289  +
                    builder.scanned_count = Some(deser.read_integer(member)?);
         290  +
                }
         291  +
                Some(3) => {
         292  +
                    builder.last_evaluated_key = Some({
         293  +
                        let mut container = std::collections::HashMap::new();
         294  +
                        deser.read_map(member, &mut |key, deser| {
         295  +
                            container.insert(key, crate::types::AttributeValue::deserialize(deser)?);
         296  +
                            Ok(())
         297  +
                        })?;
         298  +
                        container
  209    299   
                    });
  210    300   
                }
  211    301   
                Some(4) => {
  212    302   
                    builder.consumed_capacity = Some(crate::types::ConsumedCapacity::deserialize(deser)?);
  213    303   
                }
  214    304   
                _ => {}
  215    305   
            }
  216    306   
            Ok(())
  217    307   
        })?;
  218    308   
        Ok(builder.build())

tmp-codegen-diff/aws-sdk/sdk/dynamodb/src/operation/restore_table_from_backup.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 `RestoreTableFromBackup`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct RestoreTableFromBackup;
    6      6   
impl RestoreTableFromBackup {
    7      7   
    /// Creates a new `RestoreTableFromBackup`
    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::restore_table_from_backup::RestoreTableFromBackupInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::restore_table_from_backup::RestoreTableFromBackupOutput::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::restore_table_from_backup::RestoreTableFromBackupInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::restore_table_from_backup::RestoreTableFromBackupOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::restore_table_from_backup::RestoreTableFromBackupError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -118,122 +247,432 @@
  138    142   
                crate::operation::restore_table_from_backup::RestoreTableFromBackupError,
  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 RestoreTableFromBackupResponseDeserializer;
  147    151   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for RestoreTableFromBackupResponseDeserializer {
  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_restore_table_from_backup::de_restore_table_from_backup_http_error(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(
         175  +
                            crate::operation::restore_table_from_backup::RestoreTableFromBackupError::unhandled(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  +
                "BackupInUseException" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::BackupInUseException({
         186  +
                    let mut tmp = match protocol
         187  +
                        .deserialize_response(response, crate::types::error::BackupInUseException::SCHEMA, _cfg)
         188  +
                        .and_then(|mut deser| {
         189  +
                            crate::types::error::BackupInUseException::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  +
                "BackupNotFoundException" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::BackupNotFoundException({
         210  +
                    let mut tmp = match protocol
         211  +
                        .deserialize_response(response, crate::types::error::BackupNotFoundException::SCHEMA, _cfg)
         212  +
                        .and_then(|mut deser| {
         213  +
                            crate::types::error::BackupNotFoundException::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  +
                        }
         226  +
                    };
         227  +
                    tmp.meta = generic;
         228  +
                    if tmp.message.is_none() {
         229  +
                        tmp.message = _error_message;
         230  +
                    }
         231  +
                    tmp
         232  +
                }),
         233  +
                "InternalServerError" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::InternalServerError({
         234  +
                    let mut tmp = match protocol
         235  +
                        .deserialize_response(response, crate::types::error::InternalServerError::SCHEMA, _cfg)
         236  +
                        .and_then(|mut deser| {
         237  +
                            crate::types::error::InternalServerError::deserialize_with_response(
         238  +
                                &mut *deser,
         239  +
                                response.headers(),
         240  +
                                response.status().into(),
         241  +
                                body,
         242  +
                            )
         243  +
                        }) {
         244  +
                        ::std::result::Result::Ok(val) => val,
         245  +
                        ::std::result::Result::Err(e) => {
         246  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         247  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         248  +
                            ))
         249  +
                        }
         250  +
                    };
         251  +
                    tmp.meta = generic;
         252  +
                    if tmp.message.is_none() {
         253  +
                        tmp.message = _error_message;
         254  +
                    }
         255  +
                    tmp
         256  +
                }),
         257  +
                "InvalidEndpointException" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::InvalidEndpointException({
         258  +
                    let mut tmp = match protocol
         259  +
                        .deserialize_response(response, crate::types::error::InvalidEndpointException::SCHEMA, _cfg)
         260  +
                        .and_then(|mut deser| {
         261  +
                            crate::types::error::InvalidEndpointException::deserialize_with_response(
         262  +
                                &mut *deser,
         263  +
                                response.headers(),
         264  +
                                response.status().into(),
         265  +
                                body,
         266  +
                            )
         267  +
                        }) {
         268  +
                        ::std::result::Result::Ok(val) => val,
         269  +
                        ::std::result::Result::Err(e) => {
         270  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         271  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         272  +
                            ))
         273  +
                        }
         274  +
                    };
         275  +
                    tmp.meta = generic;
         276  +
                    if tmp.message.is_none() {
         277  +
                        tmp.message = _error_message;
         278  +
                    }
         279  +
                    tmp
         280  +
                }),
         281  +
                "LimitExceededException" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::LimitExceededException({
         282  +
                    let mut tmp = match protocol
         283  +
                        .deserialize_response(response, crate::types::error::LimitExceededException::SCHEMA, _cfg)
         284  +
                        .and_then(|mut deser| {
         285  +
                            crate::types::error::LimitExceededException::deserialize_with_response(
         286  +
                                &mut *deser,
         287  +
                                response.headers(),
         288  +
                                response.status().into(),
         289  +
                                body,
         290  +
                            )
         291  +
                        }) {
         292  +
                        ::std::result::Result::Ok(val) => val,
         293  +
                        ::std::result::Result::Err(e) => {
         294  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         295  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         296  +
                            ))
         297  +
                        }
         298  +
                    };
         299  +
                    tmp.meta = generic;
         300  +
                    if tmp.message.is_none() {
         301  +
                        tmp.message = _error_message;
         302  +
                    }
         303  +
                    tmp
         304  +
                }),
         305  +
                "TableAlreadyExistsException" => {
         306  +
                    crate::operation::restore_table_from_backup::RestoreTableFromBackupError::TableAlreadyExistsException({
         307  +
                        let mut tmp = match protocol
         308  +
                            .deserialize_response(response, crate::types::error::TableAlreadyExistsException::SCHEMA, _cfg)
         309  +
                            .and_then(|mut deser| {
         310  +
                                crate::types::error::TableAlreadyExistsException::deserialize_with_response(
         311  +
                                    &mut *deser,
         312  +
                                    response.headers(),
         313  +
                                    response.status().into(),
         314  +
                                    body,
         315  +
                                )
         316  +
                            }) {
         317  +
                            ::std::result::Result::Ok(val) => val,
         318  +
                            ::std::result::Result::Err(e) => {
         319  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         320  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         321  +
                                ))
         322  +
                            }
         323  +
                        };
         324  +
                        tmp.meta = generic;
         325  +
                        if tmp.message.is_none() {
         326  +
                            tmp.message = _error_message;
         327  +
                        }
         328  +
                        tmp
         329  +
                    })
         330  +
                }
         331  +
                "TableInUseException" => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::TableInUseException({
         332  +
                    let mut tmp = match protocol
         333  +
                        .deserialize_response(response, crate::types::error::TableInUseException::SCHEMA, _cfg)
         334  +
                        .and_then(|mut deser| {
         335  +
                            crate::types::error::TableInUseException::deserialize_with_response(
         336  +
                                &mut *deser,
         337  +
                                response.headers(),
         338  +
                                response.status().into(),
         339  +
                                body,
         340  +
                            )
         341  +
                        }) {
         342  +
                        ::std::result::Result::Ok(val) => val,
         343  +
                        ::std::result::Result::Err(e) => {
         344  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         345  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         346  +
                            ))
         347  +
                        }
         348  +
                    };
         349  +
                    tmp.meta = generic;
         350  +
                    if tmp.message.is_none() {
         351  +
                        tmp.message = _error_message;
         352  +
                    }
         353  +
                    tmp
         354  +
                }),
         355  +
                _ => crate::operation::restore_table_from_backup::RestoreTableFromBackupError::generic(generic),
         356  +
            };
         357  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         358  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         359  +
            ))
  160    360   
        } else {
  161         -
            crate::protocol_serde::shape_restore_table_from_backup::de_restore_table_from_backup_http_response(status, headers, body)
  162         -
        };
  163         -
        crate::protocol_serde::type_erase_result(parse_result)
         361  +
            let protocol = _cfg
         362  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         363  +
                .expect("a SharedClientProtocol is required");
         364  +
            let mut deser = protocol
         365  +
                .deserialize_response(response, RestoreTableFromBackup::OUTPUT_SCHEMA, _cfg)
         366  +
                .map_err(|e| {
         367  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         368  +
                })?;
         369  +
            let body = response.body().bytes().expect("body loaded");
         370  +
            let output = crate::operation::restore_table_from_backup::RestoreTableFromBackupOutput::deserialize_with_response(
         371  +
                &mut *deser,
         372  +
                response.headers(),
         373  +
                response.status().into(),
         374  +
                body,
         375  +
            )
         376  +
            .map_err(|e| {
         377  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         378  +
            })?;
         379  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         380  +
        }
  164    381   
    }
  165    382   
}
  166    383   
#[derive(Debug)]
  167    384   
struct RestoreTableFromBackupRequestSerializer;
  168    385   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for RestoreTableFromBackupRequestSerializer {
  169    386   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  170    387   
    fn serialize_input(
  171    388   
        &self,
  172    389   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  173    390   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  174    391   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  175    392   
        let input = input
  176    393   
            .downcast::<crate::operation::restore_table_from_backup::RestoreTableFromBackupInput>()
  177    394   
            .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::restore_table_from_backup::RestoreTableFromBackupInput,
  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::restore_table_from_backup::RestoreTableFromBackupInput,
  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.RestoreTableFromBackup",
  207         -
            );
  208         -
            builder
  209         -
        };
  210         -
        let body = ::aws_smithy_types::body::SdkBody::from(
  211         -
            crate::protocol_serde::shape_restore_table_from_backup::ser_restore_table_from_backup_input(&input)?,
  212         -
        );
  213         -
        if let Some(content_length) = body.content_length() {
  214         -
            let content_length = content_length.to_string();
  215         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  216         -
        }
  217         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         395  +
        let protocol = _cfg
         396  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         397  +
            .expect("a SharedClientProtocol is required");
         398  +
        let mut request = protocol
         399  +
            .serialize_request(&input, RestoreTableFromBackup::INPUT_SCHEMA, "", _cfg)
         400  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         401  +
         402  +
        return ::std::result::Result::Ok(request);
  218    403   
    }
  219    404   
}
  220    405   
#[derive(Debug)]
  221    406   
struct RestoreTableFromBackupEndpointParamsInterceptor;
  222    407   
  223    408   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for RestoreTableFromBackupEndpointParamsInterceptor {
  224    409   
    fn name(&self) -> &'static str {
  225    410   
        "RestoreTableFromBackupEndpointParamsInterceptor"
  226    411   
    }
  227    412   

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

@@ -43,43 +173,173 @@
   63     63   
    "com.amazonaws.dynamodb.synthetic",
   64     64   
    "RestoreTableFromBackupInput",
   65     65   
);
   66     66   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_TARGET_TABLE_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   67     67   
    ::aws_smithy_schema::ShapeId::from_static(
   68     68   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$TargetTableName",
   69     69   
        "com.amazonaws.dynamodb.synthetic",
   70     70   
        "RestoreTableFromBackupInput",
   71     71   
    ),
   72     72   
    ::aws_smithy_schema::ShapeType::String,
   73         -
    "target_table_name",
          73  +
    "TargetTableName",
   74     74   
    0,
   75     75   
);
   76     76   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_BACKUP_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   77     77   
    ::aws_smithy_schema::ShapeId::from_static(
   78     78   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$BackupArn",
   79     79   
        "com.amazonaws.dynamodb.synthetic",
   80     80   
        "RestoreTableFromBackupInput",
   81     81   
    ),
   82     82   
    ::aws_smithy_schema::ShapeType::String,
   83         -
    "backup_arn",
          83  +
    "BackupArn",
   84     84   
    1,
   85     85   
);
   86     86   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_BILLING_MODE_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   87     87   
    ::aws_smithy_schema::ShapeId::from_static(
   88     88   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$BillingModeOverride",
   89     89   
        "com.amazonaws.dynamodb.synthetic",
   90     90   
        "RestoreTableFromBackupInput",
   91     91   
    ),
   92     92   
    ::aws_smithy_schema::ShapeType::String,
   93         -
    "billing_mode_override",
          93  +
    "BillingModeOverride",
   94     94   
    2,
   95     95   
);
   96     96   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_GLOBAL_SECONDARY_INDEX_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   97     97   
    ::aws_smithy_schema::ShapeId::from_static(
   98     98   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$GlobalSecondaryIndexOverride",
   99     99   
        "com.amazonaws.dynamodb.synthetic",
  100    100   
        "RestoreTableFromBackupInput",
  101    101   
    ),
  102    102   
    ::aws_smithy_schema::ShapeType::List,
  103         -
    "global_secondary_index_override",
         103  +
    "GlobalSecondaryIndexOverride",
  104    104   
    3,
  105    105   
);
  106    106   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_LOCAL_SECONDARY_INDEX_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  107    107   
    ::aws_smithy_schema::ShapeId::from_static(
  108    108   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$LocalSecondaryIndexOverride",
  109    109   
        "com.amazonaws.dynamodb.synthetic",
  110    110   
        "RestoreTableFromBackupInput",
  111    111   
    ),
  112    112   
    ::aws_smithy_schema::ShapeType::List,
  113         -
    "local_secondary_index_override",
         113  +
    "LocalSecondaryIndexOverride",
  114    114   
    4,
  115    115   
);
  116    116   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_PROVISIONED_THROUGHPUT_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  117    117   
    ::aws_smithy_schema::ShapeId::from_static(
  118    118   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$ProvisionedThroughputOverride",
  119    119   
        "com.amazonaws.dynamodb.synthetic",
  120    120   
        "RestoreTableFromBackupInput",
  121    121   
    ),
  122    122   
    ::aws_smithy_schema::ShapeType::Structure,
  123         -
    "provisioned_throughput_override",
         123  +
    "ProvisionedThroughputOverride",
  124    124   
    5,
  125    125   
);
  126    126   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_ON_DEMAND_THROUGHPUT_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  127    127   
    ::aws_smithy_schema::ShapeId::from_static(
  128    128   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$OnDemandThroughputOverride",
  129    129   
        "com.amazonaws.dynamodb.synthetic",
  130    130   
        "RestoreTableFromBackupInput",
  131    131   
    ),
  132    132   
    ::aws_smithy_schema::ShapeType::Structure,
  133         -
    "on_demand_throughput_override",
         133  +
    "OnDemandThroughputOverride",
  134    134   
    6,
  135    135   
);
  136    136   
static RESTORETABLEFROMBACKUPINPUT_MEMBER_SSE_SPECIFICATION_OVERRIDE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  137    137   
    ::aws_smithy_schema::ShapeId::from_static(
  138    138   
        "com.amazonaws.dynamodb.synthetic#RestoreTableFromBackupInput$SSESpecificationOverride",
  139    139   
        "com.amazonaws.dynamodb.synthetic",
  140    140   
        "RestoreTableFromBackupInput",
  141    141   
    ),
  142    142   
    ::aws_smithy_schema::ShapeType::Structure,
  143         -
    "sse_specification_override",
         143  +
    "SSESpecificationOverride",
  144    144   
    7,
  145    145   
);
  146    146   
static RESTORETABLEFROMBACKUPINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  147    147   
    RESTORETABLEFROMBACKUPINPUT_SCHEMA_ID,
  148    148   
    ::aws_smithy_schema::ShapeType::Structure,
  149    149   
    &[
  150    150   
        &RESTORETABLEFROMBACKUPINPUT_MEMBER_TARGET_TABLE_NAME,
  151    151   
        &RESTORETABLEFROMBACKUPINPUT_MEMBER_BACKUP_ARN,
  152    152   
        &RESTORETABLEFROMBACKUPINPUT_MEMBER_BILLING_MODE_OVERRIDE,
  153    153   
        &RESTORETABLEFROMBACKUPINPUT_MEMBER_GLOBAL_SECONDARY_INDEX_OVERRIDE,
@@ -185,185 +311,318 @@
  205    205   
            ser.write_struct(&RESTORETABLEFROMBACKUPINPUT_MEMBER_ON_DEMAND_THROUGHPUT_OVERRIDE, val)?;
  206    206   
        }
  207    207   
        if let Some(ref val) = self.sse_specification_override {
  208    208   
            ser.write_struct(&RESTORETABLEFROMBACKUPINPUT_MEMBER_SSE_SPECIFICATION_OVERRIDE, val)?;
  209    209   
        }
  210    210   
        Ok(())
  211    211   
    }
  212    212   
}
  213    213   
impl RestoreTableFromBackupInput {
  214    214   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  215         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  216         -
        deserializer: &mut D,
         215  +
    pub fn deserialize(
         216  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  217    217   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  218    218   
        #[allow(unused_variables, unused_mut)]
  219    219   
        let mut builder = Self::builder();
  220    220   
        #[allow(
  221    221   
            unused_variables,
  222    222   
            unreachable_code,
  223    223   
            clippy::single_match,
  224    224   
            clippy::match_single_binding,
  225    225   
            clippy::diverging_sub_expression
  226    226   
        )]
  227         -
        deserializer.read_struct(&RESTORETABLEFROMBACKUPINPUT_SCHEMA, (), |_, member, deser| {
         227  +
        deserializer.read_struct(&RESTORETABLEFROMBACKUPINPUT_SCHEMA, &mut |member, deser| {
  228    228   
            match member.member_index() {
  229    229   
                Some(0) => {
  230    230   
                    builder.target_table_name = Some(deser.read_string(member)?);
  231    231   
                }
  232    232   
                Some(1) => {
  233    233   
                    builder.backup_arn = Some(deser.read_string(member)?);
  234    234   
                }
  235    235   
                Some(2) => {
  236    236   
                    builder.billing_mode_override = Some(crate::types::BillingMode::from(deser.read_string(member)?.as_str()));
  237    237   
                }
  238    238   
                Some(3) => {
  239    239   
                    builder.global_secondary_index_override = Some({
  240         -
                        let container = if let Some(cap) = deser.container_size() {
  241         -
                            Vec::with_capacity(cap)
  242         -
                        } else {
  243         -
                            Vec::new()
  244         -
                        };
  245         -
                        deser.read_list(member, container, |mut list, deser| {
  246         -
                            list.push(crate::types::GlobalSecondaryIndex::deserialize(deser)?);
  247         -
                            Ok(list)
  248         -
                        })?
         240  +
                        let mut container = Vec::new();
         241  +
                        deser.read_list(member, &mut |deser| {
         242  +
                            container.push(crate::types::GlobalSecondaryIndex::deserialize(deser)?);
         243  +
                            Ok(())
         244  +
                        })?;
         245  +
                        container
  249    246   
                    });
  250    247   
                }
  251    248   
                Some(4) => {
  252    249   
                    builder.local_secondary_index_override = Some({
  253         -
                        let container = if let Some(cap) = deser.container_size() {
  254         -
                            Vec::with_capacity(cap)
  255         -
                        } else {
  256         -
                            Vec::new()
  257         -
                        };
  258         -
                        deser.read_list(member, container, |mut list, deser| {
  259         -
                            list.push(crate::types::LocalSecondaryIndex::deserialize(deser)?);
  260         -
                            Ok(list)
  261         -
                        })?
         250  +
                        let mut container = Vec::new();
         251  +
                        deser.read_list(member, &mut |deser| {
         252  +
                            container.push(crate::types::LocalSecondaryIndex::deserialize(deser)?);
         253  +
                            Ok(())
         254  +
                        })?;
         255  +
                        container
  262    256   
                    });
  263    257   
                }
  264    258   
                Some(5) => {
  265    259   
                    builder.provisioned_throughput_override = Some(crate::types::ProvisionedThroughput::deserialize(deser)?);
  266    260   
                }
  267    261   
                Some(6) => {
  268    262   
                    builder.on_demand_throughput_override = Some(crate::types::OnDemandThroughput::deserialize(deser)?);
  269    263   
                }
  270    264   
                Some(7) => {
  271    265   
                    builder.sse_specification_override = Some(crate::types::SseSpecification::deserialize(deser)?);
  272    266   
                }
  273    267   
                _ => {}
  274    268   
            }
  275    269   
            Ok(())
  276    270   
        })?;
         271  +
        builder.target_table_name = builder.target_table_name.or(Some(String::new()));
         272  +
        builder.backup_arn = builder.backup_arn.or(Some(String::new()));
  277    273   
        builder
  278    274   
            .build()
  279    275   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  280    276   
    }
  281    277   
}
         278  +
impl RestoreTableFromBackupInput {
         279  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         280  +
    pub fn deserialize_with_response(
         281  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         282  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         283  +
        _status: u16,
         284  +
        _body: &[u8],
         285  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         286  +
        Self::deserialize(deserializer)
         287  +
    }
         288  +
}
  282    289   
impl RestoreTableFromBackupInput {
  283    290   
    /// Creates a new builder-style object to manufacture [`RestoreTableFromBackupInput`](crate::operation::restore_table_from_backup::RestoreTableFromBackupInput).
  284    291   
    pub fn builder() -> crate::operation::restore_table_from_backup::builders::RestoreTableFromBackupInputBuilder {
  285    292   
        crate::operation::restore_table_from_backup::builders::RestoreTableFromBackupInputBuilder::default()
  286    293   
    }
  287    294   
}
  288    295   
  289    296   
/// A builder for [`RestoreTableFromBackupInput`](crate::operation::restore_table_from_backup::RestoreTableFromBackupInput).
  290    297   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  291    298   
#[non_exhaustive]

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

@@ -1,1 +96,143 @@
   18     18   
    "com.amazonaws.dynamodb.synthetic",
   19     19   
    "RestoreTableFromBackupOutput",
   20     20   
);
   21     21   
static RESTORETABLEFROMBACKUPOUTPUT_MEMBER_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#RestoreTableFromBackupOutput$TableDescription",
   24     24   
        "com.amazonaws.dynamodb.synthetic",
   25     25   
        "RestoreTableFromBackupOutput",
   26     26   
    ),
   27     27   
    ::aws_smithy_schema::ShapeType::Structure,
   28         -
    "table_description",
          28  +
    "TableDescription",
   29     29   
    0,
   30     30   
);
          31  +
static RESTORETABLEFROMBACKUPOUTPUT_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 RESTORETABLEFROMBACKUPOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   32     39   
    RESTORETABLEFROMBACKUPOUTPUT_SCHEMA_ID,
   33     40   
    ::aws_smithy_schema::ShapeType::Structure,
   34         -
    &[&RESTORETABLEFROMBACKUPOUTPUT_MEMBER_TABLE_DESCRIPTION],
          41  +
    &[
          42  +
        &RESTORETABLEFROMBACKUPOUTPUT_MEMBER_TABLE_DESCRIPTION,
          43  +
        &RESTORETABLEFROMBACKUPOUTPUT_MEMBER__REQUEST_ID,
          44  +
    ],
   35     45   
);
   36     46   
impl RestoreTableFromBackupOutput {
   37     47   
    /// The schema for this shape.
   38     48   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTORETABLEFROMBACKUPOUTPUT_SCHEMA;
   39     49   
}
   40     50   
impl ::aws_smithy_schema::serde::SerializableStruct for RestoreTableFromBackupOutput {
   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.table_description {
   47     57   
            ser.write_struct(&RESTORETABLEFROMBACKUPOUTPUT_MEMBER_TABLE_DESCRIPTION, val)?;
   48     58   
        }
   49     59   
        Ok(())
   50     60   
    }
   51     61   
}
   52     62   
impl RestoreTableFromBackupOutput {
   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(&RESTORETABLEFROMBACKUPOUTPUT_SCHEMA, (), |_, member, deser| {
          76  +
        deserializer.read_struct(&RESTORETABLEFROMBACKUPOUTPUT_SCHEMA, &mut |member, deser| {
          77  +
            match member.member_index() {
          78  +
                Some(0) => {
          79  +
                    builder.table_description = Some(crate::types::TableDescription::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 RestoreTableFromBackupOutput {
          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(&RESTORETABLEFROMBACKUPOUTPUT_SCHEMA, &mut |member, deser| {
   67    114   
            match member.member_index() {
   68    115   
                Some(0) => {
   69    116   
                    builder.table_description = Some(crate::types::TableDescription::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/restore_table_to_point_in_time.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 `RestoreTableToPointInTime`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct RestoreTableToPointInTime;
    6      6   
impl RestoreTableToPointInTime {
    7      7   
    /// Creates a new `RestoreTableToPointInTime`
    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::restore_table_to_point_in_time::RestoreTableToPointInTimeInput::SCHEMA;
          14  +
    /// The schema for this operation's output shape.
          15  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          16  +
        crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeOutput::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::restore_table_to_point_in_time::RestoreTableToPointInTimeInput,
   14     20   
    ) -> ::std::result::Result<
   15     21   
        crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeOutput,
   16     22   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     23   
            crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError,
   18     24   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     25   
        >,
   20     26   
    > {
@@ -124,130 +253,474 @@
  144    150   
                crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError,
  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 RestoreTableToPointInTimeResponseDeserializer;
  153    159   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for RestoreTableToPointInTimeResponseDeserializer {
  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_restore_table_to_point_in_time::de_restore_table_to_point_in_time_http_error(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::restore_table_to_point_in_time::RestoreTableToPointInTimeError::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" => crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::InternalServerError({
         194  +
                    let mut tmp = match protocol
         195  +
                        .deserialize_response(response, crate::types::error::InternalServerError::SCHEMA, _cfg)
         196  +
                        .and_then(|mut deser| {
         197  +
                            crate::types::error::InternalServerError::deserialize_with_response(
         198  +
                                &mut *deser,
         199  +
                                response.headers(),
         200  +
                                response.status().into(),
         201  +
                                body,
         202  +
                            )
         203  +
                        }) {
         204  +
                        ::std::result::Result::Ok(val) => val,
         205  +
                        ::std::result::Result::Err(e) => {
         206  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         207  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         208  +
                            ))
         209  +
                        }
         210  +
                    };
         211  +
                    tmp.meta = generic;
         212  +
                    if tmp.message.is_none() {
         213  +
                        tmp.message = _error_message;
         214  +
                    }
         215  +
                    tmp
         216  +
                }),
         217  +
                "InvalidEndpointException" => {
         218  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::InvalidEndpointException({
         219  +
                        let mut tmp = match protocol
         220  +
                            .deserialize_response(response, crate::types::error::InvalidEndpointException::SCHEMA, _cfg)
         221  +
                            .and_then(|mut deser| {
         222  +
                                crate::types::error::InvalidEndpointException::deserialize_with_response(
         223  +
                                    &mut *deser,
         224  +
                                    response.headers(),
         225  +
                                    response.status().into(),
         226  +
                                    body,
         227  +
                                )
         228  +
                            }) {
         229  +
                            ::std::result::Result::Ok(val) => val,
         230  +
                            ::std::result::Result::Err(e) => {
         231  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         232  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         233  +
                                ))
         234  +
                            }
         235  +
                        };
         236  +
                        tmp.meta = generic;
         237  +
                        if tmp.message.is_none() {
         238  +
                            tmp.message = _error_message;
         239  +
                        }
         240  +
                        tmp
         241  +
                    })
         242  +
                }
         243  +
                "InvalidRestoreTimeException" => {
         244  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::InvalidRestoreTimeException({
         245  +
                        let mut tmp = match protocol
         246  +
                            .deserialize_response(response, crate::types::error::InvalidRestoreTimeException::SCHEMA, _cfg)
         247  +
                            .and_then(|mut deser| {
         248  +
                                crate::types::error::InvalidRestoreTimeException::deserialize_with_response(
         249  +
                                    &mut *deser,
         250  +
                                    response.headers(),
         251  +
                                    response.status().into(),
         252  +
                                    body,
         253  +
                                )
         254  +
                            }) {
         255  +
                            ::std::result::Result::Ok(val) => val,
         256  +
                            ::std::result::Result::Err(e) => {
         257  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         258  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         259  +
                                ))
         260  +
                            }
         261  +
                        };
         262  +
                        tmp.meta = generic;
         263  +
                        if tmp.message.is_none() {
         264  +
                            tmp.message = _error_message;
         265  +
                        }
         266  +
                        tmp
         267  +
                    })
         268  +
                }
         269  +
                "LimitExceededException" => {
         270  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::LimitExceededException({
         271  +
                        let mut tmp = match protocol
         272  +
                            .deserialize_response(response, crate::types::error::LimitExceededException::SCHEMA, _cfg)
         273  +
                            .and_then(|mut deser| {
         274  +
                                crate::types::error::LimitExceededException::deserialize_with_response(
         275  +
                                    &mut *deser,
         276  +
                                    response.headers(),
         277  +
                                    response.status().into(),
         278  +
                                    body,
         279  +
                                )
         280  +
                            }) {
         281  +
                            ::std::result::Result::Ok(val) => val,
         282  +
                            ::std::result::Result::Err(e) => {
         283  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         284  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         285  +
                                ))
         286  +
                            }
         287  +
                        };
         288  +
                        tmp.meta = generic;
         289  +
                        if tmp.message.is_none() {
         290  +
                            tmp.message = _error_message;
         291  +
                        }
         292  +
                        tmp
         293  +
                    })
         294  +
                }
         295  +
                "PointInTimeRecoveryUnavailableException" => {
         296  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::PointInTimeRecoveryUnavailableException({
         297  +
                        let mut tmp = match protocol
         298  +
                            .deserialize_response(response, crate::types::error::PointInTimeRecoveryUnavailableException::SCHEMA, _cfg)
         299  +
                            .and_then(|mut deser| {
         300  +
                                crate::types::error::PointInTimeRecoveryUnavailableException::deserialize_with_response(
         301  +
                                    &mut *deser,
         302  +
                                    response.headers(),
         303  +
                                    response.status().into(),
         304  +
                                    body,
         305  +
                                )
         306  +
                            }) {
         307  +
                            ::std::result::Result::Ok(val) => val,
         308  +
                            ::std::result::Result::Err(e) => {
         309  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         310  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         311  +
                                ))
         312  +
                            }
         313  +
                        };
         314  +
                        tmp.meta = generic;
         315  +
                        if tmp.message.is_none() {
         316  +
                            tmp.message = _error_message;
         317  +
                        }
         318  +
                        tmp
         319  +
                    })
         320  +
                }
         321  +
                "TableAlreadyExistsException" => {
         322  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::TableAlreadyExistsException({
         323  +
                        let mut tmp = match protocol
         324  +
                            .deserialize_response(response, crate::types::error::TableAlreadyExistsException::SCHEMA, _cfg)
         325  +
                            .and_then(|mut deser| {
         326  +
                                crate::types::error::TableAlreadyExistsException::deserialize_with_response(
         327  +
                                    &mut *deser,
         328  +
                                    response.headers(),
         329  +
                                    response.status().into(),
         330  +
                                    body,
         331  +
                                )
         332  +
                            }) {
         333  +
                            ::std::result::Result::Ok(val) => val,
         334  +
                            ::std::result::Result::Err(e) => {
         335  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         336  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         337  +
                                ))
         338  +
                            }
         339  +
                        };
         340  +
                        tmp.meta = generic;
         341  +
                        if tmp.message.is_none() {
         342  +
                            tmp.message = _error_message;
         343  +
                        }
         344  +
                        tmp
         345  +
                    })
         346  +
                }
         347  +
                "TableInUseException" => crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::TableInUseException({
         348  +
                    let mut tmp = match protocol
         349  +
                        .deserialize_response(response, crate::types::error::TableInUseException::SCHEMA, _cfg)
         350  +
                        .and_then(|mut deser| {
         351  +
                            crate::types::error::TableInUseException::deserialize_with_response(
         352  +
                                &mut *deser,
         353  +
                                response.headers(),
         354  +
                                response.status().into(),
         355  +
                                body,
         356  +
                            )
         357  +
                        }) {
         358  +
                        ::std::result::Result::Ok(val) => val,
         359  +
                        ::std::result::Result::Err(e) => {
         360  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         361  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         362  +
                            ))
         363  +
                        }
         364  +
                    };
         365  +
                    tmp.meta = generic;
         366  +
                    if tmp.message.is_none() {
         367  +
                        tmp.message = _error_message;
         368  +
                    }
         369  +
                    tmp
         370  +
                }),
         371  +
                "TableNotFoundException" => {
         372  +
                    crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::TableNotFoundException({
         373  +
                        let mut tmp = match protocol
         374  +
                            .deserialize_response(response, crate::types::error::TableNotFoundException::SCHEMA, _cfg)
         375  +
                            .and_then(|mut deser| {
         376  +
                                crate::types::error::TableNotFoundException::deserialize_with_response(
         377  +
                                    &mut *deser,
         378  +
                                    response.headers(),
         379  +
                                    response.status().into(),
         380  +
                                    body,
         381  +
                                )
         382  +
                            }) {
         383  +
                            ::std::result::Result::Ok(val) => val,
         384  +
                            ::std::result::Result::Err(e) => {
         385  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         386  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         387  +
                                ))
         388  +
                            }
         389  +
                        };
         390  +
                        tmp.meta = generic;
         391  +
                        if tmp.message.is_none() {
         392  +
                            tmp.message = _error_message;
         393  +
                        }
         394  +
                        tmp
         395  +
                    })
         396  +
                }
         397  +
                _ => crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeError::generic(generic),
         398  +
            };
         399  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         400  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         401  +
            ))
  166    402   
        } else {
  167         -
            crate::protocol_serde::shape_restore_table_to_point_in_time::de_restore_table_to_point_in_time_http_response(status, headers, body)
  168         -
        };
  169         -
        crate::protocol_serde::type_erase_result(parse_result)
         403  +
            let protocol = _cfg
         404  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         405  +
                .expect("a SharedClientProtocol is required");
         406  +
            let mut deser = protocol
         407  +
                .deserialize_response(response, RestoreTableToPointInTime::OUTPUT_SCHEMA, _cfg)
         408  +
                .map_err(|e| {
         409  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         410  +
                })?;
         411  +
            let body = response.body().bytes().expect("body loaded");
         412  +
            let output = crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeOutput::deserialize_with_response(
         413  +
                &mut *deser,
         414  +
                response.headers(),
         415  +
                response.status().into(),
         416  +
                body,
         417  +
            )
         418  +
            .map_err(|e| {
         419  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         420  +
            })?;
         421  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         422  +
        }
  170    423   
    }
  171    424   
}
  172    425   
#[derive(Debug)]
  173    426   
struct RestoreTableToPointInTimeRequestSerializer;
  174    427   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for RestoreTableToPointInTimeRequestSerializer {
  175    428   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  176    429   
    fn serialize_input(
  177    430   
        &self,
  178    431   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  179    432   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  180    433   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  181    434   
        let input = input
  182    435   
            .downcast::<crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeInput>()
  183    436   
            .expect("correct type");
  184         -
        let _header_serialization_settings = _cfg
  185         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  186         -
            .cloned()
  187         -
            .unwrap_or_default();
  188         -
        let mut request_builder = {
  189         -
            #[allow(clippy::uninlined_format_args)]
  190         -
            fn uri_base(
  191         -
                _input: &crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeInput,
  192         -
                output: &mut ::std::string::String,
  193         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  194         -
                use ::std::fmt::Write as _;
  195         -
                ::std::write!(output, "/").expect("formatting should succeed");
  196         -
                ::std::result::Result::Ok(())
  197         -
            }
  198         -
            #[allow(clippy::unnecessary_wraps)]
  199         -
            fn update_http_builder(
  200         -
                input: &crate::operation::restore_table_to_point_in_time::RestoreTableToPointInTimeInput,
  201         -
                builder: ::http_1x::request::Builder,
  202         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  203         -
                let mut uri = ::std::string::String::new();
  204         -
                uri_base(input, &mut uri)?;
  205         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  206         -
            }
  207         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  208         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.0");
  209         -
            builder = _header_serialization_settings.set_default_header(
  210         -
                builder,
  211         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  212         -
                "DynamoDB_20120810.RestoreTableToPointInTime",
  213         -
            );
  214         -
            builder
  215         -
        };
  216         -
        let body = ::aws_smithy_types::body::SdkBody::from(
  217         -
            crate::protocol_serde::shape_restore_table_to_point_in_time::ser_restore_table_to_point_in_time_input(&input)?,
  218         -
        );
  219         -
        if let Some(content_length) = body.content_length() {
  220         -
            let content_length = content_length.to_string();
  221         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  222         -
        }
  223         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         437  +
        let protocol = _cfg
         438  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         439  +
            .expect("a SharedClientProtocol is required");
         440  +
        let mut request = protocol
         441  +
            .serialize_request(&input, RestoreTableToPointInTime::INPUT_SCHEMA, "", _cfg)
         442  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         443  +
         444  +
        return ::std::result::Result::Ok(request);
  224    445   
    }
  225    446   
}
  226    447   
#[derive(Debug)]
  227    448   
struct RestoreTableToPointInTimeEndpointParamsInterceptor;
  228    449   
  229    450   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for RestoreTableToPointInTimeEndpointParamsInterceptor {
  230    451   
    fn name(&self) -> &'static str {
  231    452   
        "RestoreTableToPointInTimeEndpointParamsInterceptor"
  232    453   
    }
  233    454