AWS SDK

AWS SDK

rev. ec7b2441254af868911fccffe8d8dca83aff0045 (ignoring whitespace)

Files changed:

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_get_policy.rs

@@ -1,0 +148,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_get_policy_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<crate::operation::get_policy::GetPolicyOutput, crate::operation::get_policy::GetPolicyError> {
    8         -
    #[allow(unused_mut)]
    9         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   10         -
        .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
   11         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   12         -
    let generic = generic_builder.build();
   13         -
    let error_code = match generic.code() {
   14         -
        Some(code) => code,
   15         -
        None => return Err(crate::operation::get_policy::GetPolicyError::unhandled(generic)),
   16         -
    };
   17         -
   18         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   19         -
    Err(match error_code {
   20         -
        "InvalidParameterValueException" => crate::operation::get_policy::GetPolicyError::InvalidParameterValueException({
   21         -
            #[allow(unused_mut)]
   22         -
            let mut tmp = {
   23         -
                #[allow(unused_mut)]
   24         -
                let mut output = crate::types::error::builders::InvalidParameterValueExceptionBuilder::default();
   25         -
                output = crate::protocol_serde::shape_invalid_parameter_value_exception::de_invalid_parameter_value_exception_json_err(
   26         -
                    _response_body,
   27         -
                    output,
   28         -
                )
   29         -
                .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
   30         -
                let output = output.meta(generic);
   31         -
                output.build()
   32         -
            };
   33         -
            if tmp.message.is_none() {
   34         -
                tmp.message = _error_message;
   35         -
            }
   36         -
            tmp
   37         -
        }),
   38         -
        "ResourceNotFoundException" => crate::operation::get_policy::GetPolicyError::ResourceNotFoundException({
   39         -
            #[allow(unused_mut)]
   40         -
            let mut tmp = {
   41         -
                #[allow(unused_mut)]
   42         -
                let mut output = crate::types::error::builders::ResourceNotFoundExceptionBuilder::default();
   43         -
                output = crate::protocol_serde::shape_resource_not_found_exception::de_resource_not_found_exception_json_err(_response_body, output)
   44         -
                    .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
   45         -
                let output = output.meta(generic);
   46         -
                output.build()
   47         -
            };
   48         -
            if tmp.message.is_none() {
   49         -
                tmp.message = _error_message;
   50         -
            }
   51         -
            tmp
   52         -
        }),
   53         -
        "ServiceException" => crate::operation::get_policy::GetPolicyError::ServiceException({
   54         -
            #[allow(unused_mut)]
   55         -
            let mut tmp = {
   56         -
                #[allow(unused_mut)]
   57         -
                let mut output = crate::types::error::builders::ServiceExceptionBuilder::default();
   58         -
                output = crate::protocol_serde::shape_service_exception::de_service_exception_json_err(_response_body, output)
   59         -
                    .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
   60         -
                let output = output.meta(generic);
   61         -
                output.build()
   62         -
            };
   63         -
            if tmp.message.is_none() {
   64         -
                tmp.message = _error_message;
   65         -
            }
   66         -
            tmp
   67         -
        }),
   68         -
        "TooManyRequestsException" => crate::operation::get_policy::GetPolicyError::TooManyRequestsException({
   69         -
            #[allow(unused_mut)]
   70         -
            let mut tmp = {
   71         -
                #[allow(unused_mut)]
   72         -
                let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
   73         -
                output = crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
   74         -
                    .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
   75         -
                output = output.set_retry_after_seconds(
   76         -
                    crate::protocol_serde::shape_too_many_requests_exception::de_retry_after_seconds_header(_response_headers).map_err(|_| {
   77         -
                        crate::operation::get_policy::GetPolicyError::unhandled("Failed to parse retryAfterSeconds from header `Retry-After")
   78         -
                    })?,
   79         -
                );
   80         -
                let output = output.meta(generic);
   81         -
                output.build()
   82         -
            };
   83         -
            if tmp.message.is_none() {
   84         -
                tmp.message = _error_message;
   85         -
            }
   86         -
            tmp
   87         -
        }),
   88         -
        _ => crate::operation::get_policy::GetPolicyError::generic(generic),
   89         -
    })
   90         -
}
   91         -
   92         -
#[allow(clippy::unnecessary_wraps)]
   93         -
pub fn de_get_policy_http_response(
   94         -
    _response_status: u16,
   95         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
   96         -
    _response_body: &[u8],
   97         -
) -> std::result::Result<crate::operation::get_policy::GetPolicyOutput, crate::operation::get_policy::GetPolicyError> {
   98         -
    Ok({
   99         -
        #[allow(unused_mut)]
  100         -
        let mut output = crate::operation::get_policy::builders::GetPolicyOutputBuilder::default();
  101         -
        output = crate::protocol_serde::shape_get_policy::de_get_policy(_response_body, output)
  102         -
            .map_err(crate::operation::get_policy::GetPolicyError::unhandled)?;
  103         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
  104         -
        output.build()
  105         -
    })
  106         -
}
  107         -
  108         -
pub(crate) fn de_get_policy(
  109         -
    _value: &[u8],
  110         -
    mut builder: crate::operation::get_policy::builders::GetPolicyOutputBuilder,
  111         -
) -> ::std::result::Result<crate::operation::get_policy::builders::GetPolicyOutputBuilder, ::aws_smithy_json::deserialize::error::DeserializeError> {
  112         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  113         -
    let tokens = &mut tokens_owned;
  114         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  115         -
    loop {
  116         -
        match tokens.next().transpose()? {
  117         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  118         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  119         -
                "Policy" => {
  120         -
                    builder = builder.set_policy(
  121         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  122         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  123         -
                            .transpose()?,
  124         -
                    );
  125         -
                }
  126         -
                "RevisionId" => {
  127         -
                    builder = builder.set_revision_id(
  128         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  129         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  130         -
                            .transpose()?,
  131         -
                    );
  132         -
                }
  133         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  134         -
            },
  135         -
            other => {
  136         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  137         -
                    "expected object key or end object, found: {other:?}"
  138         -
                )))
  139         -
            }
  140         -
        }
  141         -
    }
  142         -
    if tokens.next().is_some() {
  143         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  144         -
            "found more JSON tokens after completing parsing",
  145         -
        ));
  146         -
    }
  147         -
    Ok(builder)
  148         -
}

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_get_provisioned_concurrency_config.rs

@@ -1,0 +213,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_get_provisioned_concurrency_config_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<
    8         -
    crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigOutput,
    9         -
    crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError,
   10         -
> {
   11         -
    #[allow(unused_mut)]
   12         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   13         -
        .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
   14         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   15         -
    let generic = generic_builder.build();
   16         -
    let error_code = match generic.code() {
   17         -
        Some(code) => code,
   18         -
        None => return Err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled(generic)),
   19         -
    };
   20         -
   21         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   22         -
    Err(match error_code {
   23         -
        "InvalidParameterValueException" => {
   24         -
            crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::InvalidParameterValueException({
   25         -
                #[allow(unused_mut)]
   26         -
                let mut tmp = {
   27         -
                    #[allow(unused_mut)]
   28         -
                    let mut output = crate::types::error::builders::InvalidParameterValueExceptionBuilder::default();
   29         -
                    output = crate::protocol_serde::shape_invalid_parameter_value_exception::de_invalid_parameter_value_exception_json_err(
   30         -
                        _response_body,
   31         -
                        output,
   32         -
                    )
   33         -
                    .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
   34         -
                    let output = output.meta(generic);
   35         -
                    output.build()
   36         -
                };
   37         -
                if tmp.message.is_none() {
   38         -
                    tmp.message = _error_message;
   39         -
                }
   40         -
                tmp
   41         -
            })
   42         -
        }
   43         -
        "ProvisionedConcurrencyConfigNotFoundException" => {
   44         -
            crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::ProvisionedConcurrencyConfigNotFoundException(
   45         -
                {
   46         -
                    #[allow(unused_mut)]
   47         -
                    let mut tmp = {
   48         -
                        #[allow(unused_mut)]
   49         -
                        let mut output = crate::types::error::builders::ProvisionedConcurrencyConfigNotFoundExceptionBuilder::default();
   50         -
                        output = crate::protocol_serde::shape_provisioned_concurrency_config_not_found_exception::de_provisioned_concurrency_config_not_found_exception_json_err(_response_body, output).map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
   51         -
                        let output = output.meta(generic);
   52         -
                        output.build()
   53         -
                    };
   54         -
                    if tmp.message.is_none() {
   55         -
                        tmp.message = _error_message;
   56         -
                    }
   57         -
                    tmp
   58         -
                },
   59         -
            )
   60         -
        }
   61         -
        "ResourceNotFoundException" => {
   62         -
            crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::ResourceNotFoundException({
   63         -
                #[allow(unused_mut)]
   64         -
                let mut tmp = {
   65         -
                    #[allow(unused_mut)]
   66         -
                    let mut output = crate::types::error::builders::ResourceNotFoundExceptionBuilder::default();
   67         -
                    output =
   68         -
                        crate::protocol_serde::shape_resource_not_found_exception::de_resource_not_found_exception_json_err(_response_body, output)
   69         -
                            .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
   70         -
                    let output = output.meta(generic);
   71         -
                    output.build()
   72         -
                };
   73         -
                if tmp.message.is_none() {
   74         -
                    tmp.message = _error_message;
   75         -
                }
   76         -
                tmp
   77         -
            })
   78         -
        }
   79         -
        "ServiceException" => crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::ServiceException({
   80         -
            #[allow(unused_mut)]
   81         -
            let mut tmp = {
   82         -
                #[allow(unused_mut)]
   83         -
                let mut output = crate::types::error::builders::ServiceExceptionBuilder::default();
   84         -
                output = crate::protocol_serde::shape_service_exception::de_service_exception_json_err(_response_body, output)
   85         -
                    .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
   86         -
                let output = output.meta(generic);
   87         -
                output.build()
   88         -
            };
   89         -
            if tmp.message.is_none() {
   90         -
                tmp.message = _error_message;
   91         -
            }
   92         -
            tmp
   93         -
        }),
   94         -
        "TooManyRequestsException" => {
   95         -
            crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::TooManyRequestsException({
   96         -
                #[allow(unused_mut)]
   97         -
                let mut tmp = {
   98         -
                    #[allow(unused_mut)]
   99         -
                    let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
  100         -
                    output =
  101         -
                        crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
  102         -
                            .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
  103         -
                    output = output.set_retry_after_seconds(
  104         -
                        crate::protocol_serde::shape_too_many_requests_exception::de_retry_after_seconds_header(_response_headers).map_err(|_| {
  105         -
                            crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled(
  106         -
                                "Failed to parse retryAfterSeconds from header `Retry-After",
  107         -
                            )
  108         -
                        })?,
  109         -
                    );
  110         -
                    let output = output.meta(generic);
  111         -
                    output.build()
  112         -
                };
  113         -
                if tmp.message.is_none() {
  114         -
                    tmp.message = _error_message;
  115         -
                }
  116         -
                tmp
  117         -
            })
  118         -
        }
  119         -
        _ => crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::generic(generic),
  120         -
    })
  121         -
}
  122         -
  123         -
#[allow(clippy::unnecessary_wraps)]
  124         -
pub fn de_get_provisioned_concurrency_config_http_response(
  125         -
    _response_status: u16,
  126         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
  127         -
    _response_body: &[u8],
  128         -
) -> std::result::Result<
  129         -
    crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigOutput,
  130         -
    crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError,
  131         -
> {
  132         -
    Ok({
  133         -
        #[allow(unused_mut)]
  134         -
        let mut output = crate::operation::get_provisioned_concurrency_config::builders::GetProvisionedConcurrencyConfigOutputBuilder::default();
  135         -
        output = crate::protocol_serde::shape_get_provisioned_concurrency_config::de_get_provisioned_concurrency_config(_response_body, output)
  136         -
            .map_err(crate::operation::get_provisioned_concurrency_config::GetProvisionedConcurrencyConfigError::unhandled)?;
  137         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
  138         -
        output.build()
  139         -
    })
  140         -
}
  141         -
  142         -
pub(crate) fn de_get_provisioned_concurrency_config(
  143         -
    _value: &[u8],
  144         -
    mut builder: crate::operation::get_provisioned_concurrency_config::builders::GetProvisionedConcurrencyConfigOutputBuilder,
  145         -
) -> ::std::result::Result<
  146         -
    crate::operation::get_provisioned_concurrency_config::builders::GetProvisionedConcurrencyConfigOutputBuilder,
  147         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  148         -
> {
  149         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  150         -
    let tokens = &mut tokens_owned;
  151         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  152         -
    loop {
  153         -
        match tokens.next().transpose()? {
  154         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  155         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  156         -
                "AllocatedProvisionedConcurrentExecutions" => {
  157         -
                    builder = builder.set_allocated_provisioned_concurrent_executions(
  158         -
                        ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
  159         -
                            .map(i32::try_from)
  160         -
                            .transpose()?,
  161         -
                    );
  162         -
                }
  163         -
                "AvailableProvisionedConcurrentExecutions" => {
  164         -
                    builder = builder.set_available_provisioned_concurrent_executions(
  165         -
                        ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
  166         -
                            .map(i32::try_from)
  167         -
                            .transpose()?,
  168         -
                    );
  169         -
                }
  170         -
                "LastModified" => {
  171         -
                    builder = builder.set_last_modified(
  172         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  173         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  174         -
                            .transpose()?,
  175         -
                    );
  176         -
                }
  177         -
                "RequestedProvisionedConcurrentExecutions" => {
  178         -
                    builder = builder.set_requested_provisioned_concurrent_executions(
  179         -
                        ::aws_smithy_json::deserialize::token::expect_number_or_null(tokens.next())?
  180         -
                            .map(i32::try_from)
  181         -
                            .transpose()?,
  182         -
                    );
  183         -
                }
  184         -
                "Status" => {
  185         -
                    builder = builder.set_status(
  186         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  187         -
                            .map(|s| s.to_unescaped().map(|u| crate::types::ProvisionedConcurrencyStatusEnum::from(u.as_ref())))
  188         -
                            .transpose()?,
  189         -
                    );
  190         -
                }
  191         -
                "StatusReason" => {
  192         -
                    builder = builder.set_status_reason(
  193         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  194         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  195         -
                            .transpose()?,
  196         -
                    );
  197         -
                }
  198         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  199         -
            },
  200         -
            other => {
  201         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  202         -
                    "expected object key or end object, found: {other:?}"
  203         -
                )))
  204         -
            }
  205         -
        }
  206         -
    }
  207         -
    if tokens.next().is_some() {
  208         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  209         -
            "found more JSON tokens after completing parsing",
  210         -
        ));
  211         -
    }
  212         -
    Ok(builder)
  213         -
}

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_get_runtime_management_config.rs

@@ -1,0 +168,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
#[allow(clippy::unnecessary_wraps)]
    3         -
pub fn de_get_runtime_management_config_http_error(
    4         -
    _response_status: u16,
    5         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
    6         -
    _response_body: &[u8],
    7         -
) -> std::result::Result<
    8         -
    crate::operation::get_runtime_management_config::GetRuntimeManagementConfigOutput,
    9         -
    crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError,
   10         -
> {
   11         -
    #[allow(unused_mut)]
   12         -
    let mut generic_builder = crate::protocol_serde::parse_http_error_metadata(_response_status, _response_headers, _response_body)
   13         -
        .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
   14         -
    generic_builder = ::aws_types::request_id::apply_request_id(generic_builder, _response_headers);
   15         -
    let generic = generic_builder.build();
   16         -
    let error_code = match generic.code() {
   17         -
        Some(code) => code,
   18         -
        None => return Err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled(generic)),
   19         -
    };
   20         -
   21         -
    let _error_message = generic.message().map(|msg| msg.to_owned());
   22         -
    Err(match error_code {
   23         -
        "InvalidParameterValueException" => {
   24         -
            crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::InvalidParameterValueException({
   25         -
                #[allow(unused_mut)]
   26         -
                let mut tmp = {
   27         -
                    #[allow(unused_mut)]
   28         -
                    let mut output = crate::types::error::builders::InvalidParameterValueExceptionBuilder::default();
   29         -
                    output = crate::protocol_serde::shape_invalid_parameter_value_exception::de_invalid_parameter_value_exception_json_err(
   30         -
                        _response_body,
   31         -
                        output,
   32         -
                    )
   33         -
                    .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
   34         -
                    let output = output.meta(generic);
   35         -
                    output.build()
   36         -
                };
   37         -
                if tmp.message.is_none() {
   38         -
                    tmp.message = _error_message;
   39         -
                }
   40         -
                tmp
   41         -
            })
   42         -
        }
   43         -
        "ResourceNotFoundException" => crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::ResourceNotFoundException({
   44         -
            #[allow(unused_mut)]
   45         -
            let mut tmp = {
   46         -
                #[allow(unused_mut)]
   47         -
                let mut output = crate::types::error::builders::ResourceNotFoundExceptionBuilder::default();
   48         -
                output = crate::protocol_serde::shape_resource_not_found_exception::de_resource_not_found_exception_json_err(_response_body, output)
   49         -
                    .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
   50         -
                let output = output.meta(generic);
   51         -
                output.build()
   52         -
            };
   53         -
            if tmp.message.is_none() {
   54         -
                tmp.message = _error_message;
   55         -
            }
   56         -
            tmp
   57         -
        }),
   58         -
        "ServiceException" => crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::ServiceException({
   59         -
            #[allow(unused_mut)]
   60         -
            let mut tmp = {
   61         -
                #[allow(unused_mut)]
   62         -
                let mut output = crate::types::error::builders::ServiceExceptionBuilder::default();
   63         -
                output = crate::protocol_serde::shape_service_exception::de_service_exception_json_err(_response_body, output)
   64         -
                    .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
   65         -
                let output = output.meta(generic);
   66         -
                output.build()
   67         -
            };
   68         -
            if tmp.message.is_none() {
   69         -
                tmp.message = _error_message;
   70         -
            }
   71         -
            tmp
   72         -
        }),
   73         -
        "TooManyRequestsException" => crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::TooManyRequestsException({
   74         -
            #[allow(unused_mut)]
   75         -
            let mut tmp = {
   76         -
                #[allow(unused_mut)]
   77         -
                let mut output = crate::types::error::builders::TooManyRequestsExceptionBuilder::default();
   78         -
                output = crate::protocol_serde::shape_too_many_requests_exception::de_too_many_requests_exception_json_err(_response_body, output)
   79         -
                    .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
   80         -
                output = output.set_retry_after_seconds(
   81         -
                    crate::protocol_serde::shape_too_many_requests_exception::de_retry_after_seconds_header(_response_headers).map_err(|_| {
   82         -
                        crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled(
   83         -
                            "Failed to parse retryAfterSeconds from header `Retry-After",
   84         -
                        )
   85         -
                    })?,
   86         -
                );
   87         -
                let output = output.meta(generic);
   88         -
                output.build()
   89         -
            };
   90         -
            if tmp.message.is_none() {
   91         -
                tmp.message = _error_message;
   92         -
            }
   93         -
            tmp
   94         -
        }),
   95         -
        _ => crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::generic(generic),
   96         -
    })
   97         -
}
   98         -
   99         -
#[allow(clippy::unnecessary_wraps)]
  100         -
pub fn de_get_runtime_management_config_http_response(
  101         -
    _response_status: u16,
  102         -
    _response_headers: &::aws_smithy_runtime_api::http::Headers,
  103         -
    _response_body: &[u8],
  104         -
) -> std::result::Result<
  105         -
    crate::operation::get_runtime_management_config::GetRuntimeManagementConfigOutput,
  106         -
    crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError,
  107         -
> {
  108         -
    Ok({
  109         -
        #[allow(unused_mut)]
  110         -
        let mut output = crate::operation::get_runtime_management_config::builders::GetRuntimeManagementConfigOutputBuilder::default();
  111         -
        output = crate::protocol_serde::shape_get_runtime_management_config::de_get_runtime_management_config(_response_body, output)
  112         -
            .map_err(crate::operation::get_runtime_management_config::GetRuntimeManagementConfigError::unhandled)?;
  113         -
        output._set_request_id(::aws_types::request_id::RequestId::request_id(_response_headers).map(str::to_string));
  114         -
        output.build()
  115         -
    })
  116         -
}
  117         -
  118         -
pub(crate) fn de_get_runtime_management_config(
  119         -
    _value: &[u8],
  120         -
    mut builder: crate::operation::get_runtime_management_config::builders::GetRuntimeManagementConfigOutputBuilder,
  121         -
) -> ::std::result::Result<
  122         -
    crate::operation::get_runtime_management_config::builders::GetRuntimeManagementConfigOutputBuilder,
  123         -
    ::aws_smithy_json::deserialize::error::DeserializeError,
  124         -
> {
  125         -
    let mut tokens_owned = ::aws_smithy_json::deserialize::json_token_iter(crate::protocol_serde::or_empty_doc(_value)).peekable();
  126         -
    let tokens = &mut tokens_owned;
  127         -
    ::aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
  128         -
    loop {
  129         -
        match tokens.next().transpose()? {
  130         -
            Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
  131         -
            Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
  132         -
                "FunctionArn" => {
  133         -
                    builder = builder.set_function_arn(
  134         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  135         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  136         -
                            .transpose()?,
  137         -
                    );
  138         -
                }
  139         -
                "RuntimeVersionArn" => {
  140         -
                    builder = builder.set_runtime_version_arn(
  141         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  142         -
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  143         -
                            .transpose()?,
  144         -
                    );
  145         -
                }
  146         -
                "UpdateRuntimeOn" => {
  147         -
                    builder = builder.set_update_runtime_on(
  148         -
                        ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
  149         -
                            .map(|s| s.to_unescaped().map(|u| crate::types::UpdateRuntimeOn::from(u.as_ref())))
  150         -
                            .transpose()?,
  151         -
                    );
  152         -
                }
  153         -
                _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
  154         -
            },
  155         -
            other => {
  156         -
                return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
  157         -
                    "expected object key or end object, found: {other:?}"
  158         -
                )))
  159         -
            }
  160         -
        }
  161         -
    }
  162         -
    if tokens.next().is_some() {
  163         -
        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
  164         -
            "found more JSON tokens after completing parsing",
  165         -
        ));
  166         -
    }
  167         -
    Ok(builder)
  168         -
}

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_headers_list.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_image_config.rs

@@ -1,0 +74,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub fn ser_image_config(
    3         -
    object: &mut ::aws_smithy_json::serialize::JsonObjectWriter,
    4         -
    input: &crate::types::ImageConfig,
    5         -
) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
    6         -
    if let Some(var_1) = &input.entry_point {
    7         -
        let mut array_2 = object.key("EntryPoint").start_array();
    8         -
        for item_3 in var_1 {
    9         -
            {
   10         -
                array_2.value().string(item_3.as_str());
   11         -
            }
   12         -
        }
   13         -
        array_2.finish();
   14         -
    }
   15         -
    if let Some(var_4) = &input.command {
   16         -
        let mut array_5 = object.key("Command").start_array();
   17         -
        for item_6 in var_4 {
   18         -
            {
   19         -
                array_5.value().string(item_6.as_str());
   20         -
            }
   21         -
        }
   22         -
        array_5.finish();
   23         -
    }
   24         -
    if let Some(var_7) = &input.working_directory {
   25         -
        object.key("WorkingDirectory").string(var_7.as_str());
   26         -
    }
   27         -
    Ok(())
   28         -
}
   29         -
   30         -
pub(crate) fn de_image_config<'a, I>(
   31         -
    tokens: &mut ::std::iter::Peekable<I>,
   32         -
    _value: &'a [u8],
   33         -
) -> ::std::result::Result<Option<crate::types::ImageConfig>, ::aws_smithy_json::deserialize::error::DeserializeError>
   34         -
where
   35         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
   36         -
{
   37         -
    match tokens.next().transpose()? {
   38         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   39         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   40         -
            #[allow(unused_mut)]
   41         -
            let mut builder = crate::types::builders::ImageConfigBuilder::default();
   42         -
            loop {
   43         -
                match tokens.next().transpose()? {
   44         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   45         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   46         -
                        "EntryPoint" => {
   47         -
                            builder = builder.set_entry_point(crate::protocol_serde::shape_string_list::de_string_list(tokens, _value)?);
   48         -
                        }
   49         -
                        "Command" => {
   50         -
                            builder = builder.set_command(crate::protocol_serde::shape_string_list::de_string_list(tokens, _value)?);
   51         -
                        }
   52         -
                        "WorkingDirectory" => {
   53         -
                            builder = builder.set_working_directory(
   54         -
                                ::aws_smithy_json::deserialize::token::expect_string_or_null(tokens.next())?
   55         -
                                    .map(|s| s.to_unescaped().map(|u| u.into_owned()))
   56         -
                                    .transpose()?,
   57         -
                            );
   58         -
                        }
   59         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   60         -
                    },
   61         -
                    other => {
   62         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   63         -
                            "expected object key or end object, found: {other:?}"
   64         -
                        )))
   65         -
                    }
   66         -
                }
   67         -
            }
   68         -
            Ok(Some(builder.build()))
   69         -
        }
   70         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   71         -
            "expected start object or null",
   72         -
        )),
   73         -
    }
   74         -
}

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_image_config_error.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_image_config_response.rs

@@ -1,0 +39,0 @@
    1         -
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2         -
pub(crate) fn de_image_config_response<'a, I>(
    3         -
    tokens: &mut ::std::iter::Peekable<I>,
    4         -
    _value: &'a [u8],
    5         -
) -> ::std::result::Result<Option<crate::types::ImageConfigResponse>, ::aws_smithy_json::deserialize::error::DeserializeError>
    6         -
where
    7         -
    I: Iterator<Item = Result<::aws_smithy_json::deserialize::Token<'a>, ::aws_smithy_json::deserialize::error::DeserializeError>>,
    8         -
{
    9         -
    match tokens.next().transpose()? {
   10         -
        Some(::aws_smithy_json::deserialize::Token::ValueNull { .. }) => Ok(None),
   11         -
        Some(::aws_smithy_json::deserialize::Token::StartObject { .. }) => {
   12         -
            #[allow(unused_mut)]
   13         -
            let mut builder = crate::types::builders::ImageConfigResponseBuilder::default();
   14         -
            loop {
   15         -
                match tokens.next().transpose()? {
   16         -
                    Some(::aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
   17         -
                    Some(::aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => match key.to_unescaped()?.as_ref() {
   18         -
                        "ImageConfig" => {
   19         -
                            builder = builder.set_image_config(crate::protocol_serde::shape_image_config::de_image_config(tokens, _value)?);
   20         -
                        }
   21         -
                        "Error" => {
   22         -
                            builder = builder.set_error(crate::protocol_serde::shape_image_config_error::de_image_config_error(tokens, _value)?);
   23         -
                        }
   24         -
                        _ => ::aws_smithy_json::deserialize::token::skip_value(tokens)?,
   25         -
                    },
   26         -
                    other => {
   27         -
                        return Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
   28         -
                            "expected object key or end object, found: {other:?}"
   29         -
                        )))
   30         -
                    }
   31         -
                }
   32         -
            }
   33         -
            Ok(Some(builder.build()))
   34         -
        }
   35         -
        _ => Err(::aws_smithy_json::deserialize::error::DeserializeError::custom(
   36         -
            "expected start object or null",
   37         -
        )),
   38         -
    }
   39         -
}

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_code_signature_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_parameter_value_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_request_content_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_runtime_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_security_group_id_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_subnet_id_exception.rs

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

tmp-codegen-diff/aws-sdk/sdk/lambda/src/protocol_serde/shape_invalid_zip_file_exception.rs

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