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

identitystore apis failing with url error #5163

Closed
JishantSingh opened this issue Feb 7, 2024 · 2 comments
Closed

identitystore apis failing with url error #5163

JishantSingh opened this issue Feb 7, 2024 · 2 comments
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.

Comments

@JishantSingh
Copy link

JishantSingh commented Feb 7, 2024

Describe the bug

identitystore.DescribeUser and identitystore.ListUsers fail with wrong url.
https://identitystore..amazonaws.com/

Tried running on macos sonoma 14.2.1 and in k8s container with golang:1.20.4 base image.

Probably true for other idc apis too, however I have only verified for these two.

Expected Behavior

Should use a valid url.

Current Behavior

Error in describe user, operation error identitystore: ListUsers, https response error StatusCode: 0, RequestID: , request send failed, Post https://identitystore..amazonaws.com/: dial tcp: lookup identitystore..amazonaws.com: no such host

Reproduction Steps

Use the following script


import (
	"context"
	"fmt"
	"github.com/aws/aws-sdk-go-v2/credentials"
	"log"

	"github.com/aws/aws-sdk-go-v2/aws"
	"github.com/aws/aws-sdk-go-v2/config"
	"github.com/aws/aws-sdk-go-v2/service/identitystore"
)

func main() {
	cfg, err := config.LoadDefaultConfig(context.TODO(),
		config.WithCredentialsProvider(credentials.NewStaticCredentialsProvider(
			"access_key",
			"secret_key",
			"token",
		)))
	if err != nil {
		log.Fatalf("unable to load SDK config, %v", err)
	}

	svc := identitystore.NewFromConfig(cfg)

	resp, err := svc.DescribeUser(context.TODO(), &identitystore.DescribeUserInput{
		IdentityStoreId: aws.String("idc_id"),
		UserId:          aws.String("idc_user_id"),
	})

	if err != nil {
		log.Fatalf("Error in describe user, %v", err)
	}
	fmt.Println("-----RECV------")
	fmt.Println(*resp)
}

Possible Solution

No response

Additional Information/Context

No response

SDK version used

1.24.1

Environment details (Version of Go (go version)? OS name and version, etc.)

Go 1.20.4, MacOS Sonoma 14.2.1,

@JishantSingh JishantSingh added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Feb 7, 2024
Copy link

github-actions bot commented Feb 7, 2024

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

@JishantSingh
Copy link
Author

Had to pass region as a mandatory option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. needs-triage This issue or PR still needs to be triaged.
Projects
None yet
Development

No branches or pull requests

1 participant