Skip to content

Add breakingChanges to the removal of sigv4 and sigv4a traits #2567

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

Merged
merged 1 commit into from
Mar 26, 2025
Merged
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"type": "feature",
"description": "Add breakingChanges to the removal of sigv4 and sigv4a traits",
"pull_requests": []
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,17 @@ structure cognitoUserPools {
traits: [unsignedPayload]
)
@externalDocumentation(Reference: "https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html")
@trait(selector: "service")
@trait(
selector: "service"
breakingChanges: [
{
change: "remove",
message: """
Removing the existing authentication scheme is not backward compatible \
and can break existing clients' authentication."""
}
]
)
structure sigv4 {
/// The signature version 4 service signing name to use in the credential
/// scope when signing requests. This value SHOULD match the `arnNamespace`
Expand All @@ -46,7 +56,17 @@ structure sigv4 {
Reference: "https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html"
Examples: "https://github.com/aws-samples/sigv4a-signing-examples"
)
@trait(selector: "service[trait|aws.auth#sigv4]")
@trait(
selector: "service[trait|aws.auth#sigv4]"
breakingChanges: [
{
change: "remove",
message: """
Removing the existing authentication scheme is not backward compatible \
and can break existing clients' authentication."""
}
]
)
structure sigv4a {
/// The signature version 4a service signing name to use in the credential
/// scope when signing requests. This value SHOULD match the `arnNamespace`
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
$version: "2.0"

metadata suppressions = [
{
id: "ModifiedTrait.Update.smithy.api#auth"
namespace: "ns.foo"
}
]

namespace ns.foo

use aws.auth#sigv4

@auth([sigv4])
@sigv4(name: "service")
service Service {
operations: [
Operation
]
}

operation Operation {}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
$version: "2.0"

metadata suppressions = [
{
id: "ModifiedTrait.Update.smithy.api#auth"
namespace: "ns.foo"
}
]

namespace ns.foo

@auth([])
service Service {
operations: [
Operation
]
}


operation Operation {}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[ERROR] ns.foo#Service: Removed trait `aws.auth#sigv4`. Previous trait value:
```
{
"name": "service"
}
```
; Removing the existing authentication scheme is not backward compatible and can break existing clients' authentication. | TraitBreakingChange.Remove
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
$version: "2.0"

metadata suppressions = [
{
id: "ModifiedTrait.Update.smithy.api#auth"
namespace: "ns.foo"
}
]

namespace ns.foo

use aws.auth#sigv4
use aws.auth#sigv4a

@auth([sigv4, sigv4a])
@sigv4(name: "service")
@sigv4a(name: "service")
service Service {
operations: [
Operation
]
}

operation Operation {}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
$version: "2.0"

metadata suppressions = [
{
id: "ModifiedTrait.Update.smithy.api#auth"
namespace: "ns.foo"
}
]

namespace ns.foo

use aws.auth#sigv4

@auth([sigv4])
@sigv4(name: "service")
service Service {
operations: [
Operation
]
}


operation Operation {}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[ERROR] ns.foo#Service: Removed trait `aws.auth#sigv4a`. Previous trait value:
```
{
"name": "service"
}
```
; Removing the existing authentication scheme is not backward compatible and can break existing clients' authentication. | TraitBreakingChange.Remove
Loading