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

fix(clients): merge default variants by comparing tags #3044

Merged
merged 2 commits into from
Nov 19, 2021

Conversation

trivikr
Copy link
Member

@trivikr trivikr commented Nov 19, 2021

Issue

Fixes #3043

Description

Merges variants from partition defaults and service defaults using tags as unique key

Testing

Verified that endpoint resolution returns dynamodb.us-gov-east-1.api.aws for DynamoDB with region=us-gov-east-1 and useDualstackEndpoint=true

Code
import { DynamoDB } from "../aws-sdk-js-v3/clients/client-dynamodb/dist-cjs/index.js";

const client = new DynamoDB({
  region: "us-gov-east-1",
  useDualstackEndpoint: true,
});
await client.listTables({});
Output
node:internal/process/esm_loader:94
    internalBinding('errors').triggerUncaughtException(
                              ^

Error: getaddrinfo ENOTFOUND dynamodb.us-gov-east-1.api.aws
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) {
  errno: -3008,
  code: 'ENOTFOUND',
  syscall: 'getaddrinfo',
  hostname: 'dynamodb.us-gov-east-1.api.aws',
  '$metadata': { attempts: 1, totalRetryDelay: 0 }
}

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@trivikr trivikr marked this pull request as ready for review November 19, 2021 01:54
@trivikr trivikr requested a review from a team as a code owner November 19, 2021 01:54
@trivikr trivikr marked this pull request as draft November 19, 2021 01:55
@trivikr trivikr marked this pull request as ready for review November 19, 2021 01:55
@trivikr trivikr changed the title fix(clients): merge partition & service default variants checking tags fix(clients): merge default variants by comparing tags Nov 19, 2021
@codecov-commenter
Copy link

Codecov Report

Merging #3044 (4e5d0fa) into main (bcfb45b) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #3044   +/-   ##
=======================================
  Coverage   58.76%   58.76%           
=======================================
  Files         567      567           
  Lines       30360    30360           
  Branches     7482     7482           
=======================================
  Hits        17841    17841           
  Misses      12519    12519           
Impacted Files Coverage Δ
...lients/client-lex-runtime-service/src/endpoints.ts 100.00% <ø> (ø)
clients/client-s3-control/src/endpoints.ts 100.00% <ø> (ø)
clients/client-sts/src/endpoints.ts 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bcfb45b...4e5d0fa. Read the comment docs.

@trivikr trivikr merged commit d65a310 into aws:main Nov 19, 2021
@trivikr trivikr deleted the merge-variants-tags-unique-key branch November 19, 2021 17:04
@github-actions
Copy link

github-actions bot commented Dec 4, 2021

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 4, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Endpoint resolution fails for DynamoDB in "us-gov-east-1" region when useDualstackEndpoint=true
3 participants