Interface EcsCredentialsProvider.Builder
- Enclosing class:
- EcsCredentialsProvider
public static interface EcsCredentialsProvider.Builder
A builder for creating a custom ECS credentials provider.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Create an ECS credentials provider using the configuration applied to this builder.withAuthToken
(String authToken) withClientBootstrap
(ClientBootstrap clientBootstrap) Sets the client bootstrap (host resolver and event loop group) to use when making the connections required by this provider.withPathAndQuery
(String pathAndQuery) withTlsContext
(TlsContext tlsContext) Sets the tls context to use for any secure network connections made while sourcing credentials.
-
Method Details
-
withClientBootstrap
Sets the client bootstrap (host resolver and event loop group) to use when making the connections required by this provider. The default is a bootstrap which uses the static default event loop group and host resolver.- Parameters:
clientBootstrap
- client bootstrap to use- Returns:
- The current builder
-
withTlsContext
Sets the tls context to use for any secure network connections made while sourcing credentials.- Parameters:
tlsContext
- the tls context to use when establishing network connections- Returns:
- The current builder
-
withHost
- Parameters:
host
- Host used to connect to the credential service.- Returns:
- The current builder
-
withPathAndQuery
- Parameters:
pathAndQuery
- The URL path and query used to connect to the credential service.- Returns:
- The current builder
-
withAuthToken
- Parameters:
authToken
- Token used to retrieve credentials.- Returns:
- The current builder
-
build
EcsCredentialsProvider build()Create an ECS credentials provider using the configuration applied to this builder.- Returns:
- A new ECS credentials provider.
-