Class InfluxDBRecordHandler
- java.lang.Object
-
- com.amazonaws.athena.connector.lambda.handlers.RecordHandler
-
- com.amazonaws.athena.connectors.influxdb.InfluxDBRecordHandler
-
- All Implemented Interfaces:
FederationRequestHandler,com.amazonaws.services.lambda.runtime.RequestStreamHandler
public class InfluxDBRecordHandler extends RecordHandler
-
-
Field Summary
-
Fields inherited from class com.amazonaws.athena.connector.lambda.handlers.RecordHandler
configOptions
-
-
Constructor Summary
Constructors Modifier Constructor Description InfluxDBRecordHandler(Map<String,String> configOptions)Creates a handler with its own connection factory.InfluxDBRecordHandler(Map<String,String> configOptions, InfluxDBConnectionFactory connectionFactory)Creates a handler that uses the given connection factory, which may be shared with anInfluxDBMetadataHandlerin the same Lambda container.protectedInfluxDBRecordHandler(software.amazon.awssdk.services.s3.S3Client s3Client, software.amazon.awssdk.services.secretsmanager.SecretsManagerClient secretsManager, software.amazon.awssdk.services.athena.AthenaClient athena, InfluxDBConnectionFactory connectionFactory, Map<String,String> configOptions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidreadWithConstraint(BlockSpiller spiller, ReadRecordsRequest recordsRequest, QueryStatusChecker queryStatusChecker)A more stream lined option for reading the row data associated with the provided Split.-
Methods inherited from class com.amazonaws.athena.connector.lambda.handlers.RecordHandler
doHandleRequest, doReadRecords, getCachableSecretsManager, getKmsEncryptionProvider, getSpillConfig, handleRequest, onPing
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.amazonaws.athena.connector.lambda.handlers.FederationRequestHandler
createCredentialsProvider, getAthenaClient, getCredentialProvider, getCredentialProvider, getDatabaseConnectionSecret, getRequestOverrideConfig, getRequestOverrideConfig, getRequestOverrideConfig, getS3Client, getSecret, getSecret, getSessionCredentials, isRequestFederated, resolveSecrets, resolveWithDefaultCredentials
-
-
-
-
Constructor Detail
-
InfluxDBRecordHandler
public InfluxDBRecordHandler(Map<String,String> configOptions)
Creates a handler with its own connection factory. Used when the record handler is deployed as its own Lambda handler.
-
InfluxDBRecordHandler
public InfluxDBRecordHandler(Map<String,String> configOptions, InfluxDBConnectionFactory connectionFactory)
Creates a handler that uses the given connection factory, which may be shared with anInfluxDBMetadataHandlerin the same Lambda container. This handler becomes the factory's secret resolver.
-
InfluxDBRecordHandler
protected InfluxDBRecordHandler(software.amazon.awssdk.services.s3.S3Client s3Client, software.amazon.awssdk.services.secretsmanager.SecretsManagerClient secretsManager, software.amazon.awssdk.services.athena.AthenaClient athena, InfluxDBConnectionFactory connectionFactory, Map<String,String> configOptions)
-
-
Method Detail
-
readWithConstraint
protected void readWithConstraint(BlockSpiller spiller, ReadRecordsRequest recordsRequest, QueryStatusChecker queryStatusChecker) throws Exception
Description copied from class:RecordHandlerA more stream lined option for reading the row data associated with the provided Split. This method differs from doReadRecords(...) in that the SDK handles more of the request lifecycle, leaving you to focus more closely on the task of actually reading from your source.- Specified by:
readWithConstraintin classRecordHandler- Parameters:
spiller- A BlockSpiller that should be used to write the row data associated with this Split. The BlockSpiller automatically handles chunking the response, encrypting, and spilling to S3.recordsRequest- Details of the read request, including: 1. The Split 2. The Catalog, Database, and Table the read request is for. 3. The filtering predicate (if any) 4. The columns required for projection.queryStatusChecker- A QueryStatusChecker that you can use to stop doing work for a query that has already terminated- Throws:
Exception
-
-