October 31st, 2023
Pre-releaseBreaking Changes:
-
⚠️ 🎉 (client, smithy-rs#2417, smithy-rs#3018) Retry classifiers are now configurable at the service and operation levels. Users may also define their own custom retry classifiers.For more information, see the guide.
-
⚠️ (client, smithy-rs#3011) HTTP connector configuration has changed significantly. See the upgrade guidance for details. -
⚠️ (client, smithy-rs#3038) TheenableNewSmithyRuntime: middleware
opt-out flag in smithy-build.json has been removed and no longer opts out of the client orchestrator implementation. Middleware is no longer supported. If you haven't already upgraded to the orchestrator, see the guide. -
⚠️ (client, smithy-rs#2909) It's now possible to nest runtime components with theRuntimePlugin
trait. Acurrent_components
argument was added to theruntime_components
method so that components configured from previous runtime plugins can be referenced in the current runtime plugin. Ordering of runtime plugins was also introduced via a newRuntimePlugin::order
method. -
⚠️ (all, smithy-rs#2948) Update MSRV to Rust 1.70.0 -
⚠️ (client, smithy-rs#2970)aws_smithy_client::hyper_ext::Adapter
was moved/renamed toaws_smithy_runtime::client::connectors::hyper_connector::HyperConnector
. -
⚠️ (client, smithy-rs#2970) Test connectors moved intoaws_smithy_runtime::client::connectors::test_util
behind thetest-util
feature. -
⚠️ (client, smithy-rs#2970) DVR's RecordingConnection and ReplayingConnection were renamed to RecordingConnector and ReplayingConnector respectively. -
⚠️ (client, smithy-rs#2970) TestConnection was renamed to EventConnector. -
⚠️ (all, smithy-rs#2973) Removeonce_cell
from public API. -
⚠️ (all, smithy-rs#2995) Structure members with the typeOption<Vec<T>>
now produce an accessor with the type&[T]
instead ofOption<&[T]>
. This is enabled by default for clients and can be disabled by updating your smithy-build.json with the following setting:{ "codegen": { "flattenCollectionAccessors": false, ... } }
-
⚠️ (client, smithy-rs#2978) Thefutures_core::stream::Stream
trait has been removed from public API.FnStream
only supportsnext
,try_next
,collect
, andtry_collect
methods.TryFlatMap::flat_map
returnsPaginationStream
, which should be preferred toFnStream
at an interface level. Other stream operations that were previously available through the trait or its extension traits can be added later in a backward compatible manner. Finally,fn_stream
has been moved to be a child module ofpagination_stream
. -
⚠️ (client, smithy-rs#2983) Thefutures_core::stream::Stream
trait has been removed fromByteStream
. The methods mentioned in the doc will continue to be supported. Other stream operations that were previously available through the trait or its extension traits can be added later in a backward compatible manner. -
⚠️ (client, smithy-rs#2997)StaticUriEndpointResolver
'suri
constructor now takes aString
instead of aUri
. -
⚠️ (server, smithy-rs#3038)SdkError
is no longer re-exported in generated server crates. -
⚠️ (client, smithy-rs#3039) Thecustomize()
method is now sync and infallible. Remove anyawait
s and error handling from it to make things compile again. -
🐛
⚠️ (all, smithy-rs#3037, aws-sdk-rust#756) Our algorithm for converting identifiers tosnake_case
has been updated. This may result in a small change for some identifiers, particularly acronyms ending ins
, e.g.ACLs
. -
⚠️ (client, smithy-rs#3055) The future return types on traitsEndpointResolver
andIdentityResolver
changed to new-typesEndpointFuture
andIdentityFuture
respectively. -
⚠️ (client, smithy-rs#3032)EndpointPrefix::new
no longer returnscrate::operation::error::BuildError
for an Err variant, instead returns a more specificInvalidEndpointError
. -
⚠️ (client, smithy-rs#3061) Lifetimes have been added to theEndpointResolver
trait. -
⚠️ (client, smithy-rs#3065) Several traits have been renamed from noun form to verb form to be more idiomatic:AuthSchemeOptionResolver
->ResolveAuthSchemeOptions
EndpointResolver
->ResolveEndpoint
IdentityResolver
->ResolveIdentity
Signer
->Sign
RequestSerializer
->SerializeRequest
ResponseDeserializer
->DeserializeResponse
Interceptor
->Intercept
-
⚠️ (client, smithy-rs#3059) This change has detailed upgrade guidance. A summary is below.
TheHttpRequest
type alias now points toaws-smithy-runtime-api::client::http::Request
. This is a first-party request type to allow us to gracefully supporthttp = 1.0
when it arrives. Most customer code using this method should be unaffected.TryFrom
/TryInto
conversions are provided forhttp = 0.2.*
. -
⚠️ (client, smithy-rs#2917)RuntimeComponents
have been added as an argument to theIdentityResolver::resolve_identity
trait function. -
⚠️ (client, smithy-rs#3072) Theidempotency_provider
field has been removed from config as a public field. If you need access to this field, it is still available from the context of an interceptor. -
⚠️ (client, smithy-rs#3078) Theconfig::Builder::endpoint_resolver
method no longer accepts&'static str
. Useconfig::Builder::endpoint_url
instead. -
⚠️ (client, smithy-rs#3043, smithy-rs#3078) This change has detailed upgrade guidance.
The endpoint interfaces fromaws-smithy-http
have been removed. Service-specific endpoint resolver traits have been added. -
⚠️ (all, smithy-rs#3054, smithy-rs#3070)aws_smithy_http::operation::error::{BuildError, SerializationError}
have been moved toaws_smithy_types::error::operation::{BuildError, SerializationError}
. Type aliases for them are left inaws_smithy_http
for backwards compatibility but are deprecated. -
⚠️ (all, smithy-rs#3076)aws_smithy_http::body::{BoxBody, Error, SdkBody}
have been moved toaws_smithy_types::body::{BoxBody, Error, SdkBody}
. Type aliases for them are left inaws_smithy_http
for backwards compatibility but are deprecated. -
⚠️ (all, smithy-rs#3076, smithy-rs#3091)aws_smithy_http::byte_stream::{AggregatedBytes, ByteStream, error::Error, FsBuilder, Length}
have been moved toaws_smithy_types::byte_stream::{AggregatedBytes, ByteStream, error::Error, FsBuilder, Length}
. Type aliases for them are left inaws_smithy_http
for backwards compatibility but are deprecated. -
⚠️ (client, smithy-rs#3077) Behavior Break! Identities for auth are now cached by default. See theConfig
builder'sidentity_cache()
method docs for an example of how to disable this caching. -
⚠️ (all, smithy-rs#3033, smithy-rs#3088, smithy-rs#3101) Publicly exposed types fromhttp-body
andhyper
crates withinaws-smithy-types
are now feature-gated. See the upgrade guidance for details. -
⚠️ (all, smithy-rs#3033, smithy-rs#3088)ByteStream::poll_next
is now feature-gated. You can turn on a cargo featurebyte-stream-poll-next
inaws-smithy-types
to use it. -
⚠️ (client, smithy-rs#3092, smithy-rs#3093) Theconnection
andresult
modules inaws-smithy-http
have been moved toaws-smithy-runtime-api
. Type aliases for all affected pub items, except for a trait, are left inaws-smithy-http
for backwards compatibility but are deprecated. Due to lack of trait aliases, the moved traitCreateUnhandledError
needs to be used fromaws-smithy-runtime-api
. -
🐛
⚠️ (server, smithy-rs#3095, smithy-rs#3096) Service builder initialization now takes in a${serviceName}Config
object on which plugins and layers should be registered. Thebuilder_with_plugins
andbuilder_without_plugins
methods on the service builder, as well as thelayer
method on the built service have been deprecated, and will be removed in a future release. See the upgrade guidance for more details.
New this release:
- 🎉 (client, smithy-rs#2916, smithy-rs#1767) Support for Smithy IDLv2 nullability is now enabled by default. You can maintain the old behavior by setting `nullabilityCheckMode: "CLIENT_ZERO_VALUE_V1" in your codegen config.
For upgrade guidance and more info, see here. - 🎉 (server, smithy-rs#3005) Python middleware can set URI. This can be used to route a request to a different handler.
- 🎉 (client, smithy-rs#3071) Clients now have a default async sleep implementation so that one does not need to be specified if you're using Tokio.
- 🐛 (client, smithy-rs#2944, smithy-rs#2951)
CustomizableOperation
, created as a result of calling the.customize
method on a fluent builder, ceased to beSend
andSync
in the previous releases. It is nowSend
andSync
again. - 🐛 (client, smithy-rs#2960) Generate a region setter when a model uses SigV4.
- 🐛 (all, smithy-rs#2969, smithy-rs#1896) Fix code generation for union members with the
@httpPayload
trait. - (client, smithy-rs#2964) Required members with @contextParam are now treated as client-side required.
- 🐛 (client, smithy-rs#2926, smithy-rs#2972) Fix regression with redacting sensitive HTTP response bodies.
- 🐛 (all, smithy-rs#2831, aws-sdk-rust#818) Omit fractional seconds from
http-date
format. - 🐛 (client, smithy-rs#2985) Source defaults from the default trait instead of implicitly based on type. This has minimal changes in the generated code.
- (client, smithy-rs#2996) Produce better docs when items are marked @required
- 🐛 (client, smithy-rs#3034, smithy-rs#3087) Enable custom auth schemes to work by changing the code generated auth options to be set at the client level at
DEFAULTS
priority.