AWS SDK

AWS SDK

rev. 96f5a1b4ad139d2f1ad1e8e40f300e1cd1ff574c (ignoring whitespace)

Files changed:

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_destination/_delete_delivery_destination_input.rs

@@ -23,23 +108,120 @@
   43     43   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   44     44   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   45     45   
        if let Some(ref val) = self.name {
   46     46   
            ser.write_string(&DELETEDELIVERYDESTINATIONINPUT_MEMBER_NAME, val)?;
   47     47   
        }
   48     48   
        Ok(())
   49     49   
    }
   50     50   
}
   51     51   
impl DeleteDeliveryDestinationInput {
   52     52   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   53         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   54         -
        deserializer: &mut D,
          53  +
    pub fn deserialize(
          54  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   55     55   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   56     56   
        #[allow(unused_variables, unused_mut)]
   57     57   
        let mut builder = Self::builder();
   58     58   
        #[allow(
   59     59   
            unused_variables,
   60     60   
            unreachable_code,
   61     61   
            clippy::single_match,
   62     62   
            clippy::match_single_binding,
   63     63   
            clippy::diverging_sub_expression
   64     64   
        )]
   65         -
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONINPUT_SCHEMA, (), |_, member, deser| {
          65  +
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONINPUT_SCHEMA, &mut |member, deser| {
   66     66   
            match member.member_index() {
   67     67   
                Some(0) => {
   68     68   
                    builder.name = Some(deser.read_string(member)?);
   69     69   
                }
   70     70   
                _ => {}
   71     71   
            }
   72     72   
            Ok(())
   73     73   
        })?;
          74  +
        builder.name = builder.name.or(Some(String::new()));
   74     75   
        builder
   75     76   
            .build()
   76     77   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   77     78   
    }
   78     79   
}
          80  +
impl DeleteDeliveryDestinationInput {
          81  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          82  +
    pub fn deserialize_with_response(
          83  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          84  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          85  +
        _status: u16,
          86  +
        _body: &[u8],
          87  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          88  +
        Self::deserialize(deserializer)
          89  +
    }
          90  +
}
   79     91   
impl DeleteDeliveryDestinationInput {
   80     92   
    /// Creates a new builder-style object to manufacture [`DeleteDeliveryDestinationInput`](crate::operation::delete_delivery_destination::DeleteDeliveryDestinationInput).
   81     93   
    pub fn builder() -> crate::operation::delete_delivery_destination::builders::DeleteDeliveryDestinationInputBuilder {
   82     94   
        crate::operation::delete_delivery_destination::builders::DeleteDeliveryDestinationInputBuilder::default()
   83     95   
    }
   84     96   
}
   85     97   
   86     98   
/// A builder for [`DeleteDeliveryDestinationInput`](crate::operation::delete_delivery_destination::DeleteDeliveryDestinationInput).
   87     99   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   88    100   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_destination/_delete_delivery_destination_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct DeleteDeliveryDestinationOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.cloudwatchlogs.synthetic#DeleteDeliveryDestinationOutput",
   10     10   
    "com.amazonaws.cloudwatchlogs.synthetic",
   11     11   
    "DeleteDeliveryDestinationOutput",
   12     12   
);
   13         -
static DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static DELETEDELIVERYDESTINATIONOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&DELETEDELIVERYDESTINATIONOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl DeleteDeliveryDestinationOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for DeleteDeliveryDestinationOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl DeleteDeliveryDestinationOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl DeleteDeliveryDestinationOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for DeleteDeliveryDestinationOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl DeleteDeliveryDestinationOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`DeleteDeliveryDestinationOutput`](crate::operation::delete_delivery_destination::DeleteDeliveryDestinationOutput).
   58     89   
    pub fn builder() -> crate::operation::delete_delivery_destination::builders::DeleteDeliveryDestinationOutputBuilder {
   59     90   
        crate::operation::delete_delivery_destination::builders::DeleteDeliveryDestinationOutputBuilder::default()
   60     91   
    }

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_destination_policy.rs

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

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_destination_policy/_delete_delivery_destination_policy_input.rs

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

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_destination_policy/_delete_delivery_destination_policy_output.rs

@@ -1,1 +83,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct DeleteDeliveryDestinationPolicyOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.cloudwatchlogs.synthetic#DeleteDeliveryDestinationPolicyOutput",
   10     10   
    "com.amazonaws.cloudwatchlogs.synthetic",
   11     11   
    "DeleteDeliveryDestinationPolicyOutput",
   12     12   
);
          13  +
static DELETEDELIVERYDESTINATIONPOLICYOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
   13     20   
static DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   14     21   
    DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA_ID,
   15     22   
    ::aws_smithy_schema::ShapeType::Structure,
   16         -
    &[],
          23  +
    &[&DELETEDELIVERYDESTINATIONPOLICYOUTPUT_MEMBER__REQUEST_ID],
   17     24   
);
   18     25   
impl DeleteDeliveryDestinationPolicyOutput {
   19     26   
    /// The schema for this shape.
   20     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA;
   21     28   
}
   22     29   
impl ::aws_smithy_schema::serde::SerializableStruct for DeleteDeliveryDestinationPolicyOutput {
   23     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   24     31   
    fn serialize_members(
   25     32   
        &self,
   26     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   27     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   28     35   
        Ok(())
   29     36   
    }
   30     37   
}
   31     38   
impl DeleteDeliveryDestinationPolicyOutput {
   32     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   33         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   34         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   35     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   36     43   
        #[allow(unused_variables, unused_mut)]
   37     44   
        let mut builder = Self::builder();
   38     45   
        #[allow(
   39     46   
            unused_variables,
   40     47   
            unreachable_code,
   41     48   
            clippy::single_match,
   42     49   
            clippy::match_single_binding,
   43     50   
            clippy::diverging_sub_expression
   44     51   
        )]
   45         -
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&DELETEDELIVERYDESTINATIONPOLICYOUTPUT_SCHEMA, &mut |member, deser| {
   46     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   47     57   
                _ => {}
   48     58   
            }
   49     59   
            Ok(())
   50     60   
        })?;
   51     61   
        Ok(builder.build())
   52     62   
    }
   53     63   
}
          64  +
impl DeleteDeliveryDestinationPolicyOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   54     82   
impl ::aws_types::request_id::RequestId for DeleteDeliveryDestinationPolicyOutput {
   55     83   
    fn request_id(&self) -> Option<&str> {
   56     84   
        self._request_id.as_deref()
   57     85   
    }
   58     86   
}
   59     87   
impl DeleteDeliveryDestinationPolicyOutput {
   60     88   
    /// Creates a new builder-style object to manufacture [`DeleteDeliveryDestinationPolicyOutput`](crate::operation::delete_delivery_destination_policy::DeleteDeliveryDestinationPolicyOutput).
   61     89   
    pub fn builder() -> crate::operation::delete_delivery_destination_policy::builders::DeleteDeliveryDestinationPolicyOutputBuilder {
   62     90   
        crate::operation::delete_delivery_destination_policy::builders::DeleteDeliveryDestinationPolicyOutputBuilder::default()
   63     91   
    }

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_source.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 `DeleteDeliverySource`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct DeleteDeliverySource;
    6      6   
impl DeleteDeliverySource {
    7      7   
    /// Creates a new `DeleteDeliverySource`
    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::delete_delivery_source::DeleteDeliverySourceInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::delete_delivery_source::DeleteDeliverySourceOutput::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::delete_delivery_source::DeleteDeliverySourceInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::delete_delivery_source::DeleteDeliverySourceOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::delete_delivery_source::DeleteDeliverySourceError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -124,128 +253,414 @@
  144    148   
                crate::operation::delete_delivery_source::DeleteDeliverySourceError,
  145    149   
            >::new());
  146    150   
  147    151   
        ::std::borrow::Cow::Owned(rcb)
  148    152   
    }
  149    153   
}
  150    154   
  151    155   
#[derive(Debug)]
  152    156   
struct DeleteDeliverySourceResponseDeserializer;
  153    157   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for DeleteDeliverySourceResponseDeserializer {
  154         -
    fn deserialize_nonstreaming(
         158  +
    fn deserialize_nonstreaming_with_config(
  155    159   
        &self,
  156    160   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         161  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  157    162   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  158    163   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  159         -
        let headers = response.headers();
  160         -
        let body = response.body().bytes().expect("body loaded");
  161    164   
        #[allow(unused_mut)]
  162    165   
        let mut force_error = false;
  163    166   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  164         -
        let parse_result = if !success && status != 200 || force_error {
  165         -
            crate::protocol_serde::shape_delete_delivery_source::de_delete_delivery_source_http_error(status, headers, body)
  166         -
        } else {
  167         -
            crate::protocol_serde::shape_delete_delivery_source::de_delete_delivery_source_http_response(status, headers, body)
         167  +
        if !success && status != 200 || force_error {
         168  +
            let headers = response.headers();
         169  +
            let body = response.body().bytes().expect("body loaded");
         170  +
            #[allow(unused_mut)]
         171  +
            let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(status, headers, body).map_err(|e| {
         172  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         173  +
            })?;
         174  +
            generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, headers);
         175  +
            let generic = generic_builder.build();
         176  +
            let error_code = match generic.code() {
         177  +
                ::std::option::Option::Some(code) => code,
         178  +
                ::std::option::Option::None => {
         179  +
                    return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         180  +
                        ::aws_smithy_runtime_api::box_error::BoxError::from(
         181  +
                            crate::operation::delete_delivery_source::DeleteDeliverySourceError::unhandled(generic),
         182  +
                        ),
         183  +
                    ))
         184  +
                }
  168    185   
            };
  169         -
        crate::protocol_serde::type_erase_result(parse_result)
         186  +
            let _error_message = generic.message().map(|msg| msg.to_owned());
         187  +
            let protocol = _cfg
         188  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         189  +
                .expect("a SharedClientProtocol is required");
         190  +
            let err = match error_code {
         191  +
                "ConflictException" => crate::operation::delete_delivery_source::DeleteDeliverySourceError::ConflictException({
         192  +
                    let mut tmp = match protocol
         193  +
                        .deserialize_response(response, crate::types::error::ConflictException::SCHEMA, _cfg)
         194  +
                        .and_then(|mut deser| {
         195  +
                            crate::types::error::ConflictException::deserialize_with_response(
         196  +
                                &mut *deser,
         197  +
                                response.headers(),
         198  +
                                response.status().into(),
         199  +
                                body,
         200  +
                            )
         201  +
                        }) {
         202  +
                        ::std::result::Result::Ok(val) => val,
         203  +
                        ::std::result::Result::Err(e) => {
         204  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         205  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         206  +
                            ))
         207  +
                        }
         208  +
                    };
         209  +
                    tmp.meta = generic;
         210  +
                    if tmp.message.is_none() {
         211  +
                        tmp.message = _error_message;
         212  +
                    }
         213  +
                    tmp
         214  +
                }),
         215  +
                "ResourceNotFoundException" => crate::operation::delete_delivery_source::DeleteDeliverySourceError::ResourceNotFoundException({
         216  +
                    let mut tmp = match protocol
         217  +
                        .deserialize_response(response, crate::types::error::ResourceNotFoundException::SCHEMA, _cfg)
         218  +
                        .and_then(|mut deser| {
         219  +
                            crate::types::error::ResourceNotFoundException::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  +
                "ServiceQuotaExceededException" => {
         240  +
                    crate::operation::delete_delivery_source::DeleteDeliverySourceError::ServiceQuotaExceededException({
         241  +
                        let mut tmp = match protocol
         242  +
                            .deserialize_response(response, crate::types::error::ServiceQuotaExceededException::SCHEMA, _cfg)
         243  +
                            .and_then(|mut deser| {
         244  +
                                crate::types::error::ServiceQuotaExceededException::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  +
                }
         265  +
                "ServiceUnavailableException" => crate::operation::delete_delivery_source::DeleteDeliverySourceError::ServiceUnavailableException({
         266  +
                    let mut tmp = match protocol
         267  +
                        .deserialize_response(response, crate::types::error::ServiceUnavailableException::SCHEMA, _cfg)
         268  +
                        .and_then(|mut deser| {
         269  +
                            crate::types::error::ServiceUnavailableException::deserialize_with_response(
         270  +
                                &mut *deser,
         271  +
                                response.headers(),
         272  +
                                response.status().into(),
         273  +
                                body,
         274  +
                            )
         275  +
                        }) {
         276  +
                        ::std::result::Result::Ok(val) => val,
         277  +
                        ::std::result::Result::Err(e) => {
         278  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         279  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         280  +
                            ))
         281  +
                        }
         282  +
                    };
         283  +
                    tmp.meta = generic;
         284  +
                    if tmp.message.is_none() {
         285  +
                        tmp.message = _error_message;
         286  +
                    }
         287  +
                    tmp
         288  +
                }),
         289  +
                "ThrottlingException" => crate::operation::delete_delivery_source::DeleteDeliverySourceError::ThrottlingException({
         290  +
                    let mut tmp = match protocol
         291  +
                        .deserialize_response(response, crate::types::error::ThrottlingException::SCHEMA, _cfg)
         292  +
                        .and_then(|mut deser| {
         293  +
                            crate::types::error::ThrottlingException::deserialize_with_response(
         294  +
                                &mut *deser,
         295  +
                                response.headers(),
         296  +
                                response.status().into(),
         297  +
                                body,
         298  +
                            )
         299  +
                        }) {
         300  +
                        ::std::result::Result::Ok(val) => val,
         301  +
                        ::std::result::Result::Err(e) => {
         302  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         303  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         304  +
                            ))
         305  +
                        }
         306  +
                    };
         307  +
                    tmp.meta = generic;
         308  +
                    if tmp.message.is_none() {
         309  +
                        tmp.message = _error_message;
         310  +
                    }
         311  +
                    tmp
         312  +
                }),
         313  +
                "ValidationException" => crate::operation::delete_delivery_source::DeleteDeliverySourceError::ValidationException({
         314  +
                    let mut tmp = match protocol
         315  +
                        .deserialize_response(response, crate::types::error::ValidationException::SCHEMA, _cfg)
         316  +
                        .and_then(|mut deser| {
         317  +
                            crate::types::error::ValidationException::deserialize_with_response(
         318  +
                                &mut *deser,
         319  +
                                response.headers(),
         320  +
                                response.status().into(),
         321  +
                                body,
         322  +
                            )
         323  +
                        }) {
         324  +
                        ::std::result::Result::Ok(val) => val,
         325  +
                        ::std::result::Result::Err(e) => {
         326  +
                            return ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(
         327  +
                                ::aws_smithy_runtime_api::box_error::BoxError::from(e),
         328  +
                            ))
         329  +
                        }
         330  +
                    };
         331  +
                    tmp.meta = generic;
         332  +
                    if tmp.message.is_none() {
         333  +
                        tmp.message = _error_message;
         334  +
                    }
         335  +
                    tmp
         336  +
                }),
         337  +
                _ => crate::operation::delete_delivery_source::DeleteDeliverySourceError::generic(generic),
         338  +
            };
         339  +
            ::std::result::Result::Err(::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::operation(
         340  +
                ::aws_smithy_runtime_api::client::interceptors::context::Error::erase(err),
         341  +
            ))
         342  +
        } else {
         343  +
            let protocol = _cfg
         344  +
                .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         345  +
                .expect("a SharedClientProtocol is required");
         346  +
            let mut deser = protocol
         347  +
                .deserialize_response(response, DeleteDeliverySource::OUTPUT_SCHEMA, _cfg)
         348  +
                .map_err(|e| {
         349  +
                    ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         350  +
                })?;
         351  +
            let body = response.body().bytes().expect("body loaded");
         352  +
            let output = crate::operation::delete_delivery_source::DeleteDeliverySourceOutput::deserialize_with_response(
         353  +
                &mut *deser,
         354  +
                response.headers(),
         355  +
                response.status().into(),
         356  +
                body,
         357  +
            )
         358  +
            .map_err(|e| {
         359  +
                ::aws_smithy_runtime_api::client::orchestrator::OrchestratorError::other(::aws_smithy_runtime_api::box_error::BoxError::from(e))
         360  +
            })?;
         361  +
            ::std::result::Result::Ok(::aws_smithy_runtime_api::client::interceptors::context::Output::erase(output))
         362  +
        }
  170    363   
    }
  171    364   
}
  172    365   
#[derive(Debug)]
  173    366   
struct DeleteDeliverySourceRequestSerializer;
  174    367   
impl ::aws_smithy_runtime_api::client::ser_de::SerializeRequest for DeleteDeliverySourceRequestSerializer {
  175    368   
    #[allow(unused_mut, clippy::let_and_return, clippy::needless_borrow, clippy::useless_conversion)]
  176    369   
    fn serialize_input(
  177    370   
        &self,
  178    371   
        input: ::aws_smithy_runtime_api::client::interceptors::context::Input,
  179    372   
        _cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  180    373   
    ) -> ::std::result::Result<::aws_smithy_runtime_api::client::orchestrator::HttpRequest, ::aws_smithy_runtime_api::box_error::BoxError> {
  181    374   
        let input = input
  182    375   
            .downcast::<crate::operation::delete_delivery_source::DeleteDeliverySourceInput>()
  183    376   
            .expect("correct type");
  184         -
        let _header_serialization_settings = _cfg
  185         -
            .load::<crate::serialization_settings::HeaderSerializationSettings>()
  186         -
            .cloned()
  187         -
            .unwrap_or_default();
  188         -
        let mut request_builder = {
  189         -
            #[allow(clippy::uninlined_format_args)]
  190         -
            fn uri_base(
  191         -
                _input: &crate::operation::delete_delivery_source::DeleteDeliverySourceInput,
  192         -
                output: &mut ::std::string::String,
  193         -
            ) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::BuildError> {
  194         -
                use ::std::fmt::Write as _;
  195         -
                ::std::write!(output, "/").expect("formatting should succeed");
  196         -
                ::std::result::Result::Ok(())
  197         -
            }
  198         -
            #[allow(clippy::unnecessary_wraps)]
  199         -
            fn update_http_builder(
  200         -
                input: &crate::operation::delete_delivery_source::DeleteDeliverySourceInput,
  201         -
                builder: ::http_1x::request::Builder,
  202         -
            ) -> ::std::result::Result<::http_1x::request::Builder, ::aws_smithy_types::error::operation::BuildError> {
  203         -
                let mut uri = ::std::string::String::new();
  204         -
                uri_base(input, &mut uri)?;
  205         -
                ::std::result::Result::Ok(builder.method("POST").uri(uri))
  206         -
            }
  207         -
            let mut builder = update_http_builder(&input, ::http_1x::request::Builder::new())?;
  208         -
            builder = _header_serialization_settings.set_default_header(builder, ::http_1x::header::CONTENT_TYPE, "application/x-amz-json-1.1");
  209         -
            builder = _header_serialization_settings.set_default_header(
  210         -
                builder,
  211         -
                ::http_1x::header::HeaderName::from_static("x-amz-target"),
  212         -
                "Logs_20140328.DeleteDeliverySource",
  213         -
            );
  214         -
            builder
  215         -
        };
  216         -
        let body = ::aws_smithy_types::body::SdkBody::from(crate::protocol_serde::shape_delete_delivery_source::ser_delete_delivery_source_input(
  217         -
            &input,
  218         -
        )?);
  219         -
        if let Some(content_length) = body.content_length() {
  220         -
            let content_length = content_length.to_string();
  221         -
            request_builder = _header_serialization_settings.set_default_header(request_builder, ::http_1x::header::CONTENT_LENGTH, &content_length);
  222         -
        }
  223         -
        ::std::result::Result::Ok(request_builder.body(body).expect("valid request").try_into().unwrap())
         377  +
        let protocol = _cfg
         378  +
            .load::<::aws_smithy_schema::protocol::SharedClientProtocol>()
         379  +
            .expect("a SharedClientProtocol is required");
         380  +
        let mut request = protocol
         381  +
            .serialize_request(&input, DeleteDeliverySource::INPUT_SCHEMA, "", _cfg)
         382  +
            .map_err(::aws_smithy_runtime_api::box_error::BoxError::from)?;
         383  +
         384  +
        return ::std::result::Result::Ok(request);
  224    385   
    }
  225    386   
}
  226    387   
#[derive(Debug)]
  227    388   
struct DeleteDeliverySourceEndpointParamsInterceptor;
  228    389   
  229    390   
impl ::aws_smithy_runtime_api::client::interceptors::Intercept for DeleteDeliverySourceEndpointParamsInterceptor {
  230    391   
    fn name(&self) -> &'static str {
  231    392   
        "DeleteDeliverySourceEndpointParamsInterceptor"
  232    393   
    }
  233    394   

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_source/_delete_delivery_source_input.rs

@@ -23,23 +108,120 @@
   43     43   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   44     44   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   45     45   
        if let Some(ref val) = self.name {
   46     46   
            ser.write_string(&DELETEDELIVERYSOURCEINPUT_MEMBER_NAME, val)?;
   47     47   
        }
   48     48   
        Ok(())
   49     49   
    }
   50     50   
}
   51     51   
impl DeleteDeliverySourceInput {
   52     52   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   53         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   54         -
        deserializer: &mut D,
          53  +
    pub fn deserialize(
          54  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   55     55   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   56     56   
        #[allow(unused_variables, unused_mut)]
   57     57   
        let mut builder = Self::builder();
   58     58   
        #[allow(
   59     59   
            unused_variables,
   60     60   
            unreachable_code,
   61     61   
            clippy::single_match,
   62     62   
            clippy::match_single_binding,
   63     63   
            clippy::diverging_sub_expression
   64     64   
        )]
   65         -
        deserializer.read_struct(&DELETEDELIVERYSOURCEINPUT_SCHEMA, (), |_, member, deser| {
          65  +
        deserializer.read_struct(&DELETEDELIVERYSOURCEINPUT_SCHEMA, &mut |member, deser| {
   66     66   
            match member.member_index() {
   67     67   
                Some(0) => {
   68     68   
                    builder.name = Some(deser.read_string(member)?);
   69     69   
                }
   70     70   
                _ => {}
   71     71   
            }
   72     72   
            Ok(())
   73     73   
        })?;
          74  +
        builder.name = builder.name.or(Some(String::new()));
   74     75   
        builder
   75     76   
            .build()
   76     77   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
   77     78   
    }
   78     79   
}
          80  +
impl DeleteDeliverySourceInput {
          81  +
    /// Deserializes this structure from a body deserializer and HTTP response.
          82  +
    pub fn deserialize_with_response(
          83  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          84  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
          85  +
        _status: u16,
          86  +
        _body: &[u8],
          87  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          88  +
        Self::deserialize(deserializer)
          89  +
    }
          90  +
}
   79     91   
impl DeleteDeliverySourceInput {
   80     92   
    /// Creates a new builder-style object to manufacture [`DeleteDeliverySourceInput`](crate::operation::delete_delivery_source::DeleteDeliverySourceInput).
   81     93   
    pub fn builder() -> crate::operation::delete_delivery_source::builders::DeleteDeliverySourceInputBuilder {
   82     94   
        crate::operation::delete_delivery_source::builders::DeleteDeliverySourceInputBuilder::default()
   83     95   
    }
   84     96   
}
   85     97   
   86     98   
/// A builder for [`DeleteDeliverySourceInput`](crate::operation::delete_delivery_source::DeleteDeliverySourceInput).
   87     99   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
   88    100   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_delivery_source/_delete_delivery_source_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct DeleteDeliverySourceOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static DELETEDELIVERYSOURCEOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.cloudwatchlogs.synthetic#DeleteDeliverySourceOutput",
   10     10   
    "com.amazonaws.cloudwatchlogs.synthetic",
   11     11   
    "DeleteDeliverySourceOutput",
   12     12   
);
   13         -
static DELETEDELIVERYSOURCEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(DELETEDELIVERYSOURCEOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static DELETEDELIVERYSOURCEOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static DELETEDELIVERYSOURCEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    DELETEDELIVERYSOURCEOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&DELETEDELIVERYSOURCEOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl DeleteDeliverySourceOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DELETEDELIVERYSOURCEOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for DeleteDeliverySourceOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl DeleteDeliverySourceOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&DELETEDELIVERYSOURCEOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&DELETEDELIVERYSOURCEOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl DeleteDeliverySourceOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for DeleteDeliverySourceOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl DeleteDeliverySourceOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`DeleteDeliverySourceOutput`](crate::operation::delete_delivery_source::DeleteDeliverySourceOutput).
   58     89   
    pub fn builder() -> crate::operation::delete_delivery_source::builders::DeleteDeliverySourceOutputBuilder {
   59     90   
        crate::operation::delete_delivery_source::builders::DeleteDeliverySourceOutputBuilder::default()
   60     91   
    }

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

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_destination/_delete_destination_input.rs

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

tmp-codegen-diff/aws-sdk/sdk/cloudwatchlogs/src/operation/delete_destination/_delete_destination_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct DeleteDestinationOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static DELETEDESTINATIONOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.cloudwatchlogs.synthetic#DeleteDestinationOutput",
   10     10   
    "com.amazonaws.cloudwatchlogs.synthetic",
   11     11   
    "DeleteDestinationOutput",
   12     12   
);
   13         -
static DELETEDESTINATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(DELETEDESTINATIONOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static DELETEDESTINATIONOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static DELETEDESTINATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    DELETEDESTINATIONOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&DELETEDESTINATIONOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl DeleteDestinationOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DELETEDESTINATIONOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for DeleteDestinationOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl DeleteDestinationOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&DELETEDESTINATIONOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&DELETEDESTINATIONOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl DeleteDestinationOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for DeleteDestinationOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl DeleteDestinationOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`DeleteDestinationOutput`](crate::operation::delete_destination::DeleteDestinationOutput).
   58     89   
    pub fn builder() -> crate::operation::delete_destination::builders::DeleteDestinationOutputBuilder {
   59     90   
        crate::operation::delete_destination::builders::DeleteDestinationOutputBuilder::default()
   60     91   
    }

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