Server Test Python

Server Test Python

rev. d06a46cae0f385cdae37a9f8264db3469a090ab5

Files changed:

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_match.rs

@@ -1,1 +138,138 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_match_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::MatchInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::match_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_match::de_match(bytes.as_ref(), input)?;
   29     29   
        }
   30     30   
        input.build()?
   31     31   
    })
   32     32   
}
   33     33   
   34     34   
#[allow(clippy::unnecessary_wraps)]
   35     35   
pub fn ser_match_http_response(
   36     36   
    #[allow(unused_variables)] output: crate::output::MatchOutput,
   37     37   
) -> std::result::Result<
   38         -
    ::aws_smithy_http_server::response::Response,
   39         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          38  +
    ::aws_smithy_legacy_http_server::response::Response,
          39  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   40     40   
> {
   41     41   
    Ok({
   42     42   
        #[allow(unused_mut)]
   43     43   
        let mut builder = ::http::Response::builder();
   44         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          44  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   45     45   
            builder,
   46     46   
            ::http::header::CONTENT_TYPE,
   47     47   
            "application/x-amz-json-1.1",
   48     48   
        );
   49     49   
        let http_status: u16 = 200;
   50     50   
        builder = builder.status(http_status);
   51     51   
        let payload = "";
   52     52   
        let content_length = payload.len();
   53         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          53  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   54     54   
            builder,
   55     55   
            ::http::header::CONTENT_LENGTH,
   56     56   
            content_length,
   57     57   
        );
   58         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          58  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   59     59   
        builder.body(body)?
   60     60   
    })
   61     61   
}
   62     62   
   63     63   
#[allow(clippy::unnecessary_wraps)]
   64     64   
pub fn ser_match_http_error(
   65     65   
    error: &crate::error::MatchError,
   66     66   
) -> std::result::Result<
   67         -
    ::aws_smithy_http_server::response::Response,
   68         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          67  +
    ::aws_smithy_legacy_http_server::response::Response,
          68  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   69     69   
> {
   70     70   
    Ok({
   71     71   
        match error {
   72     72   
            crate::error::MatchError::ValidationException(output) => {
   73     73   
                let payload = crate::protocol_serde::shape_validation_exception::ser_validation_exception_error(output)?;
   74     74   
                #[allow(unused_mut)]
   75     75   
                let mut builder = ::http::Response::builder();
   76         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          76  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   77     77   
                    builder,
   78     78   
                    ::http::header::CONTENT_TYPE,
   79     79   
                    "application/x-amz-json-1.1",
   80     80   
                );
   81     81   
                let content_length = payload.len();
   82         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          82  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   83     83   
                    builder,
   84     84   
                    ::http::header::CONTENT_LENGTH,
   85     85   
                    content_length,
   86     86   
                );
   87     87   
                builder
   88     88   
                    .status(400)
   89         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          89  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   90     90   
            }
   91     91   
            crate::error::MatchError::InternalServerError(output) => {
   92     92   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   93     93   
                #[allow(unused_mut)]
   94     94   
                let mut builder = ::http::Response::builder();
   95         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          95  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   96     96   
                    builder,
   97     97   
                    ::http::header::CONTENT_TYPE,
   98     98   
                    "application/x-amz-json-1.1",
   99     99   
                );
  100    100   
                let content_length = payload.len();
  101         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
         101  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
  102    102   
                    builder,
  103    103   
                    ::http::header::CONTENT_LENGTH,
  104    104   
                    content_length,
  105    105   
                );
  106    106   
                builder
  107    107   
                    .status(500)
  108         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
         108  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
  109    109   
            }
  110    110   
        }
  111    111   
    })
  112    112   
}
  113    113   
  114    114   
pub(crate) fn de_match(
  115    115   
    value: &[u8],
  116    116   
    mut builder: crate::input::match_input_internal::Builder,
  117    117   
) -> ::std::result::Result<
  118    118   
    crate::input::match_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_option.rs

@@ -1,1 +120,120 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_option_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::OptionInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::option_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_option::de_option(bytes.as_ref(), input)?;
   29     29   
        }
   30     30   
        input.build()
   31     31   
    })
   32     32   
}
   33     33   
   34     34   
#[allow(clippy::unnecessary_wraps)]
   35     35   
pub fn ser_option_http_response(
   36     36   
    #[allow(unused_variables)] output: crate::output::OptionOutput,
   37     37   
) -> std::result::Result<
   38         -
    ::aws_smithy_http_server::response::Response,
   39         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          38  +
    ::aws_smithy_legacy_http_server::response::Response,
          39  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   40     40   
> {
   41     41   
    Ok({
   42     42   
        #[allow(unused_mut)]
   43     43   
        let mut builder = ::http::Response::builder();
   44         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          44  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   45     45   
            builder,
   46     46   
            ::http::header::CONTENT_TYPE,
   47     47   
            "application/x-amz-json-1.1",
   48     48   
        );
   49     49   
        let http_status: u16 = 200;
   50     50   
        builder = builder.status(http_status);
   51     51   
        let payload =
   52     52   
            crate::protocol_serde::shape_option_output::ser_option_output_output_output(&output)?;
   53     53   
        let content_length = payload.len();
   54         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          54  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   55     55   
            builder,
   56     56   
            ::http::header::CONTENT_LENGTH,
   57     57   
            content_length,
   58     58   
        );
   59         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          59  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   60     60   
        builder.body(body)?
   61     61   
    })
   62     62   
}
   63     63   
   64     64   
#[allow(clippy::unnecessary_wraps)]
   65     65   
pub fn ser_option_http_error(
   66     66   
    error: &crate::error::OptionError,
   67     67   
) -> std::result::Result<
   68         -
    ::aws_smithy_http_server::response::Response,
   69         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          68  +
    ::aws_smithy_legacy_http_server::response::Response,
          69  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   70     70   
> {
   71     71   
    Ok({
   72     72   
        match error {
   73     73   
            crate::error::OptionError::InternalServerError(output) => {
   74     74   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   75     75   
                #[allow(unused_mut)]
   76     76   
                let mut builder = ::http::Response::builder();
   77         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          77  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   78     78   
                    builder,
   79     79   
                    ::http::header::CONTENT_TYPE,
   80     80   
                    "application/x-amz-json-1.1",
   81     81   
                );
   82     82   
                let content_length = payload.len();
   83         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          83  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   84     84   
                    builder,
   85     85   
                    ::http::header::CONTENT_LENGTH,
   86     86   
                    content_length,
   87     87   
                );
   88     88   
                builder
   89     89   
                    .status(500)
   90         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          90  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   91     91   
            }
   92     92   
        }
   93     93   
    })
   94     94   
}
   95     95   
   96     96   
pub(crate) fn de_option(
   97     97   
    value: &[u8],
   98     98   
    mut builder: crate::input::option_input_internal::Builder,
   99     99   
) -> ::std::result::Result<
  100    100   
    crate::input::option_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_reserved_words_as_members.rs

@@ -1,1 +138,138 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_reserved_words_as_members_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::ReservedWordsAsMembersInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::reserved_words_as_members_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_reserved_words_as_members::de_reserved_words_as_members(bytes.as_ref(), input)?;
   29     29   
        }
   30     30   
        input.build()?
   31     31   
    })
   32     32   
}
   33     33   
   34     34   
#[allow(clippy::unnecessary_wraps)]
   35     35   
pub fn ser_reserved_words_as_members_http_response(
   36     36   
    #[allow(unused_variables)] output: crate::output::ReservedWordsAsMembersOutput,
   37     37   
) -> std::result::Result<
   38         -
    ::aws_smithy_http_server::response::Response,
   39         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          38  +
    ::aws_smithy_legacy_http_server::response::Response,
          39  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   40     40   
> {
   41     41   
    Ok({
   42     42   
        #[allow(unused_mut)]
   43     43   
        let mut builder = ::http::Response::builder();
   44         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          44  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   45     45   
            builder,
   46     46   
            ::http::header::CONTENT_TYPE,
   47     47   
            "application/x-amz-json-1.1",
   48     48   
        );
   49     49   
        let http_status: u16 = 200;
   50     50   
        builder = builder.status(http_status);
   51     51   
        let payload = "";
   52     52   
        let content_length = payload.len();
   53         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          53  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   54     54   
            builder,
   55     55   
            ::http::header::CONTENT_LENGTH,
   56     56   
            content_length,
   57     57   
        );
   58         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          58  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   59     59   
        builder.body(body)?
   60     60   
    })
   61     61   
}
   62     62   
   63     63   
#[allow(clippy::unnecessary_wraps)]
   64     64   
pub fn ser_reserved_words_as_members_http_error(
   65     65   
    error: &crate::error::ReservedWordsAsMembersError,
   66     66   
) -> std::result::Result<
   67         -
    ::aws_smithy_http_server::response::Response,
   68         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          67  +
    ::aws_smithy_legacy_http_server::response::Response,
          68  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   69     69   
> {
   70     70   
    Ok({
   71     71   
        match error {
   72     72   
            crate::error::ReservedWordsAsMembersError::ValidationException(output) => {
   73     73   
                let payload = crate::protocol_serde::shape_validation_exception::ser_validation_exception_error(output)?;
   74     74   
                #[allow(unused_mut)]
   75     75   
                let mut builder = ::http::Response::builder();
   76         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          76  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   77     77   
                    builder,
   78     78   
                    ::http::header::CONTENT_TYPE,
   79     79   
                    "application/x-amz-json-1.1",
   80     80   
                );
   81     81   
                let content_length = payload.len();
   82         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          82  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   83     83   
                    builder,
   84     84   
                    ::http::header::CONTENT_LENGTH,
   85     85   
                    content_length,
   86     86   
                );
   87     87   
                builder
   88     88   
                    .status(400)
   89         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          89  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   90     90   
            }
   91     91   
            crate::error::ReservedWordsAsMembersError::InternalServerError(output) => {
   92     92   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   93     93   
                #[allow(unused_mut)]
   94     94   
                let mut builder = ::http::Response::builder();
   95         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          95  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   96     96   
                    builder,
   97     97   
                    ::http::header::CONTENT_TYPE,
   98     98   
                    "application/x-amz-json-1.1",
   99     99   
                );
  100    100   
                let content_length = payload.len();
  101         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
         101  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
  102    102   
                    builder,
  103    103   
                    ::http::header::CONTENT_LENGTH,
  104    104   
                    content_length,
  105    105   
                );
  106    106   
                builder
  107    107   
                    .status(500)
  108         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
         108  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
  109    109   
            }
  110    110   
        }
  111    111   
    })
  112    112   
}
  113    113   
  114    114   
pub(crate) fn de_reserved_words_as_members(
  115    115   
    value: &[u8],
  116    116   
    mut builder: crate::input::reserved_words_as_members_input_internal::Builder,
  117    117   
) -> ::std::result::Result<
  118    118   
    crate::input::reserved_words_as_members_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_result.rs

@@ -1,1 +120,120 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_result_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::ResultInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::result_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_result::de_result(bytes.as_ref(), input)?;
   29     29   
        }
   30     30   
        input.build()
   31     31   
    })
   32     32   
}
   33     33   
   34     34   
#[allow(clippy::unnecessary_wraps)]
   35     35   
pub fn ser_result_http_response(
   36     36   
    #[allow(unused_variables)] output: crate::output::ResultOutput,
   37     37   
) -> std::result::Result<
   38         -
    ::aws_smithy_http_server::response::Response,
   39         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          38  +
    ::aws_smithy_legacy_http_server::response::Response,
          39  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   40     40   
> {
   41     41   
    Ok({
   42     42   
        #[allow(unused_mut)]
   43     43   
        let mut builder = ::http::Response::builder();
   44         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          44  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   45     45   
            builder,
   46     46   
            ::http::header::CONTENT_TYPE,
   47     47   
            "application/x-amz-json-1.1",
   48     48   
        );
   49     49   
        let http_status: u16 = 200;
   50     50   
        builder = builder.status(http_status);
   51     51   
        let payload =
   52     52   
            crate::protocol_serde::shape_result_output::ser_result_output_output_output(&output)?;
   53     53   
        let content_length = payload.len();
   54         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          54  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   55     55   
            builder,
   56     56   
            ::http::header::CONTENT_LENGTH,
   57     57   
            content_length,
   58     58   
        );
   59         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          59  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   60     60   
        builder.body(body)?
   61     61   
    })
   62     62   
}
   63     63   
   64     64   
#[allow(clippy::unnecessary_wraps)]
   65     65   
pub fn ser_result_http_error(
   66     66   
    error: &crate::error::ResultError,
   67     67   
) -> std::result::Result<
   68         -
    ::aws_smithy_http_server::response::Response,
   69         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          68  +
    ::aws_smithy_legacy_http_server::response::Response,
          69  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   70     70   
> {
   71     71   
    Ok({
   72     72   
        match error {
   73     73   
            crate::error::ResultError::InternalServerError(output) => {
   74     74   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   75     75   
                #[allow(unused_mut)]
   76     76   
                let mut builder = ::http::Response::builder();
   77         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          77  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   78     78   
                    builder,
   79     79   
                    ::http::header::CONTENT_TYPE,
   80     80   
                    "application/x-amz-json-1.1",
   81     81   
                );
   82     82   
                let content_length = payload.len();
   83         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          83  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   84     84   
                    builder,
   85     85   
                    ::http::header::CONTENT_LENGTH,
   86     86   
                    content_length,
   87     87   
                );
   88     88   
                builder
   89     89   
                    .status(500)
   90         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          90  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   91     91   
            }
   92     92   
        }
   93     93   
    })
   94     94   
}
   95     95   
   96     96   
pub(crate) fn de_result(
   97     97   
    value: &[u8],
   98     98   
    mut builder: crate::input::result_input_internal::Builder,
   99     99   
) -> ::std::result::Result<
  100    100   
    crate::input::result_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_rpc_echo.rs

@@ -1,1 +138,138 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_rpc_echo_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::RpcEchoInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::rpc_echo_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_rpc_echo::de_rpc_echo(bytes.as_ref(), input)?;
   29     29   
        }
   30     30   
        input.build()?
   31     31   
    })
   32     32   
}
   33     33   
   34     34   
#[allow(clippy::unnecessary_wraps)]
   35     35   
pub fn ser_rpc_echo_http_response(
   36     36   
    #[allow(unused_variables)] output: crate::output::RpcEchoOutput,
   37     37   
) -> std::result::Result<
   38         -
    ::aws_smithy_http_server::response::Response,
   39         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          38  +
    ::aws_smithy_legacy_http_server::response::Response,
          39  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   40     40   
> {
   41     41   
    Ok({
   42     42   
        #[allow(unused_mut)]
   43     43   
        let mut builder = ::http::Response::builder();
   44         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          44  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   45     45   
            builder,
   46     46   
            ::http::header::CONTENT_TYPE,
   47     47   
            "application/x-amz-json-1.1",
   48     48   
        );
   49     49   
        let http_status: u16 = 200;
   50     50   
        builder = builder.status(http_status);
   51     51   
        let payload = "";
   52     52   
        let content_length = payload.len();
   53         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          53  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   54     54   
            builder,
   55     55   
            ::http::header::CONTENT_LENGTH,
   56     56   
            content_length,
   57     57   
        );
   58         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          58  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   59     59   
        builder.body(body)?
   60     60   
    })
   61     61   
}
   62     62   
   63     63   
#[allow(clippy::unnecessary_wraps)]
   64     64   
pub fn ser_rpc_echo_http_error(
   65     65   
    error: &crate::error::RPCEchoError,
   66     66   
) -> std::result::Result<
   67         -
    ::aws_smithy_http_server::response::Response,
   68         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          67  +
    ::aws_smithy_legacy_http_server::response::Response,
          68  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   69     69   
> {
   70     70   
    Ok({
   71     71   
        match error {
   72     72   
            crate::error::RPCEchoError::ValidationException(output) => {
   73     73   
                let payload = crate::protocol_serde::shape_validation_exception::ser_validation_exception_error(output)?;
   74     74   
                #[allow(unused_mut)]
   75     75   
                let mut builder = ::http::Response::builder();
   76         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          76  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   77     77   
                    builder,
   78     78   
                    ::http::header::CONTENT_TYPE,
   79     79   
                    "application/x-amz-json-1.1",
   80     80   
                );
   81     81   
                let content_length = payload.len();
   82         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          82  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   83     83   
                    builder,
   84     84   
                    ::http::header::CONTENT_LENGTH,
   85     85   
                    content_length,
   86     86   
                );
   87     87   
                builder
   88     88   
                    .status(400)
   89         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          89  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   90     90   
            }
   91     91   
            crate::error::RPCEchoError::InternalServerError(output) => {
   92     92   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   93     93   
                #[allow(unused_mut)]
   94     94   
                let mut builder = ::http::Response::builder();
   95         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          95  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   96     96   
                    builder,
   97     97   
                    ::http::header::CONTENT_TYPE,
   98     98   
                    "application/x-amz-json-1.1",
   99     99   
                );
  100    100   
                let content_length = payload.len();
  101         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
         101  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
  102    102   
                    builder,
  103    103   
                    ::http::header::CONTENT_LENGTH,
  104    104   
                    content_length,
  105    105   
                );
  106    106   
                builder
  107    107   
                    .status(500)
  108         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
         108  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
  109    109   
            }
  110    110   
        }
  111    111   
    })
  112    112   
}
  113    113   
  114    114   
pub(crate) fn de_rpc_echo(
  115    115   
    value: &[u8],
  116    116   
    mut builder: crate::input::rpc_echo_input_internal::Builder,
  117    117   
) -> ::std::result::Result<
  118    118   
    crate::input::rpc_echo_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_structure_name_punning.rs

@@ -1,1 +122,122 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
#[allow(clippy::unnecessary_wraps)]
    3      3   
pub async fn de_structure_name_punning_http_request<B>(
    4      4   
    #[allow(unused_variables)] request: ::http::Request<B>,
    5      5   
) -> std::result::Result<
    6      6   
    crate::input::StructureNamePunningInput,
    7         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection,
           7  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection,
    8      8   
>
    9      9   
where
   10         -
    B: ::aws_smithy_http_server::body::HttpBody + Send,
          10  +
    B: ::aws_smithy_legacy_http_server::body::HttpBody + Send,
   11     11   
    B::Data: Send,
   12         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::RequestRejection:
   13         -
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
          12  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::RequestRejection:
          13  +
        From<<B as ::aws_smithy_legacy_http_server::body::HttpBody>::Error>,
   14     14   
{
   15     15   
    Ok({
   16     16   
        #[allow(unused_mut)]
   17     17   
        let mut input = crate::input::structure_name_punning_input_internal::Builder::default();
   18     18   
        #[allow(unused_variables)]
   19     19   
        let ::aws_smithy_runtime_api::http::RequestParts {
   20     20   
            uri, headers, body, ..
   21     21   
        } = ::aws_smithy_runtime_api::http::Request::try_from(request)?.into_parts();
   22     22   
        let bytes = ::hyper::body::to_bytes(body).await?;
   23     23   
        if !bytes.is_empty() {
   24         -
            ::aws_smithy_http_server::protocol::content_type_header_classifier_smithy(
          24  +
            ::aws_smithy_legacy_http_server::protocol::content_type_header_classifier_smithy(
   25     25   
                &headers,
   26     26   
                Some("application/x-amz-json-1.1"),
   27     27   
            )?;
   28     28   
            input = crate::protocol_serde::shape_structure_name_punning::de_structure_name_punning(
   29     29   
                bytes.as_ref(),
   30     30   
                input,
   31     31   
            )?;
   32     32   
        }
   33     33   
        input.build()
   34     34   
    })
   35     35   
}
   36     36   
   37     37   
#[allow(clippy::unnecessary_wraps)]
   38     38   
pub fn ser_structure_name_punning_http_response(
   39     39   
    #[allow(unused_variables)] output: crate::output::StructureNamePunningOutput,
   40     40   
) -> std::result::Result<
   41         -
    ::aws_smithy_http_server::response::Response,
   42         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          41  +
    ::aws_smithy_legacy_http_server::response::Response,
          42  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   43     43   
> {
   44     44   
    Ok({
   45     45   
        #[allow(unused_mut)]
   46     46   
        let mut builder = ::http::Response::builder();
   47         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          47  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   48     48   
            builder,
   49     49   
            ::http::header::CONTENT_TYPE,
   50     50   
            "application/x-amz-json-1.1",
   51     51   
        );
   52     52   
        let http_status: u16 = 200;
   53     53   
        builder = builder.status(http_status);
   54     54   
        let payload = "";
   55     55   
        let content_length = payload.len();
   56         -
        builder = ::aws_smithy_http::header::set_response_header_if_absent(
          56  +
        builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   57     57   
            builder,
   58     58   
            ::http::header::CONTENT_LENGTH,
   59     59   
            content_length,
   60     60   
        );
   61         -
        let body = ::aws_smithy_http_server::body::to_boxed(payload);
          61  +
        let body = ::aws_smithy_legacy_http_server::body::to_boxed(payload);
   62     62   
        builder.body(body)?
   63     63   
    })
   64     64   
}
   65     65   
   66     66   
#[allow(clippy::unnecessary_wraps)]
   67     67   
pub fn ser_structure_name_punning_http_error(
   68     68   
    error: &crate::error::StructureNamePunningError,
   69     69   
) -> std::result::Result<
   70         -
    ::aws_smithy_http_server::response::Response,
   71         -
    ::aws_smithy_http_server::protocol::aws_json::rejection::ResponseRejection,
          70  +
    ::aws_smithy_legacy_http_server::response::Response,
          71  +
    ::aws_smithy_legacy_http_server::protocol::aws_json::rejection::ResponseRejection,
   72     72   
> {
   73     73   
    Ok({
   74     74   
        match error {
   75     75   
            crate::error::StructureNamePunningError::InternalServerError(output) => {
   76     76   
                let payload = crate::protocol_serde::shape_internal_server_error::ser_internal_server_error_error(output)?;
   77     77   
                #[allow(unused_mut)]
   78     78   
                let mut builder = ::http::Response::builder();
   79         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          79  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   80     80   
                    builder,
   81     81   
                    ::http::header::CONTENT_TYPE,
   82     82   
                    "application/x-amz-json-1.1",
   83     83   
                );
   84     84   
                let content_length = payload.len();
   85         -
                builder = ::aws_smithy_http::header::set_response_header_if_absent(
          85  +
                builder = ::aws_smithy_legacy_http::header::set_response_header_if_absent(
   86     86   
                    builder,
   87     87   
                    ::http::header::CONTENT_LENGTH,
   88     88   
                    content_length,
   89     89   
                );
   90     90   
                builder
   91     91   
                    .status(500)
   92         -
                    .body(::aws_smithy_http_server::body::to_boxed(payload))?
          92  +
                    .body(::aws_smithy_legacy_http_server::body::to_boxed(payload))?
   93     93   
            }
   94     94   
        }
   95     95   
    })
   96     96   
}
   97     97   
   98     98   
pub(crate) fn de_structure_name_punning(
   99     99   
    value: &[u8],
  100    100   
    mut builder: crate::input::structure_name_punning_input_internal::Builder,
  101    101   
) -> ::std::result::Result<
  102    102   
    crate::input::structure_name_punning_input_internal::Builder,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/python_operation_adaptor.rs

@@ -1,1 +313,327 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Python handler for operation `RPCEcho`.
    3      3   
pub(crate) async fn rpc_echo(
    4      4   
    input: crate::input::RpcEchoInput,
    5         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
           5  +
    state: ::aws_smithy_legacy_http_server::Extension<
           6  +
        ::aws_smithy_http_server_python::context::PyContext,
           7  +
    >,
    6      8   
    handler: ::aws_smithy_http_server_python::PyHandler,
    7      9   
) -> std::result::Result<crate::output::RpcEchoOutput, crate::error::RPCEchoError> {
    8     10   
    // Async block used to run the handler and catch any Python error.
    9     11   
    let result = if handler.is_coroutine {
   10     12   
        ::tracing::trace!(name = "rpc_echo", "executing python handler coroutine");
   11     13   
        let result = ::pyo3::Python::with_gil(|py| {
   12     14   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
   13     15   
            let coroutine = if handler.args == 1 {
   14     16   
                pyhandler.call1((input,))?
   15     17   
            } else {
   16     18   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
   17     19   
            };
   18     20   
            ::pyo3_asyncio::tokio::into_future(coroutine)
   19     21   
        })?;
   20     22   
        result.await.and_then(|r| {
   21     23   
            ::pyo3::Python::with_gil(|py| r.extract::<crate::output::RpcEchoOutput>(py))
   22     24   
        })
   23     25   
    } else {
   24     26   
        ::tracing::trace!(name = "rpc_echo", "executing python handler function");
   25     27   
        ::pyo3::Python::with_gil(|py| {
   26     28   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
   27     29   
            let output = if handler.args == 1 {
   28     30   
                pyhandler.call1((input,))?
   29     31   
            } else {
   30     32   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
   31     33   
            };
   32     34   
            output.extract::<crate::output::RpcEchoOutput>()
   33     35   
        })
   34     36   
    };
   35     37   
    // Catch and record a Python traceback.
   36     38   
    result.map_err(|e| {
   37     39   
        let rich_py_err =
   38     40   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
   39     41   
                e.clone_ref(py)
   40     42   
            }));
   41     43   
        ::tracing::error!(error = ?rich_py_err, "handler error");
   42     44   
        e.into()
   43     45   
    })
   44     46   
}
   45     47   
   46     48   
/// Python handler for operation `Match`.
   47     49   
pub(crate) async fn r#match(
   48     50   
    input: crate::input::MatchInput,
   49         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
          51  +
    state: ::aws_smithy_legacy_http_server::Extension<
          52  +
        ::aws_smithy_http_server_python::context::PyContext,
          53  +
    >,
   50     54   
    handler: ::aws_smithy_http_server_python::PyHandler,
   51     55   
) -> std::result::Result<crate::output::MatchOutput, crate::error::MatchError> {
   52     56   
    // Async block used to run the handler and catch any Python error.
   53     57   
    let result = if handler.is_coroutine {
   54     58   
        ::tracing::trace!(name = "r#match", "executing python handler coroutine");
   55     59   
        let result = ::pyo3::Python::with_gil(|py| {
   56     60   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
   57     61   
            let coroutine = if handler.args == 1 {
   58     62   
                pyhandler.call1((input,))?
   59     63   
            } else {
   60     64   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
   61     65   
            };
   62     66   
            ::pyo3_asyncio::tokio::into_future(coroutine)
   63     67   
        })?;
   64     68   
        result.await.and_then(|r| {
   65     69   
            ::pyo3::Python::with_gil(|py| r.extract::<crate::output::MatchOutput>(py))
   66     70   
        })
   67     71   
    } else {
   68     72   
        ::tracing::trace!(name = "r#match", "executing python handler function");
   69     73   
        ::pyo3::Python::with_gil(|py| {
   70     74   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
   71     75   
            let output = if handler.args == 1 {
   72     76   
                pyhandler.call1((input,))?
   73     77   
            } else {
   74     78   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
   75     79   
            };
   76     80   
            output.extract::<crate::output::MatchOutput>()
   77     81   
        })
   78     82   
    };
   79     83   
    // Catch and record a Python traceback.
   80     84   
    result.map_err(|e| {
   81     85   
        let rich_py_err =
   82     86   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
   83     87   
                e.clone_ref(py)
   84     88   
            }));
   85     89   
        ::tracing::error!(error = ?rich_py_err, "handler error");
   86     90   
        e.into()
   87     91   
    })
   88     92   
}
   89     93   
   90     94   
/// Python handler for operation `Option`.
   91     95   
pub(crate) async fn option(
   92     96   
    input: crate::input::OptionInput,
   93         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
          97  +
    state: ::aws_smithy_legacy_http_server::Extension<
          98  +
        ::aws_smithy_http_server_python::context::PyContext,
          99  +
    >,
   94    100   
    handler: ::aws_smithy_http_server_python::PyHandler,
   95    101   
) -> std::result::Result<crate::output::OptionOutput, crate::error::OptionError> {
   96    102   
    // Async block used to run the handler and catch any Python error.
   97    103   
    let result = if handler.is_coroutine {
   98    104   
        ::tracing::trace!(name = "option", "executing python handler coroutine");
   99    105   
        let result = ::pyo3::Python::with_gil(|py| {
  100    106   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  101    107   
            let coroutine = if handler.args == 1 {
  102    108   
                pyhandler.call1((input,))?
  103    109   
            } else {
  104    110   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  105    111   
            };
  106    112   
            ::pyo3_asyncio::tokio::into_future(coroutine)
  107    113   
        })?;
  108    114   
        result.await.and_then(|r| {
  109    115   
            ::pyo3::Python::with_gil(|py| r.extract::<crate::output::OptionOutput>(py))
  110    116   
        })
  111    117   
    } else {
  112    118   
        ::tracing::trace!(name = "option", "executing python handler function");
  113    119   
        ::pyo3::Python::with_gil(|py| {
  114    120   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  115    121   
            let output = if handler.args == 1 {
  116    122   
                pyhandler.call1((input,))?
  117    123   
            } else {
  118    124   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  119    125   
            };
  120    126   
            output.extract::<crate::output::OptionOutput>()
  121    127   
        })
  122    128   
    };
  123    129   
    // Catch and record a Python traceback.
  124    130   
    result.map_err(|e| {
  125    131   
        let rich_py_err =
  126    132   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
  127    133   
                e.clone_ref(py)
  128    134   
            }));
  129    135   
        ::tracing::error!(error = ?rich_py_err, "handler error");
  130    136   
        e.into()
  131    137   
    })
  132    138   
}
  133    139   
  134    140   
/// Python handler for operation `Result`.
  135    141   
pub(crate) async fn result(
  136    142   
    input: crate::input::ResultInput,
  137         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
         143  +
    state: ::aws_smithy_legacy_http_server::Extension<
         144  +
        ::aws_smithy_http_server_python::context::PyContext,
         145  +
    >,
  138    146   
    handler: ::aws_smithy_http_server_python::PyHandler,
  139    147   
) -> std::result::Result<crate::output::ResultOutput, crate::error::ResultError> {
  140    148   
    // Async block used to run the handler and catch any Python error.
  141    149   
    let result = if handler.is_coroutine {
  142    150   
        ::tracing::trace!(name = "result", "executing python handler coroutine");
  143    151   
        let result = ::pyo3::Python::with_gil(|py| {
  144    152   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  145    153   
            let coroutine = if handler.args == 1 {
  146    154   
                pyhandler.call1((input,))?
  147    155   
            } else {
  148    156   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  149    157   
            };
  150    158   
            ::pyo3_asyncio::tokio::into_future(coroutine)
  151    159   
        })?;
  152    160   
        result.await.and_then(|r| {
  153    161   
            ::pyo3::Python::with_gil(|py| r.extract::<crate::output::ResultOutput>(py))
  154    162   
        })
  155    163   
    } else {
  156    164   
        ::tracing::trace!(name = "result", "executing python handler function");
  157    165   
        ::pyo3::Python::with_gil(|py| {
  158    166   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  159    167   
            let output = if handler.args == 1 {
  160    168   
                pyhandler.call1((input,))?
  161    169   
            } else {
  162    170   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  163    171   
            };
  164    172   
            output.extract::<crate::output::ResultOutput>()
  165    173   
        })
  166    174   
    };
  167    175   
    // Catch and record a Python traceback.
  168    176   
    result.map_err(|e| {
  169    177   
        let rich_py_err =
  170    178   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
  171    179   
                e.clone_ref(py)
  172    180   
            }));
  173    181   
        ::tracing::error!(error = ?rich_py_err, "handler error");
  174    182   
        e.into()
  175    183   
    })
  176    184   
}
  177    185   
  178    186   
/// Python handler for operation `ErrCollisions`.
  179    187   
pub(crate) async fn err_collisions(
  180    188   
    input: crate::input::ErrCollisionsInput,
  181         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
         189  +
    state: ::aws_smithy_legacy_http_server::Extension<
         190  +
        ::aws_smithy_http_server_python::context::PyContext,
         191  +
    >,
  182    192   
    handler: ::aws_smithy_http_server_python::PyHandler,
  183    193   
) -> std::result::Result<crate::output::ErrCollisionsOutput, crate::error::ErrCollisionsError> {
  184    194   
    // Async block used to run the handler and catch any Python error.
  185    195   
    let result = if handler.is_coroutine {
  186    196   
        ::tracing::trace!(
  187    197   
            name = "err_collisions",
  188    198   
            "executing python handler coroutine"
  189    199   
        );
  190    200   
        let result = ::pyo3::Python::with_gil(|py| {
  191    201   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  192    202   
            let coroutine = if handler.args == 1 {
  193    203   
                pyhandler.call1((input,))?
  194    204   
            } else {
  195    205   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  196    206   
            };
  197    207   
            ::pyo3_asyncio::tokio::into_future(coroutine)
  198    208   
        })?;
  199    209   
        result.await.and_then(|r| {
  200    210   
            ::pyo3::Python::with_gil(|py| r.extract::<crate::output::ErrCollisionsOutput>(py))
  201    211   
        })
  202    212   
    } else {
  203    213   
        ::tracing::trace!(name = "err_collisions", "executing python handler function");
  204    214   
        ::pyo3::Python::with_gil(|py| {
  205    215   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  206    216   
            let output = if handler.args == 1 {
  207    217   
                pyhandler.call1((input,))?
  208    218   
            } else {
  209    219   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  210    220   
            };
  211    221   
            output.extract::<crate::output::ErrCollisionsOutput>()
  212    222   
        })
  213    223   
    };
  214    224   
    // Catch and record a Python traceback.
  215    225   
    result.map_err(|e| {
  216    226   
        let rich_py_err =
  217    227   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
  218    228   
                e.clone_ref(py)
  219    229   
            }));
  220    230   
        ::tracing::error!(error = ?rich_py_err, "handler error");
  221    231   
        e.into()
  222    232   
    })
  223    233   
}
  224    234   
  225    235   
/// Python handler for operation `StructureNamePunning`.
  226    236   
pub(crate) async fn structure_name_punning(
  227    237   
    input: crate::input::StructureNamePunningInput,
  228         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
         238  +
    state: ::aws_smithy_legacy_http_server::Extension<
         239  +
        ::aws_smithy_http_server_python::context::PyContext,
         240  +
    >,
  229    241   
    handler: ::aws_smithy_http_server_python::PyHandler,
  230    242   
) -> std::result::Result<
  231    243   
    crate::output::StructureNamePunningOutput,
  232    244   
    crate::error::StructureNamePunningError,
  233    245   
> {
  234    246   
    // Async block used to run the handler and catch any Python error.
  235    247   
    let result = if handler.is_coroutine {
  236    248   
        ::tracing::trace!(
  237    249   
            name = "structure_name_punning",
  238    250   
            "executing python handler coroutine"
  239    251   
        );
  240    252   
        let result = ::pyo3::Python::with_gil(|py| {
  241    253   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  242    254   
            let coroutine = if handler.args == 1 {
  243    255   
                pyhandler.call1((input,))?
  244    256   
            } else {
  245    257   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  246    258   
            };
  247    259   
            ::pyo3_asyncio::tokio::into_future(coroutine)
  248    260   
        })?;
  249    261   
        result.await.and_then(|r| {
  250    262   
            ::pyo3::Python::with_gil(|py| {
  251    263   
                r.extract::<crate::output::StructureNamePunningOutput>(py)
  252    264   
            })
  253    265   
        })
  254    266   
    } else {
  255    267   
        ::tracing::trace!(
  256    268   
            name = "structure_name_punning",
  257    269   
            "executing python handler function"
  258    270   
        );
  259    271   
        ::pyo3::Python::with_gil(|py| {
  260    272   
            let pyhandler: &::pyo3::types::PyFunction = handler.extract(py)?;
  261    273   
            let output = if handler.args == 1 {
  262    274   
                pyhandler.call1((input,))?
  263    275   
            } else {
  264    276   
                pyhandler.call1((input, ::pyo3::ToPyObject::to_object(&state.0, py)))?
  265    277   
            };
  266    278   
            output.extract::<crate::output::StructureNamePunningOutput>()
  267    279   
        })
  268    280   
    };
  269    281   
    // Catch and record a Python traceback.
  270    282   
    result.map_err(|e| {
  271    283   
        let rich_py_err =
  272    284   
            ::aws_smithy_http_server_python::rich_py_err(::pyo3::Python::with_gil(|py| {
  273    285   
                e.clone_ref(py)
  274    286   
            }));
  275    287   
        ::tracing::error!(error = ?rich_py_err, "handler error");
  276    288   
        e.into()
  277    289   
    })
  278    290   
}
  279    291   
  280    292   
/// Python handler for operation `ReservedWordsAsMembers`.
  281    293   
pub(crate) async fn reserved_words_as_members(
  282    294   
    input: crate::input::ReservedWordsAsMembersInput,
  283         -
    state: ::aws_smithy_http_server::Extension<::aws_smithy_http_server_python::context::PyContext>,
         295  +
    state: ::aws_smithy_legacy_http_server::Extension<
         296  +
        ::aws_smithy_http_server_python::context::PyContext,
         297  +
    >,
  284    298   
    handler: ::aws_smithy_http_server_python::PyHandler,
  285    299   
) -> std::result::Result<
  286    300   
    crate::output::ReservedWordsAsMembersOutput,
  287    301   
    crate::error::ReservedWordsAsMembersError,
  288    302   
> {
  289    303   
    // Async block used to run the handler and catch any Python error.
  290    304   
    let result = if handler.is_coroutine {
  291    305   
        ::tracing::trace!(
  292    306   
            name = "reserved_words_as_members",
  293    307   
            "executing python handler coroutine"

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/python_server_application.rs

@@ -80,80 +141,141 @@
  100    100   
    fn handlers(
  101    101   
        &mut self,
  102    102   
    ) -> &mut ::std::collections::HashMap<String, ::aws_smithy_http_server_python::PyHandler> {
  103    103   
        &mut self.handlers
  104    104   
    }
  105    105   
    fn build_service(
  106    106   
        &mut self,
  107    107   
        event_loop: &::pyo3::PyAny,
  108    108   
    ) -> ::pyo3::PyResult<
  109    109   
        ::tower::util::BoxCloneService<
  110         -
            ::http::Request<::aws_smithy_http_server::body::Body>,
  111         -
            ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         110  +
            ::http::Request<::aws_smithy_legacy_http_server::body::Body>,
         111  +
            ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  112    112   
            std::convert::Infallible,
  113    113   
        >,
  114    114   
    > {
  115    115   
        let builder = crate::service::Config::builder_without_plugins();
  116    116   
        let err_collisions_locals = ::pyo3_asyncio::TaskLocals::new(event_loop);
  117    117   
        let handler = self
  118    118   
            .handlers
  119    119   
            .get("err_collisions")
  120    120   
            .expect("Python handler for operation `err_collisions` not found")
  121    121   
            .clone();
@@ -190,190 +250,250 @@
  210    210   
        {
  211    211   
            use ::tower::Layer;
  212    212   
            ::tracing::trace!("adding middlewares to rust python router");
  213    213   
            let mut middlewares = self.middlewares.clone();
  214    214   
            // Reverse the middlewares, so they run with same order as they defined
  215    215   
            middlewares.reverse();
  216    216   
            for handler in middlewares {
  217    217   
                ::tracing::trace!(name = &handler.name, "adding python middleware");
  218    218   
                let locals = ::pyo3_asyncio::TaskLocals::new(event_loop);
  219    219   
                let layer = ::aws_smithy_http_server_python::PyMiddlewareLayer::<
  220         -
                    ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
         220  +
                    ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
  221    221   
                >::new(handler, locals);
  222    222   
                service = ::tower::util::BoxCloneService::new(layer.layer(service));
  223    223   
            }
  224    224   
        }
  225    225   
        Ok(service)
  226    226   
    }
  227    227   
}
  228    228   
#[::pyo3::pymethods]
  229    229   
impl App {
  230    230   
    /// Create a new [App].

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/service.rs

@@ -1,1 +1731,1765 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// The service builder for [`Config`].
    3      3   
///
    4      4   
/// Constructed via [`Config::builder`].
    5      5   
pub struct ConfigBuilder<Body, L, HttpPl, ModelPl> {
    6         -
    err_collisions: Option<::aws_smithy_http_server::routing::Route<Body>>,
    7         -
    r#match: Option<::aws_smithy_http_server::routing::Route<Body>>,
    8         -
    option: Option<::aws_smithy_http_server::routing::Route<Body>>,
    9         -
    reserved_words_as_members: Option<::aws_smithy_http_server::routing::Route<Body>>,
   10         -
    result: Option<::aws_smithy_http_server::routing::Route<Body>>,
   11         -
    rpc_echo: Option<::aws_smithy_http_server::routing::Route<Body>>,
   12         -
    structure_name_punning: Option<::aws_smithy_http_server::routing::Route<Body>>,
           6  +
    err_collisions: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
           7  +
    r#match: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
           8  +
    option: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
           9  +
    reserved_words_as_members: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
          10  +
    result: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
          11  +
    rpc_echo: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
          12  +
    structure_name_punning: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
   13     13   
    layer: L,
   14     14   
    http_plugin: HttpPl,
   15     15   
    model_plugin: ModelPl,
   16     16   
}
   17     17   
   18     18   
impl<Body, L, HttpPl, ModelPl> ConfigBuilder<Body, L, HttpPl, ModelPl> {
   19     19   
    /// Sets the [`ErrCollisions`](crate::operation_shape::ErrCollisions) operation.
   20     20   
    ///
   21         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
   22         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
          21  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
          22  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
   23     23   
    ///
   24     24   
    /// # Example
   25     25   
    ///
   26     26   
    /// ```no_run
   27     27   
    /// use naming_test_ops::{Config, ConfigConfig};
   28     28   
    ///
   29     29   
    /// use naming_test_ops::{input, output, error};
   30     30   
    ///
   31     31   
    /// async fn handler(input: input::ErrCollisionsInput) -> Result<output::ErrCollisionsOutput, error::ErrCollisionsError> {
   32     32   
    ///     todo!()
   33     33   
    /// }
   34     34   
    ///
   35     35   
    /// let config = ConfigConfig::builder().build();
   36     36   
    /// let app = Config::builder(config)
   37     37   
    ///     .err_collisions(handler)
   38     38   
    ///     /* Set other handlers */
   39     39   
    ///     .build()
   40     40   
    ///     .unwrap();
   41         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
          41  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
   42     42   
    /// ```
   43     43   
    ///
   44     44   
                    pub fn err_collisions<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
   45     45   
                    where
   46         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ErrCollisions, HandlerExtractors>,
          46  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ErrCollisions, HandlerExtractors>,
   47     47   
   48         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
          48  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
   49     49   
                            Config<L>,
   50     50   
                            crate::operation_shape::ErrCollisions,
   51         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ErrCollisions, HandlerType>
          51  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ErrCollisions, HandlerType>
   52     52   
                        >,
   53         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
          53  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
   54     54   
                            Config<L>,
   55     55   
                            crate::operation_shape::ErrCollisions,
   56     56   
                            ModelPl::Output
   57     57   
                        >,
   58         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
          58  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
   59     59   
                            Config<L>,
   60     60   
                            crate::operation_shape::ErrCollisions,
   61     61   
                            <
   62         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
   63         -
                                as ::aws_smithy_http_server::plugin::Plugin<
          62  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
          63  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
   64     64   
                                    Config<L>,
   65     65   
                                    crate::operation_shape::ErrCollisions,
   66     66   
                                    ModelPl::Output
   67     67   
                                >
   68     68   
                            >::Output
   69     69   
                        >,
   70     70   
   71         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
          71  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
   72     72   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
   73     73   
   74     74   
                    {
   75         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
   76         -
        use ::aws_smithy_http_server::plugin::Plugin;
          75  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
          76  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
   77     77   
        let svc = crate::operation_shape::ErrCollisions::from_handler(handler);
   78     78   
        let svc = self.model_plugin.apply(svc);
   79         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
   80         -
            .apply(svc);
          79  +
        let svc =
          80  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
          81  +
                .apply(svc);
   81     82   
        let svc = self.http_plugin.apply(svc);
   82     83   
        self.err_collisions_custom(svc)
   83     84   
    }
   84     85   
   85     86   
    /// Sets the [`ErrCollisions`](crate::operation_shape::ErrCollisions) operation.
   86     87   
    ///
   87         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
   88         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
          88  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
          89  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
   89     90   
    ///
   90     91   
    /// # Example
   91     92   
    ///
   92     93   
    /// ```no_run
   93     94   
    /// use naming_test_ops::{Config, ConfigConfig};
   94     95   
    ///
   95     96   
    /// use naming_test_ops::{input, output, error};
   96     97   
    ///
   97     98   
    /// async fn handler(input: input::ErrCollisionsInput) -> Result<output::ErrCollisionsOutput, error::ErrCollisionsError> {
   98     99   
    ///     todo!()
   99    100   
    /// }
  100    101   
    ///
  101    102   
    /// let config = ConfigConfig::builder().build();
  102    103   
    /// let svc = ::tower::util::service_fn(handler);
  103    104   
    /// let app = Config::builder(config)
  104    105   
    ///     .err_collisions_service(svc)
  105    106   
    ///     /* Set other handlers */
  106    107   
    ///     .build()
  107    108   
    ///     .unwrap();
  108         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         109  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  109    110   
    /// ```
  110    111   
    ///
  111    112   
                    pub fn err_collisions_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  112    113   
                    where
  113         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ErrCollisions, ServiceExtractors>,
         114  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ErrCollisions, ServiceExtractors>,
  114    115   
  115         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         116  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  116    117   
                            Config<L>,
  117    118   
                            crate::operation_shape::ErrCollisions,
  118         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ErrCollisions, S>
         119  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ErrCollisions, S>
  119    120   
                        >,
  120         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         121  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  121    122   
                            Config<L>,
  122    123   
                            crate::operation_shape::ErrCollisions,
  123    124   
                            ModelPl::Output
  124    125   
                        >,
  125         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         126  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  126    127   
                            Config<L>,
  127    128   
                            crate::operation_shape::ErrCollisions,
  128    129   
                            <
  129         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  130         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         130  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         131  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  131    132   
                                    Config<L>,
  132    133   
                                    crate::operation_shape::ErrCollisions,
  133    134   
                                    ModelPl::Output
  134    135   
                                >
  135    136   
                            >::Output
  136    137   
                        >,
  137    138   
  138         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         139  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  139    140   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  140    141   
  141    142   
                    {
  142         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  143         -
        use ::aws_smithy_http_server::plugin::Plugin;
         143  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         144  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  144    145   
        let svc = crate::operation_shape::ErrCollisions::from_service(service);
  145    146   
        let svc = self.model_plugin.apply(svc);
  146         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  147         -
            .apply(svc);
         147  +
        let svc =
         148  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         149  +
                .apply(svc);
  148    150   
        let svc = self.http_plugin.apply(svc);
  149    151   
        self.err_collisions_custom(svc)
  150    152   
    }
  151    153   
  152    154   
    /// Sets the [`ErrCollisions`](crate::operation_shape::ErrCollisions) to a custom [`Service`](tower::Service).
  153    155   
    /// not constrained by the Smithy contract.
  154    156   
    fn err_collisions_custom<S>(mut self, svc: S) -> Self
  155    157   
    where
  156    158   
        S: ::tower::Service<
  157    159   
                ::http::Request<Body>,
  158         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         160  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  159    161   
                Error = ::std::convert::Infallible,
  160    162   
            > + Clone
  161    163   
            + Send
  162    164   
            + 'static,
  163    165   
        S::Future: Send + 'static,
  164    166   
    {
  165         -
        self.err_collisions = Some(::aws_smithy_http_server::routing::Route::new(svc));
         167  +
        self.err_collisions = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  166    168   
        self
  167    169   
    }
  168    170   
  169    171   
    /// Sets the [`Match`](crate::operation_shape::Match) operation.
  170    172   
    ///
  171         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  172         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         173  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         174  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  173    175   
    ///
  174    176   
    /// # Example
  175    177   
    ///
  176    178   
    /// ```no_run
  177    179   
    /// use naming_test_ops::{Config, ConfigConfig};
  178    180   
    ///
  179    181   
    /// use naming_test_ops::{input, output, error};
  180    182   
    ///
  181    183   
    /// async fn handler(input: input::MatchInput) -> Result<output::MatchOutput, error::MatchError> {
  182    184   
    ///     todo!()
  183    185   
    /// }
  184    186   
    ///
  185    187   
    /// let config = ConfigConfig::builder().build();
  186    188   
    /// let app = Config::builder(config)
  187    189   
    ///     .r#match(handler)
  188    190   
    ///     /* Set other handlers */
  189    191   
    ///     .build()
  190    192   
    ///     .unwrap();
  191         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         193  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  192    194   
    /// ```
  193    195   
    ///
  194    196   
                    pub fn r#match<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  195    197   
                    where
  196         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::Match, HandlerExtractors>,
         198  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::Match, HandlerExtractors>,
  197    199   
  198         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         200  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  199    201   
                            Config<L>,
  200    202   
                            crate::operation_shape::Match,
  201         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::Match, HandlerType>
         203  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::Match, HandlerType>
  202    204   
                        >,
  203         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         205  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  204    206   
                            Config<L>,
  205    207   
                            crate::operation_shape::Match,
  206    208   
                            ModelPl::Output
  207    209   
                        >,
  208         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         210  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  209    211   
                            Config<L>,
  210    212   
                            crate::operation_shape::Match,
  211    213   
                            <
  212         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  213         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         214  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         215  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  214    216   
                                    Config<L>,
  215    217   
                                    crate::operation_shape::Match,
  216    218   
                                    ModelPl::Output
  217    219   
                                >
  218    220   
                            >::Output
  219    221   
                        >,
  220    222   
  221         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         223  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  222    224   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  223    225   
  224    226   
                    {
  225         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  226         -
        use ::aws_smithy_http_server::plugin::Plugin;
         227  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         228  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  227    229   
        let svc = crate::operation_shape::Match::from_handler(handler);
  228    230   
        let svc = self.model_plugin.apply(svc);
  229         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  230         -
            .apply(svc);
         231  +
        let svc =
         232  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         233  +
                .apply(svc);
  231    234   
        let svc = self.http_plugin.apply(svc);
  232    235   
        self.r#match_custom(svc)
  233    236   
    }
  234    237   
  235    238   
    /// Sets the [`Match`](crate::operation_shape::Match) operation.
  236    239   
    ///
  237         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  238         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         240  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         241  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  239    242   
    ///
  240    243   
    /// # Example
  241    244   
    ///
  242    245   
    /// ```no_run
  243    246   
    /// use naming_test_ops::{Config, ConfigConfig};
  244    247   
    ///
  245    248   
    /// use naming_test_ops::{input, output, error};
  246    249   
    ///
  247    250   
    /// async fn handler(input: input::MatchInput) -> Result<output::MatchOutput, error::MatchError> {
  248    251   
    ///     todo!()
  249    252   
    /// }
  250    253   
    ///
  251    254   
    /// let config = ConfigConfig::builder().build();
  252    255   
    /// let svc = ::tower::util::service_fn(handler);
  253    256   
    /// let app = Config::builder(config)
  254    257   
    ///     .r#match_service(svc)
  255    258   
    ///     /* Set other handlers */
  256    259   
    ///     .build()
  257    260   
    ///     .unwrap();
  258         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         261  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  259    262   
    /// ```
  260    263   
    ///
  261    264   
                    pub fn r#match_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  262    265   
                    where
  263         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::Match, ServiceExtractors>,
         266  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::Match, ServiceExtractors>,
  264    267   
  265         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         268  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  266    269   
                            Config<L>,
  267    270   
                            crate::operation_shape::Match,
  268         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::Match, S>
         271  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::Match, S>
  269    272   
                        >,
  270         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         273  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  271    274   
                            Config<L>,
  272    275   
                            crate::operation_shape::Match,
  273    276   
                            ModelPl::Output
  274    277   
                        >,
  275         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         278  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  276    279   
                            Config<L>,
  277    280   
                            crate::operation_shape::Match,
  278    281   
                            <
  279         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  280         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         282  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         283  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  281    284   
                                    Config<L>,
  282    285   
                                    crate::operation_shape::Match,
  283    286   
                                    ModelPl::Output
  284    287   
                                >
  285    288   
                            >::Output
  286    289   
                        >,
  287    290   
  288         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         291  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  289    292   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  290    293   
  291    294   
                    {
  292         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  293         -
        use ::aws_smithy_http_server::plugin::Plugin;
         295  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         296  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  294    297   
        let svc = crate::operation_shape::Match::from_service(service);
  295    298   
        let svc = self.model_plugin.apply(svc);
  296         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  297         -
            .apply(svc);
         299  +
        let svc =
         300  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         301  +
                .apply(svc);
  298    302   
        let svc = self.http_plugin.apply(svc);
  299    303   
        self.r#match_custom(svc)
  300    304   
    }
  301    305   
  302    306   
    /// Sets the [`Match`](crate::operation_shape::Match) to a custom [`Service`](tower::Service).
  303    307   
    /// not constrained by the Smithy contract.
  304    308   
    fn r#match_custom<S>(mut self, svc: S) -> Self
  305    309   
    where
  306    310   
        S: ::tower::Service<
  307    311   
                ::http::Request<Body>,
  308         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         312  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  309    313   
                Error = ::std::convert::Infallible,
  310    314   
            > + Clone
  311    315   
            + Send
  312    316   
            + 'static,
  313    317   
        S::Future: Send + 'static,
  314    318   
    {
  315         -
        self.r#match = Some(::aws_smithy_http_server::routing::Route::new(svc));
         319  +
        self.r#match = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  316    320   
        self
  317    321   
    }
  318    322   
  319    323   
    /// Sets the [`Option`](crate::operation_shape::Option) operation.
  320    324   
    ///
  321         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  322         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         325  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         326  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  323    327   
    ///
  324    328   
    /// # Example
  325    329   
    ///
  326    330   
    /// ```no_run
  327    331   
    /// use naming_test_ops::{Config, ConfigConfig};
  328    332   
    ///
  329    333   
    /// use naming_test_ops::{input, output, error};
  330    334   
    ///
  331    335   
    /// async fn handler(input: input::OptionInput) -> Result<output::OptionOutput, error::OptionError> {
  332    336   
    ///     todo!()
  333    337   
    /// }
  334    338   
    ///
  335    339   
    /// let config = ConfigConfig::builder().build();
  336    340   
    /// let app = Config::builder(config)
  337    341   
    ///     .option(handler)
  338    342   
    ///     /* Set other handlers */
  339    343   
    ///     .build()
  340    344   
    ///     .unwrap();
  341         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         345  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  342    346   
    /// ```
  343    347   
    ///
  344    348   
                    pub fn option<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  345    349   
                    where
  346         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::Option, HandlerExtractors>,
         350  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::Option, HandlerExtractors>,
  347    351   
  348         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         352  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  349    353   
                            Config<L>,
  350    354   
                            crate::operation_shape::Option,
  351         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::Option, HandlerType>
         355  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::Option, HandlerType>
  352    356   
                        >,
  353         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         357  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  354    358   
                            Config<L>,
  355    359   
                            crate::operation_shape::Option,
  356    360   
                            ModelPl::Output
  357    361   
                        >,
  358         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         362  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  359    363   
                            Config<L>,
  360    364   
                            crate::operation_shape::Option,
  361    365   
                            <
  362         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  363         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         366  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         367  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  364    368   
                                    Config<L>,
  365    369   
                                    crate::operation_shape::Option,
  366    370   
                                    ModelPl::Output
  367    371   
                                >
  368    372   
                            >::Output
  369    373   
                        >,
  370    374   
  371         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         375  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  372    376   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  373    377   
  374    378   
                    {
  375         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  376         -
        use ::aws_smithy_http_server::plugin::Plugin;
         379  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         380  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  377    381   
        let svc = crate::operation_shape::Option::from_handler(handler);
  378    382   
        let svc = self.model_plugin.apply(svc);
  379         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  380         -
            .apply(svc);
         383  +
        let svc =
         384  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         385  +
                .apply(svc);
  381    386   
        let svc = self.http_plugin.apply(svc);
  382    387   
        self.option_custom(svc)
  383    388   
    }
  384    389   
  385    390   
    /// Sets the [`Option`](crate::operation_shape::Option) operation.
  386    391   
    ///
  387         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  388         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         392  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         393  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  389    394   
    ///
  390    395   
    /// # Example
  391    396   
    ///
  392    397   
    /// ```no_run
  393    398   
    /// use naming_test_ops::{Config, ConfigConfig};
  394    399   
    ///
  395    400   
    /// use naming_test_ops::{input, output, error};
  396    401   
    ///
  397    402   
    /// async fn handler(input: input::OptionInput) -> Result<output::OptionOutput, error::OptionError> {
  398    403   
    ///     todo!()
  399    404   
    /// }
  400    405   
    ///
  401    406   
    /// let config = ConfigConfig::builder().build();
  402    407   
    /// let svc = ::tower::util::service_fn(handler);
  403    408   
    /// let app = Config::builder(config)
  404    409   
    ///     .option_service(svc)
  405    410   
    ///     /* Set other handlers */
  406    411   
    ///     .build()
  407    412   
    ///     .unwrap();
  408         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         413  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  409    414   
    /// ```
  410    415   
    ///
  411    416   
                    pub fn option_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  412    417   
                    where
  413         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::Option, ServiceExtractors>,
         418  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::Option, ServiceExtractors>,
  414    419   
  415         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         420  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  416    421   
                            Config<L>,
  417    422   
                            crate::operation_shape::Option,
  418         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::Option, S>
         423  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::Option, S>
  419    424   
                        >,
  420         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         425  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  421    426   
                            Config<L>,
  422    427   
                            crate::operation_shape::Option,
  423    428   
                            ModelPl::Output
  424    429   
                        >,
  425         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         430  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  426    431   
                            Config<L>,
  427    432   
                            crate::operation_shape::Option,
  428    433   
                            <
  429         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  430         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         434  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         435  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  431    436   
                                    Config<L>,
  432    437   
                                    crate::operation_shape::Option,
  433    438   
                                    ModelPl::Output
  434    439   
                                >
  435    440   
                            >::Output
  436    441   
                        >,
  437    442   
  438         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         443  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  439    444   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  440    445   
  441    446   
                    {
  442         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  443         -
        use ::aws_smithy_http_server::plugin::Plugin;
         447  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         448  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  444    449   
        let svc = crate::operation_shape::Option::from_service(service);
  445    450   
        let svc = self.model_plugin.apply(svc);
  446         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  447         -
            .apply(svc);
         451  +
        let svc =
         452  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         453  +
                .apply(svc);
  448    454   
        let svc = self.http_plugin.apply(svc);
  449    455   
        self.option_custom(svc)
  450    456   
    }
  451    457   
  452    458   
    /// Sets the [`Option`](crate::operation_shape::Option) to a custom [`Service`](tower::Service).
  453    459   
    /// not constrained by the Smithy contract.
  454    460   
    fn option_custom<S>(mut self, svc: S) -> Self
  455    461   
    where
  456    462   
        S: ::tower::Service<
  457    463   
                ::http::Request<Body>,
  458         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         464  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  459    465   
                Error = ::std::convert::Infallible,
  460    466   
            > + Clone
  461    467   
            + Send
  462    468   
            + 'static,
  463    469   
        S::Future: Send + 'static,
  464    470   
    {
  465         -
        self.option = Some(::aws_smithy_http_server::routing::Route::new(svc));
         471  +
        self.option = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  466    472   
        self
  467    473   
    }
  468    474   
  469    475   
    /// Sets the [`ReservedWordsAsMembers`](crate::operation_shape::ReservedWordsAsMembers) operation.
  470    476   
    ///
  471         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  472         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         477  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         478  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  473    479   
    ///
  474    480   
    /// # Example
  475    481   
    ///
  476    482   
    /// ```no_run
  477    483   
    /// use naming_test_ops::{Config, ConfigConfig};
  478    484   
    ///
  479    485   
    /// use naming_test_ops::{input, output, error};
  480    486   
    ///
  481    487   
    /// async fn handler(input: input::ReservedWordsAsMembersInput) -> Result<output::ReservedWordsAsMembersOutput, error::ReservedWordsAsMembersError> {
  482    488   
    ///     todo!()
  483    489   
    /// }
  484    490   
    ///
  485    491   
    /// let config = ConfigConfig::builder().build();
  486    492   
    /// let app = Config::builder(config)
  487    493   
    ///     .reserved_words_as_members(handler)
  488    494   
    ///     /* Set other handlers */
  489    495   
    ///     .build()
  490    496   
    ///     .unwrap();
  491         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         497  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  492    498   
    /// ```
  493    499   
    ///
  494    500   
                    pub fn reserved_words_as_members<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  495    501   
                    where
  496         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ReservedWordsAsMembers, HandlerExtractors>,
         502  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ReservedWordsAsMembers, HandlerExtractors>,
  497    503   
  498         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         504  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  499    505   
                            Config<L>,
  500    506   
                            crate::operation_shape::ReservedWordsAsMembers,
  501         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ReservedWordsAsMembers, HandlerType>
         507  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ReservedWordsAsMembers, HandlerType>
  502    508   
                        >,
  503         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         509  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  504    510   
                            Config<L>,
  505    511   
                            crate::operation_shape::ReservedWordsAsMembers,
  506    512   
                            ModelPl::Output
  507    513   
                        >,
  508         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         514  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  509    515   
                            Config<L>,
  510    516   
                            crate::operation_shape::ReservedWordsAsMembers,
  511    517   
                            <
  512         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  513         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         518  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         519  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  514    520   
                                    Config<L>,
  515    521   
                                    crate::operation_shape::ReservedWordsAsMembers,
  516    522   
                                    ModelPl::Output
  517    523   
                                >
  518    524   
                            >::Output
  519    525   
                        >,
  520    526   
  521         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         527  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  522    528   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  523    529   
  524    530   
                    {
  525         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  526         -
        use ::aws_smithy_http_server::plugin::Plugin;
         531  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         532  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  527    533   
        let svc = crate::operation_shape::ReservedWordsAsMembers::from_handler(handler);
  528    534   
        let svc = self.model_plugin.apply(svc);
  529         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  530         -
            .apply(svc);
         535  +
        let svc =
         536  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         537  +
                .apply(svc);
  531    538   
        let svc = self.http_plugin.apply(svc);
  532    539   
        self.reserved_words_as_members_custom(svc)
  533    540   
    }
  534    541   
  535    542   
    /// Sets the [`ReservedWordsAsMembers`](crate::operation_shape::ReservedWordsAsMembers) operation.
  536    543   
    ///
  537         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  538         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         544  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         545  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  539    546   
    ///
  540    547   
    /// # Example
  541    548   
    ///
  542    549   
    /// ```no_run
  543    550   
    /// use naming_test_ops::{Config, ConfigConfig};
  544    551   
    ///
  545    552   
    /// use naming_test_ops::{input, output, error};
  546    553   
    ///
  547    554   
    /// async fn handler(input: input::ReservedWordsAsMembersInput) -> Result<output::ReservedWordsAsMembersOutput, error::ReservedWordsAsMembersError> {
  548    555   
    ///     todo!()
  549    556   
    /// }
  550    557   
    ///
  551    558   
    /// let config = ConfigConfig::builder().build();
  552    559   
    /// let svc = ::tower::util::service_fn(handler);
  553    560   
    /// let app = Config::builder(config)
  554    561   
    ///     .reserved_words_as_members_service(svc)
  555    562   
    ///     /* Set other handlers */
  556    563   
    ///     .build()
  557    564   
    ///     .unwrap();
  558         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         565  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  559    566   
    /// ```
  560    567   
    ///
  561    568   
                    pub fn reserved_words_as_members_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  562    569   
                    where
  563         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ReservedWordsAsMembers, ServiceExtractors>,
         570  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ReservedWordsAsMembers, ServiceExtractors>,
  564    571   
  565         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         572  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  566    573   
                            Config<L>,
  567    574   
                            crate::operation_shape::ReservedWordsAsMembers,
  568         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ReservedWordsAsMembers, S>
         575  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ReservedWordsAsMembers, S>
  569    576   
                        >,
  570         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         577  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  571    578   
                            Config<L>,
  572    579   
                            crate::operation_shape::ReservedWordsAsMembers,
  573    580   
                            ModelPl::Output
  574    581   
                        >,
  575         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         582  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  576    583   
                            Config<L>,
  577    584   
                            crate::operation_shape::ReservedWordsAsMembers,
  578    585   
                            <
  579         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  580         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         586  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         587  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  581    588   
                                    Config<L>,
  582    589   
                                    crate::operation_shape::ReservedWordsAsMembers,
  583    590   
                                    ModelPl::Output
  584    591   
                                >
  585    592   
                            >::Output
  586    593   
                        >,
  587    594   
  588         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         595  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  589    596   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  590    597   
  591    598   
                    {
  592         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  593         -
        use ::aws_smithy_http_server::plugin::Plugin;
         599  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         600  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  594    601   
        let svc = crate::operation_shape::ReservedWordsAsMembers::from_service(service);
  595    602   
        let svc = self.model_plugin.apply(svc);
  596         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  597         -
            .apply(svc);
         603  +
        let svc =
         604  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         605  +
                .apply(svc);
  598    606   
        let svc = self.http_plugin.apply(svc);
  599    607   
        self.reserved_words_as_members_custom(svc)
  600    608   
    }
  601    609   
  602    610   
    /// Sets the [`ReservedWordsAsMembers`](crate::operation_shape::ReservedWordsAsMembers) to a custom [`Service`](tower::Service).
  603    611   
    /// not constrained by the Smithy contract.
  604    612   
    fn reserved_words_as_members_custom<S>(mut self, svc: S) -> Self
  605    613   
    where
  606    614   
        S: ::tower::Service<
  607    615   
                ::http::Request<Body>,
  608         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         616  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  609    617   
                Error = ::std::convert::Infallible,
  610    618   
            > + Clone
  611    619   
            + Send
  612    620   
            + 'static,
  613    621   
        S::Future: Send + 'static,
  614    622   
    {
  615         -
        self.reserved_words_as_members = Some(::aws_smithy_http_server::routing::Route::new(svc));
         623  +
        self.reserved_words_as_members =
         624  +
            Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  616    625   
        self
  617    626   
    }
  618    627   
  619    628   
    /// Sets the [`Result`](crate::operation_shape::Result) operation.
  620    629   
    ///
  621         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  622         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         630  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         631  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  623    632   
    ///
  624    633   
    /// # Example
  625    634   
    ///
  626    635   
    /// ```no_run
  627    636   
    /// use naming_test_ops::{Config, ConfigConfig};
  628    637   
    ///
  629    638   
    /// use naming_test_ops::{input, output, error};
  630    639   
    ///
  631    640   
    /// async fn handler(input: input::ResultInput) -> Result<output::ResultOutput, error::ResultError> {
  632    641   
    ///     todo!()
  633    642   
    /// }
  634    643   
    ///
  635    644   
    /// let config = ConfigConfig::builder().build();
  636    645   
    /// let app = Config::builder(config)
  637    646   
    ///     .result(handler)
  638    647   
    ///     /* Set other handlers */
  639    648   
    ///     .build()
  640    649   
    ///     .unwrap();
  641         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         650  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  642    651   
    /// ```
  643    652   
    ///
  644    653   
                    pub fn result<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  645    654   
                    where
  646         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::Result, HandlerExtractors>,
         655  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::Result, HandlerExtractors>,
  647    656   
  648         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         657  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  649    658   
                            Config<L>,
  650    659   
                            crate::operation_shape::Result,
  651         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::Result, HandlerType>
         660  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::Result, HandlerType>
  652    661   
                        >,
  653         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         662  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  654    663   
                            Config<L>,
  655    664   
                            crate::operation_shape::Result,
  656    665   
                            ModelPl::Output
  657    666   
                        >,
  658         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         667  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  659    668   
                            Config<L>,
  660    669   
                            crate::operation_shape::Result,
  661    670   
                            <
  662         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  663         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         671  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         672  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  664    673   
                                    Config<L>,
  665    674   
                                    crate::operation_shape::Result,
  666    675   
                                    ModelPl::Output
  667    676   
                                >
  668    677   
                            >::Output
  669    678   
                        >,
  670    679   
  671         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         680  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  672    681   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  673    682   
  674    683   
                    {
  675         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  676         -
        use ::aws_smithy_http_server::plugin::Plugin;
         684  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         685  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  677    686   
        let svc = crate::operation_shape::Result::from_handler(handler);
  678    687   
        let svc = self.model_plugin.apply(svc);
  679         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  680         -
            .apply(svc);
         688  +
        let svc =
         689  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         690  +
                .apply(svc);
  681    691   
        let svc = self.http_plugin.apply(svc);
  682    692   
        self.result_custom(svc)
  683    693   
    }
  684    694   
  685    695   
    /// Sets the [`Result`](crate::operation_shape::Result) operation.
  686    696   
    ///
  687         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  688         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         697  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         698  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  689    699   
    ///
  690    700   
    /// # Example
  691    701   
    ///
  692    702   
    /// ```no_run
  693    703   
    /// use naming_test_ops::{Config, ConfigConfig};
  694    704   
    ///
  695    705   
    /// use naming_test_ops::{input, output, error};
  696    706   
    ///
  697    707   
    /// async fn handler(input: input::ResultInput) -> Result<output::ResultOutput, error::ResultError> {
  698    708   
    ///     todo!()
  699    709   
    /// }
  700    710   
    ///
  701    711   
    /// let config = ConfigConfig::builder().build();
  702    712   
    /// let svc = ::tower::util::service_fn(handler);
  703    713   
    /// let app = Config::builder(config)
  704    714   
    ///     .result_service(svc)
  705    715   
    ///     /* Set other handlers */
  706    716   
    ///     .build()
  707    717   
    ///     .unwrap();
  708         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         718  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  709    719   
    /// ```
  710    720   
    ///
  711    721   
                    pub fn result_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  712    722   
                    where
  713         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::Result, ServiceExtractors>,
         723  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::Result, ServiceExtractors>,
  714    724   
  715         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         725  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  716    726   
                            Config<L>,
  717    727   
                            crate::operation_shape::Result,
  718         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::Result, S>
         728  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::Result, S>
  719    729   
                        >,
  720         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         730  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  721    731   
                            Config<L>,
  722    732   
                            crate::operation_shape::Result,
  723    733   
                            ModelPl::Output
  724    734   
                        >,
  725         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         735  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  726    736   
                            Config<L>,
  727    737   
                            crate::operation_shape::Result,
  728    738   
                            <
  729         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  730         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         739  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         740  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  731    741   
                                    Config<L>,
  732    742   
                                    crate::operation_shape::Result,
  733    743   
                                    ModelPl::Output
  734    744   
                                >
  735    745   
                            >::Output
  736    746   
                        >,
  737    747   
  738         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         748  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  739    749   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  740    750   
  741    751   
                    {
  742         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  743         -
        use ::aws_smithy_http_server::plugin::Plugin;
         752  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         753  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  744    754   
        let svc = crate::operation_shape::Result::from_service(service);
  745    755   
        let svc = self.model_plugin.apply(svc);
  746         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  747         -
            .apply(svc);
         756  +
        let svc =
         757  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         758  +
                .apply(svc);
  748    759   
        let svc = self.http_plugin.apply(svc);
  749    760   
        self.result_custom(svc)
  750    761   
    }
  751    762   
  752    763   
    /// Sets the [`Result`](crate::operation_shape::Result) to a custom [`Service`](tower::Service).
  753    764   
    /// not constrained by the Smithy contract.
  754    765   
    fn result_custom<S>(mut self, svc: S) -> Self
  755    766   
    where
  756    767   
        S: ::tower::Service<
  757    768   
                ::http::Request<Body>,
  758         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         769  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  759    770   
                Error = ::std::convert::Infallible,
  760    771   
            > + Clone
  761    772   
            + Send
  762    773   
            + 'static,
  763    774   
        S::Future: Send + 'static,
  764    775   
    {
  765         -
        self.result = Some(::aws_smithy_http_server::routing::Route::new(svc));
         776  +
        self.result = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  766    777   
        self
  767    778   
    }
  768    779   
  769    780   
    /// Sets the [`RpcEcho`](crate::operation_shape::RpcEcho) operation.
  770    781   
    ///
  771         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  772         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         782  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         783  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  773    784   
    ///
  774    785   
    /// # Example
  775    786   
    ///
  776    787   
    /// ```no_run
  777    788   
    /// use naming_test_ops::{Config, ConfigConfig};
  778    789   
    ///
  779    790   
    /// use naming_test_ops::{input, output, error};
  780    791   
    ///
  781    792   
    /// async fn handler(input: input::RpcEchoInput) -> Result<output::RpcEchoOutput, error::RPCEchoError> {
  782    793   
    ///     todo!()
  783    794   
    /// }
  784    795   
    ///
  785    796   
    /// let config = ConfigConfig::builder().build();
  786    797   
    /// let app = Config::builder(config)
  787    798   
    ///     .rpc_echo(handler)
  788    799   
    ///     /* Set other handlers */
  789    800   
    ///     .build()
  790    801   
    ///     .unwrap();
  791         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         802  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  792    803   
    /// ```
  793    804   
    ///
  794    805   
                    pub fn rpc_echo<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  795    806   
                    where
  796         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::RpcEcho, HandlerExtractors>,
         807  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::RpcEcho, HandlerExtractors>,
  797    808   
  798         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         809  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  799    810   
                            Config<L>,
  800    811   
                            crate::operation_shape::RpcEcho,
  801         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::RpcEcho, HandlerType>
         812  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::RpcEcho, HandlerType>
  802    813   
                        >,
  803         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         814  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  804    815   
                            Config<L>,
  805    816   
                            crate::operation_shape::RpcEcho,
  806    817   
                            ModelPl::Output
  807    818   
                        >,
  808         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         819  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  809    820   
                            Config<L>,
  810    821   
                            crate::operation_shape::RpcEcho,
  811    822   
                            <
  812         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  813         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         823  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         824  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  814    825   
                                    Config<L>,
  815    826   
                                    crate::operation_shape::RpcEcho,
  816    827   
                                    ModelPl::Output
  817    828   
                                >
  818    829   
                            >::Output
  819    830   
                        >,
  820    831   
  821         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         832  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  822    833   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  823    834   
  824    835   
                    {
  825         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  826         -
        use ::aws_smithy_http_server::plugin::Plugin;
         836  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         837  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  827    838   
        let svc = crate::operation_shape::RpcEcho::from_handler(handler);
  828    839   
        let svc = self.model_plugin.apply(svc);
  829         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  830         -
            .apply(svc);
         840  +
        let svc =
         841  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         842  +
                .apply(svc);
  831    843   
        let svc = self.http_plugin.apply(svc);
  832    844   
        self.rpc_echo_custom(svc)
  833    845   
    }
  834    846   
  835    847   
    /// Sets the [`RpcEcho`](crate::operation_shape::RpcEcho) operation.
  836    848   
    ///
  837         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  838         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         849  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         850  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  839    851   
    ///
  840    852   
    /// # Example
  841    853   
    ///
  842    854   
    /// ```no_run
  843    855   
    /// use naming_test_ops::{Config, ConfigConfig};
  844    856   
    ///
  845    857   
    /// use naming_test_ops::{input, output, error};
  846    858   
    ///
  847    859   
    /// async fn handler(input: input::RpcEchoInput) -> Result<output::RpcEchoOutput, error::RPCEchoError> {
  848    860   
    ///     todo!()
  849    861   
    /// }
  850    862   
    ///
  851    863   
    /// let config = ConfigConfig::builder().build();
  852    864   
    /// let svc = ::tower::util::service_fn(handler);
  853    865   
    /// let app = Config::builder(config)
  854    866   
    ///     .rpc_echo_service(svc)
  855    867   
    ///     /* Set other handlers */
  856    868   
    ///     .build()
  857    869   
    ///     .unwrap();
  858         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         870  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  859    871   
    /// ```
  860    872   
    ///
  861    873   
                    pub fn rpc_echo_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
  862    874   
                    where
  863         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::RpcEcho, ServiceExtractors>,
         875  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::RpcEcho, ServiceExtractors>,
  864    876   
  865         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         877  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  866    878   
                            Config<L>,
  867    879   
                            crate::operation_shape::RpcEcho,
  868         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::RpcEcho, S>
         880  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::RpcEcho, S>
  869    881   
                        >,
  870         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         882  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  871    883   
                            Config<L>,
  872    884   
                            crate::operation_shape::RpcEcho,
  873    885   
                            ModelPl::Output
  874    886   
                        >,
  875         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         887  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  876    888   
                            Config<L>,
  877    889   
                            crate::operation_shape::RpcEcho,
  878    890   
                            <
  879         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  880         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         891  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         892  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  881    893   
                                    Config<L>,
  882    894   
                                    crate::operation_shape::RpcEcho,
  883    895   
                                    ModelPl::Output
  884    896   
                                >
  885    897   
                            >::Output
  886    898   
                        >,
  887    899   
  888         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         900  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  889    901   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  890    902   
  891    903   
                    {
  892         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  893         -
        use ::aws_smithy_http_server::plugin::Plugin;
         904  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         905  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  894    906   
        let svc = crate::operation_shape::RpcEcho::from_service(service);
  895    907   
        let svc = self.model_plugin.apply(svc);
  896         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  897         -
            .apply(svc);
         908  +
        let svc =
         909  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         910  +
                .apply(svc);
  898    911   
        let svc = self.http_plugin.apply(svc);
  899    912   
        self.rpc_echo_custom(svc)
  900    913   
    }
  901    914   
  902    915   
    /// Sets the [`RpcEcho`](crate::operation_shape::RpcEcho) to a custom [`Service`](tower::Service).
  903    916   
    /// not constrained by the Smithy contract.
  904    917   
    fn rpc_echo_custom<S>(mut self, svc: S) -> Self
  905    918   
    where
  906    919   
        S: ::tower::Service<
  907    920   
                ::http::Request<Body>,
  908         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
         921  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
  909    922   
                Error = ::std::convert::Infallible,
  910    923   
            > + Clone
  911    924   
            + Send
  912    925   
            + 'static,
  913    926   
        S::Future: Send + 'static,
  914    927   
    {
  915         -
        self.rpc_echo = Some(::aws_smithy_http_server::routing::Route::new(svc));
         928  +
        self.rpc_echo = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
  916    929   
        self
  917    930   
    }
  918    931   
  919    932   
    /// Sets the [`StructureNamePunning`](crate::operation_shape::StructureNamePunning) operation.
  920    933   
    ///
  921         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  922         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
         934  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
         935  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  923    936   
    ///
  924    937   
    /// # Example
  925    938   
    ///
  926    939   
    /// ```no_run
  927    940   
    /// use naming_test_ops::{Config, ConfigConfig};
  928    941   
    ///
  929    942   
    /// use naming_test_ops::{input, output, error};
  930    943   
    ///
  931    944   
    /// async fn handler(input: input::StructureNamePunningInput) -> Result<output::StructureNamePunningOutput, error::StructureNamePunningError> {
  932    945   
    ///     todo!()
  933    946   
    /// }
  934    947   
    ///
  935    948   
    /// let config = ConfigConfig::builder().build();
  936    949   
    /// let app = Config::builder(config)
  937    950   
    ///     .structure_name_punning(handler)
  938    951   
    ///     /* Set other handlers */
  939    952   
    ///     .build()
  940    953   
    ///     .unwrap();
  941         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
         954  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
  942    955   
    /// ```
  943    956   
    ///
  944    957   
                    pub fn structure_name_punning<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
  945    958   
                    where
  946         -
                        HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::StructureNamePunning, HandlerExtractors>,
         959  +
                        HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::StructureNamePunning, HandlerExtractors>,
  947    960   
  948         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
         961  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  949    962   
                            Config<L>,
  950    963   
                            crate::operation_shape::StructureNamePunning,
  951         -
                            ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::StructureNamePunning, HandlerType>
         964  +
                            ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::StructureNamePunning, HandlerType>
  952    965   
                        >,
  953         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
         966  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
  954    967   
                            Config<L>,
  955    968   
                            crate::operation_shape::StructureNamePunning,
  956    969   
                            ModelPl::Output
  957    970   
                        >,
  958         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
         971  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
  959    972   
                            Config<L>,
  960    973   
                            crate::operation_shape::StructureNamePunning,
  961    974   
                            <
  962         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
  963         -
                                as ::aws_smithy_http_server::plugin::Plugin<
         975  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
         976  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
  964    977   
                                    Config<L>,
  965    978   
                                    crate::operation_shape::StructureNamePunning,
  966    979   
                                    ModelPl::Output
  967    980   
                                >
  968    981   
                            >::Output
  969    982   
                        >,
  970    983   
  971         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
         984  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
  972    985   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
  973    986   
  974    987   
                    {
  975         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
  976         -
        use ::aws_smithy_http_server::plugin::Plugin;
         988  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
         989  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
  977    990   
        let svc = crate::operation_shape::StructureNamePunning::from_handler(handler);
  978    991   
        let svc = self.model_plugin.apply(svc);
  979         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
  980         -
            .apply(svc);
         992  +
        let svc =
         993  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
         994  +
                .apply(svc);
  981    995   
        let svc = self.http_plugin.apply(svc);
  982    996   
        self.structure_name_punning_custom(svc)
  983    997   
    }
  984    998   
  985    999   
    /// Sets the [`StructureNamePunning`](crate::operation_shape::StructureNamePunning) operation.
  986   1000   
    ///
  987         -
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
  988         -
    /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
        1001  +
    /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
        1002  +
    /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
  989   1003   
    ///
  990   1004   
    /// # Example
  991   1005   
    ///
  992   1006   
    /// ```no_run
  993   1007   
    /// use naming_test_ops::{Config, ConfigConfig};
  994   1008   
    ///
  995   1009   
    /// use naming_test_ops::{input, output, error};
  996   1010   
    ///
  997   1011   
    /// async fn handler(input: input::StructureNamePunningInput) -> Result<output::StructureNamePunningOutput, error::StructureNamePunningError> {
  998   1012   
    ///     todo!()
  999   1013   
    /// }
 1000   1014   
    ///
 1001   1015   
    /// let config = ConfigConfig::builder().build();
 1002   1016   
    /// let svc = ::tower::util::service_fn(handler);
 1003   1017   
    /// let app = Config::builder(config)
 1004   1018   
    ///     .structure_name_punning_service(svc)
 1005   1019   
    ///     /* Set other handlers */
 1006   1020   
    ///     .build()
 1007   1021   
    ///     .unwrap();
 1008         -
    /// # let app: Config<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
        1022  +
    /// # let app: Config<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1>> = app;
 1009   1023   
    /// ```
 1010   1024   
    ///
 1011   1025   
                    pub fn structure_name_punning_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
 1012   1026   
                    where
 1013         -
                        S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::StructureNamePunning, ServiceExtractors>,
        1027  +
                        S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::StructureNamePunning, ServiceExtractors>,
 1014   1028   
 1015         -
                        ModelPl: ::aws_smithy_http_server::plugin::Plugin<
        1029  +
                        ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
 1016   1030   
                            Config<L>,
 1017   1031   
                            crate::operation_shape::StructureNamePunning,
 1018         -
                            ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::StructureNamePunning, S>
        1032  +
                            ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::StructureNamePunning, S>
 1019   1033   
                        >,
 1020         -
                        ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
        1034  +
                        ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
 1021   1035   
                            Config<L>,
 1022   1036   
                            crate::operation_shape::StructureNamePunning,
 1023   1037   
                            ModelPl::Output
 1024   1038   
                        >,
 1025         -
                        HttpPl: ::aws_smithy_http_server::plugin::Plugin<
        1039  +
                        HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
 1026   1040   
                            Config<L>,
 1027   1041   
                            crate::operation_shape::StructureNamePunning,
 1028   1042   
                            <
 1029         -
                                ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
 1030         -
                                as ::aws_smithy_http_server::plugin::Plugin<
        1043  +
                                ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
        1044  +
                                as ::aws_smithy_legacy_http_server::plugin::Plugin<
 1031   1045   
                                    Config<L>,
 1032   1046   
                                    crate::operation_shape::StructureNamePunning,
 1033   1047   
                                    ModelPl::Output
 1034   1048   
                                >
 1035   1049   
                            >::Output
 1036   1050   
                        >,
 1037   1051   
 1038         -
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
        1052  +
                        HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
 1039   1053   
                        <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
 1040   1054   
 1041   1055   
                    {
 1042         -
        use ::aws_smithy_http_server::operation::OperationShapeExt;
 1043         -
        use ::aws_smithy_http_server::plugin::Plugin;
        1056  +
        use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
        1057  +
        use ::aws_smithy_legacy_http_server::plugin::Plugin;
 1044   1058   
        let svc = crate::operation_shape::StructureNamePunning::from_service(service);
 1045   1059   
        let svc = self.model_plugin.apply(svc);
 1046         -
        let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
 1047         -
            .apply(svc);
        1060  +
        let svc =
        1061  +
            ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
        1062  +
                .apply(svc);
 1048   1063   
        let svc = self.http_plugin.apply(svc);
 1049   1064   
        self.structure_name_punning_custom(svc)
 1050   1065   
    }
 1051   1066   
 1052   1067   
    /// Sets the [`StructureNamePunning`](crate::operation_shape::StructureNamePunning) to a custom [`Service`](tower::Service).
 1053   1068   
    /// not constrained by the Smithy contract.
 1054   1069   
    fn structure_name_punning_custom<S>(mut self, svc: S) -> Self
 1055   1070   
    where
 1056   1071   
        S: ::tower::Service<
 1057   1072   
                ::http::Request<Body>,
 1058         -
                Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
        1073  +
                Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
 1059   1074   
                Error = ::std::convert::Infallible,
 1060   1075   
            > + Clone
 1061   1076   
            + Send
 1062   1077   
            + 'static,
 1063   1078   
        S::Future: Send + 'static,
 1064   1079   
    {
 1065         -
        self.structure_name_punning = Some(::aws_smithy_http_server::routing::Route::new(svc));
        1080  +
        self.structure_name_punning =
        1081  +
            Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
 1066   1082   
        self
 1067   1083   
    }
 1068   1084   
}
 1069   1085   
 1070   1086   
impl<Body, L, HttpPl, ModelPl> ConfigBuilder<Body, L, HttpPl, ModelPl> {
 1071   1087   
    /// Constructs a [`Config`] from the arguments provided to the builder.
 1072   1088   
    ///
 1073   1089   
    /// Forgetting to register a handler for one or more operations will result in an error.
 1074   1090   
    ///
 1075   1091   
    /// Check out [`ConfigBuilder::build_unchecked`] if you'd prefer the service to return status code 500 when an
 1076   1092   
    /// unspecified route is requested.
 1077   1093   
    pub fn build(
 1078   1094   
        self,
 1079   1095   
    ) -> ::std::result::Result<
 1080   1096   
        Config<
 1081         -
            ::aws_smithy_http_server::routing::RoutingService<
 1082         -
                ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<L::Service>,
 1083         -
                ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1097  +
            ::aws_smithy_legacy_http_server::routing::RoutingService<
        1098  +
                ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<
        1099  +
                    L::Service,
        1100  +
                >,
        1101  +
                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1084   1102   
            >,
 1085   1103   
        >,
 1086   1104   
        MissingOperationsError,
 1087   1105   
    >
 1088   1106   
    where
 1089         -
        L: ::tower::Layer<::aws_smithy_http_server::routing::Route<Body>>,
        1107  +
        L: ::tower::Layer<::aws_smithy_legacy_http_server::routing::Route<Body>>,
 1090   1108   
    {
 1091   1109   
        let router = {
 1092         -
            use ::aws_smithy_http_server::operation::OperationShape;
        1110  +
            use ::aws_smithy_legacy_http_server::operation::OperationShape;
 1093   1111   
            let mut missing_operation_names = std::collections::HashMap::new();
 1094   1112   
            if self.err_collisions.is_none() {
 1095   1113   
                missing_operation_names.insert(
 1096   1114   
                    crate::operation_shape::ErrCollisions::ID,
 1097   1115   
                    ".err_collisions()",
 1098   1116   
                );
 1099   1117   
            }
 1100   1118   
            if self.r#match.is_none() {
 1101   1119   
                missing_operation_names.insert(crate::operation_shape::Match::ID, ".r#match()");
 1102   1120   
            }
 1103   1121   
            if self.option.is_none() {
 1104   1122   
                missing_operation_names.insert(crate::operation_shape::Option::ID, ".option()");
 1105   1123   
            }
 1106   1124   
            if self.reserved_words_as_members.is_none() {
 1107   1125   
                missing_operation_names.insert(
 1108   1126   
                    crate::operation_shape::ReservedWordsAsMembers::ID,
 1109   1127   
                    ".reserved_words_as_members()",
 1110   1128   
                );
 1111   1129   
            }
 1112   1130   
            if self.result.is_none() {
 1113   1131   
                missing_operation_names.insert(crate::operation_shape::Result::ID, ".result()");
 1114   1132   
            }
 1115   1133   
            if self.rpc_echo.is_none() {
 1116   1134   
                missing_operation_names.insert(crate::operation_shape::RpcEcho::ID, ".rpc_echo()");
 1117   1135   
            }
 1118   1136   
            if self.structure_name_punning.is_none() {
 1119   1137   
                missing_operation_names.insert(
 1120   1138   
                    crate::operation_shape::StructureNamePunning::ID,
 1121   1139   
                    ".structure_name_punning()",
 1122   1140   
                );
 1123   1141   
            }
 1124   1142   
            if !missing_operation_names.is_empty() {
 1125   1143   
                return Err(MissingOperationsError {
 1126   1144   
                    operation_names2setter_methods: missing_operation_names,
 1127   1145   
                });
 1128   1146   
            }
 1129   1147   
            let unexpected_error_msg = "this should never panic since we are supposed to check beforehand that a handler has been registered for this operation; please file a bug report under https://github.com/smithy-lang/smithy-rs/issues";
 1130   1148   
 1131         -
            ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter::from_iter([
        1149  +
            ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter::from_iter([
 1132   1150   
                (
 1133   1151   
                    request_specs::err_collisions(),
 1134   1152   
                    self.err_collisions.expect(unexpected_error_msg),
 1135   1153   
                ),
 1136   1154   
                (
 1137   1155   
                    request_specs::r#match(),
 1138   1156   
                    self.r#match.expect(unexpected_error_msg),
 1139   1157   
                ),
 1140   1158   
                (
 1141   1159   
                    request_specs::option(),
 1142   1160   
                    self.option.expect(unexpected_error_msg),
 1143   1161   
                ),
 1144   1162   
                (
 1145   1163   
                    request_specs::reserved_words_as_members(),
 1146   1164   
                    self.reserved_words_as_members.expect(unexpected_error_msg),
 1147   1165   
                ),
 1148   1166   
                (
 1149   1167   
                    request_specs::result(),
 1150   1168   
                    self.result.expect(unexpected_error_msg),
 1151   1169   
                ),
 1152   1170   
                (
 1153   1171   
                    request_specs::rpc_echo(),
 1154   1172   
                    self.rpc_echo.expect(unexpected_error_msg),
 1155   1173   
                ),
 1156   1174   
                (
 1157   1175   
                    request_specs::structure_name_punning(),
 1158   1176   
                    self.structure_name_punning.expect(unexpected_error_msg),
 1159   1177   
                ),
 1160   1178   
            ])
 1161   1179   
        };
 1162         -
        let svc = ::aws_smithy_http_server::routing::RoutingService::new(router);
        1180  +
        let svc = ::aws_smithy_legacy_http_server::routing::RoutingService::new(router);
 1163   1181   
        let svc = svc.map(|s| s.layer(self.layer));
 1164   1182   
        Ok(Config { svc })
 1165   1183   
    }
 1166   1184   
 1167   1185   
    /// Constructs a [`Config`] from the arguments provided to the builder.
 1168   1186   
    /// Operations without a handler default to returning 500 Internal Server Error to the caller.
 1169   1187   
    ///
 1170   1188   
    /// Check out [`ConfigBuilder::build`] if you'd prefer the builder to fail if one or more operations do
 1171   1189   
    /// not have a registered handler.
 1172   1190   
    pub fn build_unchecked(self) -> Config<L::Service>
 1173   1191   
    where
 1174   1192   
        Body: Send + 'static,
 1175   1193   
        L: ::tower::Layer<
 1176         -
            ::aws_smithy_http_server::routing::RoutingService<
 1177         -
                ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<
 1178         -
                    ::aws_smithy_http_server::routing::Route<Body>,
        1194  +
            ::aws_smithy_legacy_http_server::routing::RoutingService<
        1195  +
                ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<
        1196  +
                    ::aws_smithy_legacy_http_server::routing::Route<Body>,
 1179   1197   
                >,
 1180         -
                ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1198  +
                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1181   1199   
            >,
 1182   1200   
        >,
 1183   1201   
    {
 1184   1202   
        let router =
 1185         -
            ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter::from_iter([
 1186         -
                (
 1187         -
                    request_specs::err_collisions(),
 1188         -
                    self.err_collisions.unwrap_or_else(|| {
 1189         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1190         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1191         -
                        >::default();
 1192         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1193         -
                    }),
 1194         -
                ),
 1195         -
                (
 1196         -
                    request_specs::r#match(),
 1197         -
                    self.r#match.unwrap_or_else(|| {
 1198         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1199         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1200         -
                        >::default();
 1201         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1202         -
                    }),
 1203         -
                ),
 1204         -
                (
 1205         -
                    request_specs::option(),
 1206         -
                    self.option.unwrap_or_else(|| {
 1207         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1208         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1209         -
                        >::default();
 1210         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1211         -
                    }),
 1212         -
                ),
 1213         -
                (
 1214         -
                    request_specs::reserved_words_as_members(),
 1215         -
                    self.reserved_words_as_members.unwrap_or_else(|| {
 1216         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1217         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1218         -
                        >::default();
 1219         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1220         -
                    }),
 1221         -
                ),
 1222         -
                (
 1223         -
                    request_specs::result(),
 1224         -
                    self.result.unwrap_or_else(|| {
 1225         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1226         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1227         -
                        >::default();
 1228         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1229         -
                    }),
 1230         -
                ),
 1231         -
                (
 1232         -
                    request_specs::rpc_echo(),
 1233         -
                    self.rpc_echo.unwrap_or_else(|| {
 1234         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1235         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1236         -
                        >::default();
 1237         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1238         -
                    }),
 1239         -
                ),
 1240         -
                (
 1241         -
                    request_specs::structure_name_punning(),
 1242         -
                    self.structure_name_punning.unwrap_or_else(|| {
 1243         -
                        let svc = ::aws_smithy_http_server::operation::MissingFailure::<
 1244         -
                            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
 1245         -
                        >::default();
 1246         -
                        ::aws_smithy_http_server::routing::Route::new(svc)
 1247         -
                    }),
 1248         -
                ),
 1249         -
            ]);
        1203  +
            ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter::from_iter(
        1204  +
                [
        1205  +
                    (
        1206  +
                        request_specs::err_collisions(),
        1207  +
                        self.err_collisions.unwrap_or_else(|| {
        1208  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1209  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1210  +
                            >::default();
        1211  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1212  +
                        }),
        1213  +
                    ),
        1214  +
                    (
        1215  +
                        request_specs::r#match(),
        1216  +
                        self.r#match.unwrap_or_else(|| {
        1217  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1218  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1219  +
                            >::default();
        1220  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1221  +
                        }),
        1222  +
                    ),
        1223  +
                    (
        1224  +
                        request_specs::option(),
        1225  +
                        self.option.unwrap_or_else(|| {
        1226  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1227  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1228  +
                            >::default();
        1229  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1230  +
                        }),
        1231  +
                    ),
        1232  +
                    (
        1233  +
                        request_specs::reserved_words_as_members(),
        1234  +
                        self.reserved_words_as_members.unwrap_or_else(|| {
        1235  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1236  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1237  +
                            >::default();
        1238  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1239  +
                        }),
        1240  +
                    ),
        1241  +
                    (
        1242  +
                        request_specs::result(),
        1243  +
                        self.result.unwrap_or_else(|| {
        1244  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1245  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1246  +
                            >::default();
        1247  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1248  +
                        }),
        1249  +
                    ),
        1250  +
                    (
        1251  +
                        request_specs::rpc_echo(),
        1252  +
                        self.rpc_echo.unwrap_or_else(|| {
        1253  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1254  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1255  +
                            >::default();
        1256  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1257  +
                        }),
        1258  +
                    ),
        1259  +
                    (
        1260  +
                        request_specs::structure_name_punning(),
        1261  +
                        self.structure_name_punning.unwrap_or_else(|| {
        1262  +
                            let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
        1263  +
                                ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
        1264  +
                            >::default();
        1265  +
                            ::aws_smithy_legacy_http_server::routing::Route::new(svc)
        1266  +
                        }),
        1267  +
                    ),
        1268  +
                ],
        1269  +
            );
 1250   1270   
        let svc = self
 1251   1271   
            .layer
 1252         -
            .layer(::aws_smithy_http_server::routing::RoutingService::new(
 1253         -
                router,
 1254         -
            ));
        1272  +
            .layer(::aws_smithy_legacy_http_server::routing::RoutingService::new(router));
 1255   1273   
        Config { svc }
 1256   1274   
    }
 1257   1275   
}
 1258   1276   
 1259   1277   
/// The error encountered when calling the [`ConfigBuilder::build`] method if one or more operation handlers are not
 1260   1278   
/// specified.
 1261   1279   
#[derive(Debug)]
 1262   1280   
pub struct MissingOperationsError {
 1263   1281   
    operation_names2setter_methods:
 1264         -
        std::collections::HashMap<::aws_smithy_http_server::shape_id::ShapeId, &'static str>,
        1282  +
        std::collections::HashMap<::aws_smithy_legacy_http_server::shape_id::ShapeId, &'static str>,
 1265   1283   
}
 1266   1284   
 1267   1285   
impl std::fmt::Display for MissingOperationsError {
 1268   1286   
    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
 1269   1287   
        write!(
 1270   1288   
            f,
 1271   1289   
            "You must specify a handler for all operations attached to `Config`.\n\
 1272   1290   
                            We are missing handlers for the following operations:\n",
 1273   1291   
        )?;
 1274   1292   
        for operation_name in self.operation_names2setter_methods.keys() {
 1275   1293   
            writeln!(f, "- {}", operation_name.absolute())?;
 1276   1294   
        }
 1277   1295   
 1278   1296   
        writeln!(
 1279   1297   
            f,
 1280   1298   
            "\nUse the dedicated methods on `ConfigBuilder` to register the missing handlers:"
 1281   1299   
        )?;
 1282   1300   
        for setter_name in self.operation_names2setter_methods.values() {
 1283   1301   
            writeln!(f, "- {}", setter_name)?;
 1284   1302   
        }
 1285   1303   
        Ok(())
 1286   1304   
    }
 1287   1305   
}
 1288   1306   
 1289   1307   
impl std::error::Error for MissingOperationsError {}
 1290   1308   
 1291   1309   
mod request_specs {
 1292   1310   
    pub(super) fn err_collisions() -> &'static str {
 1293   1311   
        "Config.ErrCollisions"
 1294   1312   
    }
 1295   1313   
    pub(super) fn r#match() -> &'static str {
 1296   1314   
        "Config.Match"
 1297   1315   
    }
 1298   1316   
    pub(super) fn option() -> &'static str {
 1299   1317   
        "Config.Option"
 1300   1318   
    }
 1301   1319   
    pub(super) fn reserved_words_as_members() -> &'static str {
 1302   1320   
        "Config.ReservedWordsAsMembers"
 1303   1321   
    }
 1304   1322   
    pub(super) fn result() -> &'static str {
 1305   1323   
        "Config.Result"
 1306   1324   
    }
 1307   1325   
    pub(super) fn rpc_echo() -> &'static str {
 1308   1326   
        "Config.RPCEcho"
 1309   1327   
    }
 1310   1328   
    pub(super) fn structure_name_punning() -> &'static str {
 1311   1329   
        "Config.StructureNamePunning"
 1312   1330   
    }
 1313   1331   
}
 1314   1332   
 1315   1333   
/// Confounds model generation machinery with lots of problematic names
 1316   1334   
///
 1317   1335   
/// See the [root](crate) documentation for more information.
 1318   1336   
#[derive(Clone)]
 1319   1337   
pub struct Config<
 1320         -
    S = ::aws_smithy_http_server::routing::RoutingService<
 1321         -
        ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<
 1322         -
            ::aws_smithy_http_server::routing::Route<::aws_smithy_http_server::body::BoxBody>,
        1338  +
    S = ::aws_smithy_legacy_http_server::routing::RoutingService<
        1339  +
        ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<
        1340  +
            ::aws_smithy_legacy_http_server::routing::Route<
        1341  +
                ::aws_smithy_legacy_http_server::body::BoxBody,
        1342  +
            >,
 1323   1343   
        >,
 1324         -
        ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1344  +
        ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1325   1345   
    >,
 1326   1346   
> {
 1327   1347   
    // This is the router wrapped by layers.
 1328   1348   
    svc: S,
 1329   1349   
}
 1330   1350   
 1331   1351   
impl Config<()> {
 1332   1352   
    /// Constructs a builder for [`Config`].
 1333   1353   
    /// You must specify a configuration object holding any plugins and layers that should be applied
 1334   1354   
    /// to the operations in this service.
 1335   1355   
    pub fn builder<
 1336   1356   
        Body,
 1337   1357   
        L,
 1338         -
        HttpPl: ::aws_smithy_http_server::plugin::HttpMarker,
 1339         -
        ModelPl: ::aws_smithy_http_server::plugin::ModelMarker,
        1358  +
        HttpPl: ::aws_smithy_legacy_http_server::plugin::HttpMarker,
        1359  +
        ModelPl: ::aws_smithy_legacy_http_server::plugin::ModelMarker,
 1340   1360   
    >(
 1341   1361   
        config: ConfigConfig<L, HttpPl, ModelPl>,
 1342   1362   
    ) -> ConfigBuilder<Body, L, HttpPl, ModelPl> {
 1343   1363   
        ConfigBuilder {
 1344   1364   
            err_collisions: None,
 1345   1365   
            r#match: None,
 1346   1366   
            option: None,
 1347   1367   
            reserved_words_as_members: None,
 1348   1368   
            result: None,
 1349   1369   
            rpc_echo: None,
 1350   1370   
            structure_name_punning: None,
 1351   1371   
            layer: config.layers,
 1352   1372   
            http_plugin: config.http_plugins,
 1353   1373   
            model_plugin: config.model_plugins,
 1354   1374   
        }
 1355   1375   
    }
 1356   1376   
 1357   1377   
    /// Constructs a builder for [`Config`].
 1358   1378   
    /// You must specify what plugins should be applied to the operations in this service.
 1359   1379   
    ///
 1360   1380   
    /// Use [`Config::builder_without_plugins`] if you don't need to apply plugins.
 1361   1381   
    ///
 1362         -
    /// Check out [`HttpPlugins`](::aws_smithy_http_server::plugin::HttpPlugins) and
 1363         -
    /// [`ModelPlugins`](::aws_smithy_http_server::plugin::ModelPlugins) if you need to apply
        1382  +
    /// Check out [`HttpPlugins`](::aws_smithy_legacy_http_server::plugin::HttpPlugins) and
        1383  +
    /// [`ModelPlugins`](::aws_smithy_legacy_http_server::plugin::ModelPlugins) if you need to apply
 1364   1384   
    /// multiple plugins.
 1365   1385   
    #[deprecated(
 1366   1386   
        since = "0.57.0",
 1367   1387   
        note = "please use the `builder` constructor and register plugins on the `ConfigConfig` object instead; see https://github.com/smithy-lang/smithy-rs/discussions/3096"
 1368   1388   
    )]
 1369   1389   
    pub fn builder_with_plugins<
 1370   1390   
        Body,
 1371         -
        HttpPl: ::aws_smithy_http_server::plugin::HttpMarker,
 1372         -
        ModelPl: ::aws_smithy_http_server::plugin::ModelMarker,
        1391  +
        HttpPl: ::aws_smithy_legacy_http_server::plugin::HttpMarker,
        1392  +
        ModelPl: ::aws_smithy_legacy_http_server::plugin::ModelMarker,
 1373   1393   
    >(
 1374   1394   
        http_plugin: HttpPl,
 1375   1395   
        model_plugin: ModelPl,
 1376   1396   
    ) -> ConfigBuilder<Body, ::tower::layer::util::Identity, HttpPl, ModelPl> {
 1377   1397   
        ConfigBuilder {
 1378   1398   
            err_collisions: None,
 1379   1399   
            r#match: None,
 1380   1400   
            option: None,
 1381   1401   
            reserved_words_as_members: None,
 1382   1402   
            result: None,
 1383   1403   
            rpc_echo: None,
 1384   1404   
            structure_name_punning: None,
 1385   1405   
            layer: ::tower::layer::util::Identity::new(),
 1386   1406   
            http_plugin,
 1387   1407   
            model_plugin,
 1388   1408   
        }
 1389   1409   
    }
 1390   1410   
 1391   1411   
    /// Constructs a builder for [`Config`].
 1392   1412   
    ///
 1393   1413   
    /// Use [`Config::builder_with_plugins`] if you need to specify plugins.
 1394   1414   
    #[deprecated(
 1395   1415   
        since = "0.57.0",
 1396   1416   
        note = "please use the `builder` constructor instead; see https://github.com/smithy-lang/smithy-rs/discussions/3096"
 1397   1417   
    )]
 1398   1418   
    pub fn builder_without_plugins<Body>() -> ConfigBuilder<
 1399   1419   
        Body,
 1400   1420   
        ::tower::layer::util::Identity,
 1401         -
        ::aws_smithy_http_server::plugin::IdentityPlugin,
 1402         -
        ::aws_smithy_http_server::plugin::IdentityPlugin,
        1421  +
        ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
        1422  +
        ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
 1403   1423   
    > {
 1404   1424   
        Self::builder_with_plugins(
 1405         -
            ::aws_smithy_http_server::plugin::IdentityPlugin,
 1406         -
            ::aws_smithy_http_server::plugin::IdentityPlugin,
        1425  +
            ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
        1426  +
            ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
 1407   1427   
        )
 1408   1428   
    }
 1409   1429   
}
 1410   1430   
 1411   1431   
impl<S> Config<S> {
 1412   1432   
    /// Converts [`Config`] into a [`MakeService`](tower::make::MakeService).
 1413         -
    pub fn into_make_service(self) -> ::aws_smithy_http_server::routing::IntoMakeService<Self> {
 1414         -
        ::aws_smithy_http_server::routing::IntoMakeService::new(self)
        1433  +
    pub fn into_make_service(
        1434  +
        self,
        1435  +
    ) -> ::aws_smithy_legacy_http_server::routing::IntoMakeService<Self> {
        1436  +
        ::aws_smithy_legacy_http_server::routing::IntoMakeService::new(self)
 1415   1437   
    }
 1416   1438   
 1417         -
    /// Converts [`Config`] into a [`MakeService`](tower::make::MakeService) with [`ConnectInfo`](::aws_smithy_http_server::request::connect_info::ConnectInfo).
        1439  +
    /// Converts [`Config`] into a [`MakeService`](tower::make::MakeService) with [`ConnectInfo`](::aws_smithy_legacy_http_server::request::connect_info::ConnectInfo).
 1418   1440   
    pub fn into_make_service_with_connect_info<C>(
 1419   1441   
        self,
 1420         -
    ) -> ::aws_smithy_http_server::routing::IntoMakeServiceWithConnectInfo<Self, C> {
 1421         -
        ::aws_smithy_http_server::routing::IntoMakeServiceWithConnectInfo::new(self)
        1442  +
    ) -> ::aws_smithy_legacy_http_server::routing::IntoMakeServiceWithConnectInfo<Self, C> {
        1443  +
        ::aws_smithy_legacy_http_server::routing::IntoMakeServiceWithConnectInfo::new(self)
 1422   1444   
    }
 1423   1445   
}
 1424   1446   
 1425   1447   
impl<S>
 1426   1448   
    Config<
 1427         -
        ::aws_smithy_http_server::routing::RoutingService<
 1428         -
            ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<S>,
 1429         -
            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1449  +
        ::aws_smithy_legacy_http_server::routing::RoutingService<
        1450  +
            ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<S>,
        1451  +
            ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1430   1452   
        >,
 1431   1453   
    >
 1432   1454   
{
 1433   1455   
    /// Applies a [`Layer`](::tower::Layer) uniformly to all routes.
 1434   1456   
    #[deprecated(
 1435   1457   
        since = "0.57.0",
 1436   1458   
        note = "please add layers to the `ConfigConfig` object instead; see https://github.com/smithy-lang/smithy-rs/discussions/3096"
 1437   1459   
    )]
 1438   1460   
    pub fn layer<L>(
 1439   1461   
        self,
 1440   1462   
        layer: &L,
 1441   1463   
    ) -> Config<
 1442         -
        ::aws_smithy_http_server::routing::RoutingService<
 1443         -
            ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<L::Service>,
 1444         -
            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1464  +
        ::aws_smithy_legacy_http_server::routing::RoutingService<
        1465  +
            ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<L::Service>,
        1466  +
            ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1445   1467   
        >,
 1446   1468   
    >
 1447   1469   
    where
 1448   1470   
        L: ::tower::Layer<S>,
 1449   1471   
    {
 1450   1472   
        Config {
 1451   1473   
            svc: self.svc.map(|s| s.layer(layer)),
 1452   1474   
        }
 1453   1475   
    }
 1454   1476   
 1455         -
    /// Applies [`Route::new`](::aws_smithy_http_server::routing::Route::new) to all routes.
        1477  +
    /// Applies [`Route::new`](::aws_smithy_legacy_http_server::routing::Route::new) to all routes.
 1456   1478   
    ///
 1457   1479   
    /// This has the effect of erasing all types accumulated via layers.
 1458   1480   
    pub fn boxed<B>(
 1459   1481   
        self,
 1460   1482   
    ) -> Config<
 1461         -
        ::aws_smithy_http_server::routing::RoutingService<
 1462         -
            ::aws_smithy_http_server::protocol::aws_json::router::AwsJsonRouter<
 1463         -
                ::aws_smithy_http_server::routing::Route<B>,
        1483  +
        ::aws_smithy_legacy_http_server::routing::RoutingService<
        1484  +
            ::aws_smithy_legacy_http_server::protocol::aws_json::router::AwsJsonRouter<
        1485  +
                ::aws_smithy_legacy_http_server::routing::Route<B>,
 1464   1486   
            >,
 1465         -
            ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1,
        1487  +
            ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1,
 1466   1488   
        >,
 1467   1489   
    >
 1468   1490   
    where
 1469   1491   
        S: ::tower::Service<
 1470   1492   
            ::http::Request<B>,
 1471         -
            Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
        1493  +
            Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
 1472   1494   
            Error = std::convert::Infallible,
 1473   1495   
        >,
 1474   1496   
        S: Clone + Send + 'static,
 1475   1497   
        S::Future: Send + 'static,
 1476   1498   
    {
 1477   1499   
        self.layer(&::tower::layer::layer_fn(
 1478         -
            ::aws_smithy_http_server::routing::Route::new,
        1500  +
            ::aws_smithy_legacy_http_server::routing::Route::new,
 1479   1501   
        ))
 1480   1502   
    }
 1481   1503   
}
 1482   1504   
 1483   1505   
impl<S, R> ::tower::Service<R> for Config<S>
 1484   1506   
where
 1485   1507   
    S: ::tower::Service<R>,
 1486   1508   
{
 1487   1509   
    type Response = S::Response;
 1488   1510   
    type Error = S::Error;
 1489   1511   
    type Future = S::Future;
 1490   1512   
 1491   1513   
    fn poll_ready(
 1492   1514   
        &mut self,
 1493   1515   
        cx: &mut std::task::Context,
 1494   1516   
    ) -> std::task::Poll<::std::result::Result<(), Self::Error>> {
 1495   1517   
        self.svc.poll_ready(cx)
 1496   1518   
    }
 1497   1519   
 1498   1520   
    fn call(&mut self, request: R) -> Self::Future {
 1499   1521   
        self.svc.call(request)
 1500   1522   
    }
 1501   1523   
}
 1502   1524   
 1503   1525   
/// An enumeration of all [operations](https://smithy.io/2.0/spec/service-types.html#operation) in Config.
 1504   1526   
#[allow(clippy::enum_variant_names)]
 1505   1527   
#[derive(Debug, PartialEq, Eq, Clone, Copy)]
 1506   1528   
pub enum Operation {
 1507   1529   
    ErrCollisions,
 1508   1530   
    Match,
 1509   1531   
    Option,
 1510   1532   
    ReservedWordsAsMembers,
 1511   1533   
    Result,
 1512   1534   
    RpcEcho,
 1513   1535   
    StructureNamePunning,
 1514   1536   
}
 1515   1537   
 1516   1538   
impl Operation {
 1517         -
    /// Returns the [operations](https://smithy.io/2.0/spec/service-types.html#operation) [`ShapeId`](::aws_smithy_http_server::shape_id::ShapeId).
 1518         -
    pub fn shape_id(&self) -> ::aws_smithy_http_server::shape_id::ShapeId {
        1539  +
    /// Returns the [operations](https://smithy.io/2.0/spec/service-types.html#operation) [`ShapeId`](::aws_smithy_legacy_http_server::shape_id::ShapeId).
        1540  +
    pub fn shape_id(&self) -> ::aws_smithy_legacy_http_server::shape_id::ShapeId {
 1519   1541   
        match self {
 1520         -
            Operation::ErrCollisions => ::aws_smithy_http_server::shape_id::ShapeId::new(
        1542  +
            Operation::ErrCollisions => ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
 1521   1543   
                "crate#ErrCollisions",
 1522   1544   
                "crate",
 1523   1545   
                "ErrCollisions",
 1524   1546   
            ),
 1525         -
            Operation::Match => {
 1526         -
                ::aws_smithy_http_server::shape_id::ShapeId::new("crate#Match", "crate", "Match")
 1527         -
            }
 1528         -
            Operation::Option => {
 1529         -
                ::aws_smithy_http_server::shape_id::ShapeId::new("crate#Option", "crate", "Option")
 1530         -
            }
 1531         -
            Operation::ReservedWordsAsMembers => ::aws_smithy_http_server::shape_id::ShapeId::new(
 1532         -
                "crate#ReservedWordsAsMembers",
        1547  +
            Operation::Match => ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1548  +
                "crate#Match",
 1533   1549   
                "crate",
 1534         -
                "ReservedWordsAsMembers",
        1550  +
                "Match",
 1535   1551   
            ),
 1536         -
            Operation::Result => {
 1537         -
                ::aws_smithy_http_server::shape_id::ShapeId::new("crate#Result", "crate", "Result")
        1552  +
            Operation::Option => ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1553  +
                "crate#Option",
        1554  +
                "crate",
        1555  +
                "Option",
        1556  +
            ),
        1557  +
            Operation::ReservedWordsAsMembers => {
        1558  +
                ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1559  +
                    "crate#ReservedWordsAsMembers",
        1560  +
                    "crate",
        1561  +
                    "ReservedWordsAsMembers",
        1562  +
                )
 1538   1563   
            }
 1539         -
            Operation::RpcEcho => ::aws_smithy_http_server::shape_id::ShapeId::new(
 1540         -
                "crate#RPCEcho",
        1564  +
            Operation::Result => ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1565  +
                "crate#Result",
 1541   1566   
                "crate",
 1542         -
                "RPCEcho",
        1567  +
                "Result",
 1543   1568   
            ),
 1544         -
            Operation::StructureNamePunning => ::aws_smithy_http_server::shape_id::ShapeId::new(
 1545         -
                "crate#StructureNamePunning",
        1569  +
            Operation::RpcEcho => ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1570  +
                "crate#RPCEcho",
 1546   1571   
                "crate",
 1547         -
                "StructureNamePunning",
        1572  +
                "RPCEcho",
 1548   1573   
            ),
        1574  +
            Operation::StructureNamePunning => {
        1575  +
                ::aws_smithy_legacy_http_server::shape_id::ShapeId::new(
        1576  +
                    "crate#StructureNamePunning",
        1577  +
                    "crate",
        1578  +
                    "StructureNamePunning",
        1579  +
                )
        1580  +
            }
 1549   1581   
        }
 1550   1582   
    }
 1551   1583   
}
 1552         -
impl<L> ::aws_smithy_http_server::service::ContainsOperation<crate::operation_shape::ErrCollisions>
 1553         -
    for Config<L>
        1584  +
impl<L>
        1585  +
    ::aws_smithy_legacy_http_server::service::ContainsOperation<
        1586  +
        crate::operation_shape::ErrCollisions,
        1587  +
    > for Config<L>
 1554   1588   
{
 1555   1589   
    const VALUE: Operation = Operation::ErrCollisions;
 1556   1590   
}
 1557         -
impl<L> ::aws_smithy_http_server::service::ContainsOperation<crate::operation_shape::Match>
        1591  +
impl<L> ::aws_smithy_legacy_http_server::service::ContainsOperation<crate::operation_shape::Match>
 1558   1592   
    for Config<L>
 1559   1593   
{
 1560   1594   
    const VALUE: Operation = Operation::Match;
 1561   1595   
}
 1562         -
impl<L> ::aws_smithy_http_server::service::ContainsOperation<crate::operation_shape::Option>
        1596  +
impl<L> ::aws_smithy_legacy_http_server::service::ContainsOperation<crate::operation_shape::Option>
 1563   1597   
    for Config<L>
 1564   1598   
{
 1565   1599   
    const VALUE: Operation = Operation::Option;
 1566   1600   
}
 1567   1601   
impl<L>
 1568         -
    ::aws_smithy_http_server::service::ContainsOperation<
        1602  +
    ::aws_smithy_legacy_http_server::service::ContainsOperation<
 1569   1603   
        crate::operation_shape::ReservedWordsAsMembers,
 1570   1604   
    > for Config<L>
 1571   1605   
{
 1572   1606   
    const VALUE: Operation = Operation::ReservedWordsAsMembers;
 1573   1607   
}
 1574         -
impl<L> ::aws_smithy_http_server::service::ContainsOperation<crate::operation_shape::Result>
        1608  +
impl<L> ::aws_smithy_legacy_http_server::service::ContainsOperation<crate::operation_shape::Result>
 1575   1609   
    for Config<L>
 1576   1610   
{
 1577   1611   
    const VALUE: Operation = Operation::Result;
 1578   1612   
}
 1579         -
impl<L> ::aws_smithy_http_server::service::ContainsOperation<crate::operation_shape::RpcEcho>
        1613  +
impl<L> ::aws_smithy_legacy_http_server::service::ContainsOperation<crate::operation_shape::RpcEcho>
 1580   1614   
    for Config<L>
 1581   1615   
{
 1582   1616   
    const VALUE: Operation = Operation::RpcEcho;
 1583   1617   
}
 1584   1618   
impl<L>
 1585         -
    ::aws_smithy_http_server::service::ContainsOperation<
        1619  +
    ::aws_smithy_legacy_http_server::service::ContainsOperation<
 1586   1620   
        crate::operation_shape::StructureNamePunning,
 1587   1621   
    > for Config<L>
 1588   1622   
{
 1589   1623   
    const VALUE: Operation = Operation::StructureNamePunning;
 1590   1624   
}
 1591   1625   
 1592         -
impl<S> ::aws_smithy_http_server::service::ServiceShape for Config<S> {
 1593         -
    const ID: ::aws_smithy_http_server::shape_id::ShapeId =
 1594         -
        ::aws_smithy_http_server::shape_id::ShapeId::new("crate#Config", "crate", "Config");
        1626  +
impl<S> ::aws_smithy_legacy_http_server::service::ServiceShape for Config<S> {
        1627  +
    const ID: ::aws_smithy_legacy_http_server::shape_id::ShapeId =
        1628  +
        ::aws_smithy_legacy_http_server::shape_id::ShapeId::new("crate#Config", "crate", "Config");
 1595   1629   
 1596   1630   
    const VERSION: Option<&'static str> = Some("2006-03-01");
 1597   1631   
 1598         -
    type Protocol = ::aws_smithy_http_server::protocol::aws_json_11::AwsJson1_1;
        1632  +
    type Protocol = ::aws_smithy_legacy_http_server::protocol::aws_json_11::AwsJson1_1;
 1599   1633   
 1600   1634   
    type Operations = Operation;
 1601   1635   
}
 1602   1636   
/// Configuration for the [`Config`]. This is the central place where to register and
 1603   1637   
/// configure [`::tower::Layer`]s, HTTP plugins, and model plugins.
 1604   1638   
///
 1605   1639   
/// ```rust,no_run
 1606   1640   
/// # use naming_test_ops::ConfigConfig;
 1607         -
/// # use ::aws_smithy_http_server::plugin::IdentityPlugin;
        1641  +
/// # use ::aws_smithy_legacy_http_server::plugin::IdentityPlugin;
 1608   1642   
/// # use ::tower::layer::util::Identity;
 1609   1643   
/// # let authentication_plugin = IdentityPlugin;
 1610   1644   
/// # let authorization_plugin = IdentityPlugin;
 1611   1645   
/// # let server_request_id_provider_layer = Identity::new();
 1612   1646   
/// let config = ConfigConfig::builder()
 1613   1647   
///     // Layers get executed first...
 1614   1648   
///     .layer(server_request_id_provider_layer)
 1615   1649   
///     // ...then HTTP plugins...
 1616   1650   
///     .http_plugin(authentication_plugin)
 1617   1651   
///     // ...and right after deserialization, model plugins.
 1618   1652   
///     .model_plugin(authorization_plugin)
 1619   1653   
///     .build();
 1620   1654   
/// ```
 1621   1655   
///
 1622   1656   
/// See the [`plugin`] system for details.
 1623   1657   
///
 1624         -
/// [`plugin`]: ::aws_smithy_http_server::plugin
        1658  +
/// [`plugin`]: ::aws_smithy_legacy_http_server::plugin
 1625   1659   
#[derive(::std::fmt::Debug)]
 1626   1660   
pub struct ConfigConfig<L, H, M> {
 1627   1661   
    layers: L,
 1628   1662   
    http_plugins: H,
 1629   1663   
    model_plugins: M,
 1630   1664   
}
 1631   1665   
 1632   1666   
impl ConfigConfig<(), (), ()> {
 1633   1667   
    /// Returns a builder to construct the configuration.
 1634   1668   
    pub fn builder() -> ConfigConfigBuilder<
 1635   1669   
        ::tower::layer::util::Identity,
 1636         -
        ::aws_smithy_http_server::plugin::IdentityPlugin,
 1637         -
        ::aws_smithy_http_server::plugin::IdentityPlugin,
        1670  +
        ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
        1671  +
        ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
 1638   1672   
    > {
 1639   1673   
        ConfigConfigBuilder {
 1640   1674   
            layers: ::tower::layer::util::Identity::new(),
 1641         -
            http_plugins: ::aws_smithy_http_server::plugin::IdentityPlugin,
 1642         -
            model_plugins: ::aws_smithy_http_server::plugin::IdentityPlugin,
        1675  +
            http_plugins: ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
        1676  +
            model_plugins: ::aws_smithy_legacy_http_server::plugin::IdentityPlugin,
 1643   1677   
        }
 1644   1678   
    }
 1645   1679   
}
 1646   1680   
 1647   1681   
/// Builder returned by [`ConfigConfig::builder()`].
 1648   1682   
#[derive(::std::fmt::Debug)]
 1649   1683   
pub struct ConfigConfigBuilder<L, H, M> {
 1650   1684   
    pub(crate) layers: L,
 1651   1685   
    pub(crate) http_plugins: H,
 1652   1686   
    pub(crate) model_plugins: M,
 1653   1687   
}
 1654   1688   
 1655   1689   
impl<L, H, M> ConfigConfigBuilder<L, H, M> {
 1656   1690   
    /// Add a [`::tower::Layer`] to the service.
 1657   1691   
    pub fn layer<NewLayer>(
 1658   1692   
        self,
 1659   1693   
        layer: NewLayer,
 1660   1694   
    ) -> ConfigConfigBuilder<::tower::layer::util::Stack<NewLayer, L>, H, M> {
 1661   1695   
        ConfigConfigBuilder {
 1662   1696   
            layers: ::tower::layer::util::Stack::new(layer, self.layers),
 1663   1697   
            http_plugins: self.http_plugins,
 1664   1698   
            model_plugins: self.model_plugins,
 1665   1699   
        }
 1666   1700   
    }
 1667   1701   
 1668   1702   
    /// Add a HTTP [plugin] to the service.
 1669   1703   
    ///
 1670         -
    /// [plugin]: ::aws_smithy_http_server::plugin
        1704  +
    /// [plugin]: ::aws_smithy_legacy_http_server::plugin
 1671   1705   
    // We eagerly require `NewPlugin: HttpMarker`, despite not really needing it, because compiler
 1672   1706   
    // errors get _substantially_ better if the user makes a mistake.
 1673         -
    pub fn http_plugin<NewPlugin: ::aws_smithy_http_server::plugin::HttpMarker>(
        1707  +
    pub fn http_plugin<NewPlugin: ::aws_smithy_legacy_http_server::plugin::HttpMarker>(
 1674   1708   
        self,
 1675   1709   
        http_plugin: NewPlugin,
 1676         -
    ) -> ConfigConfigBuilder<L, ::aws_smithy_http_server::plugin::PluginStack<NewPlugin, H>, M>
        1710  +
    ) -> ConfigConfigBuilder<L, ::aws_smithy_legacy_http_server::plugin::PluginStack<NewPlugin, H>, M>
 1677   1711   
    {
 1678   1712   
        ConfigConfigBuilder {
 1679   1713   
            layers: self.layers,
 1680         -
            http_plugins: ::aws_smithy_http_server::plugin::PluginStack::new(
        1714  +
            http_plugins: ::aws_smithy_legacy_http_server::plugin::PluginStack::new(
 1681   1715   
                http_plugin,
 1682   1716   
                self.http_plugins,
 1683   1717   
            ),
 1684   1718   
            model_plugins: self.model_plugins,
 1685   1719   
        }
 1686   1720   
    }
 1687   1721   
 1688   1722   
    /// Add a model [plugin] to the service.
 1689   1723   
    ///
 1690         -
    /// [plugin]: ::aws_smithy_http_server::plugin
        1724  +
    /// [plugin]: ::aws_smithy_legacy_http_server::plugin
 1691   1725   
    // We eagerly require `NewPlugin: ModelMarker`, despite not really needing it, because compiler
 1692   1726   
    // errors get _substantially_ better if the user makes a mistake.
 1693         -
    pub fn model_plugin<NewPlugin: ::aws_smithy_http_server::plugin::ModelMarker>(
        1727  +
    pub fn model_plugin<NewPlugin: ::aws_smithy_legacy_http_server::plugin::ModelMarker>(
 1694   1728   
        self,
 1695   1729   
        model_plugin: NewPlugin,
 1696         -
    ) -> ConfigConfigBuilder<L, H, ::aws_smithy_http_server::plugin::PluginStack<NewPlugin, M>>
        1730  +
    ) -> ConfigConfigBuilder<L, H, ::aws_smithy_legacy_http_server::plugin::PluginStack<NewPlugin, M>>
 1697   1731   
    {
 1698   1732   
        ConfigConfigBuilder {
 1699   1733   
            layers: self.layers,
 1700   1734   
            http_plugins: self.http_plugins,
 1701         -
            model_plugins: ::aws_smithy_http_server::plugin::PluginStack::new(
        1735  +
            model_plugins: ::aws_smithy_legacy_http_server::plugin::PluginStack::new(
 1702   1736   
                model_plugin,
 1703   1737   
                self.model_plugins,
 1704   1738   
            ),
 1705   1739   
        }
 1706   1740   
    }
 1707   1741   
 1708   1742   
    /// Build the configuration.
 1709   1743   
    pub fn build(self) -> super::ConfigConfig<L, H, M> {
 1710   1744   
        super::ConfigConfig {
 1711   1745   
            layers: self.layers,