AWS SDK

AWS SDK

rev. 32b1b3c3761061baed26023be3219639e42d7d12

Files changed:

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/describe_vault/_describe_vault_input.rs

@@ -4,4 +133,147 @@
   24     24   
    "com.amazonaws.glacier.synthetic",
   25     25   
    "DescribeVaultInput",
   26     26   
);
   27     27   
static DESCRIBEVAULTINPUT_MEMBER_ACCOUNT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   28     28   
    ::aws_smithy_schema::ShapeId::from_static(
   29     29   
        "com.amazonaws.glacier.synthetic#DescribeVaultInput$accountId",
   30     30   
        "com.amazonaws.glacier.synthetic",
   31     31   
        "DescribeVaultInput",
   32     32   
    ),
   33     33   
    ::aws_smithy_schema::ShapeType::String,
   34         -
    "account_id",
          34  +
    "accountId",
   35     35   
    0,
   36     36   
)
   37     37   
.with_http_label();
   38     38   
static DESCRIBEVAULTINPUT_MEMBER_VAULT_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   39     39   
    ::aws_smithy_schema::ShapeId::from_static(
   40     40   
        "com.amazonaws.glacier.synthetic#DescribeVaultInput$vaultName",
   41     41   
        "com.amazonaws.glacier.synthetic",
   42     42   
        "DescribeVaultInput",
   43     43   
    ),
   44     44   
    ::aws_smithy_schema::ShapeType::String,
   45         -
    "vault_name",
          45  +
    "vaultName",
   46     46   
    1,
   47     47   
)
   48     48   
.with_http_label();
   49     49   
static DESCRIBEVAULTINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   50     50   
    DESCRIBEVAULTINPUT_SCHEMA_ID,
   51     51   
    ::aws_smithy_schema::ShapeType::Structure,
   52     52   
    &[&DESCRIBEVAULTINPUT_MEMBER_ACCOUNT_ID, &DESCRIBEVAULTINPUT_MEMBER_VAULT_NAME],
   53         -
);
          53  +
)
          54  +
.with_http(aws_smithy_schema::traits::HttpTrait::new("GET", "/{accountId}/vaults/{vaultName}", None));
   54     55   
impl DescribeVaultInput {
   55     56   
    /// The schema for this shape.
   56     57   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEVAULTINPUT_SCHEMA;
   57     58   
}
   58     59   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeVaultInput {
   59     60   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   60     61   
    fn serialize_members(
   61     62   
        &self,
   62     63   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   63     64   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   64     65   
        if let Some(ref val) = self.account_id {
   65     66   
            ser.write_string(&DESCRIBEVAULTINPUT_MEMBER_ACCOUNT_ID, val)?;
   66     67   
        }
   67     68   
        if let Some(ref val) = self.vault_name {
   68     69   
            ser.write_string(&DESCRIBEVAULTINPUT_MEMBER_VAULT_NAME, val)?;
   69     70   
        }
   70     71   
        Ok(())
   71     72   
    }
   72     73   
}
   73     74   
impl DescribeVaultInput {
   74     75   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   75         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   76         -
        deserializer: &mut D,
          76  +
    pub fn deserialize(
          77  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   77     78   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   78     79   
        #[allow(unused_variables, unused_mut)]
   79     80   
        let mut builder = Self::builder();
   80     81   
        #[allow(
   81     82   
            unused_variables,
   82     83   
            unreachable_code,
   83     84   
            clippy::single_match,
   84     85   
            clippy::match_single_binding,
   85     86   
            clippy::diverging_sub_expression
   86     87   
        )]
   87         -
        deserializer.read_struct(&DESCRIBEVAULTINPUT_SCHEMA, (), |_, member, deser| {
          88  +
        deserializer.read_struct(&DESCRIBEVAULTINPUT_SCHEMA, &mut |member, deser| {
   88     89   
            match member.member_index() {
   89     90   
                Some(0) => {
   90     91   
                    builder.account_id = Some(deser.read_string(member)?);
   91     92   
                }
   92     93   
                Some(1) => {
   93     94   
                    builder.vault_name = Some(deser.read_string(member)?);
   94     95   
                }
   95     96   
                _ => {}
   96     97   
            }
   97     98   
            Ok(())
   98     99   
        })?;
         100  +
        builder.account_id = builder.account_id.or(Some(String::new()));
         101  +
        builder.vault_name = builder.vault_name.or(Some(String::new()));
   99    102   
        builder
  100    103   
            .build()
  101    104   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  102    105   
    }
  103    106   
}
         107  +
impl DescribeVaultInput {
         108  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         109  +
    pub fn deserialize_with_response(
         110  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         111  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         112  +
        _status: u16,
         113  +
        _body: &[u8],
         114  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         115  +
        Self::deserialize(deserializer)
         116  +
    }
         117  +
}
  104    118   
impl crate::glacier_interceptors::GlacierAccountId for DescribeVaultInput {
  105    119   
    fn account_id_mut(&mut self) -> &mut Option<String> {
  106    120   
        &mut self.account_id
  107    121   
    }
  108    122   
}
  109    123   
impl DescribeVaultInput {
  110    124   
    /// Creates a new builder-style object to manufacture [`DescribeVaultInput`](crate::operation::describe_vault::DescribeVaultInput).
  111    125   
    pub fn builder() -> crate::operation::describe_vault::builders::DescribeVaultInputBuilder {
  112    126   
        crate::operation::describe_vault::builders::DescribeVaultInputBuilder::default()
  113    127   
    }

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/describe_vault/_describe_vault_output.rs

@@ -29,29 +201,261 @@
   49     49   
    "com.amazonaws.glacier.synthetic",
   50     50   
    "DescribeVaultOutput",
   51     51   
);
   52     52   
static DESCRIBEVAULTOUTPUT_MEMBER_VAULT_ARN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   53     53   
    ::aws_smithy_schema::ShapeId::from_static(
   54     54   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$VaultARN",
   55     55   
        "com.amazonaws.glacier.synthetic",
   56     56   
        "DescribeVaultOutput",
   57     57   
    ),
   58     58   
    ::aws_smithy_schema::ShapeType::String,
   59         -
    "vault_arn",
          59  +
    "VaultARN",
   60     60   
    0,
   61     61   
);
   62     62   
static DESCRIBEVAULTOUTPUT_MEMBER_VAULT_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   63     63   
    ::aws_smithy_schema::ShapeId::from_static(
   64     64   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$VaultName",
   65     65   
        "com.amazonaws.glacier.synthetic",
   66     66   
        "DescribeVaultOutput",
   67     67   
    ),
   68     68   
    ::aws_smithy_schema::ShapeType::String,
   69         -
    "vault_name",
          69  +
    "VaultName",
   70     70   
    1,
   71     71   
);
   72     72   
static DESCRIBEVAULTOUTPUT_MEMBER_CREATION_DATE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   73     73   
    ::aws_smithy_schema::ShapeId::from_static(
   74     74   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$CreationDate",
   75     75   
        "com.amazonaws.glacier.synthetic",
   76     76   
        "DescribeVaultOutput",
   77     77   
    ),
   78     78   
    ::aws_smithy_schema::ShapeType::String,
   79         -
    "creation_date",
          79  +
    "CreationDate",
   80     80   
    2,
   81     81   
);
   82     82   
static DESCRIBEVAULTOUTPUT_MEMBER_LAST_INVENTORY_DATE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   83     83   
    ::aws_smithy_schema::ShapeId::from_static(
   84     84   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$LastInventoryDate",
   85     85   
        "com.amazonaws.glacier.synthetic",
   86     86   
        "DescribeVaultOutput",
   87     87   
    ),
   88     88   
    ::aws_smithy_schema::ShapeType::String,
   89         -
    "last_inventory_date",
          89  +
    "LastInventoryDate",
   90     90   
    3,
   91     91   
);
   92     92   
static DESCRIBEVAULTOUTPUT_MEMBER_NUMBER_OF_ARCHIVES: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   93     93   
    ::aws_smithy_schema::ShapeId::from_static(
   94     94   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$NumberOfArchives",
   95     95   
        "com.amazonaws.glacier.synthetic",
   96     96   
        "DescribeVaultOutput",
   97     97   
    ),
   98     98   
    ::aws_smithy_schema::ShapeType::Long,
   99         -
    "number_of_archives",
          99  +
    "NumberOfArchives",
  100    100   
    4,
  101    101   
);
  102    102   
static DESCRIBEVAULTOUTPUT_MEMBER_SIZE_IN_BYTES: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  103    103   
    ::aws_smithy_schema::ShapeId::from_static(
  104    104   
        "com.amazonaws.glacier.synthetic#DescribeVaultOutput$SizeInBytes",
  105    105   
        "com.amazonaws.glacier.synthetic",
  106    106   
        "DescribeVaultOutput",
  107    107   
    ),
  108    108   
    ::aws_smithy_schema::ShapeType::Long,
  109         -
    "size_in_bytes",
         109  +
    "SizeInBytes",
  110    110   
    5,
  111    111   
);
         112  +
static DESCRIBEVAULTOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
         113  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
         114  +
    ::aws_smithy_schema::ShapeType::String,
         115  +
    "request_id",
         116  +
    6,
         117  +
)
         118  +
.with_http_header("x-amzn-requestid");
  112    119   
static DESCRIBEVAULTOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  113    120   
    DESCRIBEVAULTOUTPUT_SCHEMA_ID,
  114    121   
    ::aws_smithy_schema::ShapeType::Structure,
  115    122   
    &[
  116    123   
        &DESCRIBEVAULTOUTPUT_MEMBER_VAULT_ARN,
  117    124   
        &DESCRIBEVAULTOUTPUT_MEMBER_VAULT_NAME,
  118    125   
        &DESCRIBEVAULTOUTPUT_MEMBER_CREATION_DATE,
  119    126   
        &DESCRIBEVAULTOUTPUT_MEMBER_LAST_INVENTORY_DATE,
  120    127   
        &DESCRIBEVAULTOUTPUT_MEMBER_NUMBER_OF_ARCHIVES,
  121    128   
        &DESCRIBEVAULTOUTPUT_MEMBER_SIZE_IN_BYTES,
         129  +
        &DESCRIBEVAULTOUTPUT_MEMBER__REQUEST_ID,
  122    130   
    ],
  123    131   
);
  124    132   
impl DescribeVaultOutput {
  125    133   
    /// The schema for this shape.
  126    134   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEVAULTOUTPUT_SCHEMA;
  127    135   
}
  128    136   
impl ::aws_smithy_schema::serde::SerializableStruct for DescribeVaultOutput {
  129    137   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
  130    138   
    fn serialize_members(
  131    139   
        &self,
  132    140   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
  133    141   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
  134    142   
        if let Some(ref val) = self.vault_arn {
  135    143   
            ser.write_string(&DESCRIBEVAULTOUTPUT_MEMBER_VAULT_ARN, val)?;
  136    144   
        }
  137    145   
        if let Some(ref val) = self.vault_name {
  138    146   
            ser.write_string(&DESCRIBEVAULTOUTPUT_MEMBER_VAULT_NAME, val)?;
  139    147   
        }
  140    148   
        if let Some(ref val) = self.creation_date {
  141    149   
            ser.write_string(&DESCRIBEVAULTOUTPUT_MEMBER_CREATION_DATE, val)?;
  142    150   
        }
  143    151   
        if let Some(ref val) = self.last_inventory_date {
  144    152   
            ser.write_string(&DESCRIBEVAULTOUTPUT_MEMBER_LAST_INVENTORY_DATE, val)?;
  145    153   
        }
  146    154   
        {
  147    155   
            let val = &self.number_of_archives;
  148    156   
            ser.write_long(&DESCRIBEVAULTOUTPUT_MEMBER_NUMBER_OF_ARCHIVES, *val)?;
  149    157   
        }
  150    158   
        {
  151    159   
            let val = &self.size_in_bytes;
  152    160   
            ser.write_long(&DESCRIBEVAULTOUTPUT_MEMBER_SIZE_IN_BYTES, *val)?;
  153    161   
        }
  154    162   
        Ok(())
  155    163   
    }
  156    164   
}
  157    165   
impl DescribeVaultOutput {
  158    166   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  159         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  160         -
        deserializer: &mut D,
         167  +
    pub fn deserialize(
         168  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         169  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         170  +
        #[allow(unused_variables, unused_mut)]
         171  +
        let mut builder = Self::builder();
         172  +
        #[allow(
         173  +
            unused_variables,
         174  +
            unreachable_code,
         175  +
            clippy::single_match,
         176  +
            clippy::match_single_binding,
         177  +
            clippy::diverging_sub_expression
         178  +
        )]
         179  +
        deserializer.read_struct(&DESCRIBEVAULTOUTPUT_SCHEMA, &mut |member, deser| {
         180  +
            match member.member_index() {
         181  +
                Some(0) => {
         182  +
                    builder.vault_arn = Some(deser.read_string(member)?);
         183  +
                }
         184  +
                Some(1) => {
         185  +
                    builder.vault_name = Some(deser.read_string(member)?);
         186  +
                }
         187  +
                Some(2) => {
         188  +
                    builder.creation_date = Some(deser.read_string(member)?);
         189  +
                }
         190  +
                Some(3) => {
         191  +
                    builder.last_inventory_date = Some(deser.read_string(member)?);
         192  +
                }
         193  +
                Some(4) => {
         194  +
                    builder.number_of_archives = Some(deser.read_long(member)?);
         195  +
                }
         196  +
                Some(5) => {
         197  +
                    builder.size_in_bytes = Some(deser.read_long(member)?);
         198  +
                }
         199  +
                Some(6) => {
         200  +
                    builder._request_id = Some(deser.read_string(member)?);
         201  +
                }
         202  +
                _ => {}
         203  +
            }
         204  +
            Ok(())
         205  +
        })?;
         206  +
        Ok(builder.build())
         207  +
    }
         208  +
}
         209  +
impl DescribeVaultOutput {
         210  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         211  +
    /// Header-bound members are read directly from headers, avoiding runtime
         212  +
    /// member iteration overhead. Body members are read via the deserializer.
         213  +
    pub fn deserialize_with_response(
         214  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         215  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         216  +
        _status: u16,
         217  +
        _body: &[u8],
  161    218   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  162    219   
        #[allow(unused_variables, unused_mut)]
  163    220   
        let mut builder = Self::builder();
         221  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         222  +
            builder._request_id = Some(val.to_string());
         223  +
        }
  164    224   
        #[allow(
  165    225   
            unused_variables,
  166    226   
            unreachable_code,
  167    227   
            clippy::single_match,
  168    228   
            clippy::match_single_binding,
  169    229   
            clippy::diverging_sub_expression
  170    230   
        )]
  171         -
        deserializer.read_struct(&DESCRIBEVAULTOUTPUT_SCHEMA, (), |_, member, deser| {
         231  +
        deserializer.read_struct(&DESCRIBEVAULTOUTPUT_SCHEMA, &mut |member, deser| {
  172    232   
            match member.member_index() {
  173    233   
                Some(0) => {
  174    234   
                    builder.vault_arn = Some(deser.read_string(member)?);
  175    235   
                }
  176    236   
                Some(1) => {
  177    237   
                    builder.vault_name = Some(deser.read_string(member)?);
  178    238   
                }
  179    239   
                Some(2) => {
  180    240   
                    builder.creation_date = Some(deser.read_string(member)?);
  181    241   
                }

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_data_retrieval_policy.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 `GetDataRetrievalPolicy`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct GetDataRetrievalPolicy;
    6      6   
impl GetDataRetrievalPolicy {
    7      7   
    /// Creates a new `GetDataRetrievalPolicy`
    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::get_data_retrieval_policy::GetDataRetrievalPolicyInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyOutput::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::get_data_retrieval_policy::GetDataRetrievalPolicyInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -121,125 +250,373 @@
  141    145   
                crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError,
  142    146   
            >::new());
  143    147   
  144    148   
        ::std::borrow::Cow::Owned(rcb)
  145    149   
    }
  146    150   
}
  147    151   
  148    152   
#[derive(Debug)]
  149    153   
struct GetDataRetrievalPolicyResponseDeserializer;
  150    154   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for GetDataRetrievalPolicyResponseDeserializer {
  151         -
    fn deserialize_nonstreaming(
         155  +
    fn deserialize_nonstreaming_with_config(
  152    156   
        &self,
  153    157   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         158  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  154    159   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  155    160   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  156         -
        let headers = response.headers();
  157         -
        let body = response.body().bytes().expect("body loaded");
  158    161   
        #[allow(unused_mut)]
  159    162   
        let mut force_error = false;
  160    163   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  161         -
        let parse_result = if !success && status != 200 || force_error {
  162         -
            crate::protocol_serde::shape_get_data_retrieval_policy::de_get_data_retrieval_policy_http_error(status, headers, body)
         164  +
        if !success && status != 200 || force_error {
         165  +
            let headers = response.headers();
         166  +
            let body = response.body().bytes().expect("body loaded");
         167  +
            #[allow(unused_mut)]
         168  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         169  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         170  +
            })?;
         171  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         172  +
            let generic = generic_builder.build();
         173  +
            let error_code = match generic.code() {
         174  +
                ::std::option::Option::Some(code) => code,
         175  +
                ::std::option::Option::None => {
         176  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         177  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(
         178  +
                            crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError::unhandled(generic),
         179  +
                        ),
         180  +
                    ))
         181  +
                }
         182  +
            };
         183  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         184  +
            let protocol = _cfg
         185  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         186  +
                .expect("a SharedClientProtocol is required");
         187  +
            let err = match error_code {
         188  +
                "InvalidParameterValueException" => {
         189  +
                    crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError::InvalidParameterValueException({
         190  +
                        let mut tmp = match protocol
         191  +
                            .deserialize_response(response, crate::types::error::InvalidParameterValueException::SCHEMA, _cfg)
         192  +
                            .and_then(|mut deser| {
         193  +
                                crate::types::error::InvalidParameterValueException::deserialize_with_response(
         194  +
                                    &mut *deser,
         195  +
                                    response.headers(),
         196  +
                                    response.status().into(),
         197  +
                                    body,
         198  +
                                )
         199  +
                            }) {
         200  +
                            ::std::result::Result::Ok(val) => val,
         201  +
                            ::std::result::Result::Err(e) => {
         202  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         203  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         204  +
                                ))
         205  +
                            }
         206  +
                        };
         207  +
                        tmp.meta = generic;
         208  +
                        if tmp.message.is_none() {
         209  +
                            tmp.message = _error_message;
         210  +
                        }
         211  +
                        tmp
         212  +
                    })
         213  +
                }
         214  +
                "MissingParameterValueException" => {
         215  +
                    crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError::MissingParameterValueException({
         216  +
                        let mut tmp = match protocol
         217  +
                            .deserialize_response(response, crate::types::error::MissingParameterValueException::SCHEMA, _cfg)
         218  +
                            .and_then(|mut deser| {
         219  +
                                crate::types::error::MissingParameterValueException::deserialize_with_response(
         220  +
                                    &mut *deser,
         221  +
                                    response.headers(),
         222  +
                                    response.status().into(),
         223  +
                                    body,
         224  +
                                )
         225  +
                            }) {
         226  +
                            ::std::result::Result::Ok(val) => val,
         227  +
                            ::std::result::Result::Err(e) => {
         228  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         229  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         230  +
                                ))
         231  +
                            }
         232  +
                        };
         233  +
                        tmp.meta = generic;
         234  +
                        if tmp.message.is_none() {
         235  +
                            tmp.message = _error_message;
         236  +
                        }
         237  +
                        tmp
         238  +
                    })
         239  +
                }
         240  +
                "ServiceUnavailableException" => {
         241  +
                    crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError::ServiceUnavailableException({
         242  +
                        let mut tmp = match protocol
         243  +
                            .deserialize_response(response, crate::types::error::ServiceUnavailableException::SCHEMA, _cfg)
         244  +
                            .and_then(|mut deser| {
         245  +
                                crate::types::error::ServiceUnavailableException::deserialize_with_response(
         246  +
                                    &mut *deser,
         247  +
                                    response.headers(),
         248  +
                                    response.status().into(),
         249  +
                                    body,
         250  +
                                )
         251  +
                            }) {
         252  +
                            ::std::result::Result::Ok(val) => val,
         253  +
                            ::std::result::Result::Err(e) => {
         254  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         255  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         256  +
                                ))
         257  +
                            }
         258  +
                        };
         259  +
                        tmp.meta = generic;
         260  +
                        if tmp.message.is_none() {
         261  +
                            tmp.message = _error_message;
         262  +
                        }
         263  +
                        tmp
         264  +
                    })
         265  +
                }
         266  +
                _ => crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyError::generic(generic),
         267  +
            };
         268  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         269  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         270  +
            ))
  163    271   
        } else {
  164         -
            crate::protocol_serde::shape_get_data_retrieval_policy::de_get_data_retrieval_policy_http_response(status, headers, body)
  165         -
        };
  166         -
        crate::protocol_serde::type_erase_result(parse_result)
         272  +
            let protocol = _cfg
         273  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         274  +
                .expect("a SharedClientProtocol is required");
         275  +
            let mut deser = protocol
         276  +
                .deserialize_response(response, GetDataRetrievalPolicy::OUTPUT_SCHEMA, _cfg)
         277  +
                .map_err(|e| {
         278  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         279  +
                })?;
         280  +
            let body = response.body().bytes().expect("body loaded");
         281  +
            let output = crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyOutput::deserialize_with_response(
         282  +
                &mut *deser,
         283  +
                response.headers(),
         284  +
                response.status().into(),
         285  +
                body,
         286  +
            )
         287  +
            .map_err(|e| {
         288  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         289  +
            })?;
         290  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         291  +
        }
  167    292   
    }
  168    293   
}
  169    294   
#[derive(Debug)]
  170    295   
struct GetDataRetrievalPolicyRequestSerializer;
  171    296   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for GetDataRetrievalPolicyRequestSerializer {
  172    297   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  173    298   
    fn serialize_input(
  174    299   
        &self,
  175    300   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  176    301   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  177    302   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  178    303   
        let input = input
  179    304   
            .downcast::<crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyInput>()
  180    305   
            .expect("correct type");
  181         -
        let _header_serialization_settings = _cfg
  182         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  183         -
            .cloned()
  184         -
            .unwrap_or_default();
  185         -
        let mut request_builder = {
  186         -
            #[allow(clippy::uninlined_format_args)]
  187         -
            fn uri_base(
  188         -
                _input: &crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyInput,
  189         -
                output: &mut ::std::string::String,
  190         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  191         -
                use ::std::fmt::Write as _;
  192         -
                let input_1 = &_input.account_id;
  193         -
                let input_1 = input_1
  194         -
                    .as_ref()
  195         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("account_id", "cannot be empty or unset"))?;
  196         -
                let account_id = ::aws_smithy_http::label::fmt_string(input_1, ::aws_smithy_http::label::EncodingStrategy::Default);
  197         -
                if account_id.is_empty() {
  198         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  199         -
                        "account_id",
  200         -
                        "cannot be empty or unset",
  201         -
                    ));
         306  +
        let protocol = _cfg
         307  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         308  +
            .expect("a SharedClientProtocol is required");
         309  +
        if protocol.supports_http_bindings() {
         310  +
            let mut request = protocol
         311  +
                .serialize_body(&input, GetDataRetrievalPolicy::INPUT_SCHEMA, "", _cfg)
         312  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         313  +
            {
         314  +
                let mut uri = "/{accountId}/policies/data-retrieval".to_string();
         315  +
                let mut query_params: Vec<(String, String)> = Vec::new();
         316  +
                if let Some(ref val) = input.account_id {
         317  +
                    uri = uri.replace("{accountId}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  202    318   
                }
  203         -
                ::std::write!(output, "/{accountId}/policies/data-retrieval", accountId = account_id).expect("formatting should succeed");
  204         -
                ::std::result::Result::Ok(())
  205         -
            }
  206         -
            #[allow(clippy::unnecessary_wraps)]
  207         -
            fn update_http_builder(
  208         -
                input: &crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyInput,
  209         -
                builder: ::http_1x::request::Builder,
  210         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  211         -
                let mut uri = ::std::string::String::new();
  212         -
                uri_base(input, &mut uri)?;
  213         -
                ::std::result::Result::Ok(builder.method("GET").uri(uri))
         319  +
                if !query_params.is_empty() {
         320  +
                    uri.push(if uri.contains('?') { '&' } else { '?' });
         321  +
                    let pairs: Vec<String> = query_params
         322  +
                        .iter()
         323  +
                        .map(|(k, v)| {
         324  +
                            format!(
         325  +
                                "{}={}",
         326  +
                                ::aws_smithy_schema::http_protocol::percent_encode(k),
         327  +
                                ::aws_smithy_schema::http_protocol::percent_encode(v)
         328  +
                            )
         329  +
                        })
         330  +
                        .collect();
         331  +
                    uri.push_str(&pairs.join("&"));
         332  +
                }
         333  +
                request.set_uri(uri.as_str()).expect("valid URI");
  214    334   
            }
  215         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  216         -
            builder
  217         -
        };
  218         -
        let body = ::aws_smithy_types::body::SdkBody::from("");
  219    335   
  220         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         336  +
            return ::std::result::Result::Ok(request);
         337  +
        } else {
         338  +
            let mut request = protocol
         339  +
                .serialize_request(&input, GetDataRetrievalPolicy::INPUT_SCHEMA, "", _cfg)
         340  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         341  +
         342  +
            return ::std::result::Result::Ok(request);
         343  +
        }
  221    344   
    }
  222    345   
}
  223    346   
#[derive(Debug)]
  224    347   
struct GetDataRetrievalPolicyEndpointParamsInterceptor;
  225    348   
  226    349   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for GetDataRetrievalPolicyEndpointParamsInterceptor {
  227    350   
    fn name(&self) -> &'static str {
  228    351   
        "GetDataRetrievalPolicyEndpointParamsInterceptor"
  229    352   
    }
  230    353   

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_data_retrieval_policy/_get_data_retrieval_policy_input.rs

@@ -1,1 +110,127 @@
   18     18   
    "com.amazonaws.glacier.synthetic",
   19     19   
    "GetDataRetrievalPolicyInput",
   20     20   
);
   21     21   
static GETDATARETRIEVALPOLICYINPUT_MEMBER_ACCOUNT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   22     22   
    ::aws_smithy_schema::ShapeId::from_static(
   23     23   
        "com.amazonaws.glacier.synthetic#GetDataRetrievalPolicyInput$accountId",
   24     24   
        "com.amazonaws.glacier.synthetic",
   25     25   
        "GetDataRetrievalPolicyInput",
   26     26   
    ),
   27     27   
    ::aws_smithy_schema::ShapeType::String,
   28         -
    "account_id",
          28  +
    "accountId",
   29     29   
    0,
   30     30   
)
   31     31   
.with_http_label();
   32     32   
static GETDATARETRIEVALPOLICYINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   33     33   
    GETDATARETRIEVALPOLICYINPUT_SCHEMA_ID,
   34     34   
    ::aws_smithy_schema::ShapeType::Structure,
   35     35   
    &[&GETDATARETRIEVALPOLICYINPUT_MEMBER_ACCOUNT_ID],
   36         -
);
          36  +
)
          37  +
.with_http(aws_smithy_schema::traits::HttpTrait::new(
          38  +
    "GET",
          39  +
    "/{accountId}/policies/data-retrieval",
          40  +
    None,
          41  +
));
   37     42   
impl GetDataRetrievalPolicyInput {
   38     43   
    /// The schema for this shape.
   39     44   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &GETDATARETRIEVALPOLICYINPUT_SCHEMA;
   40     45   
}
   41     46   
impl ::aws_smithy_schema::serde::SerializableStruct for GetDataRetrievalPolicyInput {
   42     47   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   43     48   
    fn serialize_members(
   44     49   
        &self,
   45     50   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   46     51   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   47     52   
        if let Some(ref val) = self.account_id {
   48     53   
            ser.write_string(&GETDATARETRIEVALPOLICYINPUT_MEMBER_ACCOUNT_ID, val)?;
   49     54   
        }
   50     55   
        Ok(())
   51     56   
    }
   52     57   
}
   53     58   
impl GetDataRetrievalPolicyInput {
   54     59   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   55         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   56         -
        deserializer: &mut D,
          60  +
    pub fn deserialize(
          61  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   57     62   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   58     63   
        #[allow(unused_variables, unused_mut)]
   59     64   
        let mut builder = Self::builder();
   60     65   
        #[allow(
   61     66   
            unused_variables,
   62     67   
            unreachable_code,
   63     68   
            clippy::single_match,
   64     69   
            clippy::match_single_binding,
   65     70   
            clippy::diverging_sub_expression
   66     71   
        )]
   67         -
        deserializer.read_struct(&GETDATARETRIEVALPOLICYINPUT_SCHEMA, (), |_, member, deser| {
          72  +
        deserializer.read_struct(&GETDATARETRIEVALPOLICYINPUT_SCHEMA, &mut |member, deser| {
   68     73   
            match member.member_index() {
   69     74   
                Some(0) => {
   70     75   
                    builder.account_id = Some(deser.read_string(member)?);
   71     76   
                }
   72     77   
                _ => {}
   73     78   
            }
   74     79   
            Ok(())
   75     80   
        })?;
          81  +
        builder.account_id = builder.account_id.or(Some(String::new()));
   76     82   
        builder
   77     83   
            .build()
   78     84   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   79     85   
    }
   80     86   
}
          87  +
impl GetDataRetrievalPolicyInput {
          88  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          89  +
    pub fn deserialize_with_response(
          90  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          91  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          92  +
        _status: u16,
          93  +
        _body: &[u8],
          94  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          95  +
        Self::deserialize(deserializer)
          96  +
    }
          97  +
}
   81     98   
impl crate::glacier_interceptors::GlacierAccountId for GetDataRetrievalPolicyInput {
   82     99   
    fn account_id_mut(&mut self) -> &mut Option<String> {
   83    100   
        &mut self.account_id
   84    101   
    }
   85    102   
}
   86    103   
impl GetDataRetrievalPolicyInput {
   87    104   
    /// Creates a new builder-style object to manufacture [`GetDataRetrievalPolicyInput`](crate::operation::get_data_retrieval_policy::GetDataRetrievalPolicyInput).
   88    105   
    pub fn builder() -> crate::operation::get_data_retrieval_policy::builders::GetDataRetrievalPolicyInputBuilder {
   89    106   
        crate::operation::get_data_retrieval_policy::builders::GetDataRetrievalPolicyInputBuilder::default()
   90    107   
    }

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_data_retrieval_policy/_get_data_retrieval_policy_output.rs

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

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_job_output.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 `GetJobOutput`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct GetJobOutput;
    6      6   
impl GetJobOutput {
    7      7   
    /// Creates a new `GetJobOutput`
    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::get_job_output::GetJobOutputInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::get_job_output::GetJobOutputOutput::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::get_job_output::GetJobOutputInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::get_job_output::GetJobOutputOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::get_job_output::GetJobOutputError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -135,139 +289,388 @@
  155    159   
  156    160   
        // If this is an error, defer to the non-streaming parser
  157    161   
        if (!response.status().is_success() && response.status().as_u16() != 200) || force_error {
  158    162   
            return ::std::option::Option::None;
  159    163   
        }
  160    164   
        ::std::option::Option::Some(crate::protocol_serde::type_erase_result(
  161    165   
            crate::protocol_serde::shape_get_job_output::de_get_job_output_http_response(response),
  162    166   
        ))
  163    167   
    }
  164    168   
  165         -
    fn deserialize_nonstreaming(
         169  +
    fn deserialize_nonstreaming_with_config(
  166    170   
        &self,
  167    171   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         172  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  168    173   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  169    174   
        // For streaming operations, we only hit this case if its an error
  170    175   
        let body = response.body().bytes().expect("body loaded");
  171         -
        crate::protocol_serde::type_erase_result(crate::protocol_serde::shape_get_job_output::de_get_job_output_http_error(
  172         -
            response.status().as_u16(),
  173         -
            response.headers(),
  174         -
            body,
         176  +
        let status = response.status().as_u16();
         177  +
        let headers = response.headers();
         178  +
        #[allow(unused_mut)]
         179  +
        let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         180  +
            ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         181  +
        })?;
         182  +
        generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         183  +
        let generic = generic_builder.build();
         184  +
        let error_code = match generic.code() {
         185  +
            ::std::option::Option::Some(code) => code,
         186  +
            ::std::option::Option::None => {
         187  +
                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         188  +
                    ::aws_smithy_runtime_api::box_error::BoxError::from(crate::operation::get_job_output::GetJobOutputError::unhandled(generic)),
         189  +
                ))
         190  +
            }
         191  +
        };
         192  +
        let _error_message = generic.message().map(|msg| msg.to_owned());
         193  +
        let protocol = _cfg
         194  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         195  +
            .expect("a SharedClientProtocol is required");
         196  +
        let err = match error_code {
         197  +
            "InvalidParameterValueException" => crate::operation::get_job_output::GetJobOutputError::InvalidParameterValueException({
         198  +
                let mut tmp = match protocol
         199  +
                    .deserialize_response(response, crate::types::error::InvalidParameterValueException::SCHEMA, _cfg)
         200  +
                    .and_then(|mut deser| {
         201  +
                        crate::types::error::InvalidParameterValueException::deserialize_with_response(
         202  +
                            &mut *deser,
         203  +
                            response.headers(),
         204  +
                            response.status().into(),
         205  +
                            body,
         206  +
                        )
         207  +
                    }) {
         208  +
                    ::std::result::Result::Ok(val) => val,
         209  +
                    ::std::result::Result::Err(e) => {
         210  +
                        return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         211  +
                            ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         212  +
                        ))
         213  +
                    }
         214  +
                };
         215  +
                tmp.meta = generic;
         216  +
                if tmp.message.is_none() {
         217  +
                    tmp.message = _error_message;
         218  +
                }
         219  +
                tmp
         220  +
            }),
         221  +
            "MissingParameterValueException" => crate::operation::get_job_output::GetJobOutputError::MissingParameterValueException({
         222  +
                let mut tmp = match protocol
         223  +
                    .deserialize_response(response, crate::types::error::MissingParameterValueException::SCHEMA, _cfg)
         224  +
                    .and_then(|mut deser| {
         225  +
                        crate::types::error::MissingParameterValueException::deserialize_with_response(
         226  +
                            &mut *deser,
         227  +
                            response.headers(),
         228  +
                            response.status().into(),
         229  +
                            body,
         230  +
                        )
         231  +
                    }) {
         232  +
                    ::std::result::Result::Ok(val) => val,
         233  +
                    ::std::result::Result::Err(e) => {
         234  +
                        return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         235  +
                            ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         236  +
                        ))
         237  +
                    }
         238  +
                };
         239  +
                tmp.meta = generic;
         240  +
                if tmp.message.is_none() {
         241  +
                    tmp.message = _error_message;
         242  +
                }
         243  +
                tmp
         244  +
            }),
         245  +
            "ResourceNotFoundException" => crate::operation::get_job_output::GetJobOutputError::ResourceNotFoundException({
         246  +
                let mut tmp = match protocol
         247  +
                    .deserialize_response(response, crate::types::error::ResourceNotFoundException::SCHEMA, _cfg)
         248  +
                    .and_then(|mut deser| {
         249  +
                        crate::types::error::ResourceNotFoundException::deserialize_with_response(
         250  +
                            &mut *deser,
         251  +
                            response.headers(),
         252  +
                            response.status().into(),
         253  +
                            body,
         254  +
                        )
         255  +
                    }) {
         256  +
                    ::std::result::Result::Ok(val) => val,
         257  +
                    ::std::result::Result::Err(e) => {
         258  +
                        return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         259  +
                            ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         260  +
                        ))
         261  +
                    }
         262  +
                };
         263  +
                tmp.meta = generic;
         264  +
                if tmp.message.is_none() {
         265  +
                    tmp.message = _error_message;
         266  +
                }
         267  +
                tmp
         268  +
            }),
         269  +
            "ServiceUnavailableException" => crate::operation::get_job_output::GetJobOutputError::ServiceUnavailableException({
         270  +
                let mut tmp = match protocol
         271  +
                    .deserialize_response(response, crate::types::error::ServiceUnavailableException::SCHEMA, _cfg)
         272  +
                    .and_then(|mut deser| {
         273  +
                        crate::types::error::ServiceUnavailableException::deserialize_with_response(
         274  +
                            &mut *deser,
         275  +
                            response.headers(),
         276  +
                            response.status().into(),
         277  +
                            body,
         278  +
                        )
         279  +
                    }) {
         280  +
                    ::std::result::Result::Ok(val) => val,
         281  +
                    ::std::result::Result::Err(e) => {
         282  +
                        return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         283  +
                            ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         284  +
                        ))
         285  +
                    }
         286  +
                };
         287  +
                tmp.meta = generic;
         288  +
                if tmp.message.is_none() {
         289  +
                    tmp.message = _error_message;
         290  +
                }
         291  +
                tmp
         292  +
            }),
         293  +
            _ => crate::operation::get_job_output::GetJobOutputError::generic(generic),
         294  +
        };
         295  +
        ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         296  +
            ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
  175    297   
        ))
  176    298   
    }
  177    299   
}
  178    300   
#[derive(Debug)]
  179    301   
struct GetJobOutputRequestSerializer;
  180    302   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for GetJobOutputRequestSerializer {
  181    303   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  182    304   
    fn serialize_input(
  183    305   
        &self,
  184    306   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  185    307   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  186    308   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  187    309   
        let input = input
  188    310   
            .downcast::<crate::operation::get_job_output::GetJobOutputInput>()
  189    311   
            .expect("correct type");
  190         -
        let _header_serialization_settings = _cfg
  191         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  192         -
            .cloned()
  193         -
            .unwrap_or_default();
  194         -
        let mut request_builder = {
  195         -
            #[allow(clippy::uninlined_format_args)]
  196         -
            fn uri_base(
  197         -
                _input: &crate::operation::get_job_output::GetJobOutputInput,
  198         -
                output: &mut ::std::string::String,
  199         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  200         -
                use ::std::fmt::Write as _;
  201         -
                let input_1 = &_input.account_id;
  202         -
                let input_1 = input_1
  203         -
                    .as_ref()
  204         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("account_id", "cannot be empty or unset"))?;
  205         -
                let account_id = ::aws_smithy_http::label::fmt_string(input_1, ::aws_smithy_http::label::EncodingStrategy::Default);
  206         -
                if account_id.is_empty() {
  207         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  208         -
                        "account_id",
  209         -
                        "cannot be empty or unset",
  210         -
                    ));
         312  +
        let protocol = _cfg
         313  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         314  +
            .expect("a SharedClientProtocol is required");
         315  +
        if protocol.supports_http_bindings() {
         316  +
            let mut request = protocol
         317  +
                .serialize_body(&input, GetJobOutput::INPUT_SCHEMA, "", _cfg)
         318  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         319  +
            {
         320  +
                let mut uri = "/{accountId}/vaults/{vaultName}/jobs/{jobId}/output".to_string();
         321  +
                let mut query_params: Vec<(String, String)> = Vec::new();
         322  +
                if let Some(ref val) = input.account_id {
         323  +
                    uri = uri.replace("{accountId}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  211    324   
                }
  212         -
                let input_2 = &_input.vault_name;
  213         -
                let input_2 = input_2
  214         -
                    .as_ref()
  215         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("vault_name", "cannot be empty or unset"))?;
  216         -
                let vault_name = ::aws_smithy_http::label::fmt_string(input_2, ::aws_smithy_http::label::EncodingStrategy::Default);
  217         -
                if vault_name.is_empty() {
  218         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  219         -
                        "vault_name",
  220         -
                        "cannot be empty or unset",
  221         -
                    ));
         325  +
                if let Some(ref val) = input.vault_name {
         326  +
                    uri = uri.replace("{vaultName}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  222    327   
                }
  223         -
                let input_3 = &_input.job_id;
  224         -
                let input_3 = input_3
  225         -
                    .as_ref()
  226         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("job_id", "cannot be empty or unset"))?;
  227         -
                let job_id = ::aws_smithy_http::label::fmt_string(input_3, ::aws_smithy_http::label::EncodingStrategy::Default);
  228         -
                if job_id.is_empty() {
  229         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  230         -
                        "job_id",
  231         -
                        "cannot be empty or unset",
  232         -
                    ));
         328  +
                if let Some(ref val) = input.job_id {
         329  +
                    uri = uri.replace("{jobId}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  233    330   
                }
  234         -
                ::std::write!(
  235         -
                    output,
  236         -
                    "/{accountId}/vaults/{vaultName}/jobs/{jobId}/output",
  237         -
                    accountId = account_id,
  238         -
                    vaultName = vault_name,
  239         -
                    jobId = job_id
  240         -
                )
  241         -
                .expect("formatting should succeed");
  242         -
                ::std::result::Result::Ok(())
  243         -
            }
  244         -
            #[allow(clippy::unnecessary_wraps)]
  245         -
            fn update_http_builder(
  246         -
                input: &crate::operation::get_job_output::GetJobOutputInput,
  247         -
                builder: ::http_1x::request::Builder,
  248         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  249         -
                let mut uri = ::std::string::String::new();
  250         -
                uri_base(input, &mut uri)?;
  251         -
                let builder = crate::protocol_serde::shape_get_job_output::ser_get_job_output_headers(input, builder)?;
  252         -
                ::std::result::Result::Ok(builder.method("GET").uri(uri))
         331  +
                if let Some(ref val) = input.range {
         332  +
                    request.headers_mut().insert("Range", val.to_string());
         333  +
                }
         334  +
                if !query_params.is_empty() {
         335  +
                    uri.push(if uri.contains('?') { '&' } else { '?' });
         336  +
                    let pairs: Vec<String> = query_params
         337  +
                        .iter()
         338  +
                        .map(|(k, v)| {
         339  +
                            format!(
         340  +
                                "{}={}",
         341  +
                                ::aws_smithy_schema::http_protocol::percent_encode(k),
         342  +
                                ::aws_smithy_schema::http_protocol::percent_encode(v)
         343  +
                            )
         344  +
                        })
         345  +
                        .collect();
         346  +
                    uri.push_str(&pairs.join("&"));
         347  +
                }
         348  +
                request.set_uri(uri.as_str()).expect("valid URI");
  253    349   
            }
  254         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  255         -
            builder
  256         -
        };
  257         -
        let body = ::aws_smithy_types::body::SdkBody::from("");
  258    350   
  259         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         351  +
            return ::std::result::Result::Ok(request);
         352  +
        } else {
         353  +
            let mut request = protocol
         354  +
                .serialize_request(&input, GetJobOutput::INPUT_SCHEMA, "", _cfg)
         355  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         356  +
         357  +
            return ::std::result::Result::Ok(request);
         358  +
        }
  260    359   
    }
  261    360   
}
  262    361   
#[derive(Debug)]
  263    362   
struct GetJobOutputEndpointParamsInterceptor;
  264    363   
  265    364   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for GetJobOutputEndpointParamsInterceptor {
  266    365   
    fn name(&self) -> &'static str {
  267    366   
        "GetJobOutputEndpointParamsInterceptor"
  268    367   
    }
  269    368   

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_job_output/_get_job_output_input.rs

@@ -40,40 +203,254 @@
   60     60   
    "com.amazonaws.glacier.synthetic",
   61     61   
    "GetJobOutputInput",
   62     62   
);
   63     63   
static GETJOBOUTPUTINPUT_MEMBER_ACCOUNT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   64     64   
    ::aws_smithy_schema::ShapeId::from_static(
   65     65   
        "com.amazonaws.glacier.synthetic#GetJobOutputInput$accountId",
   66     66   
        "com.amazonaws.glacier.synthetic",
   67     67   
        "GetJobOutputInput",
   68     68   
    ),
   69     69   
    ::aws_smithy_schema::ShapeType::String,
   70         -
    "account_id",
          70  +
    "accountId",
   71     71   
    0,
   72     72   
)
   73     73   
.with_http_label();
   74     74   
static GETJOBOUTPUTINPUT_MEMBER_VAULT_NAME: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   75     75   
    ::aws_smithy_schema::ShapeId::from_static(
   76     76   
        "com.amazonaws.glacier.synthetic#GetJobOutputInput$vaultName",
   77     77   
        "com.amazonaws.glacier.synthetic",
   78     78   
        "GetJobOutputInput",
   79     79   
    ),
   80     80   
    ::aws_smithy_schema::ShapeType::String,
   81         -
    "vault_name",
          81  +
    "vaultName",
   82     82   
    1,
   83     83   
)
   84     84   
.with_http_label();
   85     85   
static GETJOBOUTPUTINPUT_MEMBER_JOB_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   86     86   
    ::aws_smithy_schema::ShapeId::from_static(
   87     87   
        "com.amazonaws.glacier.synthetic#GetJobOutputInput$jobId",
   88     88   
        "com.amazonaws.glacier.synthetic",
   89     89   
        "GetJobOutputInput",
   90     90   
    ),
   91     91   
    ::aws_smithy_schema::ShapeType::String,
   92         -
    "job_id",
          92  +
    "jobId",
   93     93   
    2,
   94     94   
)
   95     95   
.with_http_label();
   96     96   
static GETJOBOUTPUTINPUT_MEMBER_RANGE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   97     97   
    ::aws_smithy_schema::ShapeId::from_static(
   98     98   
        "com.amazonaws.glacier.synthetic#GetJobOutputInput$range",
   99     99   
        "com.amazonaws.glacier.synthetic",
  100    100   
        "GetJobOutputInput",
  101    101   
    ),
  102    102   
    ::aws_smithy_schema::ShapeType::String,
  103    103   
    "range",
  104    104   
    3,
  105    105   
)
  106    106   
.with_http_header("Range");
  107    107   
static GETJOBOUTPUTINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  108    108   
    GETJOBOUTPUTINPUT_SCHEMA_ID,
  109    109   
    ::aws_smithy_schema::ShapeType::Structure,
  110    110   
    &[
  111    111   
        &GETJOBOUTPUTINPUT_MEMBER_ACCOUNT_ID,
  112    112   
        &GETJOBOUTPUTINPUT_MEMBER_VAULT_NAME,
  113    113   
        &GETJOBOUTPUTINPUT_MEMBER_JOB_ID,
  114    114   
        &GETJOBOUTPUTINPUT_MEMBER_RANGE,
  115    115   
    ],
  116         -
);
         116  +
)
         117  +
.with_http(aws_smithy_schema::traits::HttpTrait::new(
         118  +
    "GET",
         119  +
    "/{accountId}/vaults/{vaultName}/jobs/{jobId}/output",
         120  +
    None,
         121  +
));
  117    122   
impl GetJobOutputInput {
  118    123   
    /// The schema for this shape.
  119    124   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &GETJOBOUTPUTINPUT_SCHEMA;
  120    125   
}
  121    126   
impl ::aws_smithy_schema::serde::SerializableStruct for GetJobOutputInput {
  122    127   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
  123    128   
    fn serialize_members(
  124    129   
        &self,
  125    130   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
  126    131   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
  127    132   
        if let Some(ref val) = self.account_id {
  128    133   
            ser.write_string(&GETJOBOUTPUTINPUT_MEMBER_ACCOUNT_ID, val)?;
  129    134   
        }
  130    135   
        if let Some(ref val) = self.vault_name {
  131    136   
            ser.write_string(&GETJOBOUTPUTINPUT_MEMBER_VAULT_NAME, val)?;
  132    137   
        }
  133    138   
        if let Some(ref val) = self.job_id {
  134    139   
            ser.write_string(&GETJOBOUTPUTINPUT_MEMBER_JOB_ID, val)?;
  135    140   
        }
  136    141   
        if let Some(ref val) = self.range {
  137    142   
            ser.write_string(&GETJOBOUTPUTINPUT_MEMBER_RANGE, val)?;
  138    143   
        }
  139    144   
        Ok(())
  140    145   
    }
  141    146   
}
  142    147   
impl GetJobOutputInput {
  143    148   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  144         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  145         -
        deserializer: &mut D,
         149  +
    pub fn deserialize(
         150  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  146    151   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  147    152   
        #[allow(unused_variables, unused_mut)]
  148    153   
        let mut builder = Self::builder();
  149    154   
        #[allow(
  150    155   
            unused_variables,
  151    156   
            unreachable_code,
  152    157   
            clippy::single_match,
  153    158   
            clippy::match_single_binding,
  154    159   
            clippy::diverging_sub_expression
  155    160   
        )]
  156         -
        deserializer.read_struct(&GETJOBOUTPUTINPUT_SCHEMA, (), |_, member, deser| {
         161  +
        deserializer.read_struct(&GETJOBOUTPUTINPUT_SCHEMA, &mut |member, deser| {
  157    162   
            match member.member_index() {
  158    163   
                Some(0) => {
  159    164   
                    builder.account_id = Some(deser.read_string(member)?);
  160    165   
                }
  161    166   
                Some(1) => {
  162    167   
                    builder.vault_name = Some(deser.read_string(member)?);
  163    168   
                }
  164    169   
                Some(2) => {
  165    170   
                    builder.job_id = Some(deser.read_string(member)?);
  166    171   
                }
  167    172   
                Some(3) => {
  168    173   
                    builder.range = Some(deser.read_string(member)?);
  169    174   
                }
  170    175   
                _ => {}
  171    176   
            }
  172    177   
            Ok(())
  173    178   
        })?;
         179  +
        builder.account_id = builder.account_id.or(Some(String::new()));
         180  +
        builder.vault_name = builder.vault_name.or(Some(String::new()));
         181  +
        builder.job_id = builder.job_id.or(Some(String::new()));
         182  +
        builder
         183  +
            .build()
         184  +
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
         185  +
    }
         186  +
}
         187  +
impl GetJobOutputInput {
         188  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         189  +
    /// Header-bound members are read directly from headers, avoiding runtime
         190  +
    /// member iteration overhead. Body members are read via the deserializer.
         191  +
    pub fn deserialize_with_response(
         192  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         193  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         194  +
        _status: u16,
         195  +
        _body: &[u8],
         196  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         197  +
        #[allow(unused_variables, unused_mut)]
         198  +
        let mut builder = Self::builder();
         199  +
        if let Some(val) = headers.get("Range") {
         200  +
            builder.range = Some(val.to_string());
         201  +
        }
         202  +
        #[allow(
         203  +
            unused_variables,
         204  +
            unreachable_code,
         205  +
            clippy::single_match,
         206  +
            clippy::match_single_binding,
         207  +
            clippy::diverging_sub_expression
         208  +
        )]
         209  +
        deserializer.read_struct(&GETJOBOUTPUTINPUT_SCHEMA, &mut |member, deser| {
         210  +
            match member.member_index() {
         211  +
                Some(0) => {
         212  +
                    builder.account_id = Some(deser.read_string(member)?);
         213  +
                }
         214  +
                Some(1) => {
         215  +
                    builder.vault_name = Some(deser.read_string(member)?);
         216  +
                }
         217  +
                Some(2) => {
         218  +
                    builder.job_id = Some(deser.read_string(member)?);
         219  +
                }
         220  +
                Some(3) => { /* read from headers above */ }
         221  +
                _ => {}
         222  +
            }
         223  +
            Ok(())
         224  +
        })?;
  174    225   
        builder
  175    226   
            .build()
  176    227   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  177    228   
    }
  178    229   
}
  179    230   
impl crate::glacier_interceptors::GlacierAccountId for GetJobOutputInput {
  180    231   
    fn account_id_mut(&mut self) -> &mut Option<String> {
  181    232   
        &mut self.account_id
  182    233   
    }
  183    234   
}

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_job_output/_get_job_output_output.rs

@@ -84,84 +269,335 @@
  104    104   
    2,
  105    105   
)
  106    106   
.with_http_response_code();
  107    107   
static GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_RANGE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  108    108   
    ::aws_smithy_schema::ShapeId::from_static(
  109    109   
        "com.amazonaws.glacier.synthetic#GetJobOutputOutput$contentRange",
  110    110   
        "com.amazonaws.glacier.synthetic",
  111    111   
        "GetJobOutputOutput",
  112    112   
    ),
  113    113   
    ::aws_smithy_schema::ShapeType::String,
  114         -
    "content_range",
         114  +
    "contentRange",
  115    115   
    3,
  116    116   
)
  117    117   
.with_http_header("Content-Range");
  118    118   
static GETJOBOUTPUTOUTPUT_MEMBER_ACCEPT_RANGES: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  119    119   
    ::aws_smithy_schema::ShapeId::from_static(
  120    120   
        "com.amazonaws.glacier.synthetic#GetJobOutputOutput$acceptRanges",
  121    121   
        "com.amazonaws.glacier.synthetic",
  122    122   
        "GetJobOutputOutput",
  123    123   
    ),
  124    124   
    ::aws_smithy_schema::ShapeType::String,
  125         -
    "accept_ranges",
         125  +
    "acceptRanges",
  126    126   
    4,
  127    127   
)
  128    128   
.with_http_header("Accept-Ranges");
  129    129   
static GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_TYPE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  130    130   
    ::aws_smithy_schema::ShapeId::from_static(
  131    131   
        "com.amazonaws.glacier.synthetic#GetJobOutputOutput$contentType",
  132    132   
        "com.amazonaws.glacier.synthetic",
  133    133   
        "GetJobOutputOutput",
  134    134   
    ),
  135    135   
    ::aws_smithy_schema::ShapeType::String,
  136         -
    "content_type",
         136  +
    "contentType",
  137    137   
    5,
  138    138   
)
  139    139   
.with_http_header("Content-Type");
  140    140   
static GETJOBOUTPUTOUTPUT_MEMBER_ARCHIVE_DESCRIPTION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
  141    141   
    ::aws_smithy_schema::ShapeId::from_static(
  142    142   
        "com.amazonaws.glacier.synthetic#GetJobOutputOutput$archiveDescription",
  143    143   
        "com.amazonaws.glacier.synthetic",
  144    144   
        "GetJobOutputOutput",
  145    145   
    ),
  146    146   
    ::aws_smithy_schema::ShapeType::String,
  147         -
    "archive_description",
         147  +
    "archiveDescription",
  148    148   
    6,
  149    149   
)
  150    150   
.with_http_header("x-amz-archive-description");
         151  +
static GETJOBOUTPUTOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
         152  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
         153  +
    ::aws_smithy_schema::ShapeType::String,
         154  +
    "request_id",
         155  +
    7,
         156  +
)
         157  +
.with_http_header("x-amzn-requestid");
  151    158   
static GETJOBOUTPUTOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
  152    159   
    GETJOBOUTPUTOUTPUT_SCHEMA_ID,
  153    160   
    ::aws_smithy_schema::ShapeType::Structure,
  154    161   
    &[
  155    162   
        &GETJOBOUTPUTOUTPUT_MEMBER_BODY,
  156    163   
        &GETJOBOUTPUTOUTPUT_MEMBER_CHECKSUM,
  157    164   
        &GETJOBOUTPUTOUTPUT_MEMBER_STATUS,
  158    165   
        &GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_RANGE,
  159    166   
        &GETJOBOUTPUTOUTPUT_MEMBER_ACCEPT_RANGES,
  160    167   
        &GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_TYPE,
  161    168   
        &GETJOBOUTPUTOUTPUT_MEMBER_ARCHIVE_DESCRIPTION,
         169  +
        &GETJOBOUTPUTOUTPUT_MEMBER__REQUEST_ID,
  162    170   
    ],
  163    171   
);
  164    172   
impl GetJobOutputOutput {
  165    173   
    /// The schema for this shape.
  166    174   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &GETJOBOUTPUTOUTPUT_SCHEMA;
  167    175   
}
  168    176   
impl ::aws_smithy_schema::serde::SerializableStruct for GetJobOutputOutput {
  169    177   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
  170    178   
    fn serialize_members(
  171    179   
        &self,
  172    180   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
  173    181   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
  174         -
        {
  175         -
            let val = &self.body;
  176         -
            // streaming blob is serialized as the HTTP body by the protocol, not the codec
  177         -
        }
  178    182   
        if let Some(ref val) = self.checksum {
  179    183   
            ser.write_string(&GETJOBOUTPUTOUTPUT_MEMBER_CHECKSUM, val)?;
  180    184   
        }
  181    185   
        {
  182    186   
            let val = &self.status;
  183    187   
            ser.write_integer(&GETJOBOUTPUTOUTPUT_MEMBER_STATUS, *val)?;
  184    188   
        }
  185    189   
        if let Some(ref val) = self.content_range {
  186    190   
            ser.write_string(&GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_RANGE, val)?;
  187    191   
        }
  188    192   
        if let Some(ref val) = self.accept_ranges {
  189    193   
            ser.write_string(&GETJOBOUTPUTOUTPUT_MEMBER_ACCEPT_RANGES, val)?;
  190    194   
        }
  191    195   
        if let Some(ref val) = self.content_type {
  192    196   
            ser.write_string(&GETJOBOUTPUTOUTPUT_MEMBER_CONTENT_TYPE, val)?;
  193    197   
        }
  194    198   
        if let Some(ref val) = self.archive_description {
  195    199   
            ser.write_string(&GETJOBOUTPUTOUTPUT_MEMBER_ARCHIVE_DESCRIPTION, val)?;
  196    200   
        }
  197    201   
        Ok(())
  198    202   
    }
  199    203   
}
  200    204   
impl GetJobOutputOutput {
  201    205   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  202         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  203         -
        deserializer: &mut D,
         206  +
    pub fn deserialize(
         207  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  204    208   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  205    209   
        #[allow(unused_variables, unused_mut)]
  206    210   
        let mut builder = Self::builder();
  207    211   
        #[allow(
  208    212   
            unused_variables,
  209    213   
            unreachable_code,
  210    214   
            clippy::single_match,
  211    215   
            clippy::match_single_binding,
  212    216   
            clippy::diverging_sub_expression
  213    217   
        )]
  214         -
        deserializer.read_struct(&GETJOBOUTPUTOUTPUT_SCHEMA, (), |_, member, deser| {
         218  +
        deserializer.read_struct(&GETJOBOUTPUTOUTPUT_SCHEMA, &mut |member, deser| {
  215    219   
            match member.member_index() {
  216    220   
                Some(0) => {
  217    221   
                    builder.body = Some({
  218    222   
                        let _ = member;
  219    223   
                        ::aws_smithy_types::byte_stream::ByteStream::new(::aws_smithy_types::body::SdkBody::empty())
  220    224   
                    });
  221    225   
                }
  222    226   
                Some(1) => {
  223    227   
                    builder.checksum = Some(deser.read_string(member)?);
  224    228   
                }
  225    229   
                Some(2) => {
  226    230   
                    builder.status = Some(deser.read_integer(member)?);
  227    231   
                }
  228    232   
                Some(3) => {
  229    233   
                    builder.content_range = Some(deser.read_string(member)?);
  230    234   
                }
  231    235   
                Some(4) => {
  232    236   
                    builder.accept_ranges = Some(deser.read_string(member)?);
  233    237   
                }
  234    238   
                Some(5) => {
  235    239   
                    builder.content_type = Some(deser.read_string(member)?);
  236    240   
                }
  237    241   
                Some(6) => {
  238    242   
                    builder.archive_description = Some(deser.read_string(member)?);
  239    243   
                }
         244  +
                Some(7) => {
         245  +
                    builder._request_id = Some(deser.read_string(member)?);
         246  +
                }
         247  +
                _ => {}
         248  +
            }
         249  +
            Ok(())
         250  +
        })?;
         251  +
        Ok(builder.build())
         252  +
    }
         253  +
}
         254  +
impl GetJobOutputOutput {
         255  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         256  +
    /// Header-bound members are read directly from headers, avoiding runtime
         257  +
    /// member iteration overhead. Body members are read via the deserializer.
         258  +
    pub fn deserialize_with_response(
         259  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         260  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         261  +
        _status: u16,
         262  +
        _body: &[u8],
         263  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         264  +
        #[allow(unused_variables, unused_mut)]
         265  +
        let mut builder = Self::builder();
         266  +
        if let Some(val) = headers.get("x-amz-sha256-tree-hash") {
         267  +
            builder.checksum = Some(val.to_string());
         268  +
        }
         269  +
        if let Some(val) = headers.get("Content-Range") {
         270  +
            builder.content_range = Some(val.to_string());
         271  +
        }
         272  +
        if let Some(val) = headers.get("Accept-Ranges") {
         273  +
            builder.accept_ranges = Some(val.to_string());
         274  +
        }
         275  +
        if let Some(val) = headers.get("Content-Type") {
         276  +
            builder.content_type = Some(val.to_string());
         277  +
        }
         278  +
        if let Some(val) = headers.get("x-amz-archive-description") {
         279  +
            builder.archive_description = Some(val.to_string());
         280  +
        }
         281  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         282  +
            builder._request_id = Some(val.to_string());
         283  +
        }
         284  +
        builder.status = Some(_status as i32);
         285  +
        #[allow(
         286  +
            unused_variables,
         287  +
            unreachable_code,
         288  +
            clippy::single_match,
         289  +
            clippy::match_single_binding,
         290  +
            clippy::diverging_sub_expression
         291  +
        )]
         292  +
        deserializer.read_struct(&GETJOBOUTPUTOUTPUT_SCHEMA, &mut |member, deser| {
         293  +
            match member.member_index() {
         294  +
                Some(0) => {
         295  +
                    builder.body = Some({
         296  +
                        let _ = member;
         297  +
                        ::aws_smithy_types::byte_stream::ByteStream::new(::aws_smithy_types::body::SdkBody::empty())
         298  +
                    });
         299  +
                }
         300  +
                Some(1) => { /* read from headers above */ }
         301  +
                Some(2) => { /* read from headers above */ }
         302  +
                Some(3) => { /* read from headers above */ }
         303  +
                Some(4) => { /* read from headers above */ }
         304  +
                Some(5) => { /* read from headers above */ }
         305  +
                Some(6) => { /* read from headers above */ }
  240    306   
                _ => {}
  241    307   
            }
  242    308   
            Ok(())
  243    309   
        })?;
  244    310   
        Ok(builder.build())
  245    311   
    }
  246    312   
}
  247    313   
impl ::aws_types::request_id::RequestId for GetJobOutputOutput {
  248    314   
    fn request_id(&self) -> Option<&str> {
  249    315   
        self._request_id.as_deref()

tmp-codegen-diff/aws-sdk/sdk/glacier/src/operation/get_vault_access_policy.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 `GetVaultAccessPolicy`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct GetVaultAccessPolicy;
    6      6   
impl GetVaultAccessPolicy {
    7      7   
    /// Creates a new `GetVaultAccessPolicy`
    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::get_vault_access_policy::GetVaultAccessPolicyInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::get_vault_access_policy::GetVaultAccessPolicyOutput::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::get_vault_access_policy::GetVaultAccessPolicyInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::get_vault_access_policy::GetVaultAccessPolicyOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::get_vault_access_policy::GetVaultAccessPolicyError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -121,125 +267,398 @@
  141    145   
                crate::operation::get_vault_access_policy::GetVaultAccessPolicyError,
  142    146   
            >::new());
  143    147   
  144    148   
        ::std::borrow::Cow::Owned(rcb)
  145    149   
    }
  146    150   
}
  147    151   
  148    152   
#[derive(Debug)]
  149    153   
struct GetVaultAccessPolicyResponseDeserializer;
  150    154   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for GetVaultAccessPolicyResponseDeserializer {
  151         -
    fn deserialize_nonstreaming(
         155  +
    fn deserialize_nonstreaming_with_config(
  152    156   
        &self,
  153    157   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         158  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  154    159   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  155    160   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  156         -
        let headers = response.headers();
  157         -
        let body = response.body().bytes().expect("body loaded");
  158    161   
        #[allow(unused_mut)]
  159    162   
        let mut force_error = false;
  160    163   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  161         -
        let parse_result = if !success && status != 200 || force_error {
  162         -
            crate::protocol_serde::shape_get_vault_access_policy::de_get_vault_access_policy_http_error(status, headers, body)
         164  +
        if !success && status != 200 || force_error {
         165  +
            let headers = response.headers();
         166  +
            let body = response.body().bytes().expect("body loaded");
         167  +
            #[allow(unused_mut)]
         168  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         169  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         170  +
            })?;
         171  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         172  +
            let generic = generic_builder.build();
         173  +
            let error_code = match generic.code() {
         174  +
                ::std::option::Option::Some(code) => code,
         175  +
                ::std::option::Option::None => {
         176  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         177  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(
         178  +
                            crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::unhandled(generic),
         179  +
                        ),
         180  +
                    ))
         181  +
                }
         182  +
            };
         183  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         184  +
            let protocol = _cfg
         185  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         186  +
                .expect("a SharedClientProtocol is required");
         187  +
            let err = match error_code {
         188  +
                "InvalidParameterValueException" => {
         189  +
                    crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::InvalidParameterValueException({
         190  +
                        let mut tmp = match protocol
         191  +
                            .deserialize_response(response, crate::types::error::InvalidParameterValueException::SCHEMA, _cfg)
         192  +
                            .and_then(|mut deser| {
         193  +
                                crate::types::error::InvalidParameterValueException::deserialize_with_response(
         194  +
                                    &mut *deser,
         195  +
                                    response.headers(),
         196  +
                                    response.status().into(),
         197  +
                                    body,
         198  +
                                )
         199  +
                            }) {
         200  +
                            ::std::result::Result::Ok(val) => val,
         201  +
                            ::std::result::Result::Err(e) => {
         202  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         203  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         204  +
                                ))
         205  +
                            }
         206  +
                        };
         207  +
                        tmp.meta = generic;
         208  +
                        if tmp.message.is_none() {
         209  +
                            tmp.message = _error_message;
         210  +
                        }
         211  +
                        tmp
         212  +
                    })
         213  +
                }
         214  +
                "MissingParameterValueException" => {
         215  +
                    crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::MissingParameterValueException({
         216  +
                        let mut tmp = match protocol
         217  +
                            .deserialize_response(response, crate::types::error::MissingParameterValueException::SCHEMA, _cfg)
         218  +
                            .and_then(|mut deser| {
         219  +
                                crate::types::error::MissingParameterValueException::deserialize_with_response(
         220  +
                                    &mut *deser,
         221  +
                                    response.headers(),
         222  +
                                    response.status().into(),
         223  +
                                    body,
         224  +
                                )
         225  +
                            }) {
         226  +
                            ::std::result::Result::Ok(val) => val,
         227  +
                            ::std::result::Result::Err(e) => {
         228  +
                                return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         229  +
                                    ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         230  +
                                ))
         231  +
                            }
         232  +
                        };
         233  +
                        tmp.meta = generic;
         234  +
                        if tmp.message.is_none() {
         235  +
                            tmp.message = _error_message;
         236  +
                        }
         237  +
                        tmp
         238  +
                    })
         239  +
                }
         240  +
                "ResourceNotFoundException" => crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::ResourceNotFoundException({
         241  +
                    let mut tmp = match protocol
         242  +
                        .deserialize_response(response, crate::types::error::ResourceNotFoundException::SCHEMA, _cfg)
         243  +
                        .and_then(|mut deser| {
         244  +
                            crate::types::error::ResourceNotFoundException::deserialize_with_response(
         245  +
                                &mut *deser,
         246  +
                                response.headers(),
         247  +
                                response.status().into(),
         248  +
                                body,
         249  +
                            )
         250  +
                        }) {
         251  +
                        ::std::result::Result::Ok(val) => val,
         252  +
                        ::std::result::Result::Err(e) => {
         253  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         254  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         255  +
                            ))
         256  +
                        }
         257  +
                    };
         258  +
                    tmp.meta = generic;
         259  +
                    if tmp.message.is_none() {
         260  +
                        tmp.message = _error_message;
         261  +
                    }
         262  +
                    tmp
         263  +
                }),
         264  +
                "ServiceUnavailableException" => crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::ServiceUnavailableException({
         265  +
                    let mut tmp = match protocol
         266  +
                        .deserialize_response(response, crate::types::error::ServiceUnavailableException::SCHEMA, _cfg)
         267  +
                        .and_then(|mut deser| {
         268  +
                            crate::types::error::ServiceUnavailableException::deserialize_with_response(
         269  +
                                &mut *deser,
         270  +
                                response.headers(),
         271  +
                                response.status().into(),
         272  +
                                body,
         273  +
                            )
         274  +
                        }) {
         275  +
                        ::std::result::Result::Ok(val) => val,
         276  +
                        ::std::result::Result::Err(e) => {
         277  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         278  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         279  +
                            ))
         280  +
                        }
         281  +
                    };
         282  +
                    tmp.meta = generic;
         283  +
                    if tmp.message.is_none() {
         284  +
                        tmp.message = _error_message;
         285  +
                    }
         286  +
                    tmp
         287  +
                }),
         288  +
                _ => crate::operation::get_vault_access_policy::GetVaultAccessPolicyError::generic(generic),
         289  +
            };
         290  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         291  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         292  +
            ))
  163    293   
        } else {
  164         -
            crate::protocol_serde::shape_get_vault_access_policy::de_get_vault_access_policy_http_response(status, headers, body)
  165         -
        };
  166         -
        crate::protocol_serde::type_erase_result(parse_result)
         294  +
            let protocol = _cfg
         295  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         296  +
                .expect("a SharedClientProtocol is required");
         297  +
            let mut deser = protocol
         298  +
                .deserialize_response(response, GetVaultAccessPolicy::OUTPUT_SCHEMA, _cfg)
         299  +
                .map_err(|e| {
         300  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         301  +
                })?;
         302  +
            let body = response.body().bytes().expect("body loaded");
         303  +
            let output = crate::operation::get_vault_access_policy::GetVaultAccessPolicyOutput::deserialize_with_response(
         304  +
                &mut *deser,
         305  +
                response.headers(),
         306  +
                response.status().into(),
         307  +
                body,
         308  +
            )
         309  +
            .map_err(|e| {
         310  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         311  +
            })?;
         312  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         313  +
        }
  167    314   
    }
  168    315   
}
  169    316   
#[derive(Debug)]
  170    317   
struct GetVaultAccessPolicyRequestSerializer;
  171    318   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for GetVaultAccessPolicyRequestSerializer {
  172    319   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  173    320   
    fn serialize_input(
  174    321   
        &self,
  175    322   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  176    323   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  177    324   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  178    325   
        let input = input
  179    326   
            .downcast::<crate::operation::get_vault_access_policy::GetVaultAccessPolicyInput>()
  180    327   
            .expect("correct type");
  181         -
        let _header_serialization_settings = _cfg
  182         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  183         -
            .cloned()
  184         -
            .unwrap_or_default();
  185         -
        let mut request_builder = {
  186         -
            #[allow(clippy::uninlined_format_args)]
  187         -
            fn uri_base(
  188         -
                _input: &crate::operation::get_vault_access_policy::GetVaultAccessPolicyInput,
  189         -
                output: &mut ::std::string::String,
  190         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  191         -
                use ::std::fmt::Write as _;
  192         -
                let input_1 = &_input.account_id;
  193         -
                let input_1 = input_1
  194         -
                    .as_ref()
  195         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("account_id", "cannot be empty or unset"))?;
  196         -
                let account_id = ::aws_smithy_http::label::fmt_string(input_1, ::aws_smithy_http::label::EncodingStrategy::Default);
  197         -
                if account_id.is_empty() {
  198         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  199         -
                        "account_id",
  200         -
                        "cannot be empty or unset",
  201         -
                    ));
         328  +
        let protocol = _cfg
         329  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         330  +
            .expect("a SharedClientProtocol is required");
         331  +
        if protocol.supports_http_bindings() {
         332  +
            let mut request = protocol
         333  +
                .serialize_body(&input, GetVaultAccessPolicy::INPUT_SCHEMA, "", _cfg)
         334  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         335  +
            {
         336  +
                let mut uri = "/{accountId}/vaults/{vaultName}/access-policy".to_string();
         337  +
                let mut query_params: Vec<(String, String)> = Vec::new();
         338  +
                if let Some(ref val) = input.account_id {
         339  +
                    uri = uri.replace("{accountId}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  202    340   
                }
  203         -
                let input_2 = &_input.vault_name;
  204         -
                let input_2 = input_2
  205         -
                    .as_ref()
  206         -
                    .ok_or_else(|| ::aws_smithy_types::error::operation::BuildError::missing_field("vault_name", "cannot be empty or unset"))?;
  207         -
                let vault_name = ::aws_smithy_http::label::fmt_string(input_2, ::aws_smithy_http::label::EncodingStrategy::Default);
  208         -
                if vault_name.is_empty() {
  209         -
                    return ::std::result::Result::Err(::aws_smithy_types::error::operation::BuildError::missing_field(
  210         -
                        "vault_name",
  211         -
                        "cannot be empty or unset",
  212         -
                    ));
         341  +
                if let Some(ref val) = input.vault_name {
         342  +
                    uri = uri.replace("{vaultName}", &::aws_smithy_schema::http_protocol::percent_encode(&val.to_string()));
  213    343   
                }
  214         -
                ::std::write!(
  215         -
                    output,
  216         -
                    "/{accountId}/vaults/{vaultName}/access-policy",
  217         -
                    accountId = account_id,
  218         -
                    vaultName = vault_name
  219         -
                )
  220         -
                .expect("formatting should succeed");
  221         -
                ::std::result::Result::Ok(())
  222         -
            }
  223         -
            #[allow(clippy::unnecessary_wraps)]
  224         -
            fn update_http_builder(
  225         -
                input: &crate::operation::get_vault_access_policy::GetVaultAccessPolicyInput,
  226         -
                builder: ::http_1x::request::Builder,
  227         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  228         -
                let mut uri = ::std::string::String::new();
  229         -
                uri_base(input, &mut uri)?;
  230         -
                ::std::result::Result::Ok(builder.method("GET").uri(uri))
         344  +
                if !query_params.is_empty() {
         345  +
                    uri.push(if uri.contains('?') { '&' } else { '?' });
         346  +
                    let pairs: Vec<String> = query_params
         347  +
                        .iter()
         348  +
                        .map(|(k, v)| {
         349  +
                            format!(
         350  +
                                "{}={}",
         351  +
                                ::aws_smithy_schema::http_protocol::percent_encode(k),
         352  +
                                ::aws_smithy_schema::http_protocol::percent_encode(v)
         353  +
                            )
         354  +
                        })
         355  +
                        .collect();
         356  +
                    uri.push_str(&pairs.join("&"));
         357  +
                }
         358  +
                request.set_uri(uri.as_str()).expect("valid URI");
  231    359   
            }
  232         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  233         -
            builder
  234         -
        };
  235         -
        let body = ::aws_smithy_types::body::SdkBody::from("");
  236    360   
  237         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         361  +
            return ::std::result::Result::Ok(request);
         362  +
        } else {
         363  +
            let mut request = protocol
         364  +
                .serialize_request(&input, GetVaultAccessPolicy::INPUT_SCHEMA, "", _cfg)
         365  +
                .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         366  +
         367  +
            return ::std::result::Result::Ok(request);
         368  +
        }
  238    369   
    }
  239    370   
}
  240    371   
#[derive(Debug)]
  241    372   
struct GetVaultAccessPolicyEndpointParamsInterceptor;
  242    373   
  243    374   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for GetVaultAccessPolicyEndpointParamsInterceptor {
  244    375   
    fn name(&self) -> &'static str {
  245    376   
        "GetVaultAccessPolicyEndpointParamsInterceptor"
  246    377   
    }
  247    378