Class Athena2Configuration
java.lang.Object
org.apache.camel.component.aws2.athena.Athena2Configuration
- All Implemented Interfaces:
Cloneable
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()software.amazon.awssdk.services.athena.AthenaClientlonggetDelay()software.amazon.awssdk.services.athena.model.EncryptionOptionlongintsoftware.amazon.awssdk.core.ProtocolgetRetry()longbooleanbooleanbooleanbooleanvoidsetAccessKey(String accessKey) Amazon AWS Access Key.voidsetAmazonAthenaClient(software.amazon.awssdk.services.athena.AthenaClient amazonAthenaClient) The AmazonAthena instance to use as the client.voidsetClientRequestToken(String clientRequestToken) A unique string to ensure issues queries are idempotent.voidsetDatabase(String database) The Athena database to use.voidsetDelay(long delay) Milliseconds before the next poll for query execution status.voidsetEncryptionOption(software.amazon.awssdk.services.athena.model.EncryptionOption encryptionOption) The encryption type to use when storing query results in S3.voidsetIncludeTrace(boolean includeTrace) Include useful trace information at the beginning of queries as an SQL comment (prefixed with "--").voidsetInitialDelay(long initialDelay) Milliseconds before the first poll for query execution status.voidFor SSE-KMS and CSE-KMS, this is the KMS key ARN or ID.voidsetMaxAttempts(int maxAttempts) Maximum number of times to attempt a query.voidsetMaxResults(Integer maxResults) Max number of results to return for the given operation (if supported by the Athena API endpoint).voidsetNextToken(String nextToken) Pagination token to use in the case where the response from the previous request was truncated.voidsetOperation(Athena2Operations operation) The Athena API function to call.voidsetOutputLocation(String outputLocation) The location in Amazon S3 where query results are stored, such ass3://path/to/query/bucket/.voidsetOutputType(Athena2OutputType outputType) How query results should be returned.voidsetProfileCredentialsName(String profileCredentialsName) If using a profile credentials provider, this parameter will set the profile namevoidsetProxyHost(String proxyHost) To define a proxy host when instantiating the Athena client.voidsetProxyPort(Integer proxyPort) To define a proxy port when instantiating the Athena client.voidsetProxyProtocol(software.amazon.awssdk.core.Protocol proxyProtocol) To define a proxy protocol when instantiating the Athena client.voidsetQueryExecutionId(String queryExecutionId) The unique ID identifying the query execution.voidsetQueryString(String queryString) The SQL query to run.voidThe region in which the Athena client needs to work.voidsetResetWaitTimeoutOnRetry(boolean resetWaitTimeoutOnRetry) Reset the waitTimeout countdown in the event of a query retry.voidOptional comma separated list of error types to retry the query for.voidsetSecretKey(String secretKey) Amazon AWS Secret Key.voidsetSessionToken(String sessionToken) Amazon AWS Session Token used when the user needs to assume an IAM rolevoidsetUseDefaultCredentialsProvider(Boolean useDefaultCredentialsProvider) Set whether the Athena client should expect to load credentials through a default credentials provider or to expect static credentials to be passed in.voidsetUseProfileCredentialsProvider(boolean useProfileCredentialsProvider) Set whether the Athena client should expect to load credentials through a profile credentials provider.voidsetUseSessionCredentials(boolean useSessionCredentials) Set whether the Athena client should expect to use Session Credentials.voidsetWaitTimeout(long waitTimeout) Optional max wait time in millis to wait for a successful query completion.voidsetWorkGroup(String workGroup) The workgroup to use for running the query.
-
Constructor Details
-
Athena2Configuration
public Athena2Configuration()
-
-
Method Details
-
getAccessKey
-
setAccessKey
Amazon AWS Access Key. -
getSecretKey
-
setSecretKey
Amazon AWS Secret Key. -
getSessionToken
-
setSessionToken
Amazon AWS Session Token used when the user needs to assume an IAM role -
getAmazonAthenaClient
public software.amazon.awssdk.services.athena.AthenaClient getAmazonAthenaClient() -
setAmazonAthenaClient
public void setAmazonAthenaClient(software.amazon.awssdk.services.athena.AthenaClient amazonAthenaClient) The AmazonAthena instance to use as the client. -
getProxyProtocol
public software.amazon.awssdk.core.Protocol getProxyProtocol() -
setProxyProtocol
public void setProxyProtocol(software.amazon.awssdk.core.Protocol proxyProtocol) To define a proxy protocol when instantiating the Athena client. -
getProxyHost
-
setProxyHost
To define a proxy host when instantiating the Athena client. -
getProxyPort
-
setProxyPort
To define a proxy port when instantiating the Athena client. -
getRegion
-
setRegion
The region in which the Athena client needs to work. When using this parameter, the configuration will expect the lowercase name of the region (for example, ap-east-1). You'll need to use the name Region.EU_WEST_1.id(). -
getOutputLocation
-
setOutputLocation
The location in Amazon S3 where query results are stored, such ass3://path/to/query/bucket/. Ensure this value ends with a forward slash ('/'). -
getOutputType
-
setOutputType
How query results should be returned. One ofStreamList(default - return aGetQueryResultsIterablethat can page through all results),SelectList(returns at most 1,000 rows at a time, plus a NextToken value as a header than can be used for manual pagination of results),S3Pointer(return an S3 path pointing to the results). -
getOperation
-
setOperation
The Athena API function to call. -
getDatabase
-
setDatabase
The Athena database to use. -
getQueryExecutionId
-
setQueryExecutionId
The unique ID identifying the query execution. -
getWorkGroup
-
setWorkGroup
The workgroup to use for running the query. -
getMaxResults
-
setMaxResults
Max number of results to return for the given operation (if supported by the Athena API endpoint). If not set, it will use the Athena API default for the given operation. -
getNextToken
-
setNextToken
Pagination token to use in the case where the response from the previous request was truncated. -
getClientRequestToken
-
setClientRequestToken
A unique string to ensure issues queries are idempotent. It is unlikely you will need to set this. -
getEncryptionOption
public software.amazon.awssdk.services.athena.model.EncryptionOption getEncryptionOption() -
setEncryptionOption
public void setEncryptionOption(software.amazon.awssdk.services.athena.model.EncryptionOption encryptionOption) The encryption type to use when storing query results in S3. One ofSSE_S3,SSE_KMS, orCSE_KMS. -
getKmsKey
-
setKmsKey
For SSE-KMS and CSE-KMS, this is the KMS key ARN or ID. -
getQueryString
-
setQueryString
The SQL query to run. Except for simple queries, prefer setting this as thebodyof the Exchange or as a header usingAthena2Constants.QUERY_STRINGto avoid having to deal with URL encoding issues. -
getInitialDelay
public long getInitialDelay() -
setInitialDelay
public void setInitialDelay(long initialDelay) Milliseconds before the first poll for query execution status. See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
getDelay
public long getDelay() -
setDelay
public void setDelay(long delay) Milliseconds before the next poll for query execution status. See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
getWaitTimeout
public long getWaitTimeout() -
setWaitTimeout
public void setWaitTimeout(long waitTimeout) Optional max wait time in millis to wait for a successful query completion. See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
getRetry
-
setRetry
Optional comma separated list of error types to retry the query for. Use "retryable" to retry all retryable failure conditions (e.g. generic errors and resources exhausted), "generic" to retry "GENERIC_INTERNAL_ERROR" failures, "exhausted" to retry queries that have exhausted resource limits, "always" to always retry regardless of failure condition, or "never" or null to never retry (default). See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
getMaxAttempts
public int getMaxAttempts() -
setMaxAttempts
public void setMaxAttempts(int maxAttempts) Maximum number of times to attempt a query. Set to 1 to disable retries. See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
isResetWaitTimeoutOnRetry
public boolean isResetWaitTimeoutOnRetry() -
setResetWaitTimeoutOnRetry
public void setResetWaitTimeoutOnRetry(boolean resetWaitTimeoutOnRetry) Reset the waitTimeout countdown in the event of a query retry. If set to true, potential max time spent waiting for queries is equal to waitTimeout x maxAttempts. See the section 'Waiting for Query Completion and Retrying Failed Queries' to learn more. -
isIncludeTrace
public boolean isIncludeTrace() -
setIncludeTrace
public void setIncludeTrace(boolean includeTrace) Include useful trace information at the beginning of queries as an SQL comment (prefixed with "--"). -
setUseDefaultCredentialsProvider
Set whether the Athena client should expect to load credentials through a default credentials provider or to expect static credentials to be passed in. -
isUseDefaultCredentialsProvider
-
isUseProfileCredentialsProvider
public boolean isUseProfileCredentialsProvider() -
setUseProfileCredentialsProvider
public void setUseProfileCredentialsProvider(boolean useProfileCredentialsProvider) Set whether the Athena client should expect to load credentials through a profile credentials provider. -
isUseSessionCredentials
public boolean isUseSessionCredentials() -
setUseSessionCredentials
public void setUseSessionCredentials(boolean useSessionCredentials) Set whether the Athena client should expect to use Session Credentials. This is useful in a situation in which the user needs to assume an IAM role for doing operations in Athena. -
getProfileCredentialsName
-
setProfileCredentialsName
If using a profile credentials provider, this parameter will set the profile name -
copy
-