Skip to content

Commit 3593e07

Browse files
authored
feat!: implement smithy-modeled endpoint resolution for aws sdk (#759)
1 parent d5afc27 commit 3593e07

File tree

59 files changed

+1248
-12524
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1248
-12524
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "019ad769-8cf1-48fc-b898-5c325fca6917",
3+
"type": "feature",
4+
"description": "Add support for (S3 Transfer Acceleration)[https://docs.aws.amazon.com/AmazonS3/latest/userguide/transfer-acceleration.html]."
5+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"id": "20d71413-8e11-4769-bb84-ca93c82bd6fc",
3+
"type": "feature",
4+
"description": "Add support for (S3 Access Points)[https://aws.amazon.com/s3/features/access-points/].",
5+
"issues": [
6+
"awslabs/aws-sdk-kotlin#231"
7+
]
8+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "231f0336-689b-4a85-8b72-1059a9c4ce61",
3+
"type": "feature",
4+
"description": "Add support for dual-stack endpoints in client config."
5+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "552c1b75-b19c-49e9-ac05-2f4a88ec2bb9",
3+
"type": "feature",
4+
"description": "**BREAKING** Add smithy-modeled endpoint resolvers for AWS services. See [this discussion post](https://github.com/awslabs/aws-sdk-kotlin/discussions/761) for more information."
5+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "5e992ee9-f624-423c-a388-afec012e39be",
3+
"type": "feature",
4+
"description": "Add support for (S3 PrivateLink)[https://docs.aws.amazon.com/AmazonS3/latest/userguide/privatelink-interface-endpoints.html]."
5+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"id": "64c54161-6b84-4251-a1fc-a7c568424ee6",
3+
"type": "feature",
4+
"description": "Add support for (S3 Virtual Host Addressing)[https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html] (enabled by default).",
5+
"issues": [
6+
"awslabs/aws-sdk-kotlin#399"
7+
]
8+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "82affce8-73dd-42be-ab9e-a737337652c1",
3+
"type": "feature",
4+
"description": "Add support for [FIPS](https://aws.amazon.com/compliance/fips/) endpoints in client config."
5+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "9a088733-20ae-47fc-932a-ed5dd5959e7a",
3+
"type": "feature",
4+
"description": "Add support for (S3 Object Lambda)[https://aws.amazon.com/s3/features/object-lambda/]."
5+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"id": "e2422015-caee-497f-8049-feeda953bcaf",
3+
"type": "feature",
4+
"description": "Add support for (S3 Outposts)[https://aws.amazon.com/s3/outposts/]."
5+
}

aws-runtime/aws-config/common/src/aws/sdk/kotlin/runtime/auth/credentials/EcsCredentialsProvider.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ public class EcsCredentialsProvider internal constructor(
100100
}
101101
}
102102

103-
op.install(ResolveEndpoint(resolver = { Endpoint(url) }))
103+
op.install(ResolveEndpoint(provider = { Endpoint(url) }, params = null))
104104
op.install(retryMiddleware)
105105

106106
logger.debug { "retrieving container credentials" }
@@ -153,9 +153,9 @@ public class EcsCredentialsProvider internal constructor(
153153

154154
// TODO - validate loopback via DNS resolution instead of fixed set. Custom host names (including localhost) that
155155
// resolve to loopback won't work until then. ALL resolved addresses MUST resolve to the loopback device
156-
val allowedHosts = setOf("127.0.0.1", "[::1]")
156+
val allowedHosts = setOf("127.0.0.1", "::1")
157157

158-
if (url.host !in allowedHosts) {
158+
if (url.host.toString() !in allowedHosts) {
159159
throw ProviderConfigurationException(
160160
"The container credentials full URI ($uri) has an invalid host. Host can only be one of [${allowedHosts.joinToString()}].",
161161
)

0 commit comments

Comments
 (0)