Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge smithy-rs-release-1.x.y back into main #3306

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,25 @@
<!-- Do not manually edit this file. Use the `changelogger` tool. -->
December 11th, 2023
===================
**New this release:**
- :bug: (client, [smithy-rs#3305](https://github.com/smithy-lang/smithy-rs/issues/3305)) `crate::event_receiver::EventReceiver` is now re-exported as `crate::primitives::event_stream::EventReceiver` when a service supports event stream operations.


December 8th, 2023
==================
**New this release:**
- :tada: (all, [smithy-rs#3121](https://github.com/smithy-lang/smithy-rs/issues/3121), [smithy-rs#3295](https://github.com/smithy-lang/smithy-rs/issues/3295)) All generated docs now include docsrs labels when features are required
- :bug: (client, [smithy-rs#3262](https://github.com/smithy-lang/smithy-rs/issues/3262)) Loading native TLS trusted certs for the default HTTP client now only occurs if the default HTTP client is not overridden in config.
- (client, [smithy-rs#3277](https://github.com/smithy-lang/smithy-rs/issues/3277)) Improve the error messages for when auth fails to select an auth scheme for a request.
- (client, [smithy-rs#3282](https://github.com/smithy-lang/smithy-rs/issues/3282)) Fix documentation and examples on HyperConnector and HyperClientBuilder.
- (client, [aws-sdk-rust#990](https://github.com/awslabs/aws-sdk-rust/issues/990), @declanvk) Expose local socket address from ConnectionMetadata.
- (all, [smithy-rs#3294](https://github.com/smithy-lang/smithy-rs/issues/3294)) [`Number`](https://docs.rs/aws-smithy-types/latest/aws_smithy_types/enum.Number.html) `TryInto` implementations now succesfully convert from `f64` to numeric types when no precision is lost. This fixes some deserialization issues where numbers like `25.0` were sent when `Byte` fields were expected.

**Contributors**
Thank you for your contributions! ❤
- @declanvk ([aws-sdk-rust#990](https://github.com/awslabs/aws-sdk-rust/issues/990))


December 1st, 2023
==================
**New this release:**
Expand Down
89 changes: 1 addition & 88 deletions CHANGELOG.next.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,91 +9,4 @@
# message = "Fix typos in module documentation for generated crates"
# references = ["smithy-rs#920"]
# meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client | server | all"}
# author = "rcoh"

[[aws-sdk-rust]]
message = "Loading native TLS trusted certs for the default HTTP client now only occurs if the default HTTP client is not overridden in config."
references = ["smithy-rs#3262"]
meta = { "breaking" = false, "tada" = false, "bug" = true }
author = "jdisanti"

[[smithy-rs]]
message = "Loading native TLS trusted certs for the default HTTP client now only occurs if the default HTTP client is not overridden in config."
references = ["smithy-rs#3262"]
meta = { "breaking" = false, "tada" = false, "bug" = true, "target" = "client" }
author = "jdisanti"

[[aws-sdk-rust]]
message = """Client creation now takes microseconds instead of milliseconds.
Previously, it would take 2-3 milliseconds for each client instantiation due to time spent compiling regexes.
For applications that used several clients, this would increase start-up time in cases where it really matters,
such as for AWS Lambda cold starts. This time was improved by both changing regex implementation and caching the
result of the compilation."""
references = ["aws-sdk-rust#975", "smithy-rs#3269"]
meta = { "breaking" = false, "tada" = true, "bug" = false }
author = "jdisanti"

[[aws-sdk-rust]]
message = """Add `test_credentials` to `ConfigLoader` in `aws_config`. This allows the following pattern during tests:

```rust
async fn main() {
let conf = aws_config::defaults(BehaviorVersion::latest())
.test_credentials()
.await;
}
```

This is designed for unit tests and using local mocks like DynamoDB Local and LocalStack with the SDK.
"""
meta = { "breaking" = false, "tada" = true, "bug" = false }
author = "rcoh"
references = ["smithy-rs#3279", "aws-sdk-rust#971"]

[[aws-sdk-rust]]
message = "Improve the error messages for when auth fails to select an auth scheme for a request."
references = ["aws-sdk-rust#979", "smithy-rs#3277"]
meta = { "breaking" = false, "tada" = false, "bug" = false }
author = "jdisanti"

[[smithy-rs]]
message = "Improve the error messages for when auth fails to select an auth scheme for a request."
references = ["smithy-rs#3277"]
meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client" }
author = "jdisanti"

[[aws-sdk-rust]]
message = "Fix documentation and examples on HyperConnector and HyperClientBuilder."
references = ["aws-sdk-rust#986", "smithy-rs#3282"]
meta = { "breaking" = false, "tada" = false, "bug" = false }
author = "jdisanti"

[[smithy-rs]]
message = "Fix documentation and examples on HyperConnector and HyperClientBuilder."
references = ["smithy-rs#3282"]
meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client" }
author = "jdisanti"

[[smithy-rs]]
message = "Expose local socket address from ConnectionMetadata."
references = ["aws-sdk-rust#990"]
meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client" }
author = "declanvk"

[[smithy-rs]]
message = "All generated docs now include docsrs labels when features are required"
references = ["smithy-rs#3121", "smithy-rs#3295"]
meta = { "breaking" = false, "tada" = true, "bug" = false, "target" = "all" }
author = "rcoh"

[[aws-sdk-rust]]
message = "All generated docs now include docsrs labels when features are required"
references = ["smithy-rs#3121", "smithy-rs#3295"]
meta = { "breaking" = false, "tada" = true, "bug" = false }
author = "rcoh"

[[smithy-rs]]
message = "[`Number`](https://docs.rs/aws-smithy-types/latest/aws_smithy_types/enum.Number.html) `TryInto` implementations now succesfully convert from `f64` to numeric types when no precision is lost. This fixes some deserialization issues where numbers like `25.0` were sent when `Byte` fields were expected."
references = ["smithy-rs#3294"]
meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "all" }
author = "rcoh"
# author = "rcoh"
135 changes: 105 additions & 30 deletions aws/SDK_CHANGELOG.next.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,90 +6,165 @@
"smithy-rs": [],
"aws-sdk-rust": [
{
"message": "Make properties of S3Control PublicAccessBlockConfiguration optional. Previously, they defaulted to false, but this created invalid requests.",
"message": "Retry additional classes of H2 errors (H2 GoAway & H2 ResetStream)",
"meta": {
"bug": false,
"breaking": false,
"tada": false
},
"author": "rcoh",
"references": [
"aws-sdk-rust#738",
"aws-sdk-rust#858"
],
"since-commit": "88970ba88ef45266aade152c7c1da8e90b24c0d7",
"age": 4
},
{
"message": "Make some properties for IoT types optional. Previously, they defaulted to false, but that isn't how the service actual works.",
"meta": {
"bug": true,
"breaking": true,
"tada": false
},
"author": "milesziemer",
"references": [
"smithy-rs#3246"
"smithy-rs#3256"
],
"since-commit": "e155c3048b9989fe406ef575d461ea01dfaf294c",
"age": 5
"since-commit": "88970ba88ef45266aade152c7c1da8e90b24c0d7",
"age": 4
},
{
"message": "Allow `--` to be used in bucket names for S3",
"message": "Fix `config::Builder::set_credentials_provider` to override a credentials provider previously set.",
"meta": {
"bug": true,
"breaking": false,
"tada": false
},
"author": "rcoh",
"author": "ysaito1001",
"references": [
"smithy-rs#3253"
"aws-sdk-rust#973",
"smithy-rs#3278"
],
"since-commit": "48e3c95a3f10eebd5a637f8e7670c4232cdabbe4",
"age": 4
"since-commit": "529b3f03e2b945ea2e5e879183ccfd8e74b7377c",
"age": 3
},
{
"message": "Retry additional classes of H2 errors (H2 GoAway & H2 ResetStream)",
"message": "`config::Config::credentials_provider` has been broken since `release-2023-11-15` and is now marked as `deprecated` explicitly.",
"meta": {
"bug": false,
"breaking": false,
"tada": false
},
"author": "ysaito1001",
"references": [
"smithy-rs#3251",
"smithy-rs#3278"
],
"since-commit": "529b3f03e2b945ea2e5e879183ccfd8e74b7377c",
"age": 3
},
{
"message": "Loading native TLS trusted certs for the default HTTP client now only occurs if the default HTTP client is not overridden in config.",
"meta": {
"bug": true,
"breaking": false,
"tada": false
},
"author": "jdisanti",
"references": [
"smithy-rs#3262"
],
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "Client creation now takes microseconds instead of milliseconds.\nPreviously, it would take 2-3 milliseconds for each client instantiation due to time spent compiling regexes.\nFor applications that used several clients, this would increase start-up time in cases where it really matters,\nsuch as for AWS Lambda cold starts. This time was improved by both changing regex implementation and caching the\nresult of the compilation.",
"meta": {
"bug": false,
"breaking": false,
"tada": true
},
"author": "jdisanti",
"references": [
"aws-sdk-rust#975",
"smithy-rs#3269"
],
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "Add `test_credentials` to `ConfigLoader` in `aws_config`. This allows the following pattern during tests:\n\n```rust\nasync fn main() {\n let conf = aws_config::defaults(BehaviorVersion::latest())\n .test_credentials()\n .await;\n}\n```\n\nThis is designed for unit tests and using local mocks like DynamoDB Local and LocalStack with the SDK.\n",
"meta": {
"bug": false,
"breaking": false,
"tada": true
},
"author": "rcoh",
"references": [
"aws-sdk-rust#738",
"aws-sdk-rust#858"
"smithy-rs#3279",
"aws-sdk-rust#971"
],
"since-commit": "88970ba88ef45266aade152c7c1da8e90b24c0d7",
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "Make some properties for IoT types optional. Previously, they defaulted to false, but that isn't how the service actual works.",
"message": "Improve the error messages for when auth fails to select an auth scheme for a request.",
"meta": {
"bug": true,
"breaking": true,
"bug": false,
"breaking": false,
"tada": false
},
"author": "milesziemer",
"author": "jdisanti",
"references": [
"smithy-rs#3256"
"aws-sdk-rust#979",
"smithy-rs#3277"
],
"since-commit": "88970ba88ef45266aade152c7c1da8e90b24c0d7",
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "Fix `config::Builder::set_credentials_provider` to override a credentials provider previously set.",
"message": "Fix documentation and examples on HyperConnector and HyperClientBuilder.",
"meta": {
"bug": true,
"bug": false,
"breaking": false,
"tada": false
},
"author": "ysaito1001",
"author": "jdisanti",
"references": [
"aws-sdk-rust#973",
"smithy-rs#3278"
"aws-sdk-rust#986",
"smithy-rs#3282"
],
"since-commit": "529b3f03e2b945ea2e5e879183ccfd8e74b7377c",
"age": 1
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "`config::Config::credentials_provider` has been broken since `release-2023-11-15` and is now marked as `deprecated` explicitly.",
"message": "All generated docs now include docsrs labels when features are required",
"meta": {
"bug": false,
"breaking": false,
"tada": true
},
"author": "rcoh",
"references": [
"smithy-rs#3121",
"smithy-rs#3295"
],
"since-commit": "fc335cbc87e70aa63895828fca55b51795b94a6c",
"age": 2
},
{
"message": "`crate::event_receiver::EventReceiver` is now re-exported as `crate::primitives::event_stream::EventReceiver` when a service supports event stream operations.",
"meta": {
"bug": true,
"breaking": false,
"tada": false
},
"author": "ysaito1001",
"references": [
"smithy-rs#3251",
"smithy-rs#3278"
"smithy-rs#3305"
],
"since-commit": "529b3f03e2b945ea2e5e879183ccfd8e74b7377c",
"since-commit": "9f0ba850e03241f657e2e40ca185780e0a5878cb",
"age": 1
}
],
Expand Down
2 changes: 2 additions & 0 deletions aws/sdk/integration-tests/transcribestreaming/tests/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ use async_stream::stream;
use aws_sdk_transcribestreaming::config::{Credentials, Region};
use aws_sdk_transcribestreaming::error::SdkError;
use aws_sdk_transcribestreaming::operation::start_stream_transcription::StartStreamTranscriptionOutput;
#[allow(unused)] // making sure `EventReceiver` is re-exported
use aws_sdk_transcribestreaming::primitives::event_stream::EventReceiver;
use aws_sdk_transcribestreaming::primitives::event_stream::{HeaderValue, Message};
use aws_sdk_transcribestreaming::primitives::Blob;
use aws_sdk_transcribestreaming::types::error::{AudioStreamError, TranscriptResultStreamError};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import software.amazon.smithy.rust.codegen.core.rustlang.rustTemplate
import software.amazon.smithy.rust.codegen.core.rustlang.writable
import software.amazon.smithy.rust.codegen.core.smithy.CodegenContext
import software.amazon.smithy.rust.codegen.core.smithy.RuntimeType
import software.amazon.smithy.rust.codegen.core.smithy.RuntimeType.Companion.eventReceiver
import software.amazon.smithy.rust.codegen.core.smithy.RustCrate
import software.amazon.smithy.rust.codegen.core.util.hasEventStreamMember
import software.amazon.smithy.rust.codegen.core.util.hasEventStreamOperations
Expand Down Expand Up @@ -88,11 +89,13 @@ fun pubUseSmithyPrimitivesEventStream(codegenContext: CodegenContext, model: Mod
if (codegenContext.serviceShape.hasEventStreamOperations(model)) {
rustTemplate(
"""
pub use #{EventReceiver};
pub use #{Header};
pub use #{HeaderValue};
pub use #{Message};
pub use #{StrBytes};
""",
"EventReceiver" to eventReceiver(rc),
"Header" to RuntimeType.smithyTypes(rc).resolve("event_stream::Header"),
"HeaderValue" to RuntimeType.smithyTypes(rc).resolve("event_stream::HeaderValue"),
"Message" to RuntimeType.smithyTypes(rc).resolve("event_stream::Message"),
Expand Down
Loading