public abstract class AmazonDaxClientBuilderAbstract<Builder extends AmazonDaxClientBuilderAbstract<Builder>> extends Object
Modifier and Type | Field and Description |
---|---|
protected static AwsRegionProvider |
DEFAULT_REGION_PROVIDER |
protected static org.apache.commons.logging.Log |
LOG |
protected ClientConfig |
mClientConfig |
protected AWSCredentialsProvider |
mCredentials |
protected String[] |
mHosts |
protected Region |
mRegion |
protected AwsRegionProvider |
mRegionProvider |
protected boolean |
mSkipHostnameVerification |
Modifier | Constructor and Description |
---|---|
protected |
AmazonDaxClientBuilderAbstract() |
protected |
AmazonDaxClientBuilderAbstract(AwsRegionProvider regionProvider) |
Modifier and Type | Method and Description |
---|---|
abstract AmazonDynamoDB |
build() |
ClientConfig |
getClientConfiguration()
Returns the ClientConfiguration currently configured in the builder
|
AWSCredentialsProvider |
getCredentials()
Returns the AWSCredentialsProvider currently configured in the builder.
|
String[] |
getEndpoint()
Returns the service endpointConfiguration in use by the builder
|
String |
getRegion()
Returns the region in use by the builder.
|
protected void |
resolveCredentials(ClientConfig config) |
protected void |
resolveEndpoint(ClientConfig config) |
protected void |
resolveRegion(ClientConfig config) |
void |
setClientConfiguration(ClientConfig config)
Sets the ClientConfiguration to be used by the client.
|
void |
setCredentials(AWSCredentialsProvider credentialsProvider)
Sets the AWSCredentialsProvider used by the client.
|
void |
setEndpointConfiguration(String... hosts)
Sets the endpoint configuration to be used for requests.
|
void |
setRegion(String region)
Sets the region to be used by the client.
|
Builder |
withClientConfiguration(ClientConfig config)
Sets the ClientConfiguration to be used by the client
|
Builder |
withCredentials(AWSCredentialsProvider credentialsProvider)
Sets the AWSCredentialsProvider used by the client.
|
Builder |
withEndpointConfiguration(String... hosts)
Sets the endpoint configuration to be used for requests.
|
Builder |
withRegion(Regions region)
Sets the region to be used by the client.
|
Builder |
withRegion(String regionName)
Sets the region to be used by the client.
|
Builder |
withSkipHostnameVerification(boolean skipHostnameVerification)
Sets if hostname verification is skipped or not for TLS.
|
protected static final org.apache.commons.logging.Log LOG
protected static final AwsRegionProvider DEFAULT_REGION_PROVIDER
protected final AwsRegionProvider mRegionProvider
protected Region mRegion
protected AWSCredentialsProvider mCredentials
protected ClientConfig mClientConfig
protected String[] mHosts
protected boolean mSkipHostnameVerification
protected AmazonDaxClientBuilderAbstract()
protected AmazonDaxClientBuilderAbstract(AwsRegionProvider regionProvider)
public abstract AmazonDynamoDB build()
protected void resolveEndpoint(ClientConfig config)
protected void resolveCredentials(ClientConfig config)
protected void resolveRegion(ClientConfig config)
public final AWSCredentialsProvider getCredentials()
public final void setCredentials(AWSCredentialsProvider credentialsProvider)
DefaultAWSCredentialsProviderChain
.credentialsProvider
- New AWSCredentialsProvider to use.public final Builder withCredentials(AWSCredentialsProvider credentialsProvider)
DefaultAWSCredentialsProviderChain
.credentialsProvider
- New AWSCredentialsProvider to use.public final String getRegion()
public final void setRegion(String region)
region
- Region to usepublic final Builder withRegion(Regions region)
For regions not explicitly in the Regions
enum use withRegion(String)
.
region
- Region to usepublic final Builder withRegion(String regionName)
regionName
- Region to usepublic final ClientConfig getClientConfiguration()
public final void setClientConfiguration(ClientConfig config)
If not specified the default is typically PredefinedClientConfigurations.defaultConfig()
but may differ per
service. Note that part of the configuration can be overridden by the configs of this builder (endpoint, region,
credentials) when build() is called.
config
- Custom configuration to usepublic final Builder withClientConfiguration(ClientConfig config)
If not specified the default is typically PredefinedClientConfigurations.defaultConfig()
but may differ per
service. Note that part of the configuration can be overridden by the configs of this builder (endpoint, region,
credentials) when build() is called.
config
- Custom configuration to usepublic final String[] getEndpoint()
public final void setEndpointConfiguration(String... hosts)
hosts
- The endpointConfiguration to use, in the form [scheme://]hostname:portpublic final Builder withEndpointConfiguration(String... hosts)
hosts
- The endpointConfiguration to use, in the form [scheme://]hostname:portpublic final Builder withSkipHostnameVerification(boolean skipHostnameVerification)
skipHostnameVerification
- skip hostname verification of TLS connections. This parameter has no impact on unecrypted clusters.
The default is to perform hostname verification, setting this to true will skip verification.
Be sure you understand the implication of doing so, which is the inability to authenticate the cluster that you are connecting to.