Breaking Changes:
- β (aws-sdk-rust#490) Update all SDK and runtime crates to edition 2021
New this release:
- (smithy-rs#1262, @liubin) Fix link to Developer Guide in crate's README.md
- π (aws-sdk-rust#1271, @elrob) Treat blank environment variable credentials (
AWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEY) as missing instead of attempting to use them to sign requests. - (aws-sdk-rust#479, smithy-rs#1296) Add support for configuring the session length in AssumeRoleProvider
- (smithy-rs#1296) Add caching to AssumeRoleProvider
- (smithy-rs#1300, @benesch) Add endpoint resolver to SdkConfig. This enables overriding the endpoint resolver for all services build from a single SdkConfig.
Contributors Thank you for your contributions! β€
- @benesch (smithy-rs#1300)
- @elrob (aws-sdk-rust#1271)
- @liubin (smithy-rs#1262)
Breaking Changes:
-
β (aws-sdk-rust#406)
aws_types::config::Confighas been renamed toaws_types::sdk_config::SdkConfig. This is to better differentiate it from service-specific configs likeaws_sdk_s3::Config. If you were creating shared configs withaws_config::load_from_env(), then you don't have to do anything. If you were directly referring to a shared config, update yourusestatements andstructnames.Before:
use aws_types::config::Config; fn main() { let config = Config::builder() // config builder methods... .build() .await; }
After:
// We re-export this type from the root module so it's easier to reference use aws_types::SdkConfig; fn main() { let config = SdkConfig::builder() // config builder methods... .build() .await; }
-
β (smithy-rs#724) Timeout configuration has been refactored a bit. If you were setting timeouts through environment variables or an AWS profile, then you shouldn't need to change anything. Take note, however, that we don't currently support HTTP connect, read, write, or TLS negotiation timeouts. If you try to set any of those timeouts in your profile or environment, we'll log a warning explaining that those timeouts don't currently do anything.
If you were using timeouts programmatically, you'll need to update your code. In previous versions, timeout configuration was stored in a single
TimeoutConfigstruct. In this new version, timeouts have been broken up into several different config structs that are then collected in atimeout::Configstruct. As an example, to get the API per-attempt timeout in previous versions you would access it with<your TimeoutConfig>.api_call_attempt_timeout()and in this new version you would access it with<your timeout::Config>.api.call_attempt_timeout(). We also made some unimplemented timeouts inaccessible in order to avoid giving users the impression that setting them had an effect. We plan to re-introduce them once they're made functional in a future update.
New this release:
- π (aws-sdk-rust#475, aws-sdk-rust#473) Enable presigning for S3 operations UploadPart and DeleteObject
Breaking Changes:
- β (smithy-rs#1216)
aws-sigv4no longer skips thecontent-lengthandcontent-typeheaders when signing withSignatureLocation::QueryParams
New this release:
- π (smithy-rs#1220, aws-sdk-rust#462) Made it possible to change settings, such as load timeout, on the credential cache used by the
DefaultCredentialsChain. - π (smithy-rs#1197) Fixed a bug that caused clients to eventually stop retrying. The cross-request retry allowance wasn't being reimbursed upon receiving a successful response, so once this allowance reached zero, no further retries would ever be attempted.
- π (smithy-rs#1217, aws-sdk-rust#467)
ClientBuilderhelpersrustls()andnative_tls()now returnDynConnectorso that they once again work when constructing clients with custom middleware in the SDK. - π (smithy-rs#1216, aws-sdk-rust#466) Fixed a bug in S3 that prevented the
content-lengthandcontent-typeinputs from being included in a presigned request signature. With this fix, customers can generate presigned URLs that enforcecontent-lengthandcontent-typefor requests to S3.
Breaking Changes:
-
β (smithy-rs#1144) The
aws_config::http_providermodule has been renamed toaws_config::http_credential_providerto better reflect its purpose. -
β (smithy-rs#1144) Some APIs required that timeout configuration be specified with an
aws_smithy_client::timeout::Settingsstruct while others required anaws_smithy_types::timeout::TimeoutConfigstruct. Both were equivalent. Nowaws_smithy_types::timeout::TimeoutConfigis used everywhere andaws_smithy_client::timeout::Settingshas been removed. Here's how to migrate code your code that depended ontimeout::Settings:The old way:
let timeout = timeout::Settings::new() .with_connect_timeout(Duration::from_secs(1)) .with_read_timeout(Duration::from_secs(2));
The new way:
// This example is passing values, so they're wrapped in `Option::Some`. You can disable a timeout by passing `None`. let timeout = TimeoutConfig::new() .with_connect_timeout(Some(Duration::from_secs(1))) .with_read_timeout(Some(Duration::from_secs(2)));
-
β (smithy-rs#1144)
MakeConnectorFn,HttpConnector, andHttpSettingshave been moved fromaws_config::provider_configtoaws_smithy_client::http_connector. This is in preparation for a later update that will change how connectors are created and configured.If you were using these structs/enums, you can migrate your old code by importing them from their new location.
-
β (smithy-rs#1144) Along with moving
HttpConnectortoaws_smithy_client, theHttpConnector::make_connectormethod has been renamed toHttpConnector::connector.If you were using this method, you can migrate your old code by calling
connectorinstead ofmake_connector. -
β (smithy-rs#1085) Moved the following re-exports into a
typesmodule for all services:aws_sdk_<service>::AggregatedBytes->aws_sdk_<service>::types::AggregatedBytesaws_sdk_<service>::Blob->aws_sdk_<service>::types::Blobaws_sdk_<service>::ByteStream->aws_sdk_<service>::types::ByteStreamaws_sdk_<service>::DateTime->aws_sdk_<service>::types::DateTimeaws_sdk_<service>::SdkError->aws_sdk_<service>::types::SdkError
-
β (smithy-rs#1085)
AggregatedBytesandByteStreamare now only re-exported if the service has streaming operations, andBlob/DateTimeare only re-exported if the service uses them. -
β (smithy-rs#1130) MSRV increased from
1.54to1.56.1per our 2-behind MSRV policy. -
β (smithy-rs#1132) Fluent clients for all services no longer have generics, and now use
DynConnectorandDynMiddlewareto allow for connector/middleware customization. This should only break references to the client that specified generic types for it.If you customized the AWS client's connector or middleware with something like the following:
let client = aws_sdk_s3::Client::with_config( aws_sdk_s3::client::Builder::new() .connector(my_custom_connector) // Connector customization .middleware(my_custom_middleware) // Middleware customization .default_async_sleep() .build(), config );
Then you will need to wrap the custom connector or middleware in
DynConnectorandDynMiddlewarerespectively:let client = aws_sdk_s3::Client::with_config( aws_sdk_s3::client::Builder::new() .connector(DynConnector::new(my_custom_connector)) // Now with `DynConnector` .middleware(DynMiddleware::new(my_custom_middleware)) // Now with `DynMiddleware` .default_async_sleep() .build(), config );
If you had functions that took a generic connector, such as the following:
fn some_function<C, E>(conn: C) -> Result<()> where C: aws_smithy_client::bounds::SmithyConnector<Error = E> + Send + 'static, E: Into<aws_smithy_http::result::ConnectorError> { // ... }
Then the generics and trait bounds will no longer be necessary:
fn some_function(conn: DynConnector) -> Result<()> { // ... }
Similarly, functions that took a generic middleware can replace the generic with
DynMiddlewareand remove their trait bounds.
New this release:
- π (aws-sdk-rust#443) The
ProfileFileRegionProviderwill now respect regions set in chained profiles - (smithy-rs#1144) Several modules defined in the
aws_configcrate that used to be declared within another module's file have been moved to their own files. The moved modules arests,connector, anddefault_providers. They still have the exact same import paths. - π (smithy-rs#1129) Fix some docs links not working because they were escaped when they shouldn't have been
- (smithy-rs#1085) The
ClientandConfigre-exports now have their documentation inlined in the service docs - π (smithy-rs#1180) Fixed example showing how to use hardcoded credentials in
aws-types
New this release:
- (aws-sdk-rust#423) Added
impl Into<http::request::Builder> for PresignedRequestand a conversion method for turningPresignedRequests intohttp::Requests. - (smithy-rs#1087) Convert several
infospans todebugin aws-config - (smithy-rs#1118) SDK examples now come from
awsdocs/aws-doc-sdk-examplesrather than fromsmithy-rs
New this release:
- π (smithy-rs#1100) Internal: Update sync script to run gradle clean. This fixes an issue where codegen was not triggered when only properties changed.
New this release:
- π (smithy-rs#1089) Fix dev-dependency cycle between aws-sdk-sso and aws-config
New this release:
- π (aws-sdk-rust#348) The docs for fluent builders now have easy links to their corresponding Input, Output, and Error structs
- π (smithy-rs#1051, aws-sdk-rust#4) Add support for SSO credentials
- ππ (smithy-rs#1065, aws-sdk-rust#398, @nmoutschen) Silence profile credential warnings in Lambda environment
- π (aws-sdk-rust#405, smithy-rs#1083) Fixed paginator bug impacting EC2 describe VPCs (and others)
Contributors Thank you for your contributions! β€
- @nmoutschen (aws-sdk-rust#398, smithy-rs#1065)
New this release:
- π (smithy-rs#1050, @nmoutschen) Fix typos for X-Ray trace ID environment variable in aws_http::recursion_detection
- π (smithy-rs#1054, aws-sdk-rust#391) Fix critical paginator bug where an empty outputToken lead to a never ending stream.
Contributors Thank you for your contributions! β€
- @nmoutschen (smithy-rs#1050)
Breaking Changes:
- β (smithy-rs#990) Codegen will no longer produce builders and clients with methods that take
impl Into<T>except for strings and boxed types. - β (smithy-rs#961) The
meta,environment, anddnsCargo feature flags were removed fromaws-config. The code behind thednsflag is now enabled whenrt-tokiois enabled. The code behind themetaandenvironmentflags is always enabled now. - β (smithy-rs#1003)
aws_http::AwsErrorRetryPolicywas moved toaws_http::retry::AwsErrorRetryPolicy. - β (smithy-rs#1017, smithy-rs#930) Simplify features in aws-config. All features have been removed from
aws-configwith the exception of:rt-tokio,rustlsandnative-tls. All other features are now included by default. If you depended on those features specifically, remove them from your features listing.
New this release:
- π (aws-sdk-rust#47, smithy-rs#1006) Add support for paginators! Paginated APIs now include
.into_paginator()and (when supported).into_paginator().items()to enable paginating responses automatically. The paginator API should be considered in preview and is subject to change pending customer feedback. - (smithy-rs#712) We removed an example 'telephone-game' that was problematic for our CI. The APIs that that example demonstrated are also demonstrated by our Polly and TranscribeStreaming examples so please check those out if you miss it.
- π (aws-sdk-rust#357) Generated docs should no longer contain links that don't go anywhere
- (aws-sdk-rust#254, @jacco) Made fluent operation structs cloneable
- (smithy-rs#973) Debug implementation of Credentials will print
expiryin a human readable way. - π (smithy-rs#999, smithy-rs#143, aws-sdk-rust#344) Add Route53 customization to trim
/hostedzone/prefix prior to serialization. This fixes a bug where round-tripping a hosted zone id resulted in an error. - π (smithy-rs#998, aws-sdk-rust#359) Fix bug where ECS credential provider could not perform retries.
- (smithy-rs#1003) Add recursion detection middleware to the default stack
- (smithy-rs#1002, aws-sdk-rust#352) aws_types::Config is now
Clone - (smithy-rs#670, @jacco) Example for Config builder region function added
- (smithy-rs#1021, @kiiadi) Add function to
aws_config::profile::ProfileSetthat allows listing of loaded profiles by name. - π (smithy-rs#1046, aws-sdk-rust#384) Fix IMDS credentials provider bug where the instance profile name was incorrectly cached.
Contributors Thank you for your contributions! β€
- @jacco (aws-sdk-rust#254, smithy-rs#670)
- @kiiadi (smithy-rs#1021)
Breaking Changes:
-
β (smithy-rs#930) If you directly depend on AWS or Smithy runtime crates (e.g., AWS crates not named
aws-configor prefixed withaws-sdk-), the formerly default features from those crates must now be explicitly set in yourCargo.toml.Upgrade guide
before after aws-smithy-async = "VERSION"aws-smithy-async = { version = "VERSION", features = ["rt-tokio"] }aws-smithy-client = "VERSION"aws-smithy-client = { version = "VERSION", features = ["client-hyper", "rustls", "rt-tokio"] }aws-smithy-http = "VERSION"aws-smithy-http = { version = "VERSION", features = ["rt-tokio"] } -
β (smithy-rs#940)
aws_hyper::Clientwhich was just a re-export ofaws_smithy_types::Clientwith generics set has been removed. If you usedaws_hyper::Clientoraws_hyper::Client::https()you can update your code to useaws_smithy_client::Builder::https(). -
β (smithy-rs#947) The features
aws-hyper/rustlsandaws-hyper/native-tlshave been removed. If you were using these, use the identical features onaws-smithy-client. -
β (smithy-rs#959, smithy-rs#934)
aws-hyper::AwsMiddlewareis now generated into generated service clients directly. If you usedaws_hyper::Middleware, use ::middleware::DefaultMiddleware` instead.
New this release:
- π (aws-sdk-rust#330) A bug that occurred when signing certain query strings has been fixed
- π (smithy-rs#949, @a-xp) Fix incorrect argument order in the builder for
LazyCachingCredentialsProvider - π (aws-sdk-rust#304)
aws-configwill now work as intended for users that want to usenative-tlsinstead ofrustls. Previously, it was difficult to ensure thatrustlswas not in use. Also, there is now an example of how to usenative-tlsand a test that ensuresrustlsis not in the dependency tree - π (aws-sdk-rust#317, smithy-rs#907) Removed inaccurate log message when a client was used without a sleep implementation, and improved context and call to action in logged messages around missing sleep implementations.
- (smithy-rs#923) Use provided
sleep_implfor retries instead of using Tokio directly. - (smithy-rs#920) Fix typos in module documentation for generated crates
- π (aws-sdk-rust#301, smithy-rs#892) Avoid serializing repetitive
xmlnsattributes when serializing XML. This reduces the length of serialized requests and should improve compatibility with localstack. - π (smithy-rs#953, aws-sdk-rust#331) Fixed a bug where certain characters caused a panic during URI encoding.
Contributors Thank you for your contributions! β€
- @a-xp (smithy-rs#949)
- This release was a version bump to fix a version number conflict in crates.io
New this release
- Add docs.rs metadata section to all crates to document all features
- Added a new example showing how to set all currently supported timeouts
- Add a new check so that the SDK doesn't emit an irrelevant
$HOMEdir warning when running in a Lambda (aws-sdk-rust#307) - π Don't capture empty session tokens from the
AWS_SESSION_TOKENenvironment variable (aws-sdk-rust#316, smithy-rs#906)
Breaking Changes
RetryConfigBuilder::merge_withhas been renamed toRetryConfigBuilder::take_unset_fromCredentials::from_keysis now behind a feature flag namedhardcoded-credentialsinaws-types. It is NOT secure to hardcode credentials into your application, and the credentials providers that come with the AWS SDK should be preferred. (smithy-rs#875, smithy-rs#317)- (aws-smithy-client): Extraneous
pub use SdkSuccessremoved fromaws_smithy_client::hyper_ext. (smithy-rs#855) - The
add_metadatafunction was removed fromAwsUserAgentinaws-http. Usewith_feature_metadata,with_config_metadata, orwith_framework_metadatanow instead. (smithy-rs#865) - Several breaking changes around
aws_smithy_types::Instantwere introduced by smithy-rs#849:aws_smithy_types::Instantfrom was renamed toDateTimeto avoid confusion with the standard library's monotonically nondecreasingInstanttype.DateParseErrorinaws_smithy_typeshas been renamed toDateTimeParseErrorto match the type that's being parsed.- The
chrono-conversionsfeature and associated functions have been moved to theaws-smithy-types-convertcrate.- Calls to
Instant::from_chronoshould be changed to:use aws_smithy_types::DateTime; use aws_smithy_types_convert::date_time::DateTimeExt; // For chrono::DateTime<Utc> let date_time = DateTime::from_chrono_utc(chrono_date_time); // For chrono::DateTime<FixedOffset> let date_time = DateTime::from_chrono_offset(chrono_date_time);
- Calls to
instant.to_chrono()should be changed to:use aws_smithy_types_convert::date_time::DateTimeExt; date_time.to_chrono_utc();
- Calls to
Instant::from_system_timeandInstant::to_system_timehave been changed toFromtrait implementations.- Calls to
from_system_timeshould be changed to:DateTime::from(system_time); // or let date_time: DateTime = system_time.into();
- Calls to
to_system_timeshould be changed to:SystemTime::from(date_time); // or let system_time: SystemTime = date_time.into();
- Calls to
- Several functions in
Instant/DateTimewere renamed:Instant::from_f64->DateTime::from_secs_f64Instant::from_fractional_seconds->DateTime::from_fractional_secsInstant::from_epoch_seconds->DateTime::from_secsInstant::from_epoch_millis->DateTime::from_millisInstant::epoch_fractional_seconds->DateTime::as_secs_f64Instant::has_nanos->DateTime::has_subsec_nanosInstant::epoch_seconds->DateTime::secsInstant::epoch_subsecond_nanos->DateTime::subsec_nanosInstant::to_epoch_millis->DateTime::to_millis
- The
DateTime::fmtmethod is now fallible and fails when aDateTime's value is outside what can be represented by the desired date format.
New this week
β οΈ MSRV increased from 1.53.0 to 1.54.0 per our 3-behind MSRV policy.- Conversions from
aws_smithy_types::DateTimetoOffsetDateTimefrom thetimecrate are now available from theaws-smithy-types-convertcrate. (smithy-rs#849) - Fixed links to Usage Examples (smithy-rs#862, @floric)
- Added missing features to user agent formatting, and made it possible to configure an app name for the user agent via service config. (smithy-rs#865)
- π Relaxed profile name validation to allow
@and other characters (smithy-rs#861, aws-sdk-rust#270) - π Fixed signing problem with S3 Control (smithy-rs#858, aws-sd-rust#291)
- π Timeouts for requests are now configurable. You can set a timeout for each individual request attempt or for all attempts made for a request. (smithy-rs#831)
SdkErrornow includes a variantTimeoutErrorfor when a request times out (smithy-rs#885)
- Improve docs on
aws-smithy-client(smithy-rs#855) - Fix http-body dependency version (smithy-rs#883, aws-sdk-rust#305)
Contributions
Thank you for your contributions! β€οΈ
- @floric (smithy-rs#862)
No changes since last release except for version bumping since older versions
of the AWS SDK were failing to compile with the 0.27.0-alpha.2 version chosen
for some of the supporting crates.
Breaking Changes
- Members named
builderon model structs were renamed tobuilder_valueso that their accessors don't conflict with the existingbuilder()methods (smithy-rs#842)
New this week
- Fix epoch seconds date-time parsing bug in
aws-smithy-types(smithy-rs#834) - Omit trailing zeros from fraction when formatting HTTP dates in
aws-smithy-types(smithy-rs#834) - Moved examples into repository root (aws-sdk-rust#181, smithy-rs#843)
- Model structs now have accessor methods for their members. We recommend updating code to use accessors instead of public fields. A future release will deprecate the public fields before they are made private. (smithy-rs#842)
- π Fix bug that caused signing to fail for requests where the body length was <=9. (smithy-rs#845)
New this week
- π Add support for AWS Glacier (smithy-rs#801)
- π Add support for AWS Panorama
- π Fix
native-tlsfeature inaws-config(aws-sdk-rust#265, smithy-rs#803) - Add example to aws-sig-auth for generating an IAM Token for RDS (smithy-rs#811, aws-sdk-rust#147)
- π
hyper::Error(IncompleteMessage)will now be retried (smithy-rs#815) - π S3 request metadata signing now correctly trims headers fixing problems like this (smithy-rs#761)
- All unions (eg.
dynamodb::model::AttributeValue) now include an additionalUnknownvariant. These support cases where a new union variant has been added on the server but the client has not been updated. - π Fix generated docs on unions like
dynamodb::AttributeValue. (smithy-rs#826)
Breaking Changes
<operation>.make_operation(&config)is now anasyncfunction for all operations. Code should be updated to call.await. This will only impact users using the low-level API. (smithy-rs#797)
Breaking Changes
CredentialsErrorvariants became non-exhaustive. This makes them impossible to construct directly outside of theaws_typescrate. In order to construct credentials errors, new methods have been added for each variant. Instead ofCredentialsError::Unhandled(...), you should instead useCredentialsError::unhandled. Matching methods exist for all variants. (#781)- The default credentials chain now returns
CredentialsError::CredentialsNotLoadedinstead ofProviderErrorwhen no credentials providers are configured. β οΈ All Smithy runtime crates have been renamed to have anaws-prefix. This may require code changes:- Cargo.toml changes:
smithy-async->aws-smithy-asyncsmithy-client->aws-smithy-clientsmithy-eventstream->aws-smithy-eventstreamsmithy-http->aws-smithy-httpsmithy-http-tower->aws-smithy-http-towersmithy-json->aws-smithy-jsonsmithy-protocol-test->aws-smithy-protocol-testsmithy-query->aws-smithy-querysmithy-types->aws-smithy-typessmithy-xml->aws-smithy-xml
- Rust
usestatement changes:smithy_async->aws_smithy_asyncsmithy_client->aws_smithy_clientsmithy_eventstream->aws_smithy_eventstreamsmithy_http->aws_smithy_httpsmithy_http_tower->aws_smithy_http_towersmithy_json->aws_smithy_jsonsmithy_protocol_test->aws_smithy_protocol_testsmithy_query->aws_smithy_querysmithy_types->aws_smithy_typessmithy_xml->aws_smithy_xml
- Cargo.toml changes:
New this week
- Moved the contents of
aws-authinto theaws-httpruntime crate (smithy-rs#783) - Fix instances where docs were missing in generated services and add
#[warn_missing_docs](smithy-rs#779) - Add tracing output for resolved AWS endpoint (smithy-rs#784)
- Update AWS service models (smithy-rs#790)
- Add support for the following Glacier customizations:
- Set the ApiVersion header (smithy-rs#138, #787)
New this week
- Prepare crate manifests for publishing to crates.io (smithy-rs#755)
- Add support for IAM Roles for tasks credential provider (smithy-rs#765, aws-sdk-rust#123)
- All service crates now have generated README files (smithy-rs#766)
- Update AWS service models (smithy-rs#772)
- π Add support for Amazon Managed Grafana (smithy-rs#772)
Breaking changes
β οΈ MSRV increased from 1.52.1 to 1.53.0 per our 3-behind MSRV policy.SmithyConnectorandDynConnectornow returnConnectorErrorinstead ofBox<dyn Error>. If you have written a custom connector, it will need to be updated to return the new error type. (#744)- The
DispatchErrorvariant ofSdkErrornow containsConnectorErrorinstead ofBox<dyn Error>(#744).
New This Week
- π Make retry behavior configurable
- With env vars
AWS_MAX_ATTEMPTSandAWS_RETRY_MODE - With
~/.aws/configsettingsmax_attemptsandretry_mode - By calling the
with_retry_configmethod on aConfigand passing in aRetryConfig - Only the
Standardretry mode is currently implemented.Adaptiveretry mode will be implemented at a later date. - For more info, see the AWS Reference pages on configuring these settings:
- With env vars
- π Add presigned request support and examples for S3 GetObject and PutObject (smithy-rs#731, aws-sdk-rust#139)
- π Add presigned request support and example for Polly SynthesizeSpeech (smithy-rs#735, aws-sdk-rust#139)
- Add connect & HTTP read timeouts to IMDS, defaulting to 1 second
- IO and timeout errors from Hyper can now be retried (#744)
- π Fix error when receiving
Contevent from S3 SelectObjectContent (smithy-rs#736) - π Fix bug in event stream receiver that could cause the last events in the response stream to be lost when using S3 SelectObjectContent (smithy-rs#736)
- Updated EC2 code examples to include readme; refactored operations from main into separate functions.
- Updated Transcribe code example to take an audio file as a command-line option and added readme.
- Refactored API Gateway code example by moving operation out of main and into a separate function; added readme.
- Updated Auto Scaling code example to move operation from main to separate function; added readme.
- Updated AWS Config code examples to include a readme; added command-line options; added DeleteConfigurationRecorder, DeleteDeliveryChannel, ListConfigurationRecorders, ListDeliveryChannels, ListResources, ShowResourceHistory, and EnableConfig code examples.
- π Add support for 6 new AWS services:
- Wisdom
- VoiceId
- Account
- KafkaConnect
- OpenSearch
- CloudControl
New This Week
- π IMDS support in the default credential provider chain (aws-sdk-rust#97)
- π Add
sts::AssumeRoleProvidertoaws-config. This enables customers to invoke STS directly, instead of using it via~/.aws/config. (smithy-rs#703, aws-sdk-rust#3) - Add IMDS client to
aws-config(smithy-rs#701) - Add IMDS credential provider to
aws-config(smithy-rs#709) - Add IMDS region provider to
aws-config(smithy-rs#715, aws-sdk-rust#97) - Update event stream
Receivers to beSend(aws-sdk-rust#224) - Add query param signing to the
aws-sigv4crate (smithy-rs#707) - π Update event stream
Receivers to beSend(smithy-rs#702, #aws-sdk-rust#224) - π Fix panic when signing non-ASCII header values (smithy-rs#708, aws-sdk-rust#226)
- Add an example that uses Polly, Transcribe, and S3 called telephone-game
Contributions
Thank you for your contributions! β€οΈ
- @jonhoo (smithy-rs#703)
- π Add support for
OpenSearchservice & bring in other model updates (#todo) - Cleanup docs in
aws-config
New This Week
-
π Fixes issue where
Content-Lengthheader could be duplicated leading to signing failure (aws-sdk-rust#220, smithy-rs#697) -
Updated AutoScaling code examples to use asynchronous config; added readme file; tested on 0.0.17 bits
This release adds support for three commonly requested features:
- More powerful credential chain
- Support for constructing multiple clients from the same configuration
- Support for Transcribe streaming and S3 Select
In addition, this overhauls client configuration which lead to a number of breaking changes. Detailed changes are inline.
Current Credential Provider Support:
- Environment variables
- Web Identity Token Credentials
- Profile file support (partial)
- Credentials
- SSO
- ECS Credential source
- IMDS credential source
- Assume role from source profile
- Static credentials source profile
- WebTokenIdentity provider
- Region
- Credentials
- IMDS
- ECS
from_env loaded region & credentials from environment variables only. Default sources have been removed from the generated
SDK clients and moved to the aws-config package. Note that the aws-config package default chain adds support for
profile file and web identity token profiles.
- Add a dependency on
aws-config:[dependencies] aws-config = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.17-alpha" }
- Update your client creation code:
// `shared_config` can be used to construct multiple different service clients! let shared_config = aws_config::load_from_env().await; // before: <service>::Client::from_env(); let client = <service>::Client::new(&shared_config)
Config::build() has been modified to not fallback to a default provider. Instead, use aws-config to load and modify
the default chain. Note that when you switch to aws-config, support for profile files and web identity tokens will be added.
-
Add a dependency on
aws-config:[dependencies] aws-config = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.17-alpha" }
-
Update your client creation code:
fn before() { let region = aws_types::region::ChainProvider::first_try(<1 provider>).or_default_provider(); let config = <service>::Config::builder().region(region).build(); let client = <service>::Client::from_conf(&config); } async fn after() { use aws_config::meta::region::RegionProviderChain; let region_provider = RegionProviderChain::first_try(<1 provider>).or_default_provider(); // `shared_config` can be used to construct multiple different service clients! let shared_config = aws_config::from_env().region(region_provider).load().await; let client = <service>::Client::new(&shared_config) }
All credential providers that were in aws-auth-providers have been moved to aws-config. Unless you have a specific use case
for a specific credential provider, you should use the default provider chain:
let shared_config = aws_config::load_from_env().await;
let client = <service>::Client::new(&shared_config);AsyncProvideCredentials has been renamed to ProvideCredentials. The trait has been moved from aws-auth to aws-types.
The original ProvideCredentials trait has been removed. The return type has been changed to by a custom future.
For synchronous use cases:
use aws_types::credentials::{ProvideCredentials, future};
#[derive(Debug)]
struct CustomCreds;
impl ProvideCredentials for CustomCreds {
fn provide_credentials<'a>(&'a self) -> future::ProvideCredentials<'a>
where
Self: 'a,
{
// if your credentials are synchronous, use `::ready`
// if your credentials are loaded asynchronously, use `::new`
future::ProvideCredentials::ready(todo!()) // your credentials go here
}
}For asynchronous use cases:
use aws_types::credentials::{ProvideCredentials, future, Result};
#[derive(Debug)]
struct CustomAsyncCreds;
impl CustomAsyncCreds {
async fn load_credentials(&self) -> Result {
Ok(Credentials::from_keys("my creds...", "secret", None))
}
}
impl ProvideCredentials for CustomCreds {
fn provide_credentials<'a>(&'a self) -> future::ProvideCredentials<'a>
where
Self: 'a,
{
future::ProvideCredentials::new(self.load_credentials())
}
}Breaking Changes
-
Credential providers from
aws-auth-providershave been moved toaws-config(smithy-rs#678) -
AsyncProvideCredentialshas been renamed toProvideCredentials. The original non-async provide credentials has been removed. See the migration guide above. -
<sevicename>::from_env()has been removed (#675). A drop-in replacement is available:- Add a dependency on
aws-config:[dependencies] aws-config = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.17-alpha" }
- Update your client creation code:
let client = <service>>::Client::new(&aws_config::load_from_env().await)
- Add a dependency on
-
ProvideRegionhas been moved toaws_config::meta::region::ProvideRegion. (smithy-rs#675) -
aws_types::region::ChainProviderhas been moved toaws_config::meta::region::RegionProviderChain(smithy-rs#675). -
ProvideRegionis now asynchronous. Code that calledprovider.region()must be changed toprovider.region().await. -
<awsservice>::Config::builder()will not load a default region. To preserve previous behavior:- Add a dependency on
aws-config:[dependencies] aws-config = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.17-alpha" }
-
let shared_config = aws_config::load_from_env().await; let config = <service>::config::Builder::from(&shared_config).<other builder modifications>.build();
- Add a dependency on
New this week
- π Add profile file provider for region (smithy-rs#594, smithy-rs#682)
- π Add support for shared configuration between multiple services (smithy-rs#673)
- π Add support for Transcribe
StartStreamTranscriptionand S3SelectObjectContentoperations (smithy-rs#667) - π Add support for new MemoryDB service (smithy-rs#677)
- Improve documentation on collection-aware builders (smithy-rs#664)
- Update AWS SDK models (smithy-rs#677)
- π Fix sigv4 signing when request ALPN negotiates to HTTP/2. (smithy-rs#674)
- π Fix integer size on S3
Size(smithy-rs#679, #209) - π Fix MediaLive response parsing issue (smithy-rs#683, #212)
New This Week
- π Add Chime Identity, Chime Messaging, and Snow Device Management support (smithy-rs#657)
- π Add profile file credential provider implementation. This implementation currently does not support credential sources for assume role providers other than environment variables. (smithy-rs#640)
- π Add support for WebIdentityToken providers via profile & environment variables. (smithy-rs#654)
- π Fix name collision that occurred when a model had both a union and a structure named
Result(smithy-rs#643) - π Fix STS Assume Role with WebIdentity & Assume role with SAML to support clients with no credentials provided (smithy-rs#652)
- Update AWS SDK models (smithy-rs#657)
- Add initial implementation of a default provider chain. (smithy-rs#650)
This release primarily contains internal changes to runtime components & updates to AWS models.
Breaking changes
-
(smithy-rs#635) The
config(),config_mut(),request(), andrequest_mut()methods onoperation::Requesthave been renamed toproperties(),properties_mut(),http(), andhttp_mut()respectively. -
(smithy-rs#635) The
Responsetype on Tower middleware has been changed fromhttp::Response<SdkBody>tooperation::Response. The HTTP response is still available from theoperation::Responseusing itshttp()andhttp_mut()methods. -
(smithy-rs#635) The
ParseHttpResponsetrait'sparse_unloaded()method now takes anoperation::Responserather than anhttp::Response<SdkBody>. -
(smithy-rs#626)
ParseHttpResponseno longer has a generic argument for the body type, but instead, always usesSdkBody. This may cause compilation failures for you if you are using Smithy generated types to parse JSON or XML without using a client to request data from a service. The fix should be as simple as removing<SdkBody>in the example below:Before:
let output = <Query as ParseHttpResponse<SdkBody>>::parse_loaded(&parser, &response).unwrap();
After:
let output = <Query as ParseHttpResponse>::parse_loaded(&parser, &response).unwrap();
New This Week
- The closure passed to
async_provide_credentials_fncan now borrow values (smithy-rs#637) - Bring in the latest AWS models (smithy-rs#630)
IoT Data Plane is now available! If you discover it isn't functioning as expected, please let us know!
This week also sees the addition of a robust async caching credentials provider. Take a look at the STS example to see how to use it.
To upgrade to the new release, update tag to v0.0.14-alpha:
[dependencies]
# e.g. S3:
aws-sdk-s3 = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.14-alpha" }
New This Week
- π Add IoT Data Plane (smithy-rs#624)
- π Add LazyCachingCredentialsProvider to aws-auth for use with expiring credentials, such as STS AssumeRole. Update STS example to use this new provider (smithy-rs#578, smithy-rs#595)
- π Correctly encode HTTP Checksums using base64 instead of hex. Fixes #164. (smithy-rs#615)
- Overhaul serialization/deserialization of numeric/boolean types. This resolves issues around serialization of NaN/Infinity and should also reduce the number of allocations required during serialization. (smithy-rs#618)
- Update SQS example to clarify usage of FIFO vs. standard queues (#162, @trevorrobertsjr)
Contributions
Thank you for your contributions! β€οΈ
- @trevorrobertsjr (#622)
π This week's release includes most of the remaining AWS services (269 in total!).
Breaking changes
test-utilhas been made an optional dependency and has moved from aws-hyper to smithy-http. If you were relying onaws_hyper::TestConnection, addsmithy-clientas a dependency and enable the optionaltest-utilfeature. This prunes some unnecessary dependencies onroxmltreeandserde_jsonfor most users. (smithy-rs#608)
New This Week
- π Release all but four remaining AWS services! Glacier, IoT Data Plane, Timestream DB and Transcribe Streaming will be available in a future release. If you discover that a service isn't functioning as expected please let us know! (smithy-rs#607)
- π Bugfix: Fix parsing bug where parsing XML incorrectly stripped whitespace (smithy-rs#590, #153)
- We now run some tests on Windows (smithy-rs#594)
- π Bugfix: Constrain RFC-3339 timestamp formatting to microsecond precision (smithy-rs#596, #152)
This week we've added Autoscaling and fixed an S3 bug.
To update to the new release, change your tag to v0.0.12-alpha.
New this Week
- π Add support for Autoscaling (#576, #582)
AsyncProvideCredentialsnow introduces an additional lifetime parameter, simplifying bridging it with#[async_trait]interfaces- Fix S3 bug when content type was set explicitly (aws-sdk-rust#131, #566, @eagletmt)
Contributions Thank you for your contributions! β€οΈ
- @eagletmt (#566)
This week, we've added AWS Config, EBS, Cognito, and Snowball. Projects that are implementing the ProvideCredentials trait will need to update their imports and should consider using the new async_provide_credentials_fn for async credential use-cases.
To update to the new release, change your tag to v0.0.11-alpha.
New this Week
β οΈ Breaking Change:ProvideCredentialsandCredentialErrorwere both moved intoaws_auth::providerwhen they were previously inaws_auth(#572)- π Add support for AWS Config (#570)
- π Add support for EBS (#567)
- π Add support for Cognito (#573)
- π Add support for Snowball (#579, @landonxjames)
- Make it possible to asynchronously provide credentials with
async_provide_credentials_fn(#572, #577) - Improve RDS, QLDB, Polly, and KMS examples (#561, #560, #558, #556, #550)
- Update AWS SDK models (#575)
- π Bugfix: Fill in message from error response even when it doesn't match the modeled case format (#565)
Contributions
Thank you for your contributions! β€οΈ
- landonxjames (#579)
This week, we've added EKS, ECR and Cloudwatch. The JSON deserialization implementation has been replaced, please be on the lookout for potential issues and compile time improvements.
To update to the new release, change your tag to v0.0.10-alpha.
New this Week
- π Add support for ECR (smithy-rs#557)
- π Add support for Cloudwatch (smithy-rs#554)
- π Add support for EKS (smithy-rs#553)
β οΈ Breaking Change: httpLabel no longer causes fields to be non-optional. You may need to adapt code that uses models. (#537)β οΈ Breaking Change:Exceptionis not renamed toError. Code may need to be updated to replaceErrorwithExceptionwhen naming error shapes.β οΈ Breaking Change: Models are now in strict pascal case including acronyms (e.g.dynamodb::model::{SSESpecification => SseSpecification})- Add more SES examples, and improve examples for Batch.
- Improved error handling ergonomics: Errors now provide
is_<variantname>()methods to simplify error handling - π Bugfix: Fix bug in
create_multipart_upload: #127 (smithy-rs#531, @eagletmt)
Contributors
Thank you for your contributions! β€οΈ
- @eagletmt (#531)
This week, we've added CloudWatch Logs support and fixed several bugs in the generated S3 clients. There are breaking changes on builders and unions this week.
To upgrade to the new release, update tag to v0.0.9-alpha:
[dependencies]
# e.g. Cloudwatch Logs:
aws-sdk-cloudwatchlogs = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.9-alpha" }New this Week
- π Add support for CloudWatch Logs (smithy-rs#526)
β οΈ Breaking Change: Theset_*functions on generated Builders now always take anOption(smithy-rs#506)β οΈ Breaking Change: Theas_*functions on unions now returnResultrather thanOptionto clearly indicate what the actual value is (smithy-rs#527)- Add more S3 examples, and improve SNS, SQS, and SageMaker examples. Improve example doc comments (smithy-rs#490, smithy-rs#508, smithy-rs#509, smithy-rs#510, smithy-rs#511, smithy-rs#512, smithy-rs#513, smithy-rs#524)
- Combine individual example packages into per-service example packages with multiple binaries (smithy-rs#481, smithy-rs#490)
- π Bugfix: Show response body in trace logs for calls that don't return a stream (smithy-rs#514)
- π Bugfix: Correctly parse S3's GetBucketLocation response (smithy-rs#516)
- π Bugfix: Fix S3 ListObjectsV2 for prefixes containing tilde characters (smithy-rs#519)
- π Bugfix: Fix S3 PutBucketLifecycle operation by adding support for the
@httpChecksumRequiredSmithy trait (smithy-rs#523) - π Bugfix: Correctly parse
x-amz-expirationheader on S3 GetObject responses (smithy-rs#525, @eagletmt)
Contributions
Thank you for your contributions! β€οΈ
- @eagletmt (smithy-rs#525)
- @zekisherif (smithy-rs#515)
This week, we've added CloudFormation, SageMaker, EC2, and SES. More details below.
To upgrade to the new release, update tag to v0.0.8-alpha:
[dependencies]
# e.g. EC2:
aws-sdk-ec2 = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.8-alpha" }New this Week
- π Add support for CloudFormation (smithy-rs#500, @alistaim)
- π Add support for SageMaker (smithy-rs#473, @alistaim)
- π Add support for EC2 (smithy-rs#495)
- π Add support for SES (smithy-rs#499)
- Add support for the EC2 Query protocol (smithy-rs#475)
- Refactor smithy/hyper connectors to enable client-specified middleware (smithy-rs#496, @jonhoo)
- π Bugfix: RFC-3339 timestamp formatting is no longer truncating zeros off of the number of seconds (smithy-rs#479, smithy-rs#489)
Contributors:
- @Doug-AWS
- @jdisanti
- @rcoh
- @alistaim
- @jonhoo
Thanks!!
This week weβve added MediaLive, MediaPackage, SNS, Batch, STS, RDS, RDSData, Route53, and IAM. More details below.
To upgrade to the new release, update tag to v0.0.7-alpha:
[dependencies]
# e.g. SNS:
aws-sdk-sns = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.7-alpha" }New this Week
- Breaking change: Some string enums have changed case:
DynamoDB::{SSEStatus => SseStatus. SSEType => SseType} - π Add support for MediaLive and MediaPackage (#449, @alastaim)
- π Add support for SNS (smithy-rs#450)
- π Add support for Batch (smithy-rs#452)
- π Add support for STS. Note: This does not include support for an STS-based credential provider although an example is provided. (smithy-rs#453)
- π Add support for RDS (smithy-rs#455) and RDS-Data (smithy-rs#470). (@LMJW)
- π Add support for Route53 (smithy-rs#457, @alistaim)
- Support AWS Endpoints & Regions. With this update, regions like
iam-fipsandcn-north-1will now resolve to the correct endpoint. Please report any issues with endpoint resolution. (smithy-rs#468) - π Primitive numerics and booleans are now filtered from serialization when they are 0 and not marked as required. This resolves issues where maxResults needed to be set even though it is optional & fixes errors during deserialization. (smithy-rs#451)
- π S3 Head Object returned the wrong error when the object did not exist (smithy-rs#460, fixes smithy-rs#456)
Contributors:
- @rcoh
- @jdisanti
- @alistaim
- @LMJW
Thanks!
New this week:
- π Add support for SQS. SQS is our first service to use the awsQuery protocol. Please report any issues you may encounter.
- π Add support for ECS.
- Breaking Change: Refactored
smithy_types::Errorto be more flexible. Internal fields ofErrorare now private and can now be accessed accessor functions. (smithy-rs#426) - Breaking change: Smithy Enums do not implement
serde::Serialize ByteStream::from_pathnow acceptsimplications AsRef<Path>(@LMJW)- Add support for S3 extended request id (smithy-rs#429)
- Add support for the awsQuery protocol. smithy-rs can now add support for all services except EC2.
- Bugfix: Timestamps that fell precisely on minute boundaries were not properly formatted (smithy-rs#435)
- Improve documentation for
ByteStream& addpub use ByteStreamto generated crates (smithy-rs#443) - Add support for
EndpointPrefixneeded fors3::WriteGetObjectResponse(smithy-rs#420)
Contributors:
- @jdisanti
- @rcoh
- @LMJW
Thanks!
You can install the new release by updating your dependencies to tag = "v0.0.5-alpha", e.g.
[dependencies]
aws-sdk-s3 = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.5-alpha" }- π Add S3 support. S3 is the first protocol to use our new XML serializers which increases the likelihood of undiscovered issues. In addition, virtual addressing, dualstack and transfer acceleration are not currently supported. Please try it out and let us know if you run into any problems! (smithy-rs#398) π
- π Add support for SSM. SSM was prioritized based on your votesβPlease keep voting for the services and feature most important to you! (smithy-rs#393) π
- Add request/response tracing. These can be enabled via tracing subscriber by setting:
RUST_LOG='smithy_http_tower::dispatch=trace,smithy_http::middleware=trace'(smithy-rs#397) - Bugfix: Generated service docs were missing at the module level (smithy-rs#404)
ByteStreamcan now be created fromPathandFileviaByteStream::from_path(smithy-rs#412)- Example code now uses
write_all_buf(#408, @lmjw) - The
Authorizationandx-amz-security-tokenheaders are now marked as sensitive and will be omitted from logs even when full request/response tracing is enabled
And more: See the corresponding smithy-rs release.
Contributors:
- @rcoh
- @jdisanti
- @LMJW
Thanks!
You can install the new release by updating your dependencies to tag = "v0.0.4-alpha", e.g.
[dependencies]
aws-sdk-lambda = { git = "https://github.com/awslabs/aws-sdk-rust", tag = "v0.0.4-alpha" }New this week:
- π Add support for AWS Lambda (smithy-rs#361, @richardhboyd) π
- Generate docs automatically and host on GitHub Pages: https://awslabs.github.io/aws-sdk-rust/ (#81)
- Add support for streaming request bodies. This is technically a breaking change but no currently generated AWS services expose this type. (smithy-rs#359)
- Types represented by the Smithy
Settype now generateVec<T>in all cases. This is also technically breaking but not currently exposed. (smithy-rs#270) - Bugfix: The
.message()field of errors will now look for bothmessageandMessagein the model (smithy-rs#374) - Add support for the
AWS_REGIONenvironment variable. (smithy-rs#362) - The request type generated by the fluent builders, e.g.
dynamodb.list_tables()is nowDebug(smithy-rs#377, @declanvk)
And more: See the corresponding smithy-rs release.
Contributors:
- @richardhboyd
- @declanvk
- @jdisanti2019
- @rcoh
Thanks!
New this week:
- Fix stack overflow in
SdkBodyDebug implementation - Upgrade to Smithy 1.7. This adds support for several new API Gateway endpoints
- Add support for streaming response bodies. This is currently only used in Polly
- Added code examples for Kinesis
More details in smithy-rs: https://github.com/awslabs/smithy-rs/releases/tag/v0.8