Feature-gate public use of `http-body` and `hyper` within `aws-smithy-types` (#3088)
## Motivation and Context Implements https://github.com/awslabs/smithy-rs/issues/3033 ## Description This PR hides behind cargo features the third-party types from `http-body` and `hyper` crates that are used in`aws-smithy-types`' public API. Customers need to opt-in by enabling a cargo feature `http-body-0-4-x` in `aws-smithy-types` to create an `SdkBody` or `ByteStream` using those third-party types. For more details, please see [the upgrade guide](https://github.com/awslabs/smithy-rs/discussions/3089 ). As can been seen from code changes, to reduce the surface area where we need to feature-gate things, we have fused the `aws_smithy_types::body::Inner::Streaming` enum variant into `aws_smithy_types::body::Inner::Dyn` variant, thereby removing `SdkBody::from_dyn`. ## Testing Relied on existing tests in CI ## Checklist - [x] I have updated `CHANGELOG.next.toml` if I made changes to the smithy-rs codegen or runtime crates ---- _By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice._ --------- Co-authored-by:Zelda Hessler <zhessler@amazon.com>
Loading
Please register or sign in to comment