SdkPresigner.Builder has a set of methods common with AwsClientBuilder but no common hierarchy
- Dominant language
- Java
- Stars
- 2.6k
- Forks
- 1k
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 51
Description
## Describe the Feature
At the moment SdkPresigner.Builder has 3 builder methods which are
```
Builder region(Region region);
Builder credentialsProvider(AwsCredentialsProvider credentialsProvider);
Builder endpointOverride(URI endpointOverride);
```
The same 3 methods exist within SdkClientBuilder (endpointOverride is inherited from SdkClientBuilder), however these methods belong to different hierarchies.
## Is your Feature Request related to a problem?
For me as a developer there are different kinds of deployments
1. Start application locally pointing to localstack (static region, anonymous credentials, endpoint overridden to localhost:port
2. Start application locally pointing to stack in AWS cloud (static region, static credentials, no endpoint override)
3. Start application in AWS (automatic region, automatic credentials from default chain, no endpoint override)
So for having a Presigner and a Client I'd have to have twice as much code doing just the same (providing configuration to AWS SDK constructs)
## Proposed Solution
introduce 3 interfaces
```
public interface EndpointOverrideAware, T> {
B endpointOverride(URI endpointOverride);
}
public interface CredentialsProviderAware, T> {
B credentialsProvider(AwsCredentialsProvider credentialsProvider);
}
public interface RegionAware, T> {
B region(Region region);
}
```
and inherit both SdkPresigner.Builder and SdkClientBuilder from these interfaces.
- [v] I may be able to implement this feature request
Contributor guide
Assessment
This issue has not been assessed yet.