Skip to content
This repository was archived by the owner on Jan 19, 2022. It is now read-only.

Confusing credential defaults / documentation. #470

Closed
internetstaff opened this issue May 30, 2019 · 2 comments
Closed

Confusing credential defaults / documentation. #470

internetstaff opened this issue May 30, 2019 · 2 comments
Labels
component: core An issue related to core functionality - credentials, region resolution type: documentation A documentation update
Milestone

Comments

@internetstaff
Copy link

I'm on v2.1.1.RELEASE

The documentation is at least unclear on the credential configuration:

https://cloud.spring.io/spring-cloud-aws/spring-cloud-aws.html#_sdk_credentials_configuration

... says the DefaultAWSCredentialsProvider will be used if nothing is configured. While this is accurate within a certain context, it does not appear to be the case when auto configuration is included.

https://cloud.spring.io/spring-cloud-aws/spring-cloud-aws.html#_configuring_credentials

... does not make it clear what the default chain is, or that it is not the DefaultAWSCredentialsProvider. It seems odd that the Default wouldn't be the default. :)

The chain that seems to get configured by default (EC2ContainerCredentialsProviderWrapper -> ProfileCredentialsProvider) does make some sense as a default for an EC2 or ECS deployment.

However, it causes applications to hang repeatedly and, worse, silently for 2s when running on a non-EC2 instance - e.g. in local development. For example, firing up a QueueMessagingTemplate with a default configuration it would take ~7s to send a message because the EC2ContainerCredentialsProvider tried 3 times to query the metadata on each send.

I see lots of people getting frustrated with startup time and credentialing and abandoning auto configuration completely. It seems like using DefaultAWSCredentialsProvider as a default would solve a lot of issues for people since the problems not using it can be silent and challenging to debug.

This is related to at least #52 #102 #191 #354

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label May 30, 2019
@mdkv4
Copy link

mdkv4 commented Jul 15, 2019

+1 Additionally I would add that the workaround in #52 no longer works.

#102 (comment)
Appears to be the only way to force the usage of DefaultAWSCredentialsProviderChain

Appears to be fixed in #170

@maciejwalkowiak maciejwalkowiak added component: core An issue related to core functionality - credentials, region resolution type: documentation A documentation update labels May 29, 2020
@maciejwalkowiak
Copy link
Contributor

Ability to use DefaultAWSCredentialsProviderChain as added in #170 but I agree documentation is not clear.

@maciejwalkowiak maciejwalkowiak removed the status: waiting-for-triage An issue we've not yet triaged label May 30, 2020
@maciejwalkowiak maciejwalkowiak added this to the 2.2.3 milestone May 30, 2020
tmnuwan12 pushed a commit to tmnuwan12/spring-cloud-aws that referenced this issue Jun 7, 2020
maciejwalkowiak added a commit to maciejwalkowiak/spring-cloud-aws that referenced this issue Oct 15, 2020
maciejwalkowiak added a commit to maciejwalkowiak/spring-cloud-aws that referenced this issue Oct 15, 2020
maciejwalkowiak added a commit to maciejwalkowiak/spring-cloud-aws that referenced this issue Oct 15, 2020
maciejwalkowiak added a commit to maciejwalkowiak/spring-cloud-aws that referenced this issue Oct 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
component: core An issue related to core functionality - credentials, region resolution type: documentation A documentation update
Development

No branches or pull requests

4 participants