Server Test

Server Test

rev. 3c756f73b1f83a0eed4275d9d1e22df0b10b66fb (ignoring whitespace)

Files changed:

tmp-codegen-diff/codegen-server-test/rpcv2Cbor-http0x/rust-server-codegen/src/types.rs

@@ -0,1 +0,5 @@
           1  +
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
pub use ::aws_smithy_types::date_time::Format as DateTimeFormat;
           3  +
pub use ::aws_smithy_types::error::display::DisplayErrorContext;
           4  +
pub use ::aws_smithy_types::Blob;
           5  +
pub use ::aws_smithy_types::DateTime;

tmp-codegen-diff/codegen-server-test/rpcv2Cbor-http0x/rust-server-codegen/src/unconstrained.rs

@@ -0,1 +0,152 @@
           1  +
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
           2  +
           3  +
pub(crate) mod sparse_set_map_unconstrained {
           4  +
           5  +
    #[derive(Debug, Clone)]
           6  +
    pub(crate) struct SparseSetMapUnconstrained(
           7  +
        pub(crate)  std::collections::HashMap<
           8  +
            ::std::string::String,
           9  +
            ::std::option::Option<
          10  +
                crate::unconstrained::string_set_unconstrained::StringSetUnconstrained,
          11  +
            >,
          12  +
        >,
          13  +
    );
          14  +
          15  +
    impl From<SparseSetMapUnconstrained>
          16  +
        for crate::constrained::MaybeConstrained<
          17  +
            crate::constrained::sparse_set_map_constrained::SparseSetMapConstrained,
          18  +
        >
          19  +
    {
          20  +
        fn from(value: SparseSetMapUnconstrained) -> Self {
          21  +
            Self::Unconstrained(value)
          22  +
        }
          23  +
    }
          24  +
    impl std::convert::TryFrom<SparseSetMapUnconstrained>
          25  +
        for crate::constrained::sparse_set_map_constrained::SparseSetMapConstrained
          26  +
    {
          27  +
        type Error = crate::model::sparse_set_map::ConstraintViolation;
          28  +
        fn try_from(value: SparseSetMapUnconstrained) -> std::result::Result<Self, Self::Error> {
          29  +
            let res: ::std::result::Result<
          30  +
                ::std::collections::HashMap<
          31  +
                    ::std::string::String,
          32  +
                    ::std::option::Option<crate::model::StringSet>,
          33  +
                >,
          34  +
                Self::Error,
          35  +
            > = value
          36  +
                .0
          37  +
                .into_iter()
          38  +
                .map(|(k, v)| match v {
          39  +
                    None => Ok((k, None)),
          40  +
                    Some(v) => match crate::model::StringSet::try_from(v) {
          41  +
                        Ok(v) => Ok((k, Some(v))),
          42  +
                        Err(inner_constraint_violation) => {
          43  +
                            Err(Self::Error::Value(k, inner_constraint_violation))
          44  +
                        }
          45  +
                    },
          46  +
                })
          47  +
                .collect();
          48  +
            let hm = res?;
          49  +
            Ok(Self(hm))
          50  +
        }
          51  +
    }
          52  +
}
          53  +
pub(crate) mod string_set_unconstrained {
          54  +
          55  +
    #[derive(Debug, Clone)]
          56  +
    pub(crate) struct StringSetUnconstrained(pub(crate) std::vec::Vec<::std::string::String>);
          57  +
          58  +
    impl From<StringSetUnconstrained>
          59  +
        for crate::constrained::MaybeConstrained<crate::model::StringSet>
          60  +
    {
          61  +
        fn from(value: StringSetUnconstrained) -> Self {
          62  +
            Self::Unconstrained(value)
          63  +
        }
          64  +
    }
          65  +
    impl std::convert::TryFrom<StringSetUnconstrained> for crate::model::StringSet {
          66  +
        type Error = crate::model::string_set::ConstraintViolation;
          67  +
        fn try_from(value: StringSetUnconstrained) -> std::result::Result<Self, Self::Error> {
          68  +
            let inner = value.0;
          69  +
            Self::try_from(inner)
          70  +
        }
          71  +
    }
          72  +
}
          73  +
pub(crate) mod dense_set_map_unconstrained {
          74  +
          75  +
    #[derive(Debug, Clone)]
          76  +
    pub(crate) struct DenseSetMapUnconstrained(
          77  +
        pub(crate)  std::collections::HashMap<
          78  +
            ::std::string::String,
          79  +
            crate::unconstrained::string_set_unconstrained::StringSetUnconstrained,
          80  +
        >,
          81  +
    );
          82  +
          83  +
    impl From<DenseSetMapUnconstrained>
          84  +
        for crate::constrained::MaybeConstrained<
          85  +
            crate::constrained::dense_set_map_constrained::DenseSetMapConstrained,
          86  +
        >
          87  +
    {
          88  +
        fn from(value: DenseSetMapUnconstrained) -> Self {
          89  +
            Self::Unconstrained(value)
          90  +
        }
          91  +
    }
          92  +
    impl std::convert::TryFrom<DenseSetMapUnconstrained>
          93  +
        for crate::constrained::dense_set_map_constrained::DenseSetMapConstrained
          94  +
    {
          95  +
        type Error = crate::model::dense_set_map::ConstraintViolation;
          96  +
        fn try_from(value: DenseSetMapUnconstrained) -> std::result::Result<Self, Self::Error> {
          97  +
            let res: ::std::result::Result<
          98  +
                ::std::collections::HashMap<::std::string::String, crate::model::StringSet>,
          99  +
                Self::Error,
         100  +
            > = value
         101  +
                .0
         102  +
                .into_iter()
         103  +
                .map(|(k, v)| match crate::model::StringSet::try_from(v) {
         104  +
                    Ok(v) => Ok((k, v)),
         105  +
                    Err(inner_constraint_violation) => {
         106  +
                        Err(Self::Error::Value(k, inner_constraint_violation))
         107  +
                    }
         108  +
                })
         109  +
                .collect();
         110  +
            let hm = res?;
         111  +
            Ok(Self(hm))
         112  +
        }
         113  +
    }
         114  +
}
         115  +
pub(crate) mod foo_enum_list_unconstrained {
         116  +
         117  +
    #[derive(Debug, Clone)]
         118  +
    pub(crate) struct FooEnumListUnconstrained(pub(crate) std::vec::Vec<::std::string::String>);
         119  +
         120  +
    impl From<FooEnumListUnconstrained>
         121  +
        for crate::constrained::MaybeConstrained<
         122  +
            crate::constrained::foo_enum_list_constrained::FooEnumListConstrained,
         123  +
        >
         124  +
    {
         125  +
        fn from(value: FooEnumListUnconstrained) -> Self {
         126  +
            Self::Unconstrained(value)
         127  +
        }
         128  +
    }
         129  +
    impl std::convert::TryFrom<FooEnumListUnconstrained>
         130  +
        for crate::constrained::foo_enum_list_constrained::FooEnumListConstrained
         131  +
    {
         132  +
        type Error = crate::model::foo_enum_list::ConstraintViolation;
         133  +
        fn try_from(value: FooEnumListUnconstrained) -> std::result::Result<Self, Self::Error> {
         134  +
            let res: ::std::result::Result<
         135  +
                ::std::vec::Vec<crate::model::FooEnum>,
         136  +
                (usize, crate::model::foo_enum::ConstraintViolation),
         137  +
            > = value
         138  +
                .0
         139  +
                .into_iter()
         140  +
                .enumerate()
         141  +
                .map(|(idx, inner)| {
         142  +
                    inner
         143  +
                        .try_into()
         144  +
                        .map_err(|inner_violation| (idx, inner_violation))
         145  +
                })
         146  +
                .collect();
         147  +
            let inner =
         148  +
                res.map_err(|(idx, inner_violation)| Self::Error::Member(idx, inner_violation))?;
         149  +
            Ok(Self(inner))
         150  +
        }
         151  +
    }
         152  +
}

tmp-codegen-diff/codegen-server-test/rpcv2Cbor/rust-server-codegen/Cargo.toml

@@ -1,1 +56,60 @@
   10     10   
codegen-version = "ci"
   11     11   
protocol = "smithy.protocols#rpcv2Cbor"
   12     12   
[dependencies.aws-smithy-cbor]
   13     13   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-cbor"
   14     14   
[dependencies.aws-smithy-http]
   15     15   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-http"
   16     16   
[dependencies.aws-smithy-http-server]
   17     17   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-http-server"
   18     18   
[dependencies.aws-smithy-runtime-api]
   19     19   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-runtime-api"
          20  +
features = ["http-1x"]
   20     21   
[dependencies.aws-smithy-types]
   21     22   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-types"
          23  +
features = ["http-body-1-x"]
   22     24   
[dependencies.futures-util]
   23     25   
version = "0.3"
   24         -
[dependencies.http]
   25         -
version = "0.2.9"
   26         -
[dependencies.hyper]
   27         -
version = "0.14.26"
          26  +
[dependencies.http-1x]
          27  +
version = "1"
          28  +
package = "http"
          29  +
[dependencies.http-body-util]
          30  +
version = "0.1.3"
   28     31   
[dependencies.mime]
   29     32   
version = "0.3"
   30     33   
[dependencies.pin-project-lite]
   31     34   
version = "0.2"
   32     35   
[dependencies.tower]
   33     36   
version = "0.4"
   34     37   
[dependencies.tracing]
   35     38   
version = "0.1"
   36     39   
[dev-dependencies.aws-smithy-protocol-test]
   37     40   
path = "/home/build/workspace/smithy-rs/rust-runtime/aws-smithy-protocol-test"
          41  +
features = ["http-1x"]
   38     42   
[dev-dependencies.bytes]
   39     43   
version = "1.4.0"
   40     44   
[dev-dependencies.hyper]
   41         -
version = "0.14.12"
          45  +
version = "1"
   42     46   
[dev-dependencies.pretty_assertions]
   43     47   
version = "1.3.0"
   44     48   
[dev-dependencies.tokio]
   45     49   
version = "1.23.1"
   46     50   
features = ["macros", "test-util", "rt-multi-thread"]
   47     51   
[dev-dependencies.tracing-test]
   48     52   
version = "0.2.5"
   49     53   
features = ["no-env-filter"]
   50     54   
[features]
   51     55   
rt-tokio = ["aws-smithy-types/rt-tokio"]

tmp-codegen-diff/codegen-server-test/rpcv2Cbor/rust-server-codegen/src/lib.rs

@@ -19,19 +128,131 @@
   39     39   
)]
   40     40   
//! The [`crate::input`], [`crate::output`], and [`crate::error`]
   41     41   
//! modules provide the types used in each operation.
   42     42   
//!
   43     43   
//! ### Running on Hyper
   44     44   
//!
   45     45   
//! ```rust,no_run
   46     46   
//! # use std::net::SocketAddr;
   47     47   
//! # async fn dummy() {
   48     48   
//! use rpcv2cbor::{RpcV2Protocol, RpcV2ProtocolConfig};
          49  +
//! use rpcv2cbor::serve;
          50  +
//! use ::tokio::net::TcpListener;
   49     51   
//!
   50     52   
//! # let app = RpcV2Protocol::builder(
   51     53   
//! #     RpcV2ProtocolConfig::builder()
   52     54   
//! #         .build()
   53     55   
//! # ).build_unchecked();
   54         -
//! let server = app.into_make_service();
   55     56   
//! let bind: SocketAddr = "127.0.0.1:6969".parse()
   56     57   
//!     .expect("unable to parse the server bind address and port");
   57         -
//! ::hyper::Server::bind(&bind).serve(server).await.unwrap();
          58  +
//! let listener = TcpListener::bind(bind).await
          59  +
//!     .expect("failed to bind TCP listener");
          60  +
//! serve(listener, app.into_make_service()).await.unwrap();
   58     61   
//! # }
   59     62   
//! ```
   60     63   
//!
   61     64   
//! ### Running on Lambda
   62     65   
//!
   63     66   
//! ```rust,ignore
   64     67   
//! use rpcv2cbor::server::routing::LambdaHandler;
   65     68   
//! use rpcv2cbor::RpcV2Protocol;
   66     69   
//!
   67     70   
//! # async fn dummy() {
   68     71   
//! # let app = RpcV2Protocol::builder(
   69     72   
//! #     RpcV2ProtocolConfig::builder()
   70     73   
//! #         .build()
   71     74   
//! # ).build_unchecked();
   72     75   
//! let handler = LambdaHandler::new(app);
   73     76   
//! lambda_http::run(handler).await.unwrap();
   74     77   
//! # }
   75     78   
//! ```
   76     79   
//!
   77     80   
//! # Building the RpcV2Protocol
   78     81   
//!
   79     82   
//! To construct [`RpcV2Protocol`] we use [`RpcV2ProtocolBuilder`] returned by [`RpcV2Protocol::builder`].
   80     83   
//!
   81     84   
//! ## Plugins
   82     85   
//!
   83     86   
//! The [`RpcV2Protocol::builder`] method, returning [`RpcV2ProtocolBuilder`],
   84     87   
//! accepts a config object on which plugins can be registered.
   85     88   
//! Plugins allow you to build middleware which is aware of the operation it is being applied to.
   86     89   
//!
   87     90   
//! ```rust,no_run
   88     91   
//! # use rpcv2cbor::server::plugin::IdentityPlugin as LoggingPlugin;
   89     92   
//! # use rpcv2cbor::server::plugin::IdentityPlugin as MetricsPlugin;
   90         -
//! # use ::hyper::Body;
          93  +
//! # use ::hyper::body::Incoming;
   91     94   
//! use rpcv2cbor::server::plugin::HttpPlugins;
   92     95   
//! use rpcv2cbor::{RpcV2Protocol, RpcV2ProtocolConfig, RpcV2ProtocolBuilder};
   93     96   
//!
   94     97   
//! let http_plugins = HttpPlugins::new()
   95     98   
//!         .push(LoggingPlugin)
   96     99   
//!         .push(MetricsPlugin);
   97    100   
//! let config = RpcV2ProtocolConfig::builder().build();
   98         -
//! let builder: RpcV2ProtocolBuilder<Body, _, _, _> = RpcV2Protocol::builder(config);
         101  +
//! let builder: RpcV2ProtocolBuilder<::hyper::body::Incoming, _, _, _> = RpcV2Protocol::builder(config);
   99    102   
//! ```
  100    103   
//!
  101    104   
//! Check out [`crate::server::plugin`] to learn more about plugins.
  102    105   
//!
  103    106   
//! ## Handlers
  104    107   
//!
  105    108   
//! [`RpcV2ProtocolBuilder`] provides a setter method for each operation in your Smithy model. The setter methods expect an async function as input, matching the signature for the corresponding operation in your Smithy model.
  106    109   
//! We call these async functions **handlers**. This is where your application business logic lives.
  107    110   
//!
  108    111   
//! Every handler must take an `Input`, and optional [`extractor arguments`](crate::server::request), while returning:
@@ -135,138 +288,295 @@
  155    158   
//! [`RpcV2ProtocolBuilder::build`] requires you to provide a handler for every single operation in your Smithy model. It will return an error if that is not the case.
  156    159   
//!
  157    160   
//! [`RpcV2ProtocolBuilder::build_unchecked`], instead, does not require exhaustiveness. The server will automatically return 500 Internal Server Error to all requests for operations that do not have a registered handler.
  158    161   
//! [`RpcV2ProtocolBuilder::build_unchecked`] is particularly useful if you are deploying your Smithy service as a collection of Lambda functions, where each Lambda is only responsible for a subset of the operations in the Smithy service (or even a single one!).
  159    162   
//!
  160    163   
//! # Example
  161    164   
//!
  162    165   
//! ```rust,no_run
  163    166   
//! # use std::net::SocketAddr;
  164    167   
//! use rpcv2cbor::{RpcV2Protocol, RpcV2ProtocolConfig};
         168  +
//! use rpcv2cbor::serve;
         169  +
//! use ::tokio::net::TcpListener;
  165    170   
//!
  166    171   
//! #[::tokio::main]
  167    172   
//! pub async fn main() {
  168    173   
//!    let config = RpcV2ProtocolConfig::builder().build();
  169    174   
//!    let app = RpcV2Protocol::builder(config)
  170    175   
//!        .empty_input_output(empty_input_output)
  171    176   
//!        .float16(float16)
  172    177   
//!        .fractional_seconds(fractional_seconds)
  173    178   
//!        .greeting_with_errors(greeting_with_errors)
  174    179   
//!        .no_input_output(no_input_output)
  175    180   
//!        .operation_with_defaults(operation_with_defaults)
  176    181   
//!        .optional_input_output(optional_input_output)
  177    182   
//!        .recursive_shapes(recursive_shapes)
  178    183   
//!        .rpc_v2_cbor_dense_maps(rpc_v2_cbor_dense_maps)
  179    184   
//!        .rpc_v2_cbor_lists(rpc_v2_cbor_lists)
  180    185   
//!        .rpc_v2_cbor_sparse_maps(rpc_v2_cbor_sparse_maps)
  181    186   
//!        .simple_scalar_properties(simple_scalar_properties)
  182    187   
//!        .sparse_nulls_operation(sparse_nulls_operation)
  183    188   
//!        .build()
  184    189   
//!        .expect("failed to build an instance of RpcV2Protocol");
  185    190   
//!
  186    191   
//!    let bind: SocketAddr = "127.0.0.1:6969".parse()
  187    192   
//!        .expect("unable to parse the server bind address and port");
  188         -
//!    let server = ::hyper::Server::bind(&bind).serve(app.into_make_service());
         193  +
//!    let listener = TcpListener::bind(bind).await
         194  +
//!        .expect("failed to bind TCP listener");
  189    195   
//!    # let server = async { Ok::<_, ()>(()) };
  190    196   
//!
  191    197   
//!    // Run your service!
  192         -
//!    if let Err(err) = server.await {
         198  +
//!    if let Err(err) = serve(listener, app.into_make_service()).await {
  193    199   
//!        eprintln!("server error: {:?}", err);
  194    200   
//!    }
  195    201   
//! }
  196    202   
//!
  197    203   
//! use rpcv2cbor::{input, output, error};
  198    204   
//!
  199    205   
//! async fn empty_input_output(input: input::EmptyInputOutputInput) -> output::EmptyInputOutputOutput {
  200    206   
//!     todo!()
  201    207   
//! }
  202    208   
//!
  203    209   
//! async fn float16(input: input::Float16Input) -> output::Float16Output {
  204    210   
//!     todo!()
  205    211   
//! }
  206    212   
//!
  207    213   
//! async fn fractional_seconds(input: input::FractionalSecondsInput) -> output::FractionalSecondsOutput {
  208    214   
//!     todo!()
  209    215   
//! }
  210    216   
//!
  211    217   
//! async fn greeting_with_errors(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
  212    218   
//!     todo!()
  213    219   
//! }
  214    220   
//!
  215    221   
//! async fn no_input_output(input: input::NoInputOutputInput) -> output::NoInputOutputOutput {
  216    222   
//!     todo!()
  217    223   
//! }
  218    224   
//!
  219    225   
//! async fn operation_with_defaults(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
  220    226   
//!     todo!()
  221    227   
//! }
  222    228   
//!
  223    229   
//! async fn optional_input_output(input: input::OptionalInputOutputInput) -> output::OptionalInputOutputOutput {
  224    230   
//!     todo!()
  225    231   
//! }
  226    232   
//!
  227    233   
//! async fn recursive_shapes(input: input::RecursiveShapesInput) -> output::RecursiveShapesOutput {
  228    234   
//!     todo!()
  229    235   
//! }
  230    236   
//!
  231    237   
//! async fn rpc_v2_cbor_dense_maps(input: input::RpcV2CborDenseMapsInput) -> Result<output::RpcV2CborDenseMapsOutput, error::RpcV2CborDenseMapsError> {
  232    238   
//!     todo!()
  233    239   
//! }
  234    240   
//!
  235    241   
//! async fn rpc_v2_cbor_lists(input: input::RpcV2CborListsInput) -> Result<output::RpcV2CborListsOutput, error::RpcV2CborListsError> {
  236    242   
//!     todo!()
  237    243   
//! }
  238    244   
//!
  239    245   
//! async fn rpc_v2_cbor_sparse_maps(input: input::RpcV2CborSparseMapsInput) -> Result<output::RpcV2CborSparseMapsOutput, error::RpcV2CborSparseMapsError> {
  240    246   
//!     todo!()
  241    247   
//! }
  242    248   
//!
  243    249   
//! async fn simple_scalar_properties(input: input::SimpleScalarPropertiesInput) -> output::SimpleScalarPropertiesOutput {
  244    250   
//!     todo!()
  245    251   
//! }
  246    252   
//!
  247    253   
//! async fn sparse_nulls_operation(input: input::SparseNullsOperationInput) -> output::SparseNullsOperationOutput {
  248    254   
//!     todo!()
  249    255   
//! }
  250    256   
//!
  251    257   
//! ```
  252    258   
//!
  253         -
//! [`serve`]: https://docs.rs/hyper/0.14.16/hyper/server/struct.Builder.html#method.serve
         259  +
//! [`serve`]: crate::serve
         260  +
//! [hyper server]: https://docs.rs/hyper/latest/hyper/server/index.html
  254    261   
//! [`tower::make::MakeService`]: https://docs.rs/tower/latest/tower/make/trait.MakeService.html
  255    262   
//! [HTTP binding traits]: https://smithy.io/2.0/spec/http-bindings.html
  256    263   
//! [operations]: https://smithy.io/2.0/spec/service-types.html#operation
  257         -
//! [hyper server]: https://docs.rs/hyper/latest/hyper/server/index.html
  258    264   
//! [Service]: https://docs.rs/tower-service/latest/tower_service/trait.Service.html
         265  +
pub use crate::server::serve::serve;
  259    266   
pub use crate::service::{
  260    267   
    MissingOperationsError, RpcV2Protocol, RpcV2ProtocolBuilder, RpcV2ProtocolConfig,
  261    268   
    RpcV2ProtocolConfigBuilder,
  262    269   
};
  263    270   
  264    271   
/// Contains the types that are re-exported from the `aws-smithy-http-server` crate.
  265    272   
pub mod server {
  266    273   
    // Re-export all types from the `aws-smithy-http-server` crate.
  267    274   
    pub use ::aws_smithy_http_server::*;
  268    275   
}

tmp-codegen-diff/codegen-server-test/rpcv2Cbor/rust-server-codegen/src/operation.rs

@@ -11,11 +71,71 @@
   31     31   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
   32     32   
    B: 'static,
   33     33   
   34     34   
    B::Data: Send,
   35     35   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
   36     36   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
   37     37   
{
   38     38   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
   39     39   
    type Future = Float16InputFuture;
   40     40   
   41         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
          41  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
   42     42   
        let fut = async move {
   43     43   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
   44     44   
                request.headers(),
   45     45   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
   46     46   
            ) {
   47     47   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
   48     48   
            }
   49     49   
            crate::protocol_serde::shape_float16::de_float16_http_request(request).await
   50     50   
        };
   51     51   
        use ::futures_util::future::TryFutureExt;
@@ -90,90 +417,437 @@
  110    110   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
  111    111   
    B: 'static,
  112    112   
  113    113   
    B::Data: Send,
  114    114   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
  115    115   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
  116    116   
{
  117    117   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
  118    118   
    type Future = SparseNullsOperationInputFuture;
  119    119   
  120         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
         120  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
  121    121   
        let fut = async move {
  122    122   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
  123    123   
                request.headers(),
  124    124   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
  125    125   
            ) {
  126    126   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
  127    127   
            }
  128    128   
            crate::protocol_serde::shape_sparse_nulls_operation::de_sparse_nulls_operation_http_request(request)
  129    129   
                            .await
  130    130   
        };
  131    131   
        use ::futures_util::future::TryFutureExt;
  132    132   
        let fut = fut.map_err(
  133    133   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
  134    134   
                ::tracing::debug!(error = %e, "failed to deserialize request");
  135    135   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
  136    136   
                    e,
  137    137   
                )
  138    138   
            },
  139    139   
        );
  140    140   
        SparseNullsOperationInputFuture {
  141    141   
            inner: Box::pin(fut),
  142    142   
        }
  143    143   
    }
  144    144   
}
  145    145   
impl
  146    146   
    ::aws_smithy_http_server::response::IntoResponse<
  147    147   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
  148    148   
    > for crate::output::SparseNullsOperationOutput
  149    149   
{
  150    150   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
  151    151   
        match crate::protocol_serde::shape_sparse_nulls_operation::ser_sparse_nulls_operation_http_response(self) {
  152    152   
                        Ok(response) => response,
  153    153   
                        Err(e) => {
  154    154   
                            ::tracing::error!(error = %e, "failed to serialize response");
  155    155   
                            ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
  156    156   
                        }
  157    157   
                    }
  158    158   
    }
  159    159   
}
  160    160   
  161    161   
#[allow(unreachable_code, unused_variables)]
  162    162   
#[cfg(test)]
  163    163   
mod sparse_nulls_operation_test {
  164    164   
  165    165   
    /// Serializes null values in maps
  166    166   
    /// Test ID: RpcV2CborSparseMapsSerializeNullValues
  167    167   
    #[::tokio::test]
  168    168   
    #[::tracing_test::traced_test]
  169    169   
    async fn rpc_v2_cbor_sparse_maps_serialize_null_values_request() {
  170    170   
        #[allow(unused_mut)]
  171         -
        let mut http_request = http::Request::builder()
         171  +
        let mut http_request = ::http_1x::Request::builder()
  172    172   
            .uri("/service/RpcV2Protocol/operation/SparseNullsOperation")
  173    173   
            .method("POST")
  174    174   
            .header("Accept", "application/cbor")
  175    175   
            .header("Content-Type", "application/cbor")
  176    176   
            .header("smithy-protocol", "rpc-v2-cbor")
  177         -
            .body(::aws_smithy_http_server::body::Body::from(
  178         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
         177  +
            .body(::aws_smithy_http_server::body::boxed(
         178  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
         179  +
                    &::aws_smithy_protocol_test::decode_body_data(
  179    180   
                        "v29zcGFyc2VTdHJpbmdNYXC/Y2Zvb/b//w==".as_bytes(),
  180    181   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
         182  +
                    ),
  181    183   
                )),
  182    184   
            ))
  183    185   
            .unwrap();
  184    186   
        #[allow(unused_mut)]
  185    187   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
  186    188   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
  187         -
        let service =
  188         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
         189  +
        let service = crate::service::RpcV2Protocol::builder::<
         190  +
            ::aws_smithy_http_server::body::BoxBody,
         191  +
            _,
         192  +
            _,
         193  +
            _,
         194  +
        >(config)
  189    195   
        .sparse_nulls_operation(move |input: crate::input::SparseNullsOperationInput| {
  190    196   
            let sender = sender.clone();
  191    197   
            async move {
  192    198   
                let result = {
  193    199   
                    let expected = crate::input::SparseNullsOperationInput {
  194    200   
                        sparse_string_map: ::std::option::Option::Some({
  195    201   
                            let mut ret = ::std::collections::HashMap::new();
  196    202   
                            ret.insert("foo".to_owned(), ::std::option::Option::None);
  197    203   
                            ret
  198    204   
                        }),
  199    205   
                        sparse_string_list: ::std::option::Option::None,
  200    206   
                    };
  201    207   
                    ::pretty_assertions::assert_eq!(input, expected);
  202    208   
                    let output = crate::output::SparseNullsOperationOutput {
  203    209   
                        sparse_string_list: ::std::option::Option::None,
  204    210   
                        sparse_string_map: ::std::option::Option::None,
  205    211   
                    };
  206    212   
                    output
  207    213   
                };
  208    214   
                sender.send(()).await.expect("receiver dropped early");
  209    215   
                result
  210    216   
            }
  211    217   
        })
  212    218   
        .build_unchecked();
  213    219   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
  214    220   
            .await
  215    221   
            .expect("unable to make an HTTP request");
  216    222   
        assert!(
  217    223   
            receiver.recv().await.is_some(),
  218    224   
            "we expected operation handler to be invoked but it was not entered"
  219    225   
        );
  220    226   
    }
  221    227   
  222    228   
    /// Serializes null values in lists
  223    229   
    /// Test ID: RpcV2CborSparseListsSerializeNull
  224    230   
    #[::tokio::test]
  225    231   
    #[::tracing_test::traced_test]
  226    232   
    async fn rpc_v2_cbor_sparse_lists_serialize_null_request() {
  227    233   
        #[allow(unused_mut)]
  228         -
        let mut http_request = http::Request::builder()
         234  +
        let mut http_request = ::http_1x::Request::builder()
  229    235   
            .uri("/service/RpcV2Protocol/operation/SparseNullsOperation")
  230    236   
            .method("POST")
  231    237   
            .header("Accept", "application/cbor")
  232    238   
            .header("Content-Type", "application/cbor")
  233    239   
            .header("smithy-protocol", "rpc-v2-cbor")
  234         -
            .body(::aws_smithy_http_server::body::Body::from(
  235         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
         240  +
            .body(::aws_smithy_http_server::body::boxed(
         241  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
         242  +
                    &::aws_smithy_protocol_test::decode_body_data(
  236    243   
                        "v3BzcGFyc2VTdHJpbmdMaXN0n/b//w==".as_bytes(),
  237    244   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
         245  +
                    ),
  238    246   
                )),
  239    247   
            ))
  240    248   
            .unwrap();
  241    249   
        #[allow(unused_mut)]
  242    250   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
  243    251   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
  244         -
        let service =
  245         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
         252  +
        let service = crate::service::RpcV2Protocol::builder::<
         253  +
            ::aws_smithy_http_server::body::BoxBody,
         254  +
            _,
         255  +
            _,
         256  +
            _,
         257  +
        >(config)
  246    258   
        .sparse_nulls_operation(move |input: crate::input::SparseNullsOperationInput| {
  247    259   
            let sender = sender.clone();
  248    260   
            async move {
  249    261   
                let result = {
  250    262   
                    let expected = crate::input::SparseNullsOperationInput {
  251    263   
                        sparse_string_list: ::std::option::Option::Some(vec![
  252    264   
                            ::std::option::Option::None,
  253    265   
                        ]),
  254    266   
                        sparse_string_map: ::std::option::Option::None,
  255    267   
                    };
  256    268   
                    ::pretty_assertions::assert_eq!(input, expected);
  257    269   
                    let output = crate::output::SparseNullsOperationOutput {
  258    270   
                        sparse_string_list: ::std::option::Option::None,
  259    271   
                        sparse_string_map: ::std::option::Option::None,
  260    272   
                    };
  261    273   
                    output
  262    274   
                };
  263    275   
                sender.send(()).await.expect("receiver dropped early");
  264    276   
                result
  265    277   
            }
  266    278   
        })
  267    279   
        .build_unchecked();
  268    280   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
  269    281   
            .await
  270    282   
            .expect("unable to make an HTTP request");
  271    283   
        assert!(
  272    284   
            receiver.recv().await.is_some(),
  273    285   
            "we expected operation handler to be invoked but it was not entered"
  274    286   
        );
  275    287   
    }
  276    288   
  277    289   
    /// Deserializes null values in maps
  278    290   
    /// Test ID: RpcV2CborSparseMapsDeserializeNullValues
  279    291   
    #[::tokio::test]
  280    292   
    #[::tracing_test::traced_test]
  281    293   
    async fn rpc_v2_cbor_sparse_maps_deserialize_null_values_response() {
  282    294   
        let output = crate::output::SparseNullsOperationOutput {
  283    295   
            sparse_string_map: ::std::option::Option::Some({
  284    296   
                let mut ret = ::std::collections::HashMap::new();
  285    297   
                ret.insert("foo".to_owned(), ::std::option::Option::None);
  286    298   
                ret
  287    299   
            }),
  288    300   
            sparse_string_list: ::std::option::Option::None,
  289    301   
        };
  290    302   
        use ::aws_smithy_http_server::response::IntoResponse;
  291    303   
        let http_response = output.into_response();
  292    304   
        ::pretty_assertions::assert_eq!(
  293         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
         305  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
  294    306   
            http_response.status()
  295    307   
        );
  296    308   
        let expected_headers = [
  297    309   
            ("Content-Type", "application/cbor"),
  298    310   
            ("smithy-protocol", "rpc-v2-cbor"),
  299    311   
        ];
  300    312   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  301    313   
            http_response.headers(),
  302    314   
            expected_headers,
  303    315   
        ));
  304         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         316  +
        use ::http_body_util::BodyExt;
         317  +
        let body = http_response
         318  +
            .into_body()
         319  +
            .collect()
  305    320   
            .await
  306         -
            .expect("unable to extract body to bytes");
         321  +
            .expect("unable to collect body")
         322  +
            .to_bytes();
  307    323   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  308    324   
            &body,
  309    325   
            "v29zcGFyc2VTdHJpbmdNYXC/Y2Zvb/b//w==",
  310    326   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
  311    327   
        ));
  312    328   
    }
  313    329   
  314    330   
    /// Deserializes null values in lists
  315    331   
    /// Test ID: RpcV2CborSparseListsDeserializeNull
  316    332   
    #[::tokio::test]
  317    333   
    #[::tracing_test::traced_test]
  318    334   
    async fn rpc_v2_cbor_sparse_lists_deserialize_null_response() {
  319    335   
        let output = crate::output::SparseNullsOperationOutput {
  320    336   
            sparse_string_list: ::std::option::Option::Some(vec![::std::option::Option::None]),
  321    337   
            sparse_string_map: ::std::option::Option::None,
  322    338   
        };
  323    339   
        use ::aws_smithy_http_server::response::IntoResponse;
  324    340   
        let http_response = output.into_response();
  325    341   
        ::pretty_assertions::assert_eq!(
  326         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
         342  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
  327    343   
            http_response.status()
  328    344   
        );
  329    345   
        let expected_headers = [
  330    346   
            ("Content-Type", "application/cbor"),
  331    347   
            ("smithy-protocol", "rpc-v2-cbor"),
  332    348   
        ];
  333    349   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  334    350   
            http_response.headers(),
  335    351   
            expected_headers,
  336    352   
        ));
  337         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         353  +
        use ::http_body_util::BodyExt;
         354  +
        let body = http_response
         355  +
            .into_body()
         356  +
            .collect()
  338    357   
            .await
  339         -
            .expect("unable to extract body to bytes");
         358  +
            .expect("unable to collect body")
         359  +
            .to_bytes();
  340    360   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  341    361   
            &body,
  342    362   
            "v3BzcGFyc2VTdHJpbmdMaXN0n/b//w==",
  343    363   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
  344    364   
        ));
  345    365   
    }
  346    366   
}
  347    367   
  348    368   
::pin_project_lite::pin_project! {
  349    369   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
  350    370   
    /// [`OperationWithDefaultsInput`](crate::input::OperationWithDefaultsInput) using modelled bindings.
  351    371   
    pub struct OperationWithDefaultsInputFuture {
  352    372   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::OperationWithDefaultsInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
  353    373   
    }
  354    374   
}
  355    375   
  356    376   
impl std::future::Future for OperationWithDefaultsInputFuture {
  357    377   
    type Output = Result<
  358    378   
        crate::input::OperationWithDefaultsInput,
  359    379   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
  360    380   
    >;
  361    381   
  362    382   
    fn poll(
  363    383   
        self: std::pin::Pin<&mut Self>,
  364    384   
        cx: &mut std::task::Context<'_>,
  365    385   
    ) -> std::task::Poll<Self::Output> {
  366    386   
        let this = self.project();
  367    387   
        this.inner.as_mut().poll(cx)
  368    388   
    }
  369    389   
}
  370    390   
  371    391   
impl<B>
  372    392   
    ::aws_smithy_http_server::request::FromRequest<
  373    393   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
  374    394   
        B,
  375    395   
    > for crate::input::OperationWithDefaultsInput
  376    396   
where
  377    397   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
  378    398   
    B: 'static,
  379    399   
  380    400   
    B::Data: Send,
  381    401   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
  382    402   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
  383    403   
{
  384    404   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
  385    405   
    type Future = OperationWithDefaultsInputFuture;
  386    406   
  387         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
         407  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
  388    408   
        let fut = async move {
  389    409   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
  390    410   
                request.headers(),
  391    411   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
  392    412   
            ) {
  393    413   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
  394    414   
            }
  395    415   
            crate::protocol_serde::shape_operation_with_defaults::de_operation_with_defaults_http_request(request)
  396    416   
                            .await
  397    417   
        };
@@ -427,447 +505,530 @@
  447    467   
#[cfg(test)]
  448    468   
mod operation_with_defaults_test {
  449    469   
  450    470   
    /// Server populates default values when missing in request body.
  451    471   
    /// Test ID: RpcV2CborServerPopulatesDefaultsWhenMissingInRequestBody
  452    472   
    #[::tokio::test]
  453    473   
    #[::tracing_test::traced_test]
  454    474   
    #[should_panic]
  455    475   
    async fn rpc_v2_cbor_server_populates_defaults_when_missing_in_request_body_request() {
  456    476   
        #[allow(unused_mut)]
  457         -
        let mut http_request = http::Request::builder()
         477  +
        let mut http_request = ::http_1x::Request::builder()
  458    478   
            .uri("/service/RpcV2Protocol/operation/OperationWithDefaults")
  459    479   
            .method("POST")
  460    480   
            .header("Accept", "application/cbor")
  461    481   
            .header("Content-Type", "application/cbor")
  462    482   
            .header("smithy-protocol", "rpc-v2-cbor")
  463         -
            .body(::aws_smithy_http_server::body::Body::from(
  464         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
         483  +
            .body(::aws_smithy_http_server::body::boxed(
         484  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
         485  +
                    &::aws_smithy_protocol_test::decode_body_data(
  465    486   
                        "v2hkZWZhdWx0c6D/".as_bytes(),
  466    487   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
         488  +
                    ),
  467    489   
                )),
  468    490   
            ))
  469    491   
            .unwrap();
  470    492   
        #[allow(unused_mut)]
  471    493   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
  472    494   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
  473         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
  474         -
            config,
  475         -
        )
         495  +
        let service = crate::service::RpcV2Protocol::builder::<
         496  +
            ::aws_smithy_http_server::body::BoxBody,
         497  +
            _,
         498  +
            _,
         499  +
            _,
         500  +
        >(config)
  476    501   
        .operation_with_defaults(move |input: crate::input::OperationWithDefaultsInput| {
  477    502   
            let sender = sender.clone();
  478    503   
            async move {
  479    504   
                let result = {
  480    505   
                    let expected = crate::input::OperationWithDefaultsInput {
  481    506   
                        defaults: ::std::option::Option::Some(crate::model::Defaults {
  482    507   
                            default_string: "hi".to_owned(),
  483    508   
                            default_boolean: true,
  484    509   
                            default_list: vec![],
  485    510   
                            default_timestamp: ::aws_smithy_types::DateTime::from_fractional_secs(
@@ -566,591 +685,714 @@
  586    611   
            zero_byte: 0,
  587    612   
            zero_short: 0,
  588    613   
            zero_integer: 0,
  589    614   
            zero_long: 0,
  590    615   
            zero_float: 0_f32,
  591    616   
            zero_double: 0_f64,
  592    617   
        };
  593    618   
        use ::aws_smithy_http_server::response::IntoResponse;
  594    619   
        let http_response = output.into_response();
  595    620   
        ::pretty_assertions::assert_eq!(
  596         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
         621  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
  597    622   
            http_response.status()
  598    623   
        );
  599    624   
        let expected_headers = [
  600    625   
            ("Content-Type", "application/cbor"),
  601    626   
            ("smithy-protocol", "rpc-v2-cbor"),
  602    627   
        ];
  603    628   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  604    629   
            http_response.headers(),
  605    630   
            expected_headers,
  606    631   
        ));
  607         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         632  +
        use ::http_body_util::BodyExt;
         633  +
        let body = http_response
         634  +
            .into_body()
         635  +
            .collect()
  608    636   
            .await
  609         -
            .expect("unable to extract body to bytes");
         637  +
            .expect("unable to collect body")
         638  +
            .to_bytes();
  610    639   
        ::aws_smithy_protocol_test::assert_ok(
  611    640   
        ::aws_smithy_protocol_test::validate_body(&body, "v21kZWZhdWx0U3RyaW5nYmhpbmRlZmF1bHRCb29sZWFu9WtkZWZhdWx0TGlzdIBwZGVmYXVsdFRpbWVzdGFtcMH7AAAAAAAAAABrZGVmYXVsdEJsb2JDYWJja2RlZmF1bHRCeXRlAWxkZWZhdWx0U2hvcnQBbmRlZmF1bHRJbnRlZ2VyCmtkZWZhdWx0TG9uZxhkbGRlZmF1bHRGbG9hdPo/gAAAbWRlZmF1bHREb3VibGX7P/AAAAAAAABqZGVmYXVsdE1hcKBrZGVmYXVsdEVudW1jRk9PbmRlZmF1bHRJbnRFbnVtAWtlbXB0eVN0cmluZ2BsZmFsc2VCb29sZWFu9GllbXB0eUJsb2JAaHplcm9CeXRlAGl6ZXJvU2hvcnQAa3plcm9JbnRlZ2VyAGh6ZXJvTG9uZwBpemVyb0Zsb2F0+gAAAABqemVyb0RvdWJsZfsAAAAAAAAAAP8=", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
  612    641   
        );
  613    642   
    }
  614    643   
}
  615    644   
  616    645   
::pin_project_lite::pin_project! {
  617    646   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
  618    647   
    /// [`FractionalSecondsInput`](crate::input::FractionalSecondsInput) using modelled bindings.
  619    648   
    pub struct FractionalSecondsInputFuture {
  620    649   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::FractionalSecondsInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
  621    650   
    }
  622    651   
}
  623    652   
  624    653   
impl std::future::Future for FractionalSecondsInputFuture {
  625    654   
    type Output = Result<
  626    655   
        crate::input::FractionalSecondsInput,
  627    656   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
  628    657   
    >;
  629    658   
  630    659   
    fn poll(
  631    660   
        self: std::pin::Pin<&mut Self>,
  632    661   
        cx: &mut std::task::Context<'_>,
  633    662   
    ) -> std::task::Poll<Self::Output> {
  634    663   
        let this = self.project();
  635    664   
        this.inner.as_mut().poll(cx)
  636    665   
    }
  637    666   
}
  638    667   
  639    668   
impl<B>
  640    669   
    ::aws_smithy_http_server::request::FromRequest<
  641    670   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
  642    671   
        B,
  643    672   
    > for crate::input::FractionalSecondsInput
  644    673   
where
  645    674   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
  646    675   
    B: 'static,
  647    676   
  648    677   
    B::Data: Send,
  649    678   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
  650    679   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
  651    680   
{
  652    681   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
  653    682   
    type Future = FractionalSecondsInputFuture;
  654    683   
  655         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
         684  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
  656    685   
        let fut = async move {
  657    686   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
  658    687   
                request.headers(),
  659    688   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
  660    689   
            ) {
  661    690   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
  662    691   
            }
  663    692   
            crate::protocol_serde::shape_fractional_seconds::de_fractional_seconds_http_request(
  664    693   
                request,
  665    694   
            )
@@ -709,738 +769,798 @@
  729    758   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
  730    759   
    B: 'static,
  731    760   
  732    761   
    B::Data: Send,
  733    762   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
  734    763   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
  735    764   
{
  736    765   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
  737    766   
    type Future = GreetingWithErrorsInputFuture;
  738    767   
  739         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
         768  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
  740    769   
        let fut = async move {
  741    770   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
  742    771   
                request.headers(),
  743    772   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
  744    773   
            ) {
  745    774   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
  746    775   
            }
  747    776   
            crate::protocol_serde::shape_greeting_with_errors::de_greeting_with_errors_http_request(
  748    777   
                request,
  749    778   
            )
@@ -790,819 +1042,1083 @@
  810    839   
    #[::tokio::test]
  811    840   
    #[::tracing_test::traced_test]
  812    841   
    async fn rpc_v2_cbor_invalid_greeting_error_response() {
  813    842   
        let output = crate::error::InvalidGreeting {
  814    843   
            message: ::std::option::Option::Some("Hi".to_owned()),
  815    844   
        };
  816    845   
        let output = crate::error::GreetingWithErrorsError::InvalidGreeting(output);
  817    846   
        use ::aws_smithy_http_server::response::IntoResponse;
  818    847   
        let http_response = output.into_response();
  819    848   
        ::pretty_assertions::assert_eq!(
  820         -
            http::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
         849  +
            ::http_1x::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
  821    850   
            http_response.status()
  822    851   
        );
  823    852   
        let expected_headers = [
  824    853   
            ("Content-Type", "application/cbor"),
  825    854   
            ("smithy-protocol", "rpc-v2-cbor"),
  826    855   
        ];
  827    856   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  828    857   
            http_response.headers(),
  829    858   
            expected_headers,
  830    859   
        ));
  831         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         860  +
        use ::http_body_util::BodyExt;
         861  +
        let body = http_response
         862  +
            .into_body()
         863  +
            .collect()
  832    864   
            .await
  833         -
            .expect("unable to extract body to bytes");
         865  +
            .expect("unable to collect body")
         866  +
            .to_bytes();
  834    867   
        ::aws_smithy_protocol_test::assert_ok(
  835    868   
        ::aws_smithy_protocol_test::validate_body(&body, "v2ZfX3R5cGV4LnNtaXRoeS5wcm90b2NvbHRlc3RzLnJwY3YyQ2JvciNJbnZhbGlkR3JlZXRpbmdnTWVzc2FnZWJIaf8=", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
  836    869   
        );
  837    870   
    }
  838    871   
  839    872   
    /// Parses a complex error with no message member
  840    873   
    /// Test ID: RpcV2CborComplexError
  841    874   
    #[::tokio::test]
  842    875   
    #[::tracing_test::traced_test]
  843    876   
    async fn rpc_v2_cbor_complex_error_response() {
  844    877   
        let output = crate::error::ComplexError {
  845    878   
            top_level: ::std::option::Option::Some("Top level".to_owned()),
  846    879   
            nested: ::std::option::Option::Some(crate::model::ComplexNestedErrorData {
  847    880   
                foo: ::std::option::Option::Some("bar".to_owned()),
  848    881   
            }),
  849    882   
        };
  850    883   
        let output = crate::error::GreetingWithErrorsError::ComplexError(output);
  851    884   
        use ::aws_smithy_http_server::response::IntoResponse;
  852    885   
        let http_response = output.into_response();
  853    886   
        ::pretty_assertions::assert_eq!(
  854         -
            http::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
         887  +
            ::http_1x::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
  855    888   
            http_response.status()
  856    889   
        );
  857    890   
        let expected_headers = [
  858    891   
            ("Content-Type", "application/cbor"),
  859    892   
            ("smithy-protocol", "rpc-v2-cbor"),
  860    893   
        ];
  861    894   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  862    895   
            http_response.headers(),
  863    896   
            expected_headers,
  864    897   
        ));
  865         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         898  +
        use ::http_body_util::BodyExt;
         899  +
        let body = http_response
         900  +
            .into_body()
         901  +
            .collect()
  866    902   
            .await
  867         -
            .expect("unable to extract body to bytes");
         903  +
            .expect("unable to collect body")
         904  +
            .to_bytes();
  868    905   
        ::aws_smithy_protocol_test::assert_ok(
  869    906   
        ::aws_smithy_protocol_test::validate_body(&body, "v2ZfX3R5cGV4K3NtaXRoeS5wcm90b2NvbHRlc3RzLnJwY3YyQ2JvciNDb21wbGV4RXJyb3JoVG9wTGV2ZWxpVG9wIGxldmVsZk5lc3RlZL9jRm9vY2Jhcv//", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
  870    907   
        );
  871    908   
    }
  872    909   
    /// Test ID: RpcV2CborEmptyComplexError
  873    910   
    #[::tokio::test]
  874    911   
    #[::tracing_test::traced_test]
  875    912   
    async fn rpc_v2_cbor_empty_complex_error_response() {
  876    913   
        let output = crate::error::ComplexError {
  877    914   
            top_level: ::std::option::Option::None,
  878    915   
            nested: ::std::option::Option::None,
  879    916   
        };
  880    917   
        let output = crate::error::GreetingWithErrorsError::ComplexError(output);
  881    918   
        use ::aws_smithy_http_server::response::IntoResponse;
  882    919   
        let http_response = output.into_response();
  883    920   
        ::pretty_assertions::assert_eq!(
  884         -
            http::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
         921  +
            ::http_1x::StatusCode::from_u16(400).expect("invalid expected HTTP status code"),
  885    922   
            http_response.status()
  886    923   
        );
  887    924   
        let expected_headers = [
  888    925   
            ("Content-Type", "application/cbor"),
  889    926   
            ("smithy-protocol", "rpc-v2-cbor"),
  890    927   
        ];
  891    928   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
  892    929   
            http_response.headers(),
  893    930   
            expected_headers,
  894    931   
        ));
  895         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
         932  +
        use ::http_body_util::BodyExt;
         933  +
        let body = http_response
         934  +
            .into_body()
         935  +
            .collect()
  896    936   
            .await
  897         -
            .expect("unable to extract body to bytes");
         937  +
            .expect("unable to collect body")
         938  +
            .to_bytes();
  898    939   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
  899    940   
            &body,
  900    941   
            "v2ZfX3R5cGV4K3NtaXRoeS5wcm90b2NvbHRlc3RzLnJwY3YyQ2JvciNDb21wbGV4RXJyb3L/",
  901    942   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
  902    943   
        ));
  903    944   
    }
  904    945   
}
  905    946   
  906    947   
::pin_project_lite::pin_project! {
  907    948   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
  908    949   
    /// [`RecursiveShapesInput`](crate::input::RecursiveShapesInput) using modelled bindings.
  909    950   
    pub struct RecursiveShapesInputFuture {
  910    951   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::RecursiveShapesInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
  911    952   
    }
  912    953   
}
  913    954   
  914    955   
impl std::future::Future for RecursiveShapesInputFuture {
  915    956   
    type Output = Result<
  916    957   
        crate::input::RecursiveShapesInput,
  917    958   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
  918    959   
    >;
  919    960   
  920    961   
    fn poll(
  921    962   
        self: std::pin::Pin<&mut Self>,
  922    963   
        cx: &mut std::task::Context<'_>,
  923    964   
    ) -> std::task::Poll<Self::Output> {
  924    965   
        let this = self.project();
  925    966   
        this.inner.as_mut().poll(cx)
  926    967   
    }
  927    968   
}
  928    969   
  929    970   
impl<B>
  930    971   
    ::aws_smithy_http_server::request::FromRequest<
  931    972   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
  932    973   
        B,
  933    974   
    > for crate::input::RecursiveShapesInput
  934    975   
where
  935    976   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
  936    977   
    B: 'static,
  937    978   
  938    979   
    B::Data: Send,
  939    980   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
  940    981   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
  941    982   
{
  942    983   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
  943    984   
    type Future = RecursiveShapesInputFuture;
  944    985   
  945         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
         986  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
  946    987   
        let fut = async move {
  947    988   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
  948    989   
                request.headers(),
  949    990   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
  950    991   
            ) {
  951    992   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
  952    993   
            }
  953    994   
            crate::protocol_serde::shape_recursive_shapes::de_recursive_shapes_http_request(request)
  954    995   
                .await
  955    996   
        };
  956    997   
        use ::futures_util::future::TryFutureExt;
  957    998   
        let fut = fut.map_err(
  958    999   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
  959   1000   
                ::tracing::debug!(error = %e, "failed to deserialize request");
  960   1001   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
  961   1002   
                    e,
  962   1003   
                )
  963   1004   
            },
  964   1005   
        );
  965   1006   
        RecursiveShapesInputFuture {
  966   1007   
            inner: Box::pin(fut),
  967   1008   
        }
  968   1009   
    }
  969   1010   
}
  970   1011   
impl
  971   1012   
    ::aws_smithy_http_server::response::IntoResponse<
  972   1013   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
  973   1014   
    > for crate::output::RecursiveShapesOutput
  974   1015   
{
  975   1016   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
  976   1017   
        match crate::protocol_serde::shape_recursive_shapes::ser_recursive_shapes_http_response(
  977   1018   
            self,
  978   1019   
        ) {
  979   1020   
            Ok(response) => response,
  980   1021   
            Err(e) => {
  981   1022   
                ::tracing::error!(error = %e, "failed to serialize response");
  982   1023   
                ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
  983   1024   
            }
  984   1025   
        }
  985   1026   
    }
  986   1027   
}
  987   1028   
  988   1029   
#[allow(unreachable_code, unused_variables)]
  989   1030   
#[cfg(test)]
  990   1031   
mod recursive_shapes_test {
  991   1032   
  992   1033   
    /// Serializes recursive structures
  993   1034   
    /// Test ID: RpcV2CborRecursiveShapes
  994   1035   
    #[::tokio::test]
  995   1036   
    #[::tracing_test::traced_test]
  996   1037   
    async fn rpc_v2_cbor_recursive_shapes_request() {
  997   1038   
        #[allow(unused_mut)]
  998         -
                    let mut http_request = http::Request::builder()
        1039  +
                    let mut http_request = ::http_1x::Request::builder()
  999   1040   
                        .uri("/service/RpcV2Protocol/operation/RecursiveShapes")
 1000   1041   
                        .method("POST")
 1001   1042   
        .header("Accept", "application/cbor")
 1002   1043   
        .header("Content-Type", "application/cbor")
 1003   1044   
        .header("smithy-protocol", "rpc-v2-cbor")
 1004         -
        .body(::aws_smithy_http_server::body::Body::from(
        1045  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 1005   1046   
                        ::bytes::Bytes::copy_from_slice(
 1006   1047   
                            &::aws_smithy_protocol_test::decode_body_data("v2ZuZXN0ZWS/Y2Zvb2RGb28xZm5lc3RlZL9jYmFyZEJhcjFvcmVjdXJzaXZlTWVtYmVyv2Nmb29kRm9vMmZuZXN0ZWS/Y2JhcmRCYXIy//////8=".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 1007   1048   
                        )
 1008         -
                                )).unwrap();
        1049  +
                        ))).unwrap();
 1009   1050   
        #[allow(unused_mut)]
 1010   1051   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1011   1052   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1012         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1053  +
        let service = crate::service::RpcV2Protocol::builder::<::aws_smithy_http_server::body::BoxBody, _, _, _>(config)
 1013   1054   
                        .recursive_shapes(move |input: crate::input::RecursiveShapesInput| {
 1014   1055   
                            let sender = sender.clone();
 1015   1056   
                            async move {
 1016   1057   
                                let result = { let expected =
 1017   1058   
            crate::input::RecursiveShapesInput {
 1018   1059   
                nested:
 1019   1060   
                    ::std::option::Option::Some(
 1020   1061   
                        crate::model::RecursiveShapesInputOutputNested1 {
 1021   1062   
                            foo:
 1022   1063   
                                ::std::option::Option::Some(
@@ -1093,1134 +1212,1257 @@
 1113   1154   
                                )),
 1114   1155   
                            },
 1115   1156   
                        ),
 1116   1157   
                    },
 1117   1158   
                )),
 1118   1159   
            }),
 1119   1160   
        };
 1120   1161   
        use ::aws_smithy_http_server::response::IntoResponse;
 1121   1162   
        let http_response = output.into_response();
 1122   1163   
        ::pretty_assertions::assert_eq!(
 1123         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1164  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1124   1165   
            http_response.status()
 1125   1166   
        );
 1126   1167   
        let expected_headers = [
 1127   1168   
            ("Content-Type", "application/cbor"),
 1128   1169   
            ("smithy-protocol", "rpc-v2-cbor"),
 1129   1170   
        ];
 1130   1171   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1131   1172   
            http_response.headers(),
 1132   1173   
            expected_headers,
 1133   1174   
        ));
 1134         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1175  +
        use ::http_body_util::BodyExt;
        1176  +
        let body = http_response
        1177  +
            .into_body()
        1178  +
            .collect()
 1135   1179   
            .await
 1136         -
            .expect("unable to extract body to bytes");
        1180  +
            .expect("unable to collect body")
        1181  +
            .to_bytes();
 1137   1182   
        ::aws_smithy_protocol_test::assert_ok(
 1138   1183   
        ::aws_smithy_protocol_test::validate_body(&body, "v2ZuZXN0ZWS/Y2Zvb2RGb28xZm5lc3RlZL9jYmFyZEJhcjFvcmVjdXJzaXZlTWVtYmVyv2Nmb29kRm9vMmZuZXN0ZWS/Y2JhcmRCYXIy//////8=", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 1139   1184   
        );
 1140   1185   
    }
 1141   1186   
}
 1142   1187   
 1143   1188   
::pin_project_lite::pin_project! {
 1144   1189   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 1145   1190   
    /// [`RpcV2CborSparseMapsInput`](crate::input::RpcV2CborSparseMapsInput) using modelled bindings.
 1146   1191   
    pub struct RpcV2CborSparseMapsInputFuture {
 1147   1192   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::RpcV2CborSparseMapsInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 1148   1193   
    }
 1149   1194   
}
 1150   1195   
 1151   1196   
impl std::future::Future for RpcV2CborSparseMapsInputFuture {
 1152   1197   
    type Output = Result<
 1153   1198   
        crate::input::RpcV2CborSparseMapsInput,
 1154   1199   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 1155   1200   
    >;
 1156   1201   
 1157   1202   
    fn poll(
 1158   1203   
        self: std::pin::Pin<&mut Self>,
 1159   1204   
        cx: &mut std::task::Context<'_>,
 1160   1205   
    ) -> std::task::Poll<Self::Output> {
 1161   1206   
        let this = self.project();
 1162   1207   
        this.inner.as_mut().poll(cx)
 1163   1208   
    }
 1164   1209   
}
 1165   1210   
 1166   1211   
impl<B>
 1167   1212   
    ::aws_smithy_http_server::request::FromRequest<
 1168   1213   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 1169   1214   
        B,
 1170   1215   
    > for crate::input::RpcV2CborSparseMapsInput
 1171   1216   
where
 1172   1217   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 1173   1218   
    B: 'static,
 1174   1219   
 1175   1220   
    B::Data: Send,
 1176   1221   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 1177   1222   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 1178   1223   
{
 1179   1224   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 1180   1225   
    type Future = RpcV2CborSparseMapsInputFuture;
 1181   1226   
 1182         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        1227  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 1183   1228   
        let fut = async move {
 1184   1229   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 1185   1230   
                request.headers(),
 1186   1231   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 1187   1232   
            ) {
 1188   1233   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 1189   1234   
            }
 1190   1235   
            crate::protocol_serde::shape_rpc_v2_cbor_sparse_maps::de_rpc_v2_cbor_sparse_maps_http_request(request)
 1191   1236   
                            .await
 1192   1237   
        };
@@ -1221,1266 +1598,1672 @@
 1241   1286   
#[allow(unreachable_code, unused_variables)]
 1242   1287   
#[cfg(test)]
 1243   1288   
mod rpc_v2_cbor_sparse_maps_test {
 1244   1289   
 1245   1290   
    /// Serializes sparse maps
 1246   1291   
    /// Test ID: RpcV2CborSparseMaps
 1247   1292   
    #[::tokio::test]
 1248   1293   
    #[::tracing_test::traced_test]
 1249   1294   
    async fn rpc_v2_cbor_sparse_maps_request() {
 1250   1295   
        #[allow(unused_mut)]
 1251         -
        let mut http_request = http::Request::builder()
        1296  +
        let mut http_request = ::http_1x::Request::builder()
 1252   1297   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborSparseMaps")
 1253   1298   
            .method("POST")
 1254   1299   
            .header("Accept", "application/cbor")
 1255   1300   
            .header("Content-Type", "application/cbor")
 1256   1301   
            .header("smithy-protocol", "rpc-v2-cbor")
 1257         -
            .body(::aws_smithy_http_server::body::Body::from(
 1258         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
 1259         -
                    "v29zcGFyc2VTdHJ1Y3RNYXC/Y2Zvb79iaGlldGhlcmX/Y2Jher9iaGljYnll////".as_bytes(),
        1302  +
            .body(::aws_smithy_http_server::body::boxed(
        1303  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        1304  +
                    &::aws_smithy_protocol_test::decode_body_data(
        1305  +
                        "v29zcGFyc2VTdHJ1Y3RNYXC/Y2Zvb79iaGlldGhlcmX/Y2Jher9iaGljYnll////"
        1306  +
                            .as_bytes(),
 1260   1307   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        1308  +
                    ),
 1261   1309   
                )),
 1262   1310   
            ))
 1263   1311   
            .unwrap();
 1264   1312   
        #[allow(unused_mut)]
 1265   1313   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1266   1314   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1267         -
        let service =
 1268         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1315  +
        let service = crate::service::RpcV2Protocol::builder::<
        1316  +
            ::aws_smithy_http_server::body::BoxBody,
        1317  +
            _,
        1318  +
            _,
        1319  +
            _,
        1320  +
        >(config)
 1269   1321   
        .rpc_v2_cbor_sparse_maps(move |input: crate::input::RpcV2CborSparseMapsInput| {
 1270   1322   
            let sender = sender.clone();
 1271   1323   
            async move {
 1272   1324   
                let result = {
 1273   1325   
                    let expected = crate::input::RpcV2CborSparseMapsInput {
 1274   1326   
                        sparse_struct_map: ::std::option::Option::Some({
 1275   1327   
                            let mut ret = ::std::collections::HashMap::new();
 1276   1328   
                            ret.insert(
 1277   1329   
                                "foo".to_owned(),
 1278   1330   
                                ::std::option::Option::Some(crate::model::GreetingStruct {
 1279   1331   
                                    hi: ::std::option::Option::Some("there".to_owned()),
 1280   1332   
                                }),
 1281   1333   
                            );
 1282   1334   
                            ret.insert(
 1283   1335   
                                "baz".to_owned(),
 1284   1336   
                                ::std::option::Option::Some(crate::model::GreetingStruct {
 1285   1337   
                                    hi: ::std::option::Option::Some("bye".to_owned()),
 1286   1338   
                                }),
 1287   1339   
                            );
 1288   1340   
                            ret
 1289   1341   
                        }),
 1290   1342   
                        sparse_number_map: ::std::option::Option::None,
 1291   1343   
                        sparse_boolean_map: ::std::option::Option::None,
 1292   1344   
                        sparse_string_map: ::std::option::Option::None,
 1293   1345   
                        sparse_set_map: ::std::option::Option::None,
 1294   1346   
                    };
 1295   1347   
                    ::pretty_assertions::assert_eq!(input, expected);
 1296   1348   
                    let output = crate::output::RpcV2CborSparseMapsOutput {
 1297   1349   
                        sparse_struct_map: ::std::option::Option::None,
 1298   1350   
                        sparse_number_map: ::std::option::Option::None,
 1299   1351   
                        sparse_boolean_map: ::std::option::Option::None,
 1300   1352   
                        sparse_string_map: ::std::option::Option::None,
 1301   1353   
                        sparse_set_map: ::std::option::Option::None,
 1302   1354   
                    };
 1303   1355   
                    Ok(output)
 1304   1356   
                };
 1305   1357   
                sender.send(()).await.expect("receiver dropped early");
 1306   1358   
                result
 1307   1359   
            }
 1308   1360   
        })
 1309   1361   
        .build_unchecked();
 1310   1362   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 1311   1363   
            .await
 1312   1364   
            .expect("unable to make an HTTP request");
 1313   1365   
        assert!(
 1314   1366   
            receiver.recv().await.is_some(),
 1315   1367   
            "we expected operation handler to be invoked but it was not entered"
 1316   1368   
        );
 1317   1369   
    }
 1318   1370   
 1319   1371   
    /// Serializes null map values in sparse maps
 1320   1372   
    /// Test ID: RpcV2CborSerializesNullMapValues
 1321   1373   
    #[::tokio::test]
 1322   1374   
    #[::tracing_test::traced_test]
 1323   1375   
    async fn rpc_v2_cbor_serializes_null_map_values_request() {
 1324   1376   
        #[allow(unused_mut)]
 1325         -
                    let mut http_request = http::Request::builder()
        1377  +
                    let mut http_request = ::http_1x::Request::builder()
 1326   1378   
                        .uri("/service/RpcV2Protocol/operation/RpcV2CborSparseMaps")
 1327   1379   
                        .method("POST")
 1328   1380   
        .header("Accept", "application/cbor")
 1329   1381   
        .header("Content-Type", "application/cbor")
 1330   1382   
        .header("smithy-protocol", "rpc-v2-cbor")
 1331         -
        .body(::aws_smithy_http_server::body::Body::from(
        1383  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 1332   1384   
                        ::bytes::Bytes::copy_from_slice(
 1333   1385   
                            &::aws_smithy_protocol_test::decode_body_data("v3BzcGFyc2VCb29sZWFuTWFwv2F49v9vc3BhcnNlTnVtYmVyTWFwv2F49v9vc3BhcnNlU3RyaW5nTWFwv2F49v9vc3BhcnNlU3RydWN0TWFwv2F49v//".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 1334   1386   
                        )
 1335         -
                                )).unwrap();
        1387  +
                        ))).unwrap();
 1336   1388   
        #[allow(unused_mut)]
 1337   1389   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1338   1390   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1339         -
        let service =
 1340         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1391  +
        let service = crate::service::RpcV2Protocol::builder::<
        1392  +
            ::aws_smithy_http_server::body::BoxBody,
        1393  +
            _,
        1394  +
            _,
        1395  +
            _,
        1396  +
        >(config)
 1341   1397   
        .rpc_v2_cbor_sparse_maps(move |input: crate::input::RpcV2CborSparseMapsInput| {
 1342   1398   
            let sender = sender.clone();
 1343   1399   
            async move {
 1344   1400   
                let result = {
 1345   1401   
                    let expected = crate::input::RpcV2CborSparseMapsInput {
 1346   1402   
                        sparse_boolean_map: ::std::option::Option::Some({
 1347   1403   
                            let mut ret = ::std::collections::HashMap::new();
 1348   1404   
                            ret.insert("x".to_owned(), ::std::option::Option::None);
 1349   1405   
                            ret
 1350   1406   
                        }),
 1351   1407   
                        sparse_number_map: ::std::option::Option::Some({
 1352   1408   
                            let mut ret = ::std::collections::HashMap::new();
 1353   1409   
                            ret.insert("x".to_owned(), ::std::option::Option::None);
 1354   1410   
                            ret
 1355   1411   
                        }),
 1356   1412   
                        sparse_string_map: ::std::option::Option::Some({
 1357   1413   
                            let mut ret = ::std::collections::HashMap::new();
 1358   1414   
                            ret.insert("x".to_owned(), ::std::option::Option::None);
 1359   1415   
                            ret
 1360   1416   
                        }),
 1361   1417   
                        sparse_struct_map: ::std::option::Option::Some({
 1362   1418   
                            let mut ret = ::std::collections::HashMap::new();
 1363   1419   
                            ret.insert("x".to_owned(), ::std::option::Option::None);
 1364   1420   
                            ret
 1365   1421   
                        }),
 1366   1422   
                        sparse_set_map: ::std::option::Option::None,
 1367   1423   
                    };
 1368   1424   
                    ::pretty_assertions::assert_eq!(input, expected);
 1369   1425   
                    let output = crate::output::RpcV2CborSparseMapsOutput {
 1370   1426   
                        sparse_struct_map: ::std::option::Option::None,
 1371   1427   
                        sparse_number_map: ::std::option::Option::None,
 1372   1428   
                        sparse_boolean_map: ::std::option::Option::None,
 1373   1429   
                        sparse_string_map: ::std::option::Option::None,
 1374   1430   
                        sparse_set_map: ::std::option::Option::None,
 1375   1431   
                    };
 1376   1432   
                    Ok(output)
 1377   1433   
                };
 1378   1434   
                sender.send(()).await.expect("receiver dropped early");
 1379   1435   
                result
 1380   1436   
            }
 1381   1437   
        })
 1382   1438   
        .build_unchecked();
 1383   1439   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 1384   1440   
            .await
 1385   1441   
            .expect("unable to make an HTTP request");
 1386   1442   
        assert!(
 1387   1443   
            receiver.recv().await.is_some(),
 1388   1444   
            "we expected operation handler to be invoked but it was not entered"
 1389   1445   
        );
 1390   1446   
    }
 1391   1447   
 1392   1448   
    /// A request that contains a sparse map of sets
 1393   1449   
    /// Test ID: RpcV2CborSerializesSparseSetMap
 1394   1450   
    #[::tokio::test]
 1395   1451   
    #[::tracing_test::traced_test]
 1396   1452   
    async fn rpc_v2_cbor_serializes_sparse_set_map_request() {
 1397   1453   
        #[allow(unused_mut)]
 1398         -
        let mut http_request = http::Request::builder()
        1454  +
        let mut http_request = ::http_1x::Request::builder()
 1399   1455   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborSparseMaps")
 1400   1456   
            .method("POST")
 1401   1457   
            .header("Accept", "application/cbor")
 1402   1458   
            .header("Content-Type", "application/cbor")
 1403   1459   
            .header("smithy-protocol", "rpc-v2-cbor")
 1404         -
            .body(::aws_smithy_http_server::body::Body::from(
 1405         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        1460  +
            .body(::aws_smithy_http_server::body::boxed(
        1461  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        1462  +
                    &::aws_smithy_protocol_test::decode_body_data(
 1406   1463   
                        "v2xzcGFyc2VTZXRNYXC/YXif/2F5n2FhYWL///8=".as_bytes(),
 1407   1464   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        1465  +
                    ),
 1408   1466   
                )),
 1409   1467   
            ))
 1410   1468   
            .unwrap();
 1411   1469   
        #[allow(unused_mut)]
 1412   1470   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1413   1471   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1414         -
        let service =
 1415         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1472  +
        let service = crate::service::RpcV2Protocol::builder::<
        1473  +
            ::aws_smithy_http_server::body::BoxBody,
        1474  +
            _,
        1475  +
            _,
        1476  +
            _,
        1477  +
        >(config)
 1416   1478   
        .rpc_v2_cbor_sparse_maps(move |input: crate::input::RpcV2CborSparseMapsInput| {
 1417   1479   
            let sender = sender.clone();
 1418   1480   
            async move {
 1419   1481   
                let result = {
 1420   1482   
                    let expected = crate::input::RpcV2CborSparseMapsInput {
 1421   1483   
                        sparse_set_map: ::std::option::Option::Some({
 1422   1484   
                            let mut ret = ::std::collections::HashMap::new();
 1423   1485   
                            ret.insert(
 1424   1486   
                                "x".to_owned(),
 1425   1487   
                                ::std::option::Option::Some(
 1426   1488   
                                    vec![].try_into().expect("this is only used in tests"),
 1427   1489   
                                ),
 1428   1490   
                            );
 1429   1491   
                            ret.insert(
 1430   1492   
                                "y".to_owned(),
 1431   1493   
                                ::std::option::Option::Some(
 1432   1494   
                                    vec!["a".to_owned(), "b".to_owned()]
 1433   1495   
                                        .try_into()
 1434   1496   
                                        .expect("this is only used in tests"),
 1435   1497   
                                ),
 1436   1498   
                            );
 1437   1499   
                            ret
 1438   1500   
                        }),
 1439   1501   
                        sparse_struct_map: ::std::option::Option::None,
 1440   1502   
                        sparse_number_map: ::std::option::Option::None,
 1441   1503   
                        sparse_boolean_map: ::std::option::Option::None,
 1442   1504   
                        sparse_string_map: ::std::option::Option::None,
 1443   1505   
                    };
 1444   1506   
                    ::pretty_assertions::assert_eq!(input, expected);
 1445   1507   
                    let output = crate::output::RpcV2CborSparseMapsOutput {
 1446   1508   
                        sparse_struct_map: ::std::option::Option::None,
 1447   1509   
                        sparse_number_map: ::std::option::Option::None,
 1448   1510   
                        sparse_boolean_map: ::std::option::Option::None,
 1449   1511   
                        sparse_string_map: ::std::option::Option::None,
 1450   1512   
                        sparse_set_map: ::std::option::Option::None,
 1451   1513   
                    };
 1452   1514   
                    Ok(output)
 1453   1515   
                };
 1454   1516   
                sender.send(()).await.expect("receiver dropped early");
 1455   1517   
                result
 1456   1518   
            }
 1457   1519   
        })
 1458   1520   
        .build_unchecked();
 1459   1521   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 1460   1522   
            .await
 1461   1523   
            .expect("unable to make an HTTP request");
 1462   1524   
        assert!(
 1463   1525   
            receiver.recv().await.is_some(),
 1464   1526   
            "we expected operation handler to be invoked but it was not entered"
 1465   1527   
        );
 1466   1528   
    }
 1467   1529   
 1468   1530   
    /// A request that contains a sparse map of sets.
 1469   1531   
    /// Test ID: RpcV2CborSerializesSparseSetMapAndRetainsNull
 1470   1532   
    #[::tokio::test]
 1471   1533   
    #[::tracing_test::traced_test]
 1472   1534   
    async fn rpc_v2_cbor_serializes_sparse_set_map_and_retains_null_request() {
 1473   1535   
        #[allow(unused_mut)]
 1474         -
        let mut http_request = http::Request::builder()
        1536  +
        let mut http_request = ::http_1x::Request::builder()
 1475   1537   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborSparseMaps")
 1476   1538   
            .method("POST")
 1477   1539   
            .header("Accept", "application/cbor")
 1478   1540   
            .header("Content-Type", "application/cbor")
 1479   1541   
            .header("smithy-protocol", "rpc-v2-cbor")
 1480         -
            .body(::aws_smithy_http_server::body::Body::from(
 1481         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        1542  +
            .body(::aws_smithy_http_server::body::boxed(
        1543  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        1544  +
                    &::aws_smithy_protocol_test::decode_body_data(
 1482   1545   
                        "v2xzcGFyc2VTZXRNYXC/YXif/2F5n2FhYWL/YXr2//8=".as_bytes(),
 1483   1546   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        1547  +
                    ),
 1484   1548   
                )),
 1485   1549   
            ))
 1486   1550   
            .unwrap();
 1487   1551   
        #[allow(unused_mut)]
 1488   1552   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1489   1553   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1490         -
        let service =
 1491         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1554  +
        let service = crate::service::RpcV2Protocol::builder::<
        1555  +
            ::aws_smithy_http_server::body::BoxBody,
        1556  +
            _,
        1557  +
            _,
        1558  +
            _,
        1559  +
        >(config)
 1492   1560   
        .rpc_v2_cbor_sparse_maps(move |input: crate::input::RpcV2CborSparseMapsInput| {
 1493   1561   
            let sender = sender.clone();
 1494   1562   
            async move {
 1495   1563   
                let result = {
 1496   1564   
                    let expected = crate::input::RpcV2CborSparseMapsInput {
 1497   1565   
                        sparse_set_map: ::std::option::Option::Some({
 1498   1566   
                            let mut ret = ::std::collections::HashMap::new();
 1499   1567   
                            ret.insert(
 1500   1568   
                                "x".to_owned(),
 1501   1569   
                                ::std::option::Option::Some(
 1502   1570   
                                    vec![].try_into().expect("this is only used in tests"),
 1503   1571   
                                ),
 1504   1572   
                            );
 1505   1573   
                            ret.insert(
 1506   1574   
                                "y".to_owned(),
 1507   1575   
                                ::std::option::Option::Some(
 1508   1576   
                                    vec!["a".to_owned(), "b".to_owned()]
 1509   1577   
                                        .try_into()
 1510   1578   
                                        .expect("this is only used in tests"),
 1511   1579   
                                ),
 1512   1580   
                            );
 1513   1581   
                            ret.insert("z".to_owned(), ::std::option::Option::None);
 1514   1582   
                            ret
 1515   1583   
                        }),
 1516   1584   
                        sparse_struct_map: ::std::option::Option::None,
 1517   1585   
                        sparse_number_map: ::std::option::Option::None,
 1518   1586   
                        sparse_boolean_map: ::std::option::Option::None,
 1519   1587   
                        sparse_string_map: ::std::option::Option::None,
 1520   1588   
                    };
 1521   1589   
                    ::pretty_assertions::assert_eq!(input, expected);
 1522   1590   
                    let output = crate::output::RpcV2CborSparseMapsOutput {
 1523   1591   
                        sparse_struct_map: ::std::option::Option::None,
 1524   1592   
                        sparse_number_map: ::std::option::Option::None,
 1525   1593   
                        sparse_boolean_map: ::std::option::Option::None,
 1526   1594   
                        sparse_string_map: ::std::option::Option::None,
 1527   1595   
                        sparse_set_map: ::std::option::Option::None,
 1528   1596   
                    };
 1529   1597   
                    Ok(output)
 1530   1598   
                };
 1531   1599   
                sender.send(()).await.expect("receiver dropped early");
 1532   1600   
                result
 1533   1601   
            }
 1534   1602   
        })
 1535   1603   
        .build_unchecked();
 1536   1604   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 1537   1605   
            .await
 1538   1606   
            .expect("unable to make an HTTP request");
 1539   1607   
        assert!(
 1540   1608   
            receiver.recv().await.is_some(),
 1541   1609   
            "we expected operation handler to be invoked but it was not entered"
 1542   1610   
        );
 1543   1611   
    }
 1544   1612   
 1545   1613   
    /// Ensure that 0 and false are sent over the wire in all maps and lists
 1546   1614   
    /// Test ID: RpcV2CborSerializesZeroValuesInSparseMaps
 1547   1615   
    #[::tokio::test]
 1548   1616   
    #[::tracing_test::traced_test]
 1549   1617   
    async fn rpc_v2_cbor_serializes_zero_values_in_sparse_maps_request() {
 1550   1618   
        #[allow(unused_mut)]
 1551         -
        let mut http_request = http::Request::builder()
        1619  +
        let mut http_request = ::http_1x::Request::builder()
 1552   1620   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborSparseMaps")
 1553   1621   
            .method("POST")
 1554   1622   
            .header("Accept", "application/cbor")
 1555   1623   
            .header("Content-Type", "application/cbor")
 1556   1624   
            .header("smithy-protocol", "rpc-v2-cbor")
 1557         -
            .body(::aws_smithy_http_server::body::Body::from(
 1558         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        1625  +
            .body(::aws_smithy_http_server::body::boxed(
        1626  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        1627  +
                    &::aws_smithy_protocol_test::decode_body_data(
 1559   1628   
                        "v29zcGFyc2VOdW1iZXJNYXC/YXgA/3BzcGFyc2VCb29sZWFuTWFwv2F49P//".as_bytes(),
 1560   1629   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        1630  +
                    ),
 1561   1631   
                )),
 1562   1632   
            ))
 1563   1633   
            .unwrap();
 1564   1634   
        #[allow(unused_mut)]
 1565   1635   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1566   1636   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1567         -
        let service =
 1568         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        1637  +
        let service = crate::service::RpcV2Protocol::builder::<
        1638  +
            ::aws_smithy_http_server::body::BoxBody,
        1639  +
            _,
        1640  +
            _,
        1641  +
            _,
        1642  +
        >(config)
 1569   1643   
        .rpc_v2_cbor_sparse_maps(move |input: crate::input::RpcV2CborSparseMapsInput| {
 1570   1644   
            let sender = sender.clone();
 1571   1645   
            async move {
 1572   1646   
                let result = {
 1573   1647   
                    let expected = crate::input::RpcV2CborSparseMapsInput {
 1574   1648   
                        sparse_number_map: ::std::option::Option::Some({
 1575   1649   
                            let mut ret = ::std::collections::HashMap::new();
 1576   1650   
                            ret.insert("x".to_owned(), ::std::option::Option::Some(0));
 1577   1651   
                            ret
 1578   1652   
                        }),
@@ -1612,1686 +1934,2028 @@
 1632   1706   
                ret
 1633   1707   
            }),
 1634   1708   
            sparse_number_map: ::std::option::Option::None,
 1635   1709   
            sparse_boolean_map: ::std::option::Option::None,
 1636   1710   
            sparse_string_map: ::std::option::Option::None,
 1637   1711   
            sparse_set_map: ::std::option::Option::None,
 1638   1712   
        };
 1639   1713   
        use ::aws_smithy_http_server::response::IntoResponse;
 1640   1714   
        let http_response = output.into_response();
 1641   1715   
        ::pretty_assertions::assert_eq!(
 1642         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1716  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1643   1717   
            http_response.status()
 1644   1718   
        );
 1645   1719   
        let expected_headers = [
 1646   1720   
            ("Content-Type", "application/cbor"),
 1647   1721   
            ("smithy-protocol", "rpc-v2-cbor"),
 1648   1722   
        ];
 1649   1723   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1650   1724   
            http_response.headers(),
 1651   1725   
            expected_headers,
 1652   1726   
        ));
 1653         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1727  +
        use ::http_body_util::BodyExt;
        1728  +
        let body = http_response
        1729  +
            .into_body()
        1730  +
            .collect()
 1654   1731   
            .await
 1655         -
            .expect("unable to extract body to bytes");
        1732  +
            .expect("unable to collect body")
        1733  +
            .to_bytes();
 1656   1734   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 1657   1735   
            &body,
 1658   1736   
            "v29zcGFyc2VTdHJ1Y3RNYXC/Y2Zvb79iaGlldGhlcmX/Y2Jher9iaGljYnll////",
 1659   1737   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 1660   1738   
        ));
 1661   1739   
    }
 1662   1740   
 1663   1741   
    /// Deserializes null map values
 1664   1742   
    /// Test ID: RpcV2CborDeserializesNullMapValues
 1665   1743   
    #[::tokio::test]
 1666   1744   
    #[::tracing_test::traced_test]
 1667   1745   
    async fn rpc_v2_cbor_deserializes_null_map_values_response() {
 1668   1746   
        let output = crate::output::RpcV2CborSparseMapsOutput {
 1669   1747   
            sparse_boolean_map: ::std::option::Option::Some({
 1670   1748   
                let mut ret = ::std::collections::HashMap::new();
 1671   1749   
                ret.insert("x".to_owned(), ::std::option::Option::None);
 1672   1750   
                ret
 1673   1751   
            }),
 1674   1752   
            sparse_number_map: ::std::option::Option::Some({
 1675   1753   
                let mut ret = ::std::collections::HashMap::new();
 1676   1754   
                ret.insert("x".to_owned(), ::std::option::Option::None);
 1677   1755   
                ret
 1678   1756   
            }),
 1679   1757   
            sparse_string_map: ::std::option::Option::Some({
 1680   1758   
                let mut ret = ::std::collections::HashMap::new();
 1681   1759   
                ret.insert("x".to_owned(), ::std::option::Option::None);
 1682   1760   
                ret
 1683   1761   
            }),
 1684   1762   
            sparse_struct_map: ::std::option::Option::Some({
 1685   1763   
                let mut ret = ::std::collections::HashMap::new();
 1686   1764   
                ret.insert("x".to_owned(), ::std::option::Option::None);
 1687   1765   
                ret
 1688   1766   
            }),
 1689   1767   
            sparse_set_map: ::std::option::Option::None,
 1690   1768   
        };
 1691   1769   
        use ::aws_smithy_http_server::response::IntoResponse;
 1692   1770   
        let http_response = output.into_response();
 1693   1771   
        ::pretty_assertions::assert_eq!(
 1694         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1772  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1695   1773   
            http_response.status()
 1696   1774   
        );
 1697   1775   
        let expected_headers = [
 1698   1776   
            ("Content-Type", "application/cbor"),
 1699   1777   
            ("smithy-protocol", "rpc-v2-cbor"),
 1700   1778   
        ];
 1701   1779   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1702   1780   
            http_response.headers(),
 1703   1781   
            expected_headers,
 1704   1782   
        ));
 1705         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1783  +
        use ::http_body_util::BodyExt;
        1784  +
        let body = http_response
        1785  +
            .into_body()
        1786  +
            .collect()
 1706   1787   
            .await
 1707         -
            .expect("unable to extract body to bytes");
        1788  +
            .expect("unable to collect body")
        1789  +
            .to_bytes();
 1708   1790   
        ::aws_smithy_protocol_test::assert_ok(
 1709   1791   
        ::aws_smithy_protocol_test::validate_body(&body, "v3BzcGFyc2VCb29sZWFuTWFwv2F49v9vc3BhcnNlTnVtYmVyTWFwv2F49v9vc3BhcnNlU3RyaW5nTWFwv2F49v9vc3BhcnNlU3RydWN0TWFwv2F49v//", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 1710   1792   
        );
 1711   1793   
    }
 1712   1794   
 1713   1795   
    /// A response that contains a sparse map of sets
 1714   1796   
    /// Test ID: RpcV2CborDeserializesSparseSetMap
 1715   1797   
    #[::tokio::test]
 1716   1798   
    #[::tracing_test::traced_test]
 1717   1799   
    async fn rpc_v2_cbor_deserializes_sparse_set_map_response() {
 1718   1800   
        let output = crate::output::RpcV2CborSparseMapsOutput {
 1719   1801   
            sparse_set_map: ::std::option::Option::Some({
 1720   1802   
                let mut ret = ::std::collections::HashMap::new();
 1721   1803   
                ret.insert(
 1722   1804   
                    "x".to_owned(),
 1723   1805   
                    ::std::option::Option::Some(
 1724   1806   
                        vec![].try_into().expect("this is only used in tests"),
 1725   1807   
                    ),
 1726   1808   
                );
 1727   1809   
                ret.insert(
 1728   1810   
                    "y".to_owned(),
 1729   1811   
                    ::std::option::Option::Some(
 1730   1812   
                        vec!["a".to_owned(), "b".to_owned()]
 1731   1813   
                            .try_into()
 1732   1814   
                            .expect("this is only used in tests"),
 1733   1815   
                    ),
 1734   1816   
                );
 1735   1817   
                ret
 1736   1818   
            }),
 1737   1819   
            sparse_struct_map: ::std::option::Option::None,
 1738   1820   
            sparse_number_map: ::std::option::Option::None,
 1739   1821   
            sparse_boolean_map: ::std::option::Option::None,
 1740   1822   
            sparse_string_map: ::std::option::Option::None,
 1741   1823   
        };
 1742   1824   
        use ::aws_smithy_http_server::response::IntoResponse;
 1743   1825   
        let http_response = output.into_response();
 1744   1826   
        ::pretty_assertions::assert_eq!(
 1745         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1827  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1746   1828   
            http_response.status()
 1747   1829   
        );
 1748   1830   
        let expected_headers = [
 1749   1831   
            ("Content-Type", "application/cbor"),
 1750   1832   
            ("smithy-protocol", "rpc-v2-cbor"),
 1751   1833   
        ];
 1752   1834   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1753   1835   
            http_response.headers(),
 1754   1836   
            expected_headers,
 1755   1837   
        ));
 1756         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1838  +
        use ::http_body_util::BodyExt;
        1839  +
        let body = http_response
        1840  +
            .into_body()
        1841  +
            .collect()
 1757   1842   
            .await
 1758         -
            .expect("unable to extract body to bytes");
        1843  +
            .expect("unable to collect body")
        1844  +
            .to_bytes();
 1759   1845   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 1760   1846   
            &body,
 1761   1847   
            "v2xzcGFyc2VTZXRNYXC/YXmfYWFhYv9heJ////8=",
 1762   1848   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 1763   1849   
        ));
 1764   1850   
    }
 1765   1851   
 1766   1852   
    /// A response that contains a sparse map of sets with a null
 1767   1853   
    /// Test ID: RpcV2CborDeserializesSparseSetMapAndRetainsNull
 1768   1854   
    #[::tokio::test]
 1769   1855   
    #[::tracing_test::traced_test]
 1770   1856   
    async fn rpc_v2_cbor_deserializes_sparse_set_map_and_retains_null_response() {
 1771   1857   
        let output = crate::output::RpcV2CborSparseMapsOutput {
 1772   1858   
            sparse_set_map: ::std::option::Option::Some({
 1773   1859   
                let mut ret = ::std::collections::HashMap::new();
 1774   1860   
                ret.insert(
 1775   1861   
                    "x".to_owned(),
 1776   1862   
                    ::std::option::Option::Some(
 1777   1863   
                        vec![].try_into().expect("this is only used in tests"),
 1778   1864   
                    ),
 1779   1865   
                );
 1780   1866   
                ret.insert(
 1781   1867   
                    "y".to_owned(),
 1782   1868   
                    ::std::option::Option::Some(
 1783   1869   
                        vec!["a".to_owned(), "b".to_owned()]
 1784   1870   
                            .try_into()
 1785   1871   
                            .expect("this is only used in tests"),
 1786   1872   
                    ),
 1787   1873   
                );
 1788   1874   
                ret.insert("z".to_owned(), ::std::option::Option::None);
 1789   1875   
                ret
 1790   1876   
            }),
 1791   1877   
            sparse_struct_map: ::std::option::Option::None,
 1792   1878   
            sparse_number_map: ::std::option::Option::None,
 1793   1879   
            sparse_boolean_map: ::std::option::Option::None,
 1794   1880   
            sparse_string_map: ::std::option::Option::None,
 1795   1881   
        };
 1796   1882   
        use ::aws_smithy_http_server::response::IntoResponse;
 1797   1883   
        let http_response = output.into_response();
 1798   1884   
        ::pretty_assertions::assert_eq!(
 1799         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1885  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1800   1886   
            http_response.status()
 1801   1887   
        );
 1802   1888   
        let expected_headers = [
 1803   1889   
            ("Content-Type", "application/cbor"),
 1804   1890   
            ("smithy-protocol", "rpc-v2-cbor"),
 1805   1891   
        ];
 1806   1892   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1807   1893   
            http_response.headers(),
 1808   1894   
            expected_headers,
 1809   1895   
        ));
 1810         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1896  +
        use ::http_body_util::BodyExt;
        1897  +
        let body = http_response
        1898  +
            .into_body()
        1899  +
            .collect()
 1811   1900   
            .await
 1812         -
            .expect("unable to extract body to bytes");
        1901  +
            .expect("unable to collect body")
        1902  +
            .to_bytes();
 1813   1903   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 1814   1904   
            &body,
 1815   1905   
            "v2xzcGFyc2VTZXRNYXC/YXif/2F5n2FhYWL/YXr2//8=",
 1816   1906   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 1817   1907   
        ));
 1818   1908   
    }
 1819   1909   
 1820   1910   
    /// Ensure that 0 and false are sent over the wire in all maps and lists
 1821   1911   
    /// Test ID: RpcV2CborDeserializesZeroValuesInSparseMaps
 1822   1912   
    #[::tokio::test]
 1823   1913   
    #[::tracing_test::traced_test]
 1824   1914   
    async fn rpc_v2_cbor_deserializes_zero_values_in_sparse_maps_response() {
 1825   1915   
        let output = crate::output::RpcV2CborSparseMapsOutput {
 1826   1916   
            sparse_number_map: ::std::option::Option::Some({
 1827   1917   
                let mut ret = ::std::collections::HashMap::new();
 1828   1918   
                ret.insert("x".to_owned(), ::std::option::Option::Some(0));
 1829   1919   
                ret
 1830   1920   
            }),
 1831   1921   
            sparse_boolean_map: ::std::option::Option::Some({
 1832   1922   
                let mut ret = ::std::collections::HashMap::new();
 1833   1923   
                ret.insert("x".to_owned(), ::std::option::Option::Some(false));
 1834   1924   
                ret
 1835   1925   
            }),
 1836   1926   
            sparse_struct_map: ::std::option::Option::None,
 1837   1927   
            sparse_string_map: ::std::option::Option::None,
 1838   1928   
            sparse_set_map: ::std::option::Option::None,
 1839   1929   
        };
 1840   1930   
        use ::aws_smithy_http_server::response::IntoResponse;
 1841   1931   
        let http_response = output.into_response();
 1842   1932   
        ::pretty_assertions::assert_eq!(
 1843         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        1933  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 1844   1934   
            http_response.status()
 1845   1935   
        );
 1846   1936   
        let expected_headers = [
 1847   1937   
            ("Content-Type", "application/cbor"),
 1848   1938   
            ("smithy-protocol", "rpc-v2-cbor"),
 1849   1939   
        ];
 1850   1940   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 1851   1941   
            http_response.headers(),
 1852   1942   
            expected_headers,
 1853   1943   
        ));
 1854         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        1944  +
        use ::http_body_util::BodyExt;
        1945  +
        let body = http_response
        1946  +
            .into_body()
        1947  +
            .collect()
 1855   1948   
            .await
 1856         -
            .expect("unable to extract body to bytes");
        1949  +
            .expect("unable to collect body")
        1950  +
            .to_bytes();
 1857   1951   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 1858   1952   
            &body,
 1859   1953   
            "v29zcGFyc2VOdW1iZXJNYXC/YXgA/3BzcGFyc2VCb29sZWFuTWFwv2F49P//",
 1860   1954   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 1861   1955   
        ));
 1862   1956   
    }
 1863   1957   
}
 1864   1958   
 1865   1959   
::pin_project_lite::pin_project! {
 1866   1960   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 1867   1961   
    /// [`RpcV2CborDenseMapsInput`](crate::input::RpcV2CborDenseMapsInput) using modelled bindings.
 1868   1962   
    pub struct RpcV2CborDenseMapsInputFuture {
 1869   1963   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::RpcV2CborDenseMapsInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 1870   1964   
    }
 1871   1965   
}
 1872   1966   
 1873   1967   
impl std::future::Future for RpcV2CborDenseMapsInputFuture {
 1874   1968   
    type Output = Result<
 1875   1969   
        crate::input::RpcV2CborDenseMapsInput,
 1876   1970   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 1877   1971   
    >;
 1878   1972   
 1879   1973   
    fn poll(
 1880   1974   
        self: std::pin::Pin<&mut Self>,
 1881   1975   
        cx: &mut std::task::Context<'_>,
 1882   1976   
    ) -> std::task::Poll<Self::Output> {
 1883   1977   
        let this = self.project();
 1884   1978   
        this.inner.as_mut().poll(cx)
 1885   1979   
    }
 1886   1980   
}
 1887   1981   
 1888   1982   
impl<B>
 1889   1983   
    ::aws_smithy_http_server::request::FromRequest<
 1890   1984   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 1891   1985   
        B,
 1892   1986   
    > for crate::input::RpcV2CborDenseMapsInput
 1893   1987   
where
 1894   1988   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 1895   1989   
    B: 'static,
 1896   1990   
 1897   1991   
    B::Data: Send,
 1898   1992   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 1899   1993   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 1900   1994   
{
 1901   1995   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 1902   1996   
    type Future = RpcV2CborDenseMapsInputFuture;
 1903   1997   
 1904         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        1998  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 1905   1999   
        let fut = async move {
 1906   2000   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 1907   2001   
                request.headers(),
 1908   2002   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 1909   2003   
            ) {
 1910   2004   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 1911   2005   
            }
 1912   2006   
            crate::protocol_serde::shape_rpc_v2_cbor_dense_maps::de_rpc_v2_cbor_dense_maps_http_request(request)
 1913   2007   
                            .await
 1914   2008   
        };
@@ -1943,2037 +2161,2273 @@
 1963   2057   
#[allow(unreachable_code, unused_variables)]
 1964   2058   
#[cfg(test)]
 1965   2059   
mod rpc_v2_cbor_dense_maps_test {
 1966   2060   
 1967   2061   
    /// Serializes maps
 1968   2062   
    /// Test ID: RpcV2CborMaps
 1969   2063   
    #[::tokio::test]
 1970   2064   
    #[::tracing_test::traced_test]
 1971   2065   
    async fn rpc_v2_cbor_maps_request() {
 1972   2066   
        #[allow(unused_mut)]
 1973         -
        let mut http_request = http::Request::builder()
        2067  +
        let mut http_request = ::http_1x::Request::builder()
 1974   2068   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborDenseMaps")
 1975   2069   
            .method("POST")
 1976   2070   
            .header("Accept", "application/cbor")
 1977   2071   
            .header("Content-Type", "application/cbor")
 1978   2072   
            .header("smithy-protocol", "rpc-v2-cbor")
 1979         -
            .body(::aws_smithy_http_server::body::Body::from(
 1980         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        2073  +
            .body(::aws_smithy_http_server::body::boxed(
        2074  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        2075  +
                    &::aws_smithy_protocol_test::decode_body_data(
 1981   2076   
                        "oW5kZW5zZVN0cnVjdE1hcKJjZm9voWJoaWV0aGVyZWNiYXqhYmhpY2J5ZQ==".as_bytes(),
 1982   2077   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        2078  +
                    ),
 1983   2079   
                )),
 1984   2080   
            ))
 1985   2081   
            .unwrap();
 1986   2082   
        #[allow(unused_mut)]
 1987   2083   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 1988   2084   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 1989         -
        let service =
 1990         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2085  +
        let service = crate::service::RpcV2Protocol::builder::<
        2086  +
            ::aws_smithy_http_server::body::BoxBody,
        2087  +
            _,
        2088  +
            _,
        2089  +
            _,
        2090  +
        >(config)
 1991   2091   
        .rpc_v2_cbor_dense_maps(move |input: crate::input::RpcV2CborDenseMapsInput| {
 1992   2092   
            let sender = sender.clone();
 1993   2093   
            async move {
 1994   2094   
                let result = {
 1995   2095   
                    let expected = crate::input::RpcV2CborDenseMapsInput {
 1996   2096   
                        dense_struct_map: ::std::option::Option::Some({
 1997   2097   
                            let mut ret = ::std::collections::HashMap::new();
 1998   2098   
                            ret.insert(
 1999   2099   
                                "foo".to_owned(),
 2000   2100   
                                crate::model::GreetingStruct {
 2001   2101   
                                    hi: ::std::option::Option::Some("there".to_owned()),
 2002   2102   
                                },
 2003   2103   
                            );
 2004   2104   
                            ret.insert(
 2005   2105   
                                "baz".to_owned(),
 2006   2106   
                                crate::model::GreetingStruct {
 2007   2107   
                                    hi: ::std::option::Option::Some("bye".to_owned()),
 2008   2108   
                                },
 2009   2109   
                            );
 2010   2110   
                            ret
 2011   2111   
                        }),
 2012   2112   
                        dense_number_map: ::std::option::Option::None,
 2013   2113   
                        dense_boolean_map: ::std::option::Option::None,
 2014   2114   
                        dense_string_map: ::std::option::Option::None,
 2015   2115   
                        dense_set_map: ::std::option::Option::None,
 2016   2116   
                    };
 2017   2117   
                    ::pretty_assertions::assert_eq!(input, expected);
 2018   2118   
                    let output = crate::output::RpcV2CborDenseMapsOutput {
 2019   2119   
                        dense_struct_map: ::std::option::Option::None,
 2020   2120   
                        dense_number_map: ::std::option::Option::None,
 2021   2121   
                        dense_boolean_map: ::std::option::Option::None,
 2022   2122   
                        dense_string_map: ::std::option::Option::None,
 2023   2123   
                        dense_set_map: ::std::option::Option::None,
 2024   2124   
                    };
 2025   2125   
                    Ok(output)
 2026   2126   
                };
 2027   2127   
                sender.send(()).await.expect("receiver dropped early");
 2028   2128   
                result
 2029   2129   
            }
 2030   2130   
        })
 2031   2131   
        .build_unchecked();
 2032   2132   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 2033   2133   
            .await
 2034   2134   
            .expect("unable to make an HTTP request");
 2035   2135   
        assert!(
 2036   2136   
            receiver.recv().await.is_some(),
 2037   2137   
            "we expected operation handler to be invoked but it was not entered"
 2038   2138   
        );
 2039   2139   
    }
 2040   2140   
 2041   2141   
    /// Ensure that 0 and false are sent over the wire in all maps and lists
 2042   2142   
    /// Test ID: RpcV2CborSerializesZeroValuesInMaps
 2043   2143   
    #[::tokio::test]
 2044   2144   
    #[::tracing_test::traced_test]
 2045   2145   
    async fn rpc_v2_cbor_serializes_zero_values_in_maps_request() {
 2046   2146   
        #[allow(unused_mut)]
 2047         -
        let mut http_request = http::Request::builder()
        2147  +
        let mut http_request = ::http_1x::Request::builder()
 2048   2148   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborDenseMaps")
 2049   2149   
            .method("POST")
 2050   2150   
            .header("Accept", "application/cbor")
 2051   2151   
            .header("Content-Type", "application/cbor")
 2052   2152   
            .header("smithy-protocol", "rpc-v2-cbor")
 2053         -
            .body(::aws_smithy_http_server::body::Body::from(
 2054         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        2153  +
            .body(::aws_smithy_http_server::body::boxed(
        2154  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        2155  +
                    &::aws_smithy_protocol_test::decode_body_data(
 2055   2156   
                        "om5kZW5zZU51bWJlck1hcKFheABvZGVuc2VCb29sZWFuTWFwoWF49A==".as_bytes(),
 2056   2157   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        2158  +
                    ),
 2057   2159   
                )),
 2058   2160   
            ))
 2059   2161   
            .unwrap();
 2060   2162   
        #[allow(unused_mut)]
 2061   2163   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2062   2164   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2063         -
        let service =
 2064         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2165  +
        let service = crate::service::RpcV2Protocol::builder::<
        2166  +
            ::aws_smithy_http_server::body::BoxBody,
        2167  +
            _,
        2168  +
            _,
        2169  +
            _,
        2170  +
        >(config)
 2065   2171   
        .rpc_v2_cbor_dense_maps(move |input: crate::input::RpcV2CborDenseMapsInput| {
 2066   2172   
            let sender = sender.clone();
 2067   2173   
            async move {
 2068   2174   
                let result = {
 2069   2175   
                    let expected = crate::input::RpcV2CborDenseMapsInput {
 2070   2176   
                        dense_number_map: ::std::option::Option::Some({
 2071   2177   
                            let mut ret = ::std::collections::HashMap::new();
 2072   2178   
                            ret.insert("x".to_owned(), 0);
 2073   2179   
                            ret
 2074   2180   
                        }),
 2075   2181   
                        dense_boolean_map: ::std::option::Option::Some({
 2076   2182   
                            let mut ret = ::std::collections::HashMap::new();
 2077   2183   
                            ret.insert("x".to_owned(), false);
 2078   2184   
                            ret
 2079   2185   
                        }),
 2080   2186   
                        dense_struct_map: ::std::option::Option::None,
 2081   2187   
                        dense_string_map: ::std::option::Option::None,
 2082   2188   
                        dense_set_map: ::std::option::Option::None,
 2083   2189   
                    };
 2084   2190   
                    ::pretty_assertions::assert_eq!(input, expected);
 2085   2191   
                    let output = crate::output::RpcV2CborDenseMapsOutput {
 2086   2192   
                        dense_struct_map: ::std::option::Option::None,
 2087   2193   
                        dense_number_map: ::std::option::Option::None,
 2088   2194   
                        dense_boolean_map: ::std::option::Option::None,
 2089   2195   
                        dense_string_map: ::std::option::Option::None,
 2090   2196   
                        dense_set_map: ::std::option::Option::None,
 2091   2197   
                    };
 2092   2198   
                    Ok(output)
 2093   2199   
                };
 2094   2200   
                sender.send(()).await.expect("receiver dropped early");
 2095   2201   
                result
 2096   2202   
            }
 2097   2203   
        })
 2098   2204   
        .build_unchecked();
 2099   2205   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 2100   2206   
            .await
 2101   2207   
            .expect("unable to make an HTTP request");
 2102   2208   
        assert!(
 2103   2209   
            receiver.recv().await.is_some(),
 2104   2210   
            "we expected operation handler to be invoked but it was not entered"
 2105   2211   
        );
 2106   2212   
    }
 2107   2213   
 2108   2214   
    /// A request that contains a dense map of sets.
 2109   2215   
    /// Test ID: RpcV2CborSerializesDenseSetMap
 2110   2216   
    #[::tokio::test]
 2111   2217   
    #[::tracing_test::traced_test]
 2112   2218   
    async fn rpc_v2_cbor_serializes_dense_set_map_request() {
 2113   2219   
        #[allow(unused_mut)]
 2114         -
        let mut http_request = http::Request::builder()
        2220  +
        let mut http_request = ::http_1x::Request::builder()
 2115   2221   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborDenseMaps")
 2116   2222   
            .method("POST")
 2117   2223   
            .header("Accept", "application/cbor")
 2118   2224   
            .header("Content-Type", "application/cbor")
 2119   2225   
            .header("smithy-protocol", "rpc-v2-cbor")
 2120         -
            .body(::aws_smithy_http_server::body::Body::from(
 2121         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        2226  +
            .body(::aws_smithy_http_server::body::boxed(
        2227  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        2228  +
                    &::aws_smithy_protocol_test::decode_body_data(
 2122   2229   
                        "oWtkZW5zZVNldE1hcKJheIBheYJhYWFi".as_bytes(),
 2123   2230   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        2231  +
                    ),
 2124   2232   
                )),
 2125   2233   
            ))
 2126   2234   
            .unwrap();
 2127   2235   
        #[allow(unused_mut)]
 2128   2236   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2129   2237   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2130         -
        let service =
 2131         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2238  +
        let service = crate::service::RpcV2Protocol::builder::<
        2239  +
            ::aws_smithy_http_server::body::BoxBody,
        2240  +
            _,
        2241  +
            _,
        2242  +
            _,
        2243  +
        >(config)
 2132   2244   
        .rpc_v2_cbor_dense_maps(move |input: crate::input::RpcV2CborDenseMapsInput| {
 2133   2245   
            let sender = sender.clone();
 2134   2246   
            async move {
 2135   2247   
                let result = {
 2136   2248   
                    let expected = crate::input::RpcV2CborDenseMapsInput {
 2137   2249   
                        dense_set_map: ::std::option::Option::Some({
 2138   2250   
                            let mut ret = ::std::collections::HashMap::new();
 2139   2251   
                            ret.insert(
 2140   2252   
                                "x".to_owned(),
 2141   2253   
                                vec![].try_into().expect("this is only used in tests"),
@@ -2180,2292 +2394,2518 @@
 2200   2312   
                ret
 2201   2313   
            }),
 2202   2314   
            dense_number_map: ::std::option::Option::None,
 2203   2315   
            dense_boolean_map: ::std::option::Option::None,
 2204   2316   
            dense_string_map: ::std::option::Option::None,
 2205   2317   
            dense_set_map: ::std::option::Option::None,
 2206   2318   
        };
 2207   2319   
        use ::aws_smithy_http_server::response::IntoResponse;
 2208   2320   
        let http_response = output.into_response();
 2209   2321   
        ::pretty_assertions::assert_eq!(
 2210         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        2322  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 2211   2323   
            http_response.status()
 2212   2324   
        );
 2213   2325   
        let expected_headers = [
 2214   2326   
            ("Content-Type", "application/cbor"),
 2215   2327   
            ("smithy-protocol", "rpc-v2-cbor"),
 2216   2328   
        ];
 2217   2329   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 2218   2330   
            http_response.headers(),
 2219   2331   
            expected_headers,
 2220   2332   
        ));
 2221         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        2333  +
        use ::http_body_util::BodyExt;
        2334  +
        let body = http_response
        2335  +
            .into_body()
        2336  +
            .collect()
 2222   2337   
            .await
 2223         -
            .expect("unable to extract body to bytes");
        2338  +
            .expect("unable to collect body")
        2339  +
            .to_bytes();
 2224   2340   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 2225   2341   
            &body,
 2226   2342   
            "oW5kZW5zZVN0cnVjdE1hcKJjZm9voWJoaWV0aGVyZWNiYXqhYmhpY2J5ZQ==",
 2227   2343   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 2228   2344   
        ));
 2229   2345   
    }
 2230   2346   
 2231   2347   
    /// Ensure that 0 and false are sent over the wire in all maps and lists
 2232   2348   
    /// Test ID: RpcV2CborDeserializesZeroValuesInMaps
 2233   2349   
    #[::tokio::test]
 2234   2350   
    #[::tracing_test::traced_test]
 2235   2351   
    async fn rpc_v2_cbor_deserializes_zero_values_in_maps_response() {
 2236   2352   
        let output = crate::output::RpcV2CborDenseMapsOutput {
 2237   2353   
            dense_number_map: ::std::option::Option::Some({
 2238   2354   
                let mut ret = ::std::collections::HashMap::new();
 2239   2355   
                ret.insert("x".to_owned(), 0);
 2240   2356   
                ret
 2241   2357   
            }),
 2242   2358   
            dense_boolean_map: ::std::option::Option::Some({
 2243   2359   
                let mut ret = ::std::collections::HashMap::new();
 2244   2360   
                ret.insert("x".to_owned(), false);
 2245   2361   
                ret
 2246   2362   
            }),
 2247   2363   
            dense_struct_map: ::std::option::Option::None,
 2248   2364   
            dense_string_map: ::std::option::Option::None,
 2249   2365   
            dense_set_map: ::std::option::Option::None,
 2250   2366   
        };
 2251   2367   
        use ::aws_smithy_http_server::response::IntoResponse;
 2252   2368   
        let http_response = output.into_response();
 2253   2369   
        ::pretty_assertions::assert_eq!(
 2254         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        2370  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 2255   2371   
            http_response.status()
 2256   2372   
        );
 2257   2373   
        let expected_headers = [
 2258   2374   
            ("Content-Type", "application/cbor"),
 2259   2375   
            ("smithy-protocol", "rpc-v2-cbor"),
 2260   2376   
        ];
 2261   2377   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 2262   2378   
            http_response.headers(),
 2263   2379   
            expected_headers,
 2264   2380   
        ));
 2265         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        2381  +
        use ::http_body_util::BodyExt;
        2382  +
        let body = http_response
        2383  +
            .into_body()
        2384  +
            .collect()
 2266   2385   
            .await
 2267         -
            .expect("unable to extract body to bytes");
        2386  +
            .expect("unable to collect body")
        2387  +
            .to_bytes();
 2268   2388   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 2269   2389   
            &body,
 2270   2390   
            "om5kZW5zZU51bWJlck1hcKFheABvZGVuc2VCb29sZWFuTWFwoWF49A==",
 2271   2391   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 2272   2392   
        ));
 2273   2393   
    }
 2274   2394   
 2275   2395   
    /// A response that contains a dense map of sets
 2276   2396   
    /// Test ID: RpcV2CborDeserializesDenseSetMap
 2277   2397   
    #[::tokio::test]
 2278   2398   
    #[::tracing_test::traced_test]
 2279   2399   
    async fn rpc_v2_cbor_deserializes_dense_set_map_response() {
 2280   2400   
        let output = crate::output::RpcV2CborDenseMapsOutput {
 2281   2401   
            dense_set_map: ::std::option::Option::Some({
 2282   2402   
                let mut ret = ::std::collections::HashMap::new();
 2283   2403   
                ret.insert(
 2284   2404   
                    "x".to_owned(),
 2285   2405   
                    vec![].try_into().expect("this is only used in tests"),
 2286   2406   
                );
 2287   2407   
                ret.insert(
 2288   2408   
                    "y".to_owned(),
 2289   2409   
                    vec!["a".to_owned(), "b".to_owned()]
 2290   2410   
                        .try_into()
 2291   2411   
                        .expect("this is only used in tests"),
 2292   2412   
                );
 2293   2413   
                ret
 2294   2414   
            }),
 2295   2415   
            dense_struct_map: ::std::option::Option::None,
 2296   2416   
            dense_number_map: ::std::option::Option::None,
 2297   2417   
            dense_boolean_map: ::std::option::Option::None,
 2298   2418   
            dense_string_map: ::std::option::Option::None,
 2299   2419   
        };
 2300   2420   
        use ::aws_smithy_http_server::response::IntoResponse;
 2301   2421   
        let http_response = output.into_response();
 2302   2422   
        ::pretty_assertions::assert_eq!(
 2303         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        2423  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 2304   2424   
            http_response.status()
 2305   2425   
        );
 2306   2426   
        let expected_headers = [
 2307   2427   
            ("Content-Type", "application/cbor"),
 2308   2428   
            ("smithy-protocol", "rpc-v2-cbor"),
 2309   2429   
        ];
 2310   2430   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 2311   2431   
            http_response.headers(),
 2312   2432   
            expected_headers,
 2313   2433   
        ));
 2314         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        2434  +
        use ::http_body_util::BodyExt;
        2435  +
        let body = http_response
        2436  +
            .into_body()
        2437  +
            .collect()
 2315   2438   
            .await
 2316         -
            .expect("unable to extract body to bytes");
        2439  +
            .expect("unable to collect body")
        2440  +
            .to_bytes();
 2317   2441   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 2318   2442   
            &body,
 2319   2443   
            "oWtkZW5zZVNldE1hcKJheIBheYJhYWFi",
 2320   2444   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 2321   2445   
        ));
 2322   2446   
    }
 2323   2447   
}
 2324   2448   
 2325   2449   
::pin_project_lite::pin_project! {
 2326   2450   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 2327   2451   
    /// [`RpcV2CborListsInput`](crate::input::RpcV2CborListsInput) using modelled bindings.
 2328   2452   
    pub struct RpcV2CborListsInputFuture {
 2329   2453   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::RpcV2CborListsInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 2330   2454   
    }
 2331   2455   
}
 2332   2456   
 2333   2457   
impl std::future::Future for RpcV2CborListsInputFuture {
 2334   2458   
    type Output = Result<
 2335   2459   
        crate::input::RpcV2CborListsInput,
 2336   2460   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 2337   2461   
    >;
 2338   2462   
 2339   2463   
    fn poll(
 2340   2464   
        self: std::pin::Pin<&mut Self>,
 2341   2465   
        cx: &mut std::task::Context<'_>,
 2342   2466   
    ) -> std::task::Poll<Self::Output> {
 2343   2467   
        let this = self.project();
 2344   2468   
        this.inner.as_mut().poll(cx)
 2345   2469   
    }
 2346   2470   
}
 2347   2471   
 2348   2472   
impl<B>
 2349   2473   
    ::aws_smithy_http_server::request::FromRequest<
 2350   2474   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 2351   2475   
        B,
 2352   2476   
    > for crate::input::RpcV2CborListsInput
 2353   2477   
where
 2354   2478   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 2355   2479   
    B: 'static,
 2356   2480   
 2357   2481   
    B::Data: Send,
 2358   2482   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 2359   2483   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 2360   2484   
{
 2361   2485   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 2362   2486   
    type Future = RpcV2CborListsInputFuture;
 2363   2487   
 2364         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        2488  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 2365   2489   
        let fut = async move {
 2366   2490   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 2367   2491   
                request.headers(),
 2368   2492   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 2369   2493   
            ) {
 2370   2494   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 2371   2495   
            }
 2372   2496   
            crate::protocol_serde::shape_rpc_v2_cbor_lists::de_rpc_v2_cbor_lists_http_request(
 2373   2497   
                request,
 2374   2498   
            )
@@ -2411,2535 +2509,2633 @@
 2431   2555   
#[allow(unreachable_code, unused_variables)]
 2432   2556   
#[cfg(test)]
 2433   2557   
mod rpc_v2_cbor_lists_test {
 2434   2558   
 2435   2559   
    /// Serializes RpcV2 Cbor lists
 2436   2560   
    /// Test ID: RpcV2CborLists
 2437   2561   
    #[::tokio::test]
 2438   2562   
    #[::tracing_test::traced_test]
 2439   2563   
    async fn rpc_v2_cbor_lists_request() {
 2440   2564   
        #[allow(unused_mut)]
 2441         -
                    let mut http_request = http::Request::builder()
        2565  +
                    let mut http_request = ::http_1x::Request::builder()
 2442   2566   
                        .uri("/service/RpcV2Protocol/operation/RpcV2CborLists")
 2443   2567   
                        .method("POST")
 2444   2568   
        .header("Accept", "application/cbor")
 2445   2569   
        .header("Content-Type", "application/cbor")
 2446   2570   
        .header("smithy-protocol", "rpc-v2-cbor")
 2447         -
        .body(::aws_smithy_http_server::body::Body::from(
        2571  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 2448   2572   
                        ::bytes::Bytes::copy_from_slice(
 2449   2573   
                            &::aws_smithy_protocol_test::decode_body_data("v2pzdHJpbmdMaXN0gmNmb29jYmFyaXN0cmluZ1NldIJjZm9vY2JhcmtpbnRlZ2VyTGlzdIIBAmtib29sZWFuTGlzdIL19G10aW1lc3RhbXBMaXN0gsH7QdTX+/OAAADB+0HU1/vzgAAAaGVudW1MaXN0gmNGb29hMGtpbnRFbnVtTGlzdIIBAnBuZXN0ZWRTdHJpbmdMaXN0goJjZm9vY2JhcoJjYmF6Y3F1eG1zdHJ1Y3R1cmVMaXN0gqJhYWExYWJhMqJhYWEzYWJhNGhibG9iTGlzdIJDZm9vQ2Jhcv8=".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 2450   2574   
                        )
 2451         -
                                )).unwrap();
        2575  +
                        ))).unwrap();
 2452   2576   
        #[allow(unused_mut)]
 2453   2577   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2454   2578   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2455         -
        let service =
 2456         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2579  +
        let service = crate::service::RpcV2Protocol::builder::<
        2580  +
            ::aws_smithy_http_server::body::BoxBody,
        2581  +
            _,
        2582  +
            _,
        2583  +
            _,
        2584  +
        >(config)
 2457   2585   
        .rpc_v2_cbor_lists(move |input: crate::input::RpcV2CborListsInput| {
 2458   2586   
            let sender = sender.clone();
 2459   2587   
            async move {
 2460   2588   
                let result = {
 2461   2589   
                    let expected = crate::input::RpcV2CborListsInput {
 2462   2590   
                        string_list: ::std::option::Option::Some(vec![
 2463   2591   
                            "foo".to_owned(),
 2464   2592   
                            "bar".to_owned(),
 2465   2593   
                        ]),
 2466   2594   
                        string_set: ::std::option::Option::Some(
 2467   2595   
                            vec!["foo".to_owned(), "bar".to_owned()]
 2468   2596   
                                .try_into()
 2469   2597   
                                .expect("this is only used in tests"),
 2470   2598   
                        ),
 2471   2599   
                        integer_list: ::std::option::Option::Some(vec![1, 2]),
 2472   2600   
                        boolean_list: ::std::option::Option::Some(vec![true, false]),
 2473   2601   
                        timestamp_list: ::std::option::Option::Some(vec![
 2474         -
                                    ::aws_smithy_types::DateTime::from_fractional_secs(
 2475         -
                                        1398796238, 0_f64,
 2476         -
                                    ),
 2477         -
                                    ::aws_smithy_types::DateTime::from_fractional_secs(
 2478         -
                                        1398796238, 0_f64,
 2479         -
                                    ),
        2602  +
                            ::aws_smithy_types::DateTime::from_fractional_secs(1398796238, 0_f64),
        2603  +
                            ::aws_smithy_types::DateTime::from_fractional_secs(1398796238, 0_f64),
 2480   2604   
                        ]),
 2481   2605   
                        enum_list: ::std::option::Option::Some(vec![
 2482   2606   
                            "Foo"
 2483   2607   
                                .parse::<crate::model::FooEnum>()
 2484   2608   
                                .expect("static value validated to member"),
 2485   2609   
                            "0".parse::<crate::model::FooEnum>()
 2486   2610   
                                .expect("static value validated to member"),
 2487   2611   
                        ]),
 2488   2612   
                        int_enum_list: ::std::option::Option::Some(vec![1, 2]),
 2489   2613   
                        nested_string_list: ::std::option::Option::Some(vec![
@@ -2513,2637 +2800,2942 @@
 2533   2657   
            "we expected operation handler to be invoked but it was not entered"
 2534   2658   
        );
 2535   2659   
    }
 2536   2660   
 2537   2661   
    /// Serializes empty JSON lists
 2538   2662   
    /// Test ID: RpcV2CborListsEmpty
 2539   2663   
    #[::tokio::test]
 2540   2664   
    #[::tracing_test::traced_test]
 2541   2665   
    async fn rpc_v2_cbor_lists_empty_request() {
 2542   2666   
        #[allow(unused_mut)]
 2543         -
        let mut http_request = http::Request::builder()
        2667  +
        let mut http_request = ::http_1x::Request::builder()
 2544   2668   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborLists")
 2545   2669   
            .method("POST")
 2546   2670   
            .header("Accept", "application/cbor")
 2547   2671   
            .header("Content-Type", "application/cbor")
 2548   2672   
            .header("smithy-protocol", "rpc-v2-cbor")
 2549         -
            .body(::aws_smithy_http_server::body::Body::from(
 2550         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        2673  +
            .body(::aws_smithy_http_server::body::boxed(
        2674  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        2675  +
                    &::aws_smithy_protocol_test::decode_body_data(
 2551   2676   
                        "v2pzdHJpbmdMaXN0n///".as_bytes(),
 2552   2677   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        2678  +
                    ),
 2553   2679   
                )),
 2554   2680   
            ))
 2555   2681   
            .unwrap();
 2556   2682   
        #[allow(unused_mut)]
 2557   2683   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2558   2684   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2559         -
        let service =
 2560         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2685  +
        let service = crate::service::RpcV2Protocol::builder::<
        2686  +
            ::aws_smithy_http_server::body::BoxBody,
        2687  +
            _,
        2688  +
            _,
        2689  +
            _,
        2690  +
        >(config)
 2561   2691   
        .rpc_v2_cbor_lists(move |input: crate::input::RpcV2CborListsInput| {
 2562   2692   
            let sender = sender.clone();
 2563   2693   
            async move {
 2564   2694   
                let result = {
 2565   2695   
                    let expected = crate::input::RpcV2CborListsInput {
 2566   2696   
                        string_list: ::std::option::Option::Some(vec![]),
 2567   2697   
                        string_set: ::std::option::Option::None,
 2568   2698   
                        integer_list: ::std::option::Option::None,
 2569   2699   
                        boolean_list: ::std::option::Option::None,
 2570   2700   
                        timestamp_list: ::std::option::Option::None,
 2571   2701   
                        enum_list: ::std::option::Option::None,
 2572   2702   
                        int_enum_list: ::std::option::Option::None,
 2573   2703   
                        nested_string_list: ::std::option::Option::None,
 2574   2704   
                        structure_list: ::std::option::Option::None,
 2575   2705   
                        blob_list: ::std::option::Option::None,
 2576   2706   
                    };
 2577   2707   
                    ::pretty_assertions::assert_eq!(input, expected);
 2578   2708   
                    let output = crate::output::RpcV2CborListsOutput {
 2579   2709   
                        string_list: ::std::option::Option::None,
 2580   2710   
                        string_set: ::std::option::Option::None,
 2581   2711   
                        integer_list: ::std::option::Option::None,
 2582   2712   
                        boolean_list: ::std::option::Option::None,
 2583   2713   
                        timestamp_list: ::std::option::Option::None,
 2584   2714   
                        enum_list: ::std::option::Option::None,
 2585   2715   
                        int_enum_list: ::std::option::Option::None,
 2586   2716   
                        nested_string_list: ::std::option::Option::None,
 2587   2717   
                        structure_list: ::std::option::Option::None,
 2588   2718   
                        blob_list: ::std::option::Option::None,
 2589   2719   
                    };
 2590   2720   
                    Ok(output)
 2591   2721   
                };
 2592   2722   
                sender.send(()).await.expect("receiver dropped early");
 2593   2723   
                result
 2594   2724   
            }
 2595   2725   
        })
 2596   2726   
        .build_unchecked();
 2597   2727   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 2598   2728   
            .await
 2599   2729   
            .expect("unable to make an HTTP request");
 2600   2730   
        assert!(
 2601   2731   
            receiver.recv().await.is_some(),
 2602   2732   
            "we expected operation handler to be invoked but it was not entered"
 2603   2733   
        );
 2604   2734   
    }
 2605   2735   
 2606   2736   
    /// Serializes empty JSON definite length lists
 2607   2737   
    /// Test ID: RpcV2CborListsEmptyUsingDefiniteLength
 2608   2738   
    #[::tokio::test]
 2609   2739   
    #[::tracing_test::traced_test]
 2610   2740   
    async fn rpc_v2_cbor_lists_empty_using_definite_length_request() {
 2611   2741   
        #[allow(unused_mut)]
 2612         -
        let mut http_request = http::Request::builder()
        2742  +
        let mut http_request = ::http_1x::Request::builder()
 2613   2743   
            .uri("/service/RpcV2Protocol/operation/RpcV2CborLists")
 2614   2744   
            .method("POST")
 2615   2745   
            .header("Accept", "application/cbor")
 2616   2746   
            .header("Content-Type", "application/cbor")
 2617   2747   
            .header("smithy-protocol", "rpc-v2-cbor")
 2618         -
            .body(::aws_smithy_http_server::body::Body::from(
 2619         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        2748  +
            .body(::aws_smithy_http_server::body::boxed(
        2749  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        2750  +
                    &::aws_smithy_protocol_test::decode_body_data(
 2620   2751   
                        "oWpzdHJpbmdMaXN0gA==".as_bytes(),
 2621   2752   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        2753  +
                    ),
 2622   2754   
                )),
 2623   2755   
            ))
 2624   2756   
            .unwrap();
 2625   2757   
        #[allow(unused_mut)]
 2626   2758   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2627   2759   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2628         -
        let service =
 2629         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        2760  +
        let service = crate::service::RpcV2Protocol::builder::<
        2761  +
            ::aws_smithy_http_server::body::BoxBody,
        2762  +
            _,
        2763  +
            _,
        2764  +
            _,
        2765  +
        >(config)
 2630   2766   
        .rpc_v2_cbor_lists(move |input: crate::input::RpcV2CborListsInput| {
 2631   2767   
            let sender = sender.clone();
 2632   2768   
            async move {
 2633   2769   
                let result = {
 2634   2770   
                    let expected = crate::input::RpcV2CborListsInput {
 2635   2771   
                        string_list: ::std::option::Option::Some(vec![]),
 2636   2772   
                        string_set: ::std::option::Option::None,
 2637   2773   
                        integer_list: ::std::option::Option::None,
 2638   2774   
                        boolean_list: ::std::option::Option::None,
 2639   2775   
                        timestamp_list: ::std::option::Option::None,
 2640   2776   
                        enum_list: ::std::option::Option::None,
 2641   2777   
                        int_enum_list: ::std::option::Option::None,
 2642   2778   
                        nested_string_list: ::std::option::Option::None,
 2643   2779   
                        structure_list: ::std::option::Option::None,
 2644   2780   
                        blob_list: ::std::option::Option::None,
 2645   2781   
                    };
 2646   2782   
                    ::pretty_assertions::assert_eq!(input, expected);
 2647   2783   
                    let output = crate::output::RpcV2CborListsOutput {
 2648   2784   
                        string_list: ::std::option::Option::None,
 2649   2785   
                        string_set: ::std::option::Option::None,
 2650   2786   
                        integer_list: ::std::option::Option::None,
 2651   2787   
                        boolean_list: ::std::option::Option::None,
 2652   2788   
                        timestamp_list: ::std::option::Option::None,
 2653   2789   
                        enum_list: ::std::option::Option::None,
 2654   2790   
                        int_enum_list: ::std::option::Option::None,
 2655   2791   
                        nested_string_list: ::std::option::Option::None,
 2656   2792   
                        structure_list: ::std::option::Option::None,
 2657   2793   
                        blob_list: ::std::option::Option::None,
 2658   2794   
                    };
 2659   2795   
                    Ok(output)
 2660   2796   
                };
 2661   2797   
                sender.send(()).await.expect("receiver dropped early");
 2662   2798   
                result
 2663   2799   
            }
 2664   2800   
        })
 2665   2801   
        .build_unchecked();
 2666   2802   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 2667   2803   
            .await
 2668   2804   
            .expect("unable to make an HTTP request");
 2669   2805   
        assert!(
 2670   2806   
            receiver.recv().await.is_some(),
 2671   2807   
            "we expected operation handler to be invoked but it was not entered"
 2672   2808   
        );
 2673   2809   
    }
 2674   2810   
 2675   2811   
    /// Can deserialize indefinite length text strings inside an indefinite length list
 2676   2812   
    /// Test ID: RpcV2CborIndefiniteStringInsideIndefiniteList
 2677   2813   
    #[::tokio::test]
 2678   2814   
    #[::tracing_test::traced_test]
 2679   2815   
    async fn rpc_v2_cbor_indefinite_string_inside_indefinite_list_request() {
 2680   2816   
        #[allow(unused_mut)]
 2681         -
                    let mut http_request = http::Request::builder()
        2817  +
                    let mut http_request = ::http_1x::Request::builder()
 2682   2818   
                        .uri("/service/RpcV2Protocol/operation/RpcV2CborLists")
 2683   2819   
                        .method("POST")
 2684   2820   
        .header("Accept", "application/cbor")
 2685   2821   
        .header("Content-Type", "application/cbor")
 2686   2822   
        .header("smithy-protocol", "rpc-v2-cbor")
 2687         -
        .body(::aws_smithy_http_server::body::Body::from(
        2823  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 2688   2824   
                        ::bytes::Bytes::copy_from_slice(
 2689   2825   
                            &::aws_smithy_protocol_test::decode_body_data("v2pzdHJpbmdMaXN0n394HUFuIGV4YW1wbGUgaW5kZWZpbml0ZSBzdHJpbmcsdyB3aGljaCB3aWxsIGJlIGNodW5rZWQsbiBvbiBlYWNoIGNvbW1h/394NUFub3RoZXIgZXhhbXBsZSBpbmRlZmluaXRlIHN0cmluZyB3aXRoIG9ubHkgb25lIGNodW5r/3ZUaGlzIGlzIGEgcGxhaW4gc3RyaW5n//8=".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 2690   2826   
                        )
 2691         -
                                )).unwrap();
        2827  +
                        ))).unwrap();
 2692   2828   
        #[allow(unused_mut)]
 2693   2829   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2694   2830   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2695         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
 2696         -
            config,
 2697         -
        )
        2831  +
        let service = crate::service::RpcV2Protocol::builder::<
        2832  +
            ::aws_smithy_http_server::body::BoxBody,
        2833  +
            _,
        2834  +
            _,
        2835  +
            _,
        2836  +
        >(config)
 2698   2837   
        .rpc_v2_cbor_lists(move |input: crate::input::RpcV2CborListsInput| {
 2699   2838   
            let sender = sender.clone();
 2700   2839   
            async move {
 2701   2840   
                let result = {
 2702   2841   
                    let expected = crate::input::RpcV2CborListsInput {
 2703   2842   
                        string_list: ::std::option::Option::Some(vec![
 2704   2843   
                            "An example indefinite string, which will be chunked, on each comma"
 2705   2844   
                                .to_owned(),
 2706   2845   
                            "Another example indefinite string with only one chunk".to_owned(),
 2707   2846   
                            "This is a plain string".to_owned(),
 2708   2847   
                        ]),
 2709   2848   
                        string_set: ::std::option::Option::None,
 2710   2849   
                        integer_list: ::std::option::Option::None,
 2711   2850   
                        boolean_list: ::std::option::Option::None,
 2712   2851   
                        timestamp_list: ::std::option::Option::None,
 2713   2852   
                        enum_list: ::std::option::Option::None,
 2714   2853   
                        int_enum_list: ::std::option::Option::None,
 2715   2854   
                        nested_string_list: ::std::option::Option::None,
 2716   2855   
                        structure_list: ::std::option::Option::None,
 2717   2856   
                        blob_list: ::std::option::Option::None,
 2718   2857   
                    };
 2719   2858   
                    ::pretty_assertions::assert_eq!(input, expected);
 2720   2859   
                    let output = crate::output::RpcV2CborListsOutput {
 2721   2860   
                        string_list: ::std::option::Option::None,
 2722   2861   
                        string_set: ::std::option::Option::None,
 2723   2862   
                        integer_list: ::std::option::Option::None,
 2724   2863   
                        boolean_list: ::std::option::Option::None,
 2725   2864   
                        timestamp_list: ::std::option::Option::None,
 2726   2865   
                        enum_list: ::std::option::Option::None,
 2727   2866   
                        int_enum_list: ::std::option::Option::None,
 2728   2867   
                        nested_string_list: ::std::option::Option::None,
 2729   2868   
                        structure_list: ::std::option::Option::None,
 2730   2869   
                        blob_list: ::std::option::Option::None,
 2731   2870   
                    };
 2732   2871   
                    Ok(output)
 2733   2872   
                };
 2734   2873   
                sender.send(()).await.expect("receiver dropped early");
 2735   2874   
                result
 2736   2875   
            }
 2737   2876   
        })
 2738   2877   
        .build_unchecked();
 2739   2878   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 2740   2879   
            .await
 2741   2880   
            .expect("unable to make an HTTP request");
 2742   2881   
        assert!(
 2743   2882   
            receiver.recv().await.is_some(),
 2744   2883   
            "we expected operation handler to be invoked but it was not entered"
 2745   2884   
        );
 2746   2885   
    }
 2747   2886   
 2748   2887   
    /// Can deserialize indefinite length text strings inside a definite length list
 2749   2888   
    /// Test ID: RpcV2CborIndefiniteStringInsideDefiniteList
 2750   2889   
    #[::tokio::test]
 2751   2890   
    #[::tracing_test::traced_test]
 2752   2891   
    async fn rpc_v2_cbor_indefinite_string_inside_definite_list_request() {
 2753   2892   
        #[allow(unused_mut)]
 2754         -
                    let mut http_request = http::Request::builder()
        2893  +
                    let mut http_request = ::http_1x::Request::builder()
 2755   2894   
                        .uri("/service/RpcV2Protocol/operation/RpcV2CborLists")
 2756   2895   
                        .method("POST")
 2757   2896   
        .header("Accept", "application/cbor")
 2758   2897   
        .header("Content-Type", "application/cbor")
 2759   2898   
        .header("smithy-protocol", "rpc-v2-cbor")
 2760         -
        .body(::aws_smithy_http_server::body::Body::from(
        2899  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 2761   2900   
                        ::bytes::Bytes::copy_from_slice(
 2762   2901   
                            &::aws_smithy_protocol_test::decode_body_data("oWpzdHJpbmdMaXN0g394HUFuIGV4YW1wbGUgaW5kZWZpbml0ZSBzdHJpbmcsdyB3aGljaCB3aWxsIGJlIGNodW5rZWQsbiBvbiBlYWNoIGNvbW1h/394NUFub3RoZXIgZXhhbXBsZSBpbmRlZmluaXRlIHN0cmluZyB3aXRoIG9ubHkgb25lIGNodW5r/3ZUaGlzIGlzIGEgcGxhaW4gc3RyaW5n".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 2763   2902   
                        )
 2764         -
                                )).unwrap();
        2903  +
                        ))).unwrap();
 2765   2904   
        #[allow(unused_mut)]
 2766   2905   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 2767   2906   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 2768         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
 2769         -
            config,
 2770         -
        )
        2907  +
        let service = crate::service::RpcV2Protocol::builder::<
        2908  +
            ::aws_smithy_http_server::body::BoxBody,
        2909  +
            _,
        2910  +
            _,
        2911  +
            _,
        2912  +
        >(config)
 2771   2913   
        .rpc_v2_cbor_lists(move |input: crate::input::RpcV2CborListsInput| {
 2772   2914   
            let sender = sender.clone();
 2773   2915   
            async move {
 2774   2916   
                let result = {
 2775   2917   
                    let expected = crate::input::RpcV2CborListsInput {
 2776   2918   
                        string_list: ::std::option::Option::Some(vec![
 2777   2919   
                            "An example indefinite string, which will be chunked, on each comma"
 2778   2920   
                                .to_owned(),
 2779   2921   
                            "Another example indefinite string with only one chunk".to_owned(),
 2780   2922   
                            "This is a plain string".to_owned(),
@@ -2839,2981 +3084,3237 @@
 2859   3001   
                },
 2860   3002   
            ]),
 2861   3003   
            blob_list: ::std::option::Option::Some(vec![
 2862   3004   
                ::aws_smithy_types::Blob::new("foo"),
 2863   3005   
                ::aws_smithy_types::Blob::new("bar"),
 2864   3006   
            ]),
 2865   3007   
        };
 2866   3008   
        use ::aws_smithy_http_server::response::IntoResponse;
 2867   3009   
        let http_response = output.into_response();
 2868   3010   
        ::pretty_assertions::assert_eq!(
 2869         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        3011  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 2870   3012   
            http_response.status()
 2871   3013   
        );
 2872   3014   
        let expected_headers = [
 2873   3015   
            ("Content-Type", "application/cbor"),
 2874   3016   
            ("smithy-protocol", "rpc-v2-cbor"),
 2875   3017   
        ];
 2876   3018   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 2877   3019   
            http_response.headers(),
 2878   3020   
            expected_headers,
 2879   3021   
        ));
 2880         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        3022  +
        use ::http_body_util::BodyExt;
        3023  +
        let body = http_response
        3024  +
            .into_body()
        3025  +
            .collect()
 2881   3026   
            .await
 2882         -
            .expect("unable to extract body to bytes");
        3027  +
            .expect("unable to collect body")
        3028  +
            .to_bytes();
 2883   3029   
        ::aws_smithy_protocol_test::assert_ok(
 2884   3030   
        ::aws_smithy_protocol_test::validate_body(&body, "v2pzdHJpbmdMaXN0n2Nmb29jYmFy/2lzdHJpbmdTZXSfY2Zvb2NiYXL/a2ludGVnZXJMaXN0nwEC/2tib29sZWFuTGlzdJ/19P9tdGltZXN0YW1wTGlzdJ/B+0HU1/vzgAAAwftB1Nf784AAAP9oZW51bUxpc3SfY0Zvb2Ew/2tpbnRFbnVtTGlzdJ8BAv9wbmVzdGVkU3RyaW5nTGlzdJ+fY2Zvb2NiYXL/n2NiYXpjcXV4//9tc3RydWN0dXJlTGlzdJ+/YWFhMWFiYTL/v2FhYTNhYmE0//9oYmxvYkxpc3SfQ2Zvb0NiYXL//w==", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 2885   3031   
        );
 2886   3032   
    }
 2887   3033   
 2888   3034   
    /// Serializes empty RpcV2 Cbor lists
 2889   3035   
    /// Test ID: RpcV2CborListsEmpty
 2890   3036   
    #[::tokio::test]
 2891   3037   
    #[::tracing_test::traced_test]
 2892   3038   
    async fn rpc_v2_cbor_lists_empty_response() {
 2893   3039   
        let output = crate::output::RpcV2CborListsOutput {
 2894   3040   
            string_list: ::std::option::Option::Some(vec![]),
 2895   3041   
            string_set: ::std::option::Option::None,
 2896   3042   
            integer_list: ::std::option::Option::None,
 2897   3043   
            boolean_list: ::std::option::Option::None,
 2898   3044   
            timestamp_list: ::std::option::Option::None,
 2899   3045   
            enum_list: ::std::option::Option::None,
 2900   3046   
            int_enum_list: ::std::option::Option::None,
 2901   3047   
            nested_string_list: ::std::option::Option::None,
 2902   3048   
            structure_list: ::std::option::Option::None,
 2903   3049   
            blob_list: ::std::option::Option::None,
 2904   3050   
        };
 2905   3051   
        use ::aws_smithy_http_server::response::IntoResponse;
 2906   3052   
        let http_response = output.into_response();
 2907   3053   
        ::pretty_assertions::assert_eq!(
 2908         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        3054  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 2909   3055   
            http_response.status()
 2910   3056   
        );
 2911   3057   
        let expected_headers = [
 2912   3058   
            ("Content-Type", "application/cbor"),
 2913   3059   
            ("smithy-protocol", "rpc-v2-cbor"),
 2914   3060   
        ];
 2915   3061   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 2916   3062   
            http_response.headers(),
 2917   3063   
            expected_headers,
 2918   3064   
        ));
 2919         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        3065  +
        use ::http_body_util::BodyExt;
        3066  +
        let body = http_response
        3067  +
            .into_body()
        3068  +
            .collect()
 2920   3069   
            .await
 2921         -
            .expect("unable to extract body to bytes");
        3070  +
            .expect("unable to collect body")
        3071  +
            .to_bytes();
 2922   3072   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 2923   3073   
            &body,
 2924   3074   
            "v2pzdHJpbmdMaXN0n///",
 2925   3075   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 2926   3076   
        ));
 2927   3077   
    }
 2928   3078   
}
 2929   3079   
 2930   3080   
::pin_project_lite::pin_project! {
 2931   3081   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 2932   3082   
    /// [`SimpleScalarPropertiesInput`](crate::input::SimpleScalarPropertiesInput) using modelled bindings.
 2933   3083   
    pub struct SimpleScalarPropertiesInputFuture {
 2934   3084   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::SimpleScalarPropertiesInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 2935   3085   
    }
 2936   3086   
}
 2937   3087   
 2938   3088   
impl std::future::Future for SimpleScalarPropertiesInputFuture {
 2939   3089   
    type Output = Result<
 2940   3090   
        crate::input::SimpleScalarPropertiesInput,
 2941   3091   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 2942   3092   
    >;
 2943   3093   
 2944   3094   
    fn poll(
 2945   3095   
        self: std::pin::Pin<&mut Self>,
 2946   3096   
        cx: &mut std::task::Context<'_>,
 2947   3097   
    ) -> std::task::Poll<Self::Output> {
 2948   3098   
        let this = self.project();
 2949   3099   
        this.inner.as_mut().poll(cx)
 2950   3100   
    }
 2951   3101   
}
 2952   3102   
 2953   3103   
impl<B>
 2954   3104   
    ::aws_smithy_http_server::request::FromRequest<
 2955   3105   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 2956   3106   
        B,
 2957   3107   
    > for crate::input::SimpleScalarPropertiesInput
 2958   3108   
where
 2959   3109   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 2960   3110   
    B: 'static,
 2961   3111   
 2962   3112   
    B::Data: Send,
 2963   3113   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 2964   3114   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 2965   3115   
{
 2966   3116   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 2967   3117   
    type Future = SimpleScalarPropertiesInputFuture;
 2968   3118   
 2969         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        3119  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 2970   3120   
        let fut = async move {
 2971   3121   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 2972   3122   
                request.headers(),
 2973   3123   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 2974   3124   
            ) {
 2975   3125   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 2976   3126   
            }
 2977   3127   
            crate::protocol_serde::shape_simple_scalar_properties::de_simple_scalar_properties_http_request(request)
 2978   3128   
                            .await
 2979   3129   
        };
 2980   3130   
        use ::futures_util::future::TryFutureExt;
 2981   3131   
        let fut = fut.map_err(
 2982   3132   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
 2983   3133   
                ::tracing::debug!(error = %e, "failed to deserialize request");
 2984   3134   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
 2985   3135   
                    e,
 2986   3136   
                )
 2987   3137   
            },
 2988   3138   
        );
 2989   3139   
        SimpleScalarPropertiesInputFuture {
 2990   3140   
            inner: Box::pin(fut),
 2991   3141   
        }
 2992   3142   
    }
 2993   3143   
}
 2994   3144   
impl
 2995   3145   
    ::aws_smithy_http_server::response::IntoResponse<
 2996   3146   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 2997   3147   
    > for crate::output::SimpleScalarPropertiesOutput
 2998   3148   
{
 2999   3149   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
 3000   3150   
        match crate::protocol_serde::shape_simple_scalar_properties::ser_simple_scalar_properties_http_response(self) {
 3001   3151   
                        Ok(response) => response,
 3002   3152   
                        Err(e) => {
 3003   3153   
                            ::tracing::error!(error = %e, "failed to serialize response");
 3004   3154   
                            ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
 3005   3155   
                        }
 3006   3156   
                    }
 3007   3157   
    }
 3008   3158   
}
 3009   3159   
 3010   3160   
#[allow(unreachable_code, unused_variables)]
 3011   3161   
#[cfg(test)]
 3012   3162   
mod simple_scalar_properties_test {
 3013   3163   
 3014   3164   
    /// Serializes simple scalar properties
 3015   3165   
    /// Test ID: RpcV2CborSimpleScalarProperties
 3016   3166   
    #[::tokio::test]
 3017   3167   
    #[::tracing_test::traced_test]
 3018   3168   
    async fn rpc_v2_cbor_simple_scalar_properties_request() {
 3019   3169   
        #[allow(unused_mut)]
 3020         -
                    let mut http_request = http::Request::builder()
        3170  +
                    let mut http_request = ::http_1x::Request::builder()
 3021   3171   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3022   3172   
                        .method("POST")
 3023   3173   
        .header("Accept", "application/cbor")
 3024   3174   
        .header("Content-Type", "application/cbor")
 3025   3175   
        .header("smithy-protocol", "rpc-v2-cbor")
 3026         -
        .body(::aws_smithy_http_server::body::Body::from(
        3176  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 3027   3177   
                        ::bytes::Bytes::copy_from_slice(
 3028   3178   
                            &::aws_smithy_protocol_test::decode_body_data("v2lieXRlVmFsdWUFa2RvdWJsZVZhbHVl+z/+OVgQYk3TcWZhbHNlQm9vbGVhblZhbHVl9GpmbG9hdFZhbHVl+kD0AABsaW50ZWdlclZhbHVlGQEAaWxvbmdWYWx1ZRkmkWpzaG9ydFZhbHVlGSaqa3N0cmluZ1ZhbHVlZnNpbXBsZXB0cnVlQm9vbGVhblZhbHVl9WlibG9iVmFsdWVDZm9v/w==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 3029   3179   
                        )
 3030         -
                                )).unwrap();
        3180  +
                        ))).unwrap();
 3031   3181   
        #[allow(unused_mut)]
 3032   3182   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3033   3183   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3034         -
        let service =
 3035         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 3036         -
                .simple_scalar_properties(
 3037         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        3184  +
        let service = crate::service::RpcV2Protocol::builder::<
        3185  +
            ::aws_smithy_http_server::body::BoxBody,
        3186  +
            _,
        3187  +
            _,
        3188  +
            _,
        3189  +
        >(config)
        3190  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3038   3191   
            let sender = sender.clone();
 3039   3192   
            async move {
 3040   3193   
                let result = {
 3041   3194   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3042   3195   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3043   3196   
                        byte_value: ::std::option::Option::Some(5),
 3044   3197   
                        double_value: ::std::option::Option::Some(1.889_f64),
 3045   3198   
                        false_boolean_value: ::std::option::Option::Some(false),
 3046   3199   
                        float_value: ::std::option::Option::Some(7.625_f32),
 3047   3200   
                        integer_value: ::std::option::Option::Some(256),
 3048   3201   
                        long_value: ::std::option::Option::Some(9873),
 3049   3202   
                        short_value: ::std::option::Option::Some(9898),
 3050   3203   
                        string_value: ::std::option::Option::Some("simple".to_owned()),
 3051   3204   
                        true_boolean_value: ::std::option::Option::Some(true),
 3052         -
                                    blob_value: ::std::option::Option::Some(
 3053         -
                                        ::aws_smithy_types::Blob::new("foo"),
 3054         -
                                    ),
        3205  +
                        blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new(
        3206  +
                            "foo",
        3207  +
                        )),
 3055   3208   
                    };
 3056   3209   
                    ::pretty_assertions::assert_eq!(
 3057   3210   
                        input.true_boolean_value,
 3058   3211   
                        expected.true_boolean_value,
 3059   3212   
                        "Unexpected value for `true_boolean_value`"
 3060   3213   
                    );
 3061   3214   
                    ::pretty_assertions::assert_eq!(
 3062   3215   
                        input.false_boolean_value,
 3063   3216   
                        expected.false_boolean_value,
 3064   3217   
                        "Unexpected value for `false_boolean_value`"
@@ -3095,3248 +3209,3364 @@
 3115   3268   
                        long_value: ::std::option::Option::None,
 3116   3269   
                        short_value: ::std::option::Option::None,
 3117   3270   
                        string_value: ::std::option::Option::None,
 3118   3271   
                        blob_value: ::std::option::Option::None,
 3119   3272   
                    };
 3120   3273   
                    output
 3121   3274   
                };
 3122   3275   
                sender.send(()).await.expect("receiver dropped early");
 3123   3276   
                result
 3124   3277   
            }
 3125         -
                    },
 3126         -
                )
        3278  +
        })
 3127   3279   
        .build_unchecked();
 3128   3280   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 3129   3281   
            .await
 3130   3282   
            .expect("unable to make an HTTP request");
 3131   3283   
        assert!(
 3132   3284   
            receiver.recv().await.is_some(),
 3133   3285   
            "we expected operation handler to be invoked but it was not entered"
 3134   3286   
        );
 3135   3287   
    }
 3136   3288   
 3137   3289   
    /// The server should be capable of deserializing simple scalar properties
 3138   3290   
    /// encoded using a map with a definite length. The server should also be able to parse
 3139   3291   
    /// a key encoded using an indefinite length string.
 3140   3292   
    /// Test ID: RpcV2CborSimpleScalarPropertiesUsingIndefiniteLength
 3141   3293   
    #[::tokio::test]
 3142   3294   
    #[::tracing_test::traced_test]
 3143   3295   
    async fn rpc_v2_cbor_simple_scalar_properties_using_indefinite_length_request() {
 3144   3296   
        #[allow(unused_mut)]
 3145         -
                    let mut http_request = http::Request::builder()
        3297  +
                    let mut http_request = ::http_1x::Request::builder()
 3146   3298   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3147   3299   
                        .method("POST")
 3148   3300   
        .header("Accept", "application/cbor")
 3149   3301   
        .header("Content-Type", "application/cbor")
 3150   3302   
        .header("smithy-protocol", "rpc-v2-cbor")
 3151         -
        .body(::aws_smithy_http_server::body::Body::from(
        3303  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 3152   3304   
                        ::bytes::Bytes::copy_from_slice(
 3153   3305   
                            &::aws_smithy_protocol_test::decode_body_data("qmlieXRlVmFsdWUFf2Zkb3VibGVlVmFsdWX/+z/+OVgQYk3Tf2VmYWxzZWdCb29sZWFuZVZhbHVl//RqZmxvYXRWYWx1ZfpA9AAAbGludGVnZXJWYWx1ZRkBAGlsb25nVmFsdWUZJpFqc2hvcnRWYWx1ZRkmqn9mc3RyaW5nZVZhbHVl/2ZzaW1wbGVwdHJ1ZUJvb2xlYW5WYWx1ZfVpYmxvYlZhbHVlQ2Zvbw==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 3154   3306   
                        )
 3155         -
                                )).unwrap();
        3307  +
                        ))).unwrap();
 3156   3308   
        #[allow(unused_mut)]
 3157   3309   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3158   3310   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3159         -
        let service =
 3160         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 3161         -
                .simple_scalar_properties(
 3162         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        3311  +
        let service = crate::service::RpcV2Protocol::builder::<
        3312  +
            ::aws_smithy_http_server::body::BoxBody,
        3313  +
            _,
        3314  +
            _,
        3315  +
            _,
        3316  +
        >(config)
        3317  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3163   3318   
            let sender = sender.clone();
 3164   3319   
            async move {
 3165   3320   
                let result = {
 3166   3321   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3167   3322   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3168   3323   
                        byte_value: ::std::option::Option::Some(5),
 3169   3324   
                        double_value: ::std::option::Option::Some(1.889_f64),
 3170   3325   
                        false_boolean_value: ::std::option::Option::Some(false),
 3171   3326   
                        float_value: ::std::option::Option::Some(7.625_f32),
 3172   3327   
                        integer_value: ::std::option::Option::Some(256),
 3173   3328   
                        long_value: ::std::option::Option::Some(9873),
 3174   3329   
                        short_value: ::std::option::Option::Some(9898),
 3175   3330   
                        string_value: ::std::option::Option::Some("simple".to_owned()),
 3176   3331   
                        true_boolean_value: ::std::option::Option::Some(true),
 3177         -
                                    blob_value: ::std::option::Option::Some(
 3178         -
                                        ::aws_smithy_types::Blob::new("foo"),
 3179         -
                                    ),
        3332  +
                        blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new(
        3333  +
                            "foo",
        3334  +
                        )),
 3180   3335   
                    };
 3181   3336   
                    ::pretty_assertions::assert_eq!(
 3182   3337   
                        input.true_boolean_value,
 3183   3338   
                        expected.true_boolean_value,
 3184   3339   
                        "Unexpected value for `true_boolean_value`"
 3185   3340   
                    );
 3186   3341   
                    ::pretty_assertions::assert_eq!(
 3187   3342   
                        input.false_boolean_value,
 3188   3343   
                        expected.false_boolean_value,
 3189   3344   
                        "Unexpected value for `false_boolean_value`"
@@ -3220,3375 +3317,3476 @@
 3240   3395   
                        long_value: ::std::option::Option::None,
 3241   3396   
                        short_value: ::std::option::Option::None,
 3242   3397   
                        string_value: ::std::option::Option::None,
 3243   3398   
                        blob_value: ::std::option::Option::None,
 3244   3399   
                    };
 3245   3400   
                    output
 3246   3401   
                };
 3247   3402   
                sender.send(()).await.expect("receiver dropped early");
 3248   3403   
                result
 3249   3404   
            }
 3250         -
                    },
 3251         -
                )
        3405  +
        })
 3252   3406   
        .build_unchecked();
 3253   3407   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 3254   3408   
            .await
 3255   3409   
            .expect("unable to make an HTTP request");
 3256   3410   
        assert!(
 3257   3411   
            receiver.recv().await.is_some(),
 3258   3412   
            "we expected operation handler to be invoked but it was not entered"
 3259   3413   
        );
 3260   3414   
    }
 3261   3415   
 3262   3416   
    /// RpcV2 Cbor should not deserialize null structure values
 3263   3417   
    /// Test ID: RpcV2CborServerDoesntDeSerializeNullStructureValues
 3264   3418   
    #[::tokio::test]
 3265   3419   
    #[::tracing_test::traced_test]
 3266   3420   
    async fn rpc_v2_cbor_server_doesnt_de_serialize_null_structure_values_request() {
 3267   3421   
        #[allow(unused_mut)]
 3268         -
        let mut http_request = http::Request::builder()
        3422  +
        let mut http_request = ::http_1x::Request::builder()
 3269   3423   
            .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3270   3424   
            .method("POST")
 3271   3425   
            .header("Accept", "application/cbor")
 3272   3426   
            .header("Content-Type", "application/cbor")
 3273   3427   
            .header("smithy-protocol", "rpc-v2-cbor")
 3274         -
            .body(::aws_smithy_http_server::body::Body::from(
 3275         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        3428  +
            .body(::aws_smithy_http_server::body::boxed(
        3429  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        3430  +
                    &::aws_smithy_protocol_test::decode_body_data(
 3276   3431   
                        "v2tzdHJpbmdWYWx1Zfb/".as_bytes(),
 3277   3432   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        3433  +
                    ),
 3278   3434   
                )),
 3279   3435   
            ))
 3280   3436   
            .unwrap();
 3281   3437   
        #[allow(unused_mut)]
 3282   3438   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3283   3439   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3284         -
        let service =
 3285         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 3286         -
                .simple_scalar_properties(
 3287         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        3440  +
        let service = crate::service::RpcV2Protocol::builder::<
        3441  +
            ::aws_smithy_http_server::body::BoxBody,
        3442  +
            _,
        3443  +
            _,
        3444  +
            _,
        3445  +
        >(config)
        3446  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3288   3447   
            let sender = sender.clone();
 3289   3448   
            async move {
 3290   3449   
                let result = {
 3291   3450   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3292   3451   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3293   3452   
                        true_boolean_value: ::std::option::Option::None,
 3294   3453   
                        false_boolean_value: ::std::option::Option::None,
 3295   3454   
                        byte_value: ::std::option::Option::None,
 3296   3455   
                        double_value: ::std::option::Option::None,
 3297   3456   
                        float_value: ::std::option::Option::None,
@@ -3343,3502 +3439,3602 @@
 3363   3522   
                        long_value: ::std::option::Option::None,
 3364   3523   
                        short_value: ::std::option::Option::None,
 3365   3524   
                        string_value: ::std::option::Option::None,
 3366   3525   
                        blob_value: ::std::option::Option::None,
 3367   3526   
                    };
 3368   3527   
                    output
 3369   3528   
                };
 3370   3529   
                sender.send(()).await.expect("receiver dropped early");
 3371   3530   
                result
 3372   3531   
            }
 3373         -
                    },
 3374         -
                )
        3532  +
        })
 3375   3533   
        .build_unchecked();
 3376   3534   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 3377   3535   
            .await
 3378   3536   
            .expect("unable to make an HTTP request");
 3379   3537   
        assert!(
 3380   3538   
            receiver.recv().await.is_some(),
 3381   3539   
            "we expected operation handler to be invoked but it was not entered"
 3382   3540   
        );
 3383   3541   
    }
 3384   3542   
 3385   3543   
    /// Supports handling NaN float values.
 3386   3544   
    /// Test ID: RpcV2CborSupportsNaNFloatInputs
 3387   3545   
    #[::tokio::test]
 3388   3546   
    #[::tracing_test::traced_test]
 3389   3547   
    async fn rpc_v2_cbor_supports_na_n_float_inputs_request() {
 3390   3548   
        #[allow(unused_mut)]
 3391         -
        let mut http_request = http::Request::builder()
        3549  +
        let mut http_request = ::http_1x::Request::builder()
 3392   3550   
            .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3393   3551   
            .method("POST")
 3394   3552   
            .header("Accept", "application/cbor")
 3395   3553   
            .header("Content-Type", "application/cbor")
 3396   3554   
            .header("smithy-protocol", "rpc-v2-cbor")
 3397         -
            .body(::aws_smithy_http_server::body::Body::from(
 3398         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        3555  +
            .body(::aws_smithy_http_server::body::boxed(
        3556  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        3557  +
                    &::aws_smithy_protocol_test::decode_body_data(
 3399   3558   
                        "v2tkb3VibGVWYWx1Zft/+AAAAAAAAGpmbG9hdFZhbHVl+n/AAAD/".as_bytes(),
 3400   3559   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        3560  +
                    ),
 3401   3561   
                )),
 3402   3562   
            ))
 3403   3563   
            .unwrap();
 3404   3564   
        #[allow(unused_mut)]
 3405   3565   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3406   3566   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3407         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
 3408         -
            config,
 3409         -
        )
        3567  +
        let service = crate::service::RpcV2Protocol::builder::<
        3568  +
            ::aws_smithy_http_server::body::BoxBody,
        3569  +
            _,
        3570  +
            _,
        3571  +
            _,
        3572  +
        >(config)
 3410   3573   
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3411   3574   
            let sender = sender.clone();
 3412   3575   
            async move {
 3413   3576   
                let result = {
 3414   3577   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3415   3578   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3416   3579   
                        double_value: ::std::option::Option::Some(
 3417   3580   
                            <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
 3418   3581   
                                "NaN",
 3419   3582   
                            )
@@ -3493,3656 +3571,3739 @@
 3513   3676   
            "we expected operation handler to be invoked but it was not entered"
 3514   3677   
        );
 3515   3678   
    }
 3516   3679   
 3517   3680   
    /// Supports handling Infinity float values.
 3518   3681   
    /// Test ID: RpcV2CborSupportsInfinityFloatInputs
 3519   3682   
    #[::tokio::test]
 3520   3683   
    #[::tracing_test::traced_test]
 3521   3684   
    async fn rpc_v2_cbor_supports_infinity_float_inputs_request() {
 3522   3685   
        #[allow(unused_mut)]
 3523         -
        let mut http_request = http::Request::builder()
        3686  +
        let mut http_request = ::http_1x::Request::builder()
 3524   3687   
            .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3525   3688   
            .method("POST")
 3526   3689   
            .header("Accept", "application/cbor")
 3527   3690   
            .header("Content-Type", "application/cbor")
 3528   3691   
            .header("smithy-protocol", "rpc-v2-cbor")
 3529         -
            .body(::aws_smithy_http_server::body::Body::from(
 3530         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        3692  +
            .body(::aws_smithy_http_server::body::boxed(
        3693  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        3694  +
                    &::aws_smithy_protocol_test::decode_body_data(
 3531   3695   
                        "v2tkb3VibGVWYWx1Zft/8AAAAAAAAGpmbG9hdFZhbHVl+n+AAAD/".as_bytes(),
 3532   3696   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        3697  +
                    ),
 3533   3698   
                )),
 3534   3699   
            ))
 3535   3700   
            .unwrap();
 3536   3701   
        #[allow(unused_mut)]
 3537   3702   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3538   3703   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3539         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
 3540         -
            config,
 3541         -
        )
        3704  +
        let service = crate::service::RpcV2Protocol::builder::<
        3705  +
            ::aws_smithy_http_server::body::BoxBody,
        3706  +
            _,
        3707  +
            _,
        3708  +
            _,
        3709  +
        >(config)
 3542   3710   
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3543   3711   
            let sender = sender.clone();
 3544   3712   
            async move {
 3545   3713   
                let result = {
 3546   3714   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3547   3715   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3548   3716   
                        double_value: ::std::option::Option::Some(
 3549   3717   
                            <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
 3550   3718   
                                "Infinity",
 3551   3719   
                            )
@@ -3625,3793 +3703,3876 @@
 3645   3813   
            "we expected operation handler to be invoked but it was not entered"
 3646   3814   
        );
 3647   3815   
    }
 3648   3816   
 3649   3817   
    /// Supports handling Infinity float values.
 3650   3818   
    /// Test ID: RpcV2CborSupportsNegativeInfinityFloatInputs
 3651   3819   
    #[::tokio::test]
 3652   3820   
    #[::tracing_test::traced_test]
 3653   3821   
    async fn rpc_v2_cbor_supports_negative_infinity_float_inputs_request() {
 3654   3822   
        #[allow(unused_mut)]
 3655         -
        let mut http_request = http::Request::builder()
        3823  +
        let mut http_request = ::http_1x::Request::builder()
 3656   3824   
            .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3657   3825   
            .method("POST")
 3658   3826   
            .header("Accept", "application/cbor")
 3659   3827   
            .header("Content-Type", "application/cbor")
 3660   3828   
            .header("smithy-protocol", "rpc-v2-cbor")
 3661         -
            .body(::aws_smithy_http_server::body::Body::from(
 3662         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        3829  +
            .body(::aws_smithy_http_server::body::boxed(
        3830  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        3831  +
                    &::aws_smithy_protocol_test::decode_body_data(
 3663   3832   
                        "v2tkb3VibGVWYWx1Zfv/8AAAAAAAAGpmbG9hdFZhbHVl+v+AAAD/".as_bytes(),
 3664   3833   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        3834  +
                    ),
 3665   3835   
                )),
 3666   3836   
            ))
 3667   3837   
            .unwrap();
 3668   3838   
        #[allow(unused_mut)]
 3669   3839   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3670   3840   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3671         -
        let service = crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(
 3672         -
            config,
 3673         -
        )
        3841  +
        let service = crate::service::RpcV2Protocol::builder::<
        3842  +
            ::aws_smithy_http_server::body::BoxBody,
        3843  +
            _,
        3844  +
            _,
        3845  +
            _,
        3846  +
        >(config)
 3674   3847   
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3675   3848   
            let sender = sender.clone();
 3676   3849   
            async move {
 3677   3850   
                let result = {
 3678   3851   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3679   3852   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3680   3853   
                        double_value: ::std::option::Option::Some(
 3681   3854   
                            <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
 3682   3855   
                                "-Infinity",
 3683   3856   
                            )
@@ -3757,3930 +3834,4010 @@
 3777   3950   
            "we expected operation handler to be invoked but it was not entered"
 3778   3951   
        );
 3779   3952   
    }
 3780   3953   
 3781   3954   
    /// The server should be capable of deserializing indefinite length text strings.
 3782   3955   
    /// Test ID: RpcV2CborIndefiniteLengthStringsCanBeDeserialized
 3783   3956   
    #[::tokio::test]
 3784   3957   
    #[::tracing_test::traced_test]
 3785   3958   
    async fn rpc_v2_cbor_indefinite_length_strings_can_be_deserialized_request() {
 3786   3959   
        #[allow(unused_mut)]
 3787         -
                    let mut http_request = http::Request::builder()
        3960  +
                    let mut http_request = ::http_1x::Request::builder()
 3788   3961   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3789   3962   
                        .method("POST")
 3790   3963   
        .header("Accept", "application/cbor")
 3791   3964   
        .header("Content-Type", "application/cbor")
 3792   3965   
        .header("smithy-protocol", "rpc-v2-cbor")
 3793         -
        .body(::aws_smithy_http_server::body::Body::from(
        3966  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 3794   3967   
                        ::bytes::Bytes::copy_from_slice(
 3795   3968   
                            &::aws_smithy_protocol_test::decode_body_data("oWtzdHJpbmdWYWx1ZX94HUFuIGV4YW1wbGUgaW5kZWZpbml0ZSBzdHJpbmcscSBjaHVua2VkIG9uIGNvbW1h/w==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 3796   3969   
                        )
 3797         -
                                )).unwrap();
        3970  +
                        ))).unwrap();
 3798   3971   
        #[allow(unused_mut)]
 3799   3972   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3800   3973   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3801         -
        let service =
 3802         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 3803         -
                .simple_scalar_properties(
 3804         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        3974  +
        let service = crate::service::RpcV2Protocol::builder::<
        3975  +
            ::aws_smithy_http_server::body::BoxBody,
        3976  +
            _,
        3977  +
            _,
        3978  +
            _,
        3979  +
        >(config)
        3980  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3805   3981   
            let sender = sender.clone();
 3806   3982   
            async move {
 3807   3983   
                let result = {
 3808   3984   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3809   3985   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3810   3986   
                        string_value: ::std::option::Option::Some(
 3811   3987   
                            "An example indefinite string, chunked on comma".to_owned(),
 3812   3988   
                        ),
 3813   3989   
                        true_boolean_value: ::std::option::Option::None,
 3814   3990   
                        false_boolean_value: ::std::option::Option::None,
@@ -3862,4038 +3967,4143 @@
 3882   4058   
                        long_value: ::std::option::Option::None,
 3883   4059   
                        short_value: ::std::option::Option::None,
 3884   4060   
                        string_value: ::std::option::Option::None,
 3885   4061   
                        blob_value: ::std::option::Option::None,
 3886   4062   
                    };
 3887   4063   
                    output
 3888   4064   
                };
 3889   4065   
                sender.send(()).await.expect("receiver dropped early");
 3890   4066   
                result
 3891   4067   
            }
 3892         -
                    },
 3893         -
                )
        4068  +
        })
 3894   4069   
        .build_unchecked();
 3895   4070   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 3896   4071   
            .await
 3897   4072   
            .expect("unable to make an HTTP request");
 3898   4073   
        assert!(
 3899   4074   
            receiver.recv().await.is_some(),
 3900   4075   
            "we expected operation handler to be invoked but it was not entered"
 3901   4076   
        );
 3902   4077   
    }
 3903   4078   
 3904   4079   
    /// The server should be capable of deserializing indefinite length byte strings.
 3905   4080   
    /// Test ID: RpcV2CborIndefiniteLengthByteStringsCanBeDeserialized
 3906   4081   
    #[::tokio::test]
 3907   4082   
    #[::tracing_test::traced_test]
 3908   4083   
    async fn rpc_v2_cbor_indefinite_length_byte_strings_can_be_deserialized_request() {
 3909   4084   
        #[allow(unused_mut)]
 3910         -
                    let mut http_request = http::Request::builder()
        4085  +
                    let mut http_request = ::http_1x::Request::builder()
 3911   4086   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 3912   4087   
                        .method("POST")
 3913   4088   
        .header("Accept", "application/cbor")
 3914   4089   
        .header("Content-Type", "application/cbor")
 3915   4090   
        .header("smithy-protocol", "rpc-v2-cbor")
 3916         -
        .body(::aws_smithy_http_server::body::Body::from(
        4091  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 3917   4092   
                        ::bytes::Bytes::copy_from_slice(
 3918   4093   
                            &::aws_smithy_protocol_test::decode_body_data("oWlibG9iVmFsdWVfWCJBbiBleGFtcGxlIGluZGVmaW5pdGUtYnl0ZSBzdHJpbmcsUSBjaHVua2VkIG9uIGNvbW1h/w==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 3919   4094   
                        )
 3920         -
                                )).unwrap();
        4095  +
                        ))).unwrap();
 3921   4096   
        #[allow(unused_mut)]
 3922   4097   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 3923   4098   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 3924         -
        let service =
 3925         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 3926         -
                .simple_scalar_properties(
 3927         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        4099  +
        let service = crate::service::RpcV2Protocol::builder::<
        4100  +
            ::aws_smithy_http_server::body::BoxBody,
        4101  +
            _,
        4102  +
            _,
        4103  +
            _,
        4104  +
        >(config)
        4105  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 3928   4106   
            let sender = sender.clone();
 3929   4107   
            async move {
 3930   4108   
                let result = {
 3931   4109   
                    use ::aws_smithy_protocol_test::FloatEquals;
 3932   4110   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 3933         -
                                    blob_value: ::std::option::Option::Some(
 3934         -
                                        ::aws_smithy_types::Blob::new(
        4111  +
                        blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new(
 3935   4112   
                            "An example indefinite-byte string, chunked on comma",
 3936         -
                                        ),
 3937         -
                                    ),
        4113  +
                        )),
 3938   4114   
                        true_boolean_value: ::std::option::Option::None,
 3939   4115   
                        false_boolean_value: ::std::option::Option::None,
 3940   4116   
                        byte_value: ::std::option::Option::None,
 3941   4117   
                        double_value: ::std::option::Option::None,
 3942   4118   
                        float_value: ::std::option::Option::None,
 3943   4119   
                        integer_value: ::std::option::Option::None,
 3944   4120   
                        long_value: ::std::option::Option::None,
 3945   4121   
                        short_value: ::std::option::Option::None,
 3946   4122   
                        string_value: ::std::option::Option::None,
 3947   4123   
                    };
@@ -3987,4163 +4082,4260 @@
 4007   4183   
                        long_value: ::std::option::Option::None,
 4008   4184   
                        short_value: ::std::option::Option::None,
 4009   4185   
                        string_value: ::std::option::Option::None,
 4010   4186   
                        blob_value: ::std::option::Option::None,
 4011   4187   
                    };
 4012   4188   
                    output
 4013   4189   
                };
 4014   4190   
                sender.send(()).await.expect("receiver dropped early");
 4015   4191   
                result
 4016   4192   
            }
 4017         -
                    },
 4018         -
                )
        4193  +
        })
 4019   4194   
        .build_unchecked();
 4020   4195   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4021   4196   
            .await
 4022   4197   
            .expect("unable to make an HTTP request");
 4023   4198   
        assert!(
 4024   4199   
            receiver.recv().await.is_some(),
 4025   4200   
            "we expected operation handler to be invoked but it was not entered"
 4026   4201   
        );
 4027   4202   
    }
 4028   4203   
 4029   4204   
    /// Supports upcasting from a smaller byte representation of the same data type.
 4030   4205   
    /// Test ID: RpcV2CborSupportsUpcastingData
 4031   4206   
    #[::tokio::test]
 4032   4207   
    #[::tracing_test::traced_test]
 4033   4208   
    async fn rpc_v2_cbor_supports_upcasting_data_request() {
 4034   4209   
        #[allow(unused_mut)]
 4035         -
                    let mut http_request = http::Request::builder()
        4210  +
                    let mut http_request = ::http_1x::Request::builder()
 4036   4211   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 4037   4212   
                        .method("POST")
 4038   4213   
        .header("Accept", "application/cbor")
 4039   4214   
        .header("Content-Type", "application/cbor")
 4040   4215   
        .header("smithy-protocol", "rpc-v2-cbor")
 4041         -
        .body(::aws_smithy_http_server::body::Body::from(
        4216  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 4042   4217   
                        ::bytes::Bytes::copy_from_slice(
 4043   4218   
                            &::aws_smithy_protocol_test::decode_body_data("v2tkb3VibGVWYWx1Zfk+AGpmbG9hdFZhbHVl+UegbGludGVnZXJWYWx1ZRg4aWxvbmdWYWx1ZRkBAGpzaG9ydFZhbHVlCv8=".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 4044   4219   
                        )
 4045         -
                                )).unwrap();
        4220  +
                        ))).unwrap();
 4046   4221   
        #[allow(unused_mut)]
 4047   4222   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4048   4223   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4049         -
        let service =
 4050         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 4051         -
                .simple_scalar_properties(
 4052         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        4224  +
        let service = crate::service::RpcV2Protocol::builder::<
        4225  +
            ::aws_smithy_http_server::body::BoxBody,
        4226  +
            _,
        4227  +
            _,
        4228  +
            _,
        4229  +
        >(config)
        4230  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 4053   4231   
            let sender = sender.clone();
 4054   4232   
            async move {
 4055   4233   
                let result = {
 4056   4234   
                    use ::aws_smithy_protocol_test::FloatEquals;
 4057   4235   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 4058   4236   
                        double_value: ::std::option::Option::Some(1.5_f64),
 4059   4237   
                        float_value: ::std::option::Option::Some(7.625_f32),
 4060   4238   
                        integer_value: ::std::option::Option::Some(56),
 4061   4239   
                        long_value: ::std::option::Option::Some(256),
 4062   4240   
                        short_value: ::std::option::Option::Some(10),
@@ -4108,4286 +4222,4402 @@
 4128   4306   
                        long_value: ::std::option::Option::None,
 4129   4307   
                        short_value: ::std::option::Option::None,
 4130   4308   
                        string_value: ::std::option::Option::None,
 4131   4309   
                        blob_value: ::std::option::Option::None,
 4132   4310   
                    };
 4133   4311   
                    output
 4134   4312   
                };
 4135   4313   
                sender.send(()).await.expect("receiver dropped early");
 4136   4314   
                result
 4137   4315   
            }
 4138         -
                    },
 4139         -
                )
        4316  +
        })
 4140   4317   
        .build_unchecked();
 4141   4318   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4142   4319   
            .await
 4143   4320   
            .expect("unable to make an HTTP request");
 4144   4321   
        assert!(
 4145   4322   
            receiver.recv().await.is_some(),
 4146   4323   
            "we expected operation handler to be invoked but it was not entered"
 4147   4324   
        );
 4148   4325   
    }
 4149   4326   
 4150   4327   
    /// The server should skip over additional fields that are not part of the structure. This allows a
 4151   4328   
    /// client generated against a newer Smithy model to be able to communicate with a server that is
 4152   4329   
    /// generated against an older Smithy model.
 4153   4330   
    /// Test ID: RpcV2CborExtraFieldsInTheBodyShouldBeSkippedByServers
 4154   4331   
    #[::tokio::test]
 4155   4332   
    #[::tracing_test::traced_test]
 4156   4333   
    async fn rpc_v2_cbor_extra_fields_in_the_body_should_be_skipped_by_servers_request() {
 4157   4334   
        #[allow(unused_mut)]
 4158         -
                    let mut http_request = http::Request::builder()
        4335  +
                    let mut http_request = ::http_1x::Request::builder()
 4159   4336   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 4160   4337   
                        .method("POST")
 4161   4338   
        .header("Accept", "application/cbor")
 4162   4339   
        .header("Content-Type", "application/cbor")
 4163   4340   
        .header("smithy-protocol", "rpc-v2-cbor")
 4164         -
        .body(::aws_smithy_http_server::body::Body::from(
        4341  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 4165   4342   
                        ::bytes::Bytes::copy_from_slice(
 4166   4343   
                            &::aws_smithy_protocol_test::decode_body_data("v2lieXRlVmFsdWUFa2RvdWJsZVZhbHVl+z/+OVgQYk3TcWZhbHNlQm9vbGVhblZhbHVl9GpmbG9hdFZhbHVl+kD0AABrZXh0cmFPYmplY3S/c2luZGVmaW5pdGVMZW5ndGhNYXC/a3dpdGhBbkFycmF5nwECA///cWRlZmluaXRlTGVuZ3RoTWFwo3J3aXRoQURlZmluaXRlQXJyYXmDAQIDeB1hbmRTb21lSW5kZWZpbml0ZUxlbmd0aFN0cmluZ3gfdGhhdCBoYXMsIGJlZW4gY2h1bmtlZCBvbiBjb21tYWxub3JtYWxTdHJpbmdjZm9vanNob3J0VmFsdWUZJw9uc29tZU90aGVyRmllbGR2dGhpcyBzaG91bGQgYmUgc2tpcHBlZP9saW50ZWdlclZhbHVlGQEAaWxvbmdWYWx1ZRkmkWpzaG9ydFZhbHVlGSaqa3N0cmluZ1ZhbHVlZnNpbXBsZXB0cnVlQm9vbGVhblZhbHVl9WlibG9iVmFsdWVDZm9v/w==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 4167   4344   
                        )
 4168         -
                                )).unwrap();
        4345  +
                        ))).unwrap();
 4169   4346   
        #[allow(unused_mut)]
 4170   4347   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4171   4348   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4172         -
        let service =
 4173         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 4174         -
                .simple_scalar_properties(
 4175         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        4349  +
        let service = crate::service::RpcV2Protocol::builder::<
        4350  +
            ::aws_smithy_http_server::body::BoxBody,
        4351  +
            _,
        4352  +
            _,
        4353  +
            _,
        4354  +
        >(config)
        4355  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 4176   4356   
            let sender = sender.clone();
 4177   4357   
            async move {
 4178   4358   
                let result = {
 4179   4359   
                    use ::aws_smithy_protocol_test::FloatEquals;
 4180   4360   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 4181   4361   
                        byte_value: ::std::option::Option::Some(5),
 4182   4362   
                        double_value: ::std::option::Option::Some(1.889_f64),
 4183   4363   
                        false_boolean_value: ::std::option::Option::Some(false),
 4184   4364   
                        float_value: ::std::option::Option::Some(7.625_f32),
 4185   4365   
                        integer_value: ::std::option::Option::Some(256),
 4186   4366   
                        long_value: ::std::option::Option::Some(9873),
 4187   4367   
                        short_value: ::std::option::Option::Some(9898),
 4188   4368   
                        string_value: ::std::option::Option::Some("simple".to_owned()),
 4189   4369   
                        true_boolean_value: ::std::option::Option::Some(true),
 4190         -
                                    blob_value: ::std::option::Option::Some(
 4191         -
                                        ::aws_smithy_types::Blob::new("foo"),
 4192         -
                                    ),
        4370  +
                        blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new(
        4371  +
                            "foo",
        4372  +
                        )),
 4193   4373   
                    };
 4194   4374   
                    ::pretty_assertions::assert_eq!(
 4195   4375   
                        input.true_boolean_value,
 4196   4376   
                        expected.true_boolean_value,
 4197   4377   
                        "Unexpected value for `true_boolean_value`"
 4198   4378   
                    );
 4199   4379   
                    ::pretty_assertions::assert_eq!(
 4200   4380   
                        input.false_boolean_value,
 4201   4381   
                        expected.false_boolean_value,
 4202   4382   
                        "Unexpected value for `false_boolean_value`"
@@ -4233,4413 +4344,4526 @@
 4253   4433   
                        long_value: ::std::option::Option::None,
 4254   4434   
                        short_value: ::std::option::Option::None,
 4255   4435   
                        string_value: ::std::option::Option::None,
 4256   4436   
                        blob_value: ::std::option::Option::None,
 4257   4437   
                    };
 4258   4438   
                    output
 4259   4439   
                };
 4260   4440   
                sender.send(()).await.expect("receiver dropped early");
 4261   4441   
                result
 4262   4442   
            }
 4263         -
                    },
 4264         -
                )
        4443  +
        })
 4265   4444   
        .build_unchecked();
 4266   4445   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4267   4446   
            .await
 4268   4447   
            .expect("unable to make an HTTP request");
 4269   4448   
        assert!(
 4270   4449   
            receiver.recv().await.is_some(),
 4271   4450   
            "we expected operation handler to be invoked but it was not entered"
 4272   4451   
        );
 4273   4452   
    }
 4274   4453   
 4275   4454   
    /// Servers should tolerate requests without an Accept header set.
 4276   4455   
    /// Test ID: RpcV2CborServersShouldHandleNoAcceptHeader
 4277   4456   
    #[::tokio::test]
 4278   4457   
    #[::tracing_test::traced_test]
 4279   4458   
    async fn rpc_v2_cbor_servers_should_handle_no_accept_header_request() {
 4280   4459   
        #[allow(unused_mut)]
 4281         -
                    let mut http_request = http::Request::builder()
        4460  +
                    let mut http_request = ::http_1x::Request::builder()
 4282   4461   
                        .uri("/service/RpcV2Protocol/operation/SimpleScalarProperties")
 4283   4462   
                        .method("POST")
 4284   4463   
        .header("Content-Type", "application/cbor")
 4285   4464   
        .header("smithy-protocol", "rpc-v2-cbor")
 4286         -
        .body(::aws_smithy_http_server::body::Body::from(
        4465  +
        .body(::aws_smithy_http_server::body::boxed(::http_body_util::Full::new(
 4287   4466   
                        ::bytes::Bytes::copy_from_slice(
 4288   4467   
                            &::aws_smithy_protocol_test::decode_body_data("v2lieXRlVmFsdWUFa2RvdWJsZVZhbHVl+z/+OVgQYk3TcWZhbHNlQm9vbGVhblZhbHVl9GpmbG9hdFZhbHVl+kD0AABsaW50ZWdlclZhbHVlGQEAaWxvbmdWYWx1ZRkmkWpzaG9ydFZhbHVlGSaqa3N0cmluZ1ZhbHVlZnNpbXBsZXB0cnVlQm9vbGVhblZhbHVl9WlibG9iVmFsdWVDZm9v/w==".as_bytes(), ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 4289   4468   
                        )
 4290         -
                                )).unwrap();
        4469  +
                        ))).unwrap();
 4291   4470   
        #[allow(unused_mut)]
 4292   4471   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4293   4472   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4294         -
        let service =
 4295         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
 4296         -
                .simple_scalar_properties(
 4297         -
                    move |input: crate::input::SimpleScalarPropertiesInput| {
        4473  +
        let service = crate::service::RpcV2Protocol::builder::<
        4474  +
            ::aws_smithy_http_server::body::BoxBody,
        4475  +
            _,
        4476  +
            _,
        4477  +
            _,
        4478  +
        >(config)
        4479  +
        .simple_scalar_properties(move |input: crate::input::SimpleScalarPropertiesInput| {
 4298   4480   
            let sender = sender.clone();
 4299   4481   
            async move {
 4300   4482   
                let result = {
 4301   4483   
                    use ::aws_smithy_protocol_test::FloatEquals;
 4302   4484   
                    let expected = crate::input::SimpleScalarPropertiesInput {
 4303   4485   
                        byte_value: ::std::option::Option::Some(5),
 4304   4486   
                        double_value: ::std::option::Option::Some(1.889_f64),
 4305   4487   
                        false_boolean_value: ::std::option::Option::Some(false),
 4306   4488   
                        float_value: ::std::option::Option::Some(7.625_f32),
 4307   4489   
                        integer_value: ::std::option::Option::Some(256),
 4308   4490   
                        long_value: ::std::option::Option::Some(9873),
 4309   4491   
                        short_value: ::std::option::Option::Some(9898),
 4310   4492   
                        string_value: ::std::option::Option::Some("simple".to_owned()),
 4311   4493   
                        true_boolean_value: ::std::option::Option::Some(true),
 4312         -
                                    blob_value: ::std::option::Option::Some(
 4313         -
                                        ::aws_smithy_types::Blob::new("foo"),
 4314         -
                                    ),
        4494  +
                        blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new(
        4495  +
                            "foo",
        4496  +
                        )),
 4315   4497   
                    };
 4316   4498   
                    ::pretty_assertions::assert_eq!(
 4317   4499   
                        input.true_boolean_value,
 4318   4500   
                        expected.true_boolean_value,
 4319   4501   
                        "Unexpected value for `true_boolean_value`"
 4320   4502   
                    );
 4321   4503   
                    ::pretty_assertions::assert_eq!(
 4322   4504   
                        input.false_boolean_value,
 4323   4505   
                        expected.false_boolean_value,
 4324   4506   
                        "Unexpected value for `false_boolean_value`"
@@ -4355,4537 +5296,5551 @@
 4375   4557   
                        long_value: ::std::option::Option::None,
 4376   4558   
                        short_value: ::std::option::Option::None,
 4377   4559   
                        string_value: ::std::option::Option::None,
 4378   4560   
                        blob_value: ::std::option::Option::None,
 4379   4561   
                    };
 4380   4562   
                    output
 4381   4563   
                };
 4382   4564   
                sender.send(()).await.expect("receiver dropped early");
 4383   4565   
                result
 4384   4566   
            }
 4385         -
                    },
 4386         -
                )
        4567  +
        })
 4387   4568   
        .build_unchecked();
 4388   4569   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4389   4570   
            .await
 4390   4571   
            .expect("unable to make an HTTP request");
 4391   4572   
        assert!(
 4392   4573   
            receiver.recv().await.is_some(),
 4393   4574   
            "we expected operation handler to be invoked but it was not entered"
 4394   4575   
        );
 4395   4576   
    }
 4396   4577   
 4397   4578   
    /// Serializes simple scalar properties
 4398   4579   
    /// Test ID: RpcV2CborSimpleScalarProperties
 4399   4580   
    #[::tokio::test]
 4400   4581   
    #[::tracing_test::traced_test]
 4401   4582   
    async fn rpc_v2_cbor_simple_scalar_properties_response() {
 4402   4583   
        let output = crate::output::SimpleScalarPropertiesOutput {
 4403   4584   
            true_boolean_value: ::std::option::Option::Some(true),
 4404   4585   
            false_boolean_value: ::std::option::Option::Some(false),
 4405   4586   
            byte_value: ::std::option::Option::Some(5),
 4406   4587   
            double_value: ::std::option::Option::Some(1.889_f64),
 4407   4588   
            float_value: ::std::option::Option::Some(7.625_f32),
 4408   4589   
            integer_value: ::std::option::Option::Some(256),
 4409   4590   
            short_value: ::std::option::Option::Some(9898),
 4410   4591   
            string_value: ::std::option::Option::Some("simple".to_owned()),
 4411   4592   
            blob_value: ::std::option::Option::Some(::aws_smithy_types::Blob::new("foo")),
 4412   4593   
            long_value: ::std::option::Option::None,
 4413   4594   
        };
 4414   4595   
        use ::aws_smithy_http_server::response::IntoResponse;
 4415   4596   
        let http_response = output.into_response();
 4416   4597   
        ::pretty_assertions::assert_eq!(
 4417         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4598  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4418   4599   
            http_response.status()
 4419   4600   
        );
 4420   4601   
        let expected_headers = [
 4421   4602   
            ("Content-Type", "application/cbor"),
 4422   4603   
            ("smithy-protocol", "rpc-v2-cbor"),
 4423   4604   
        ];
 4424   4605   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4425   4606   
            http_response.headers(),
 4426   4607   
            expected_headers,
 4427   4608   
        ));
 4428         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4609  +
        use ::http_body_util::BodyExt;
        4610  +
        let body = http_response
        4611  +
            .into_body()
        4612  +
            .collect()
 4429   4613   
            .await
 4430         -
            .expect("unable to extract body to bytes");
        4614  +
            .expect("unable to collect body")
        4615  +
            .to_bytes();
 4431   4616   
        ::aws_smithy_protocol_test::assert_ok(
 4432   4617   
        ::aws_smithy_protocol_test::validate_body(&body, "v3B0cnVlQm9vbGVhblZhbHVl9XFmYWxzZUJvb2xlYW5WYWx1ZfRpYnl0ZVZhbHVlBWtkb3VibGVWYWx1Zfs//jlYEGJN02pmbG9hdFZhbHVl+kD0AABsaW50ZWdlclZhbHVlGQEAanNob3J0VmFsdWUZJqprc3RyaW5nVmFsdWVmc2ltcGxlaWJsb2JWYWx1ZUNmb2//", ::aws_smithy_protocol_test::MediaType::from("application/cbor"))
 4433   4618   
        );
 4434   4619   
    }
 4435   4620   
 4436   4621   
    /// RpcV2 Cbor should not serialize null structure values
 4437   4622   
    /// Test ID: RpcV2CborServerDoesntSerializeNullStructureValues
 4438   4623   
    #[::tokio::test]
 4439   4624   
    #[::tracing_test::traced_test]
 4440   4625   
    async fn rpc_v2_cbor_server_doesnt_serialize_null_structure_values_response() {
 4441   4626   
        let output = crate::output::SimpleScalarPropertiesOutput {
 4442   4627   
            string_value: ::std::option::Option::None,
 4443   4628   
            true_boolean_value: ::std::option::Option::None,
 4444   4629   
            false_boolean_value: ::std::option::Option::None,
 4445   4630   
            byte_value: ::std::option::Option::None,
 4446   4631   
            double_value: ::std::option::Option::None,
 4447   4632   
            float_value: ::std::option::Option::None,
 4448   4633   
            integer_value: ::std::option::Option::None,
 4449   4634   
            long_value: ::std::option::Option::None,
 4450   4635   
            short_value: ::std::option::Option::None,
 4451   4636   
            blob_value: ::std::option::Option::None,
 4452   4637   
        };
 4453   4638   
        use ::aws_smithy_http_server::response::IntoResponse;
 4454   4639   
        let http_response = output.into_response();
 4455   4640   
        ::pretty_assertions::assert_eq!(
 4456         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4641  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4457   4642   
            http_response.status()
 4458   4643   
        );
 4459   4644   
        let expected_headers = [
 4460   4645   
            ("Content-Type", "application/cbor"),
 4461   4646   
            ("smithy-protocol", "rpc-v2-cbor"),
 4462   4647   
        ];
 4463   4648   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4464   4649   
            http_response.headers(),
 4465   4650   
            expected_headers,
 4466   4651   
        ));
 4467         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4652  +
        use ::http_body_util::BodyExt;
        4653  +
        let body = http_response
        4654  +
            .into_body()
        4655  +
            .collect()
 4468   4656   
            .await
 4469         -
            .expect("unable to extract body to bytes");
        4657  +
            .expect("unable to collect body")
        4658  +
            .to_bytes();
 4470   4659   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 4471   4660   
            &body,
 4472   4661   
            "v/8=",
 4473   4662   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 4474   4663   
        ));
 4475   4664   
    }
 4476   4665   
 4477   4666   
    /// Supports handling NaN float values.
 4478   4667   
    /// Test ID: RpcV2CborSupportsNaNFloatOutputs
 4479   4668   
    #[::tokio::test]
 4480   4669   
    #[::tracing_test::traced_test]
 4481   4670   
    async fn rpc_v2_cbor_supports_na_n_float_outputs_response() {
 4482   4671   
        let output = crate::output::SimpleScalarPropertiesOutput {
 4483   4672   
            double_value: ::std::option::Option::Some(
 4484   4673   
                <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("NaN")
 4485   4674   
                    .expect("invalid string for number"),
 4486   4675   
            ),
 4487   4676   
            float_value: ::std::option::Option::Some(
 4488   4677   
                <f32 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("NaN")
 4489   4678   
                    .expect("invalid string for number"),
 4490   4679   
            ),
 4491   4680   
            true_boolean_value: ::std::option::Option::None,
 4492   4681   
            false_boolean_value: ::std::option::Option::None,
 4493   4682   
            byte_value: ::std::option::Option::None,
 4494   4683   
            integer_value: ::std::option::Option::None,
 4495   4684   
            long_value: ::std::option::Option::None,
 4496   4685   
            short_value: ::std::option::Option::None,
 4497   4686   
            string_value: ::std::option::Option::None,
 4498   4687   
            blob_value: ::std::option::Option::None,
 4499   4688   
        };
 4500   4689   
        use ::aws_smithy_http_server::response::IntoResponse;
 4501   4690   
        let http_response = output.into_response();
 4502   4691   
        ::pretty_assertions::assert_eq!(
 4503         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4692  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4504   4693   
            http_response.status()
 4505   4694   
        );
 4506   4695   
        let expected_headers = [
 4507   4696   
            ("Content-Type", "application/cbor"),
 4508   4697   
            ("smithy-protocol", "rpc-v2-cbor"),
 4509   4698   
        ];
 4510   4699   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4511   4700   
            http_response.headers(),
 4512   4701   
            expected_headers,
 4513   4702   
        ));
 4514         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4703  +
        use ::http_body_util::BodyExt;
        4704  +
        let body = http_response
        4705  +
            .into_body()
        4706  +
            .collect()
 4515   4707   
            .await
 4516         -
            .expect("unable to extract body to bytes");
        4708  +
            .expect("unable to collect body")
        4709  +
            .to_bytes();
 4517   4710   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 4518   4711   
            &body,
 4519   4712   
            "v2tkb3VibGVWYWx1Zft/+AAAAAAAAGpmbG9hdFZhbHVl+n/AAAD/",
 4520   4713   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 4521   4714   
        ));
 4522   4715   
    }
 4523   4716   
 4524   4717   
    /// Supports handling Infinity float values.
 4525   4718   
    /// Test ID: RpcV2CborSupportsInfinityFloatOutputs
 4526   4719   
    #[::tokio::test]
 4527   4720   
    #[::tracing_test::traced_test]
 4528   4721   
    async fn rpc_v2_cbor_supports_infinity_float_outputs_response() {
 4529   4722   
        let output = crate::output::SimpleScalarPropertiesOutput {
 4530   4723   
            double_value: ::std::option::Option::Some(
 4531   4724   
                <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("Infinity")
 4532   4725   
                    .expect("invalid string for number"),
 4533   4726   
            ),
 4534   4727   
            float_value: ::std::option::Option::Some(
 4535   4728   
                <f32 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("Infinity")
 4536   4729   
                    .expect("invalid string for number"),
 4537   4730   
            ),
 4538   4731   
            true_boolean_value: ::std::option::Option::None,
 4539   4732   
            false_boolean_value: ::std::option::Option::None,
 4540   4733   
            byte_value: ::std::option::Option::None,
 4541   4734   
            integer_value: ::std::option::Option::None,
 4542   4735   
            long_value: ::std::option::Option::None,
 4543   4736   
            short_value: ::std::option::Option::None,
 4544   4737   
            string_value: ::std::option::Option::None,
 4545   4738   
            blob_value: ::std::option::Option::None,
 4546   4739   
        };
 4547   4740   
        use ::aws_smithy_http_server::response::IntoResponse;
 4548   4741   
        let http_response = output.into_response();
 4549   4742   
        ::pretty_assertions::assert_eq!(
 4550         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4743  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4551   4744   
            http_response.status()
 4552   4745   
        );
 4553   4746   
        let expected_headers = [
 4554   4747   
            ("Content-Type", "application/cbor"),
 4555   4748   
            ("smithy-protocol", "rpc-v2-cbor"),
 4556   4749   
        ];
 4557   4750   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4558   4751   
            http_response.headers(),
 4559   4752   
            expected_headers,
 4560   4753   
        ));
 4561         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4754  +
        use ::http_body_util::BodyExt;
        4755  +
        let body = http_response
        4756  +
            .into_body()
        4757  +
            .collect()
 4562   4758   
            .await
 4563         -
            .expect("unable to extract body to bytes");
        4759  +
            .expect("unable to collect body")
        4760  +
            .to_bytes();
 4564   4761   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 4565   4762   
            &body,
 4566   4763   
            "v2tkb3VibGVWYWx1Zft/8AAAAAAAAGpmbG9hdFZhbHVl+n+AAAD/",
 4567   4764   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 4568   4765   
        ));
 4569   4766   
    }
 4570   4767   
 4571   4768   
    /// Supports handling Negative Infinity float values.
 4572   4769   
    /// Test ID: RpcV2CborSupportsNegativeInfinityFloatOutputs
 4573   4770   
    #[::tokio::test]
 4574   4771   
    #[::tracing_test::traced_test]
 4575   4772   
    async fn rpc_v2_cbor_supports_negative_infinity_float_outputs_response() {
 4576   4773   
        let output = crate::output::SimpleScalarPropertiesOutput {
 4577   4774   
            double_value: ::std::option::Option::Some(
 4578   4775   
                <f64 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("-Infinity")
 4579   4776   
                    .expect("invalid string for number"),
 4580   4777   
            ),
 4581   4778   
            float_value: ::std::option::Option::Some(
 4582   4779   
                <f32 as ::aws_smithy_types::primitive::Parse>::parse_smithy_primitive("-Infinity")
 4583   4780   
                    .expect("invalid string for number"),
 4584   4781   
            ),
 4585   4782   
            true_boolean_value: ::std::option::Option::None,
 4586   4783   
            false_boolean_value: ::std::option::Option::None,
 4587   4784   
            byte_value: ::std::option::Option::None,
 4588   4785   
            integer_value: ::std::option::Option::None,
 4589   4786   
            long_value: ::std::option::Option::None,
 4590   4787   
            short_value: ::std::option::Option::None,
 4591   4788   
            string_value: ::std::option::Option::None,
 4592   4789   
            blob_value: ::std::option::Option::None,
 4593   4790   
        };
 4594   4791   
        use ::aws_smithy_http_server::response::IntoResponse;
 4595   4792   
        let http_response = output.into_response();
 4596   4793   
        ::pretty_assertions::assert_eq!(
 4597         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4794  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4598   4795   
            http_response.status()
 4599   4796   
        );
 4600   4797   
        let expected_headers = [
 4601   4798   
            ("Content-Type", "application/cbor"),
 4602   4799   
            ("smithy-protocol", "rpc-v2-cbor"),
 4603   4800   
        ];
 4604   4801   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4605   4802   
            http_response.headers(),
 4606   4803   
            expected_headers,
 4607   4804   
        ));
 4608         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4805  +
        use ::http_body_util::BodyExt;
        4806  +
        let body = http_response
        4807  +
            .into_body()
        4808  +
            .collect()
 4609   4809   
            .await
 4610         -
            .expect("unable to extract body to bytes");
        4810  +
            .expect("unable to collect body")
        4811  +
            .to_bytes();
 4611   4812   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 4612   4813   
            &body,
 4613   4814   
            "v2tkb3VibGVWYWx1Zfv/8AAAAAAAAGpmbG9hdFZhbHVl+v+AAAD/",
 4614   4815   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 4615   4816   
        ));
 4616   4817   
    }
 4617   4818   
}
 4618   4819   
 4619   4820   
::pin_project_lite::pin_project! {
 4620   4821   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 4621   4822   
    /// [`OptionalInputOutputInput`](crate::input::OptionalInputOutputInput) using modelled bindings.
 4622   4823   
    pub struct OptionalInputOutputInputFuture {
 4623   4824   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::OptionalInputOutputInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 4624   4825   
    }
 4625   4826   
}
 4626   4827   
 4627   4828   
impl std::future::Future for OptionalInputOutputInputFuture {
 4628   4829   
    type Output = Result<
 4629   4830   
        crate::input::OptionalInputOutputInput,
 4630   4831   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 4631   4832   
    >;
 4632   4833   
 4633   4834   
    fn poll(
 4634   4835   
        self: std::pin::Pin<&mut Self>,
 4635   4836   
        cx: &mut std::task::Context<'_>,
 4636   4837   
    ) -> std::task::Poll<Self::Output> {
 4637   4838   
        let this = self.project();
 4638   4839   
        this.inner.as_mut().poll(cx)
 4639   4840   
    }
 4640   4841   
}
 4641   4842   
 4642   4843   
impl<B>
 4643   4844   
    ::aws_smithy_http_server::request::FromRequest<
 4644   4845   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 4645   4846   
        B,
 4646   4847   
    > for crate::input::OptionalInputOutputInput
 4647   4848   
where
 4648   4849   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 4649   4850   
    B: 'static,
 4650   4851   
 4651   4852   
    B::Data: Send,
 4652   4853   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 4653   4854   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 4654   4855   
{
 4655   4856   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 4656   4857   
    type Future = OptionalInputOutputInputFuture;
 4657   4858   
 4658         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        4859  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 4659   4860   
        let fut = async move {
 4660   4861   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 4661   4862   
                request.headers(),
 4662   4863   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 4663   4864   
            ) {
 4664   4865   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 4665   4866   
            }
 4666   4867   
            crate::protocol_serde::shape_optional_input_output::de_optional_input_output_http_request(request)
 4667   4868   
                            .await
 4668   4869   
        };
 4669   4870   
        use ::futures_util::future::TryFutureExt;
 4670   4871   
        let fut = fut.map_err(
 4671   4872   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
 4672   4873   
                ::tracing::debug!(error = %e, "failed to deserialize request");
 4673   4874   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
 4674   4875   
                    e,
 4675   4876   
                )
 4676   4877   
            },
 4677   4878   
        );
 4678   4879   
        OptionalInputOutputInputFuture {
 4679   4880   
            inner: Box::pin(fut),
 4680   4881   
        }
 4681   4882   
    }
 4682   4883   
}
 4683   4884   
impl
 4684   4885   
    ::aws_smithy_http_server::response::IntoResponse<
 4685   4886   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 4686   4887   
    > for crate::output::OptionalInputOutputOutput
 4687   4888   
{
 4688   4889   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
 4689   4890   
        match crate::protocol_serde::shape_optional_input_output::ser_optional_input_output_http_response(self) {
 4690   4891   
                        Ok(response) => response,
 4691   4892   
                        Err(e) => {
 4692   4893   
                            ::tracing::error!(error = %e, "failed to serialize response");
 4693   4894   
                            ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
 4694   4895   
                        }
 4695   4896   
                    }
 4696   4897   
    }
 4697   4898   
}
 4698   4899   
 4699   4900   
#[allow(unreachable_code, unused_variables)]
 4700   4901   
#[cfg(test)]
 4701   4902   
mod optional_input_output_test {
 4702   4903   
 4703   4904   
    /// When input is empty we write CBOR equivalent of {}
 4704   4905   
    /// Test ID: optional_input
 4705   4906   
    #[::tokio::test]
 4706   4907   
    #[::tracing_test::traced_test]
 4707   4908   
    async fn optional_input_request() {
 4708   4909   
        #[allow(unused_mut)]
 4709         -
        let mut http_request = http::Request::builder()
        4910  +
        let mut http_request = ::http_1x::Request::builder()
 4710   4911   
            .uri("/service/RpcV2Protocol/operation/OptionalInputOutput")
 4711   4912   
            .method("POST")
 4712   4913   
            .header("Accept", "application/cbor")
 4713   4914   
            .header("Content-Type", "application/cbor")
 4714   4915   
            .header("smithy-protocol", "rpc-v2-cbor")
 4715         -
            .body(::aws_smithy_http_server::body::Body::from(
 4716         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        4916  +
            .body(::aws_smithy_http_server::body::boxed(
        4917  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        4918  +
                    &::aws_smithy_protocol_test::decode_body_data(
 4717   4919   
                        "v/8=".as_bytes(),
 4718   4920   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        4921  +
                    ),
 4719   4922   
                )),
 4720   4923   
            ))
 4721   4924   
            .unwrap();
 4722   4925   
        #[allow(unused_mut)]
 4723   4926   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4724   4927   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4725         -
        let service =
 4726         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        4928  +
        let service = crate::service::RpcV2Protocol::builder::<
        4929  +
            ::aws_smithy_http_server::body::BoxBody,
        4930  +
            _,
        4931  +
            _,
        4932  +
            _,
        4933  +
        >(config)
 4727   4934   
        .optional_input_output(move |input: crate::input::OptionalInputOutputInput| {
 4728   4935   
            let sender = sender.clone();
 4729   4936   
            async move {
 4730   4937   
                let result = {
 4731   4938   
                    let expected = crate::input::OptionalInputOutputInput {
 4732   4939   
                        value: ::std::option::Option::None,
 4733   4940   
                    };
 4734   4941   
                    ::pretty_assertions::assert_eq!(input, expected);
 4735   4942   
                    let output = crate::output::OptionalInputOutputOutput {
 4736   4943   
                        value: ::std::option::Option::None,
 4737   4944   
                    };
 4738   4945   
                    output
 4739   4946   
                };
 4740   4947   
                sender.send(()).await.expect("receiver dropped early");
 4741   4948   
                result
 4742   4949   
            }
 4743   4950   
        })
 4744   4951   
        .build_unchecked();
 4745   4952   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4746   4953   
            .await
 4747   4954   
            .expect("unable to make an HTTP request");
 4748   4955   
        assert!(
 4749   4956   
            receiver.recv().await.is_some(),
 4750   4957   
            "we expected operation handler to be invoked but it was not entered"
 4751   4958   
        );
 4752   4959   
    }
 4753   4960   
 4754   4961   
    /// When output is empty we write CBOR equivalent of {}
 4755   4962   
    /// Test ID: optional_output
 4756   4963   
    #[::tokio::test]
 4757   4964   
    #[::tracing_test::traced_test]
 4758   4965   
    async fn optional_output_response() {
 4759   4966   
        let output = crate::output::OptionalInputOutputOutput {
 4760   4967   
            value: ::std::option::Option::None,
 4761   4968   
        };
 4762   4969   
        use ::aws_smithy_http_server::response::IntoResponse;
 4763   4970   
        let http_response = output.into_response();
 4764   4971   
        ::pretty_assertions::assert_eq!(
 4765         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        4972  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 4766   4973   
            http_response.status()
 4767   4974   
        );
 4768   4975   
        let expected_headers = [
 4769   4976   
            ("Content-Type", "application/cbor"),
 4770   4977   
            ("smithy-protocol", "rpc-v2-cbor"),
 4771   4978   
        ];
 4772   4979   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 4773   4980   
            http_response.headers(),
 4774   4981   
            expected_headers,
 4775   4982   
        ));
 4776         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        4983  +
        use ::http_body_util::BodyExt;
        4984  +
        let body = http_response
        4985  +
            .into_body()
        4986  +
            .collect()
 4777   4987   
            .await
 4778         -
            .expect("unable to extract body to bytes");
        4988  +
            .expect("unable to collect body")
        4989  +
            .to_bytes();
 4779   4990   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 4780   4991   
            &body,
 4781   4992   
            "v/8=",
 4782   4993   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 4783   4994   
        ));
 4784   4995   
    }
 4785   4996   
}
 4786   4997   
 4787   4998   
::pin_project_lite::pin_project! {
 4788   4999   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 4789   5000   
    /// [`EmptyInputOutputInput`](crate::input::EmptyInputOutputInput) using modelled bindings.
 4790   5001   
    pub struct EmptyInputOutputInputFuture {
 4791   5002   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::EmptyInputOutputInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 4792   5003   
    }
 4793   5004   
}
 4794   5005   
 4795   5006   
impl std::future::Future for EmptyInputOutputInputFuture {
 4796   5007   
    type Output = Result<
 4797   5008   
        crate::input::EmptyInputOutputInput,
 4798   5009   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 4799   5010   
    >;
 4800   5011   
 4801   5012   
    fn poll(
 4802   5013   
        self: std::pin::Pin<&mut Self>,
 4803   5014   
        cx: &mut std::task::Context<'_>,
 4804   5015   
    ) -> std::task::Poll<Self::Output> {
 4805   5016   
        let this = self.project();
 4806   5017   
        this.inner.as_mut().poll(cx)
 4807   5018   
    }
 4808   5019   
}
 4809   5020   
 4810   5021   
impl<B>
 4811   5022   
    ::aws_smithy_http_server::request::FromRequest<
 4812   5023   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 4813   5024   
        B,
 4814   5025   
    > for crate::input::EmptyInputOutputInput
 4815   5026   
where
 4816   5027   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 4817   5028   
    B: 'static,
 4818   5029   
 4819   5030   
    B::Data: Send,
 4820   5031   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 4821   5032   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 4822   5033   
{
 4823   5034   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 4824   5035   
    type Future = EmptyInputOutputInputFuture;
 4825   5036   
 4826         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        5037  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 4827   5038   
        let fut = async move {
 4828   5039   
            if !::aws_smithy_http_server::protocol::accept_header_classifier(
 4829   5040   
                request.headers(),
 4830   5041   
                &crate::mimes::CONTENT_TYPE_APPLICATION_CBOR,
 4831   5042   
            ) {
 4832   5043   
                return Err(::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection::NotAcceptable);
 4833   5044   
            }
 4834   5045   
            crate::protocol_serde::shape_empty_input_output::de_empty_input_output_http_request(
 4835   5046   
                request,
 4836   5047   
            )
 4837   5048   
            .await
 4838   5049   
        };
 4839   5050   
        use ::futures_util::future::TryFutureExt;
 4840   5051   
        let fut = fut.map_err(
 4841   5052   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
 4842   5053   
                ::tracing::debug!(error = %e, "failed to deserialize request");
 4843   5054   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
 4844   5055   
                    e,
 4845   5056   
                )
 4846   5057   
            },
 4847   5058   
        );
 4848   5059   
        EmptyInputOutputInputFuture {
 4849   5060   
            inner: Box::pin(fut),
 4850   5061   
        }
 4851   5062   
    }
 4852   5063   
}
 4853   5064   
impl
 4854   5065   
    ::aws_smithy_http_server::response::IntoResponse<
 4855   5066   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 4856   5067   
    > for crate::output::EmptyInputOutputOutput
 4857   5068   
{
 4858   5069   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
 4859   5070   
        match crate::protocol_serde::shape_empty_input_output::ser_empty_input_output_http_response(
 4860   5071   
            self,
 4861   5072   
        ) {
 4862   5073   
            Ok(response) => response,
 4863   5074   
            Err(e) => {
 4864   5075   
                ::tracing::error!(error = %e, "failed to serialize response");
 4865   5076   
                ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
 4866   5077   
            }
 4867   5078   
        }
 4868   5079   
    }
 4869   5080   
}
 4870   5081   
 4871   5082   
#[allow(unreachable_code, unused_variables)]
 4872   5083   
#[cfg(test)]
 4873   5084   
mod empty_input_output_test {
 4874   5085   
 4875   5086   
    /// When Input structure is empty we write CBOR equivalent of {}
 4876   5087   
    /// Test ID: empty_input
 4877   5088   
    #[::tokio::test]
 4878   5089   
    #[::tracing_test::traced_test]
 4879   5090   
    async fn empty_input_request() {
 4880   5091   
        #[allow(unused_mut)]
 4881         -
        let mut http_request = http::Request::builder()
        5092  +
        let mut http_request = ::http_1x::Request::builder()
 4882   5093   
            .uri("/service/RpcV2Protocol/operation/EmptyInputOutput")
 4883   5094   
            .method("POST")
 4884   5095   
            .header("Accept", "application/cbor")
 4885   5096   
            .header("Content-Type", "application/cbor")
 4886   5097   
            .header("smithy-protocol", "rpc-v2-cbor")
 4887         -
            .body(::aws_smithy_http_server::body::Body::from(
 4888         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5098  +
            .body(::aws_smithy_http_server::body::boxed(
        5099  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5100  +
                    &::aws_smithy_protocol_test::decode_body_data(
 4889   5101   
                        "v/8=".as_bytes(),
 4890   5102   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        5103  +
                    ),
 4891   5104   
                )),
 4892   5105   
            ))
 4893   5106   
            .unwrap();
 4894   5107   
        #[allow(unused_mut)]
 4895   5108   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4896   5109   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4897         -
        let service =
 4898         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5110  +
        let service = crate::service::RpcV2Protocol::builder::<
        5111  +
            ::aws_smithy_http_server::body::BoxBody,
        5112  +
            _,
        5113  +
            _,
        5114  +
            _,
        5115  +
        >(config)
 4899   5116   
        .empty_input_output(move |input: crate::input::EmptyInputOutputInput| {
 4900   5117   
            let sender = sender.clone();
 4901   5118   
            async move {
 4902   5119   
                let result = {
 4903   5120   
                    let expected = crate::input::EmptyInputOutputInput {};
 4904   5121   
                    ::pretty_assertions::assert_eq!(input, expected);
 4905   5122   
                    let output = crate::output::EmptyInputOutputOutput {};
 4906   5123   
                    output
 4907   5124   
                };
 4908   5125   
                sender.send(()).await.expect("receiver dropped early");
 4909   5126   
                result
 4910   5127   
            }
 4911   5128   
        })
 4912   5129   
        .build_unchecked();
 4913   5130   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4914   5131   
            .await
 4915   5132   
            .expect("unable to make an HTTP request");
 4916   5133   
        assert!(
 4917   5134   
            receiver.recv().await.is_some(),
 4918   5135   
            "we expected operation handler to be invoked but it was not entered"
 4919   5136   
        );
 4920   5137   
    }
 4921   5138   
 4922   5139   
    /// When Input structure is empty the server should accept an empty body
 4923   5140   
    /// Test ID: empty_input_no_body
 4924   5141   
    #[::tokio::test]
 4925   5142   
    #[::tracing_test::traced_test]
 4926   5143   
    async fn empty_input_no_body_request() {
 4927   5144   
        #[allow(unused_mut)]
 4928         -
        let mut http_request = http::Request::builder()
        5145  +
        let mut http_request = ::http_1x::Request::builder()
 4929   5146   
            .uri("/service/RpcV2Protocol/operation/EmptyInputOutput")
 4930   5147   
            .method("POST")
 4931   5148   
            .header("Accept", "application/cbor")
 4932   5149   
            .header("Content-Type", "application/cbor")
 4933   5150   
            .header("smithy-protocol", "rpc-v2-cbor")
 4934         -
            .body(::aws_smithy_http_server::body::Body::from(
 4935         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5151  +
            .body(::aws_smithy_http_server::body::boxed(
        5152  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5153  +
                    &::aws_smithy_protocol_test::decode_body_data(
 4936   5154   
                        "".as_bytes(),
 4937   5155   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        5156  +
                    ),
 4938   5157   
                )),
 4939   5158   
            ))
 4940   5159   
            .unwrap();
 4941   5160   
        #[allow(unused_mut)]
 4942   5161   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4943   5162   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4944         -
        let service =
 4945         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5163  +
        let service = crate::service::RpcV2Protocol::builder::<
        5164  +
            ::aws_smithy_http_server::body::BoxBody,
        5165  +
            _,
        5166  +
            _,
        5167  +
            _,
        5168  +
        >(config)
 4946   5169   
        .empty_input_output(move |input: crate::input::EmptyInputOutputInput| {
 4947   5170   
            let sender = sender.clone();
 4948   5171   
            async move {
 4949   5172   
                let result = {
 4950   5173   
                    let expected = crate::input::EmptyInputOutputInput {};
 4951   5174   
                    ::pretty_assertions::assert_eq!(input, expected);
 4952   5175   
                    let output = crate::output::EmptyInputOutputOutput {};
 4953   5176   
                    output
 4954   5177   
                };
 4955   5178   
                sender.send(()).await.expect("receiver dropped early");
 4956   5179   
                result
 4957   5180   
            }
 4958   5181   
        })
 4959   5182   
        .build_unchecked();
 4960   5183   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 4961   5184   
            .await
 4962   5185   
            .expect("unable to make an HTTP request");
 4963   5186   
        assert!(
 4964   5187   
            receiver.recv().await.is_some(),
 4965   5188   
            "we expected operation handler to be invoked but it was not entered"
 4966   5189   
        );
 4967   5190   
    }
 4968   5191   
 4969   5192   
    /// When input structure, is empty the server should accept an empty body
 4970   5193   
    /// even if the Accept header is set.
 4971   5194   
    /// Test ID: empty_input_no_body_has_accept
 4972   5195   
    #[::tokio::test]
 4973   5196   
    #[::tracing_test::traced_test]
 4974   5197   
    async fn empty_input_no_body_has_accept_request() {
 4975   5198   
        #[allow(unused_mut)]
 4976         -
        let mut http_request = http::Request::builder()
        5199  +
        let mut http_request = ::http_1x::Request::builder()
 4977   5200   
            .uri("/service/RpcV2Protocol/operation/EmptyInputOutput")
 4978   5201   
            .method("POST")
 4979   5202   
            .header("Accept", "application/cbor")
 4980   5203   
            .header("Content-Type", "application/cbor")
 4981   5204   
            .header("smithy-protocol", "rpc-v2-cbor")
 4982         -
            .body(::aws_smithy_http_server::body::Body::from(
 4983         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5205  +
            .body(::aws_smithy_http_server::body::boxed(
        5206  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5207  +
                    &::aws_smithy_protocol_test::decode_body_data(
 4984   5208   
                        "".as_bytes(),
 4985   5209   
                        ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
        5210  +
                    ),
 4986   5211   
                )),
 4987   5212   
            ))
 4988   5213   
            .unwrap();
 4989   5214   
        #[allow(unused_mut)]
 4990   5215   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 4991   5216   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 4992         -
        let service =
 4993         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5217  +
        let service = crate::service::RpcV2Protocol::builder::<
        5218  +
            ::aws_smithy_http_server::body::BoxBody,
        5219  +
            _,
        5220  +
            _,
        5221  +
            _,
        5222  +
        >(config)
 4994   5223   
        .empty_input_output(move |input: crate::input::EmptyInputOutputInput| {
 4995   5224   
            let sender = sender.clone();
 4996   5225   
            async move {
 4997   5226   
                let result = {
 4998   5227   
                    let expected = crate::input::EmptyInputOutputInput {};
 4999   5228   
                    ::pretty_assertions::assert_eq!(input, expected);
 5000   5229   
                    let output = crate::output::EmptyInputOutputOutput {};
 5001   5230   
                    output
 5002   5231   
                };
 5003   5232   
                sender.send(()).await.expect("receiver dropped early");
 5004   5233   
                result
 5005   5234   
            }
 5006   5235   
        })
 5007   5236   
        .build_unchecked();
 5008   5237   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 5009   5238   
            .await
 5010   5239   
            .expect("unable to make an HTTP request");
 5011   5240   
        assert!(
 5012   5241   
            receiver.recv().await.is_some(),
 5013   5242   
            "we expected operation handler to be invoked but it was not entered"
 5014   5243   
        );
 5015   5244   
    }
 5016   5245   
 5017   5246   
    /// When output structure is empty we write CBOR equivalent of {}
 5018   5247   
    /// Test ID: empty_output
 5019   5248   
    #[::tokio::test]
 5020   5249   
    #[::tracing_test::traced_test]
 5021   5250   
    async fn empty_output_response() {
 5022   5251   
        let output = crate::output::EmptyInputOutputOutput {};
 5023   5252   
        use ::aws_smithy_http_server::response::IntoResponse;
 5024   5253   
        let http_response = output.into_response();
 5025   5254   
        ::pretty_assertions::assert_eq!(
 5026         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        5255  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 5027   5256   
            http_response.status()
 5028   5257   
        );
 5029   5258   
        let expected_headers = [
 5030   5259   
            ("Content-Type", "application/cbor"),
 5031   5260   
            ("smithy-protocol", "rpc-v2-cbor"),
 5032   5261   
        ];
 5033   5262   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 5034   5263   
            http_response.headers(),
 5035   5264   
            expected_headers,
 5036   5265   
        ));
 5037         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        5266  +
        use ::http_body_util::BodyExt;
        5267  +
        let body = http_response
        5268  +
            .into_body()
        5269  +
            .collect()
 5038   5270   
            .await
 5039         -
            .expect("unable to extract body to bytes");
        5271  +
            .expect("unable to collect body")
        5272  +
            .to_bytes();
 5040   5273   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_body(
 5041   5274   
            &body,
 5042   5275   
            "v/8=",
 5043   5276   
            ::aws_smithy_protocol_test::MediaType::from("application/cbor"),
 5044   5277   
        ));
 5045   5278   
    }
 5046   5279   
}
 5047   5280   
 5048   5281   
::pin_project_lite::pin_project! {
 5049   5282   
    /// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
 5050   5283   
    /// [`NoInputOutputInput`](crate::input::NoInputOutputInput) using modelled bindings.
 5051   5284   
    pub struct NoInputOutputInputFuture {
 5052   5285   
        inner: std::pin::Pin<Box<dyn std::future::Future<Output = Result<crate::input::NoInputOutputInput, ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError>> + Send>>
 5053   5286   
    }
 5054   5287   
}
 5055   5288   
 5056   5289   
impl std::future::Future for NoInputOutputInputFuture {
 5057   5290   
    type Output = Result<
 5058   5291   
        crate::input::NoInputOutputInput,
 5059   5292   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError,
 5060   5293   
    >;
 5061   5294   
 5062   5295   
    fn poll(
 5063   5296   
        self: std::pin::Pin<&mut Self>,
 5064   5297   
        cx: &mut std::task::Context<'_>,
 5065   5298   
    ) -> std::task::Poll<Self::Output> {
 5066   5299   
        let this = self.project();
 5067   5300   
        this.inner.as_mut().poll(cx)
 5068   5301   
    }
 5069   5302   
}
 5070   5303   
 5071   5304   
impl<B>
 5072   5305   
    ::aws_smithy_http_server::request::FromRequest<
 5073   5306   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 5074   5307   
        B,
 5075   5308   
    > for crate::input::NoInputOutputInput
 5076   5309   
where
 5077   5310   
    B: ::aws_smithy_http_server::body::HttpBody + Send,
 5078   5311   
    B: 'static,
 5079   5312   
 5080   5313   
    B::Data: Send,
 5081   5314   
    ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection:
 5082   5315   
        From<<B as ::aws_smithy_http_server::body::HttpBody>::Error>,
 5083   5316   
{
 5084   5317   
    type Rejection = ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError;
 5085   5318   
    type Future = NoInputOutputInputFuture;
 5086   5319   
 5087         -
    fn from_request(request: ::http::Request<B>) -> Self::Future {
        5320  +
    fn from_request(request: ::http_1x::Request<B>) -> Self::Future {
 5088   5321   
        let fut = async move {
 5089   5322   
            crate::protocol_serde::shape_no_input_output::de_no_input_output_http_request(request)
 5090   5323   
                .await
 5091   5324   
        };
 5092   5325   
        use ::futures_util::future::TryFutureExt;
 5093   5326   
        let fut = fut.map_err(
 5094   5327   
            |e: ::aws_smithy_http_server::protocol::rpc_v2_cbor::rejection::RequestRejection| {
 5095   5328   
                ::tracing::debug!(error = %e, "failed to deserialize request");
 5096   5329   
                ::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(
 5097   5330   
                    e,
 5098   5331   
                )
 5099   5332   
            },
 5100   5333   
        );
 5101   5334   
        NoInputOutputInputFuture {
 5102   5335   
            inner: Box::pin(fut),
 5103   5336   
        }
 5104   5337   
    }
 5105   5338   
}
 5106   5339   
impl
 5107   5340   
    ::aws_smithy_http_server::response::IntoResponse<
 5108   5341   
        ::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor,
 5109   5342   
    > for crate::output::NoInputOutputOutput
 5110   5343   
{
 5111   5344   
    fn into_response(self) -> ::aws_smithy_http_server::response::Response {
 5112   5345   
        match crate::protocol_serde::shape_no_input_output::ser_no_input_output_http_response(self)
 5113   5346   
        {
 5114   5347   
            Ok(response) => response,
 5115   5348   
            Err(e) => {
 5116   5349   
                ::tracing::error!(error = %e, "failed to serialize response");
 5117   5350   
                ::aws_smithy_http_server::response::IntoResponse::<::aws_smithy_http_server::protocol::rpc_v2_cbor::RpcV2Cbor>::into_response(::aws_smithy_http_server::protocol::rpc_v2_cbor::runtime_error::RuntimeError::from(e))
 5118   5351   
            }
 5119   5352   
        }
 5120   5353   
    }
 5121   5354   
}
 5122   5355   
 5123   5356   
#[allow(unreachable_code, unused_variables)]
 5124   5357   
#[cfg(test)]
 5125   5358   
mod no_input_output_test {
 5126   5359   
 5127   5360   
    /// Body is empty and no Content-Type header if no input
 5128   5361   
    /// Test ID: no_input
 5129   5362   
    #[::tokio::test]
 5130   5363   
    #[::tracing_test::traced_test]
 5131   5364   
    async fn no_input_request() {
 5132   5365   
        #[allow(unused_mut)]
 5133         -
        let mut http_request = http::Request::builder()
        5366  +
        let mut http_request = ::http_1x::Request::builder()
 5134   5367   
            .uri("/service/RpcV2Protocol/operation/NoInputOutput")
 5135   5368   
            .method("POST")
 5136   5369   
            .header("Accept", "application/cbor")
 5137   5370   
            .header("smithy-protocol", "rpc-v2-cbor")
 5138         -
            .body(::aws_smithy_http_server::body::Body::from(
 5139         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5371  +
            .body(::aws_smithy_http_server::body::boxed(
        5372  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5373  +
                    &::aws_smithy_protocol_test::decode_body_data(
 5140   5374   
                        "".as_bytes(),
 5141   5375   
                        ::aws_smithy_protocol_test::MediaType::from("unknown"),
        5376  +
                    ),
 5142   5377   
                )),
 5143   5378   
            ))
 5144   5379   
            .unwrap();
 5145   5380   
        #[allow(unused_mut)]
 5146   5381   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 5147   5382   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 5148         -
        let service =
 5149         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5383  +
        let service = crate::service::RpcV2Protocol::builder::<
        5384  +
            ::aws_smithy_http_server::body::BoxBody,
        5385  +
            _,
        5386  +
            _,
        5387  +
            _,
        5388  +
        >(config)
 5150   5389   
        .no_input_output(move |input: crate::input::NoInputOutputInput| {
 5151   5390   
            let sender = sender.clone();
 5152   5391   
            async move {
 5153   5392   
                let result = {
 5154   5393   
                    let expected = crate::input::NoInputOutputInput {};
 5155   5394   
                    ::pretty_assertions::assert_eq!(input, expected);
 5156   5395   
                    let output = crate::output::NoInputOutputOutput {};
 5157   5396   
                    output
 5158   5397   
                };
 5159   5398   
                sender.send(()).await.expect("receiver dropped early");
 5160   5399   
                result
 5161   5400   
            }
 5162   5401   
        })
 5163   5402   
        .build_unchecked();
 5164   5403   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 5165   5404   
            .await
 5166   5405   
            .expect("unable to make an HTTP request");
 5167   5406   
        assert!(
 5168   5407   
            receiver.recv().await.is_some(),
 5169   5408   
            "we expected operation handler to be invoked but it was not entered"
 5170   5409   
        );
 5171   5410   
    }
 5172   5411   
 5173   5412   
    /// Servers should accept CBOR empty struct if no input.
 5174   5413   
    /// Test ID: NoInputServerAllowsEmptyCbor
 5175   5414   
    #[::tokio::test]
 5176   5415   
    #[::tracing_test::traced_test]
 5177   5416   
    async fn no_input_server_allows_empty_cbor_request() {
 5178   5417   
        #[allow(unused_mut)]
 5179         -
        let mut http_request = http::Request::builder()
        5418  +
        let mut http_request = ::http_1x::Request::builder()
 5180   5419   
            .uri("/service/RpcV2Protocol/operation/NoInputOutput")
 5181   5420   
            .method("POST")
 5182   5421   
            .header("Accept", "application/cbor")
 5183   5422   
            .header("Content-Type", "application/cbor")
 5184   5423   
            .header("smithy-protocol", "rpc-v2-cbor")
 5185         -
            .body(::aws_smithy_http_server::body::Body::from(
 5186         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5424  +
            .body(::aws_smithy_http_server::body::boxed(
        5425  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5426  +
                    &::aws_smithy_protocol_test::decode_body_data(
 5187   5427   
                        "v/8=".as_bytes(),
 5188   5428   
                        ::aws_smithy_protocol_test::MediaType::from("unknown"),
        5429  +
                    ),
 5189   5430   
                )),
 5190   5431   
            ))
 5191   5432   
            .unwrap();
 5192   5433   
        #[allow(unused_mut)]
 5193   5434   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 5194   5435   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 5195         -
        let service =
 5196         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5436  +
        let service = crate::service::RpcV2Protocol::builder::<
        5437  +
            ::aws_smithy_http_server::body::BoxBody,
        5438  +
            _,
        5439  +
            _,
        5440  +
            _,
        5441  +
        >(config)
 5197   5442   
        .no_input_output(move |input: crate::input::NoInputOutputInput| {
 5198   5443   
            let sender = sender.clone();
 5199   5444   
            async move {
 5200   5445   
                let result = {
 5201   5446   
                    let expected = crate::input::NoInputOutputInput {};
 5202   5447   
                    ::pretty_assertions::assert_eq!(input, expected);
 5203   5448   
                    let output = crate::output::NoInputOutputOutput {};
 5204   5449   
                    output
 5205   5450   
                };
 5206   5451   
                sender.send(()).await.expect("receiver dropped early");
 5207   5452   
                result
 5208   5453   
            }
 5209   5454   
        })
 5210   5455   
        .build_unchecked();
 5211   5456   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 5212   5457   
            .await
 5213   5458   
            .expect("unable to make an HTTP request");
 5214   5459   
        assert!(
 5215   5460   
            receiver.recv().await.is_some(),
 5216   5461   
            "we expected operation handler to be invoked but it was not entered"
 5217   5462   
        );
 5218   5463   
    }
 5219   5464   
 5220   5465   
    /// Servers should accept an empty body if there is no input. Additionally,
 5221   5466   
    /// they should not raise an error if the `Accept` header is set.
 5222   5467   
    /// Test ID: NoInputServerAllowsEmptyBody
 5223   5468   
    #[::tokio::test]
 5224   5469   
    #[::tracing_test::traced_test]
 5225   5470   
    async fn no_input_server_allows_empty_body_request() {
 5226   5471   
        #[allow(unused_mut)]
 5227         -
        let mut http_request = http::Request::builder()
        5472  +
        let mut http_request = ::http_1x::Request::builder()
 5228   5473   
            .uri("/service/RpcV2Protocol/operation/NoInputOutput")
 5229   5474   
            .method("POST")
 5230   5475   
            .header("Accept", "application/cbor")
 5231   5476   
            .header("Content-Type", "application/cbor")
 5232   5477   
            .header("smithy-protocol", "rpc-v2-cbor")
 5233         -
            .body(::aws_smithy_http_server::body::Body::from(
 5234         -
                ::bytes::Bytes::copy_from_slice(&::aws_smithy_protocol_test::decode_body_data(
        5478  +
            .body(::aws_smithy_http_server::body::boxed(
        5479  +
                ::http_body_util::Full::new(::bytes::Bytes::copy_from_slice(
        5480  +
                    &::aws_smithy_protocol_test::decode_body_data(
 5235   5481   
                        "".as_bytes(),
 5236   5482   
                        ::aws_smithy_protocol_test::MediaType::from("unknown"),
        5483  +
                    ),
 5237   5484   
                )),
 5238   5485   
            ))
 5239   5486   
            .unwrap();
 5240   5487   
        #[allow(unused_mut)]
 5241   5488   
        let (sender, mut receiver) = ::tokio::sync::mpsc::channel(1);
 5242   5489   
        let config = crate::service::RpcV2ProtocolConfig::builder().build();
 5243         -
        let service =
 5244         -
            crate::service::RpcV2Protocol::builder::<::hyper::body::Body, _, _, _>(config)
        5490  +
        let service = crate::service::RpcV2Protocol::builder::<
        5491  +
            ::aws_smithy_http_server::body::BoxBody,
        5492  +
            _,
        5493  +
            _,
        5494  +
            _,
        5495  +
        >(config)
 5245   5496   
        .no_input_output(move |input: crate::input::NoInputOutputInput| {
 5246   5497   
            let sender = sender.clone();
 5247   5498   
            async move {
 5248   5499   
                let result = {
 5249   5500   
                    let expected = crate::input::NoInputOutputInput {};
 5250   5501   
                    ::pretty_assertions::assert_eq!(input, expected);
 5251   5502   
                    let output = crate::output::NoInputOutputOutput {};
 5252   5503   
                    output
 5253   5504   
                };
 5254   5505   
                sender.send(()).await.expect("receiver dropped early");
 5255   5506   
                result
 5256   5507   
            }
 5257   5508   
        })
 5258   5509   
        .build_unchecked();
 5259   5510   
        let http_response = ::tower::ServiceExt::oneshot(service, http_request)
 5260   5511   
            .await
 5261   5512   
            .expect("unable to make an HTTP request");
 5262   5513   
        assert!(
 5263   5514   
            receiver.recv().await.is_some(),
 5264   5515   
            "we expected operation handler to be invoked but it was not entered"
 5265   5516   
        );
 5266   5517   
    }
 5267   5518   
 5268   5519   
    /// A `Content-Type` header should not be set if the response body is empty.
 5269   5520   
    /// Test ID: no_output
 5270   5521   
    #[::tokio::test]
 5271   5522   
    #[::tracing_test::traced_test]
 5272   5523   
    async fn no_output_response() {
 5273   5524   
        let output = crate::output::NoInputOutputOutput {};
 5274   5525   
        use ::aws_smithy_http_server::response::IntoResponse;
 5275   5526   
        let http_response = output.into_response();
 5276   5527   
        ::pretty_assertions::assert_eq!(
 5277         -
            http::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
        5528  +
            ::http_1x::StatusCode::from_u16(200).expect("invalid expected HTTP status code"),
 5278   5529   
            http_response.status()
 5279   5530   
        );
 5280   5531   
        let expected_headers = [("smithy-protocol", "rpc-v2-cbor")];
 5281   5532   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::validate_headers(
 5282   5533   
            http_response.headers(),
 5283   5534   
            expected_headers,
 5284   5535   
        ));
 5285   5536   
        let forbidden_headers = &["Content-Type"];
 5286   5537   
        ::aws_smithy_protocol_test::assert_ok(::aws_smithy_protocol_test::forbid_headers(
 5287   5538   
            http_response.headers(),
 5288   5539   
            forbidden_headers,
 5289   5540   
        ));
 5290         -
        let body = ::hyper::body::to_bytes(http_response.into_body())
        5541  +
        use ::http_body_util::BodyExt;
        5542  +
        let body = http_response
        5543  +
            .into_body()
        5544  +
            .collect()
 5291   5545   
            .await
 5292         -
            .expect("unable to extract body to bytes");
        5546  +
            .expect("unable to collect body")
        5547  +
            .to_bytes();
 5293   5548   
        // No body.
 5294   5549   
        ::pretty_assertions::assert_eq!(&body, &bytes::Bytes::new());
 5295   5550   
    }
 5296   5551   
}