SdkPresigner.Builder has a set of methods common with AwsClientBuilder but no common hierarchy
Nessuno ha ancora preso questa issue.
- Lingua principale
- Java
- Stelle
- 2.6k
- Fork
- 1k
- Merge medio
- 2g 9h
- PR unite (30g)
- 51
Descrizione
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
- Start application locally pointing to localstack (static region, anonymous credentials, endpoint overridden to localhost:port
- Start application locally pointing to stack in AWS cloud (static region, static credentials, no endpoint override)
- 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<B extends EndpointOverrideAware<T>, T> {
B endpointOverride(URI endpointOverride);
}
public interface CredentialsProviderAware<B extends CredentialsProviderAware <T>, T> {
B credentialsProvider(AwsCredentialsProvider credentialsProvider);
}
public interface RegionAware<B extends RegionAware <T>, 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
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia con SdkPresigner.Builder e SdkClientBuilder, confrontando i relativi metodi region, credentialsProvider ed endpointOverride. Il lavoro è completo quando entrambe le gerarchie di builder condividono le interfacce proposte RegionAware, CredentialsProviderAware ed EndpointOverrideAware senza duplicare i metodi di configurazione.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- java
- Ambito
- backend-api-design
- Tipo di issue
- Funzionalità
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 35/100