OUT
- type of outputClasspublic class CassandraPojoOutputFormat<OUT> extends OutputFormatBase<OUT,V>
Modifier and Type | Field and Description |
---|---|
protected com.datastax.driver.core.Session |
session |
Constructor and Description |
---|
CassandraPojoOutputFormat(ClusterBuilder builder,
Class<OUT> outputClass) |
CassandraPojoOutputFormat(ClusterBuilder builder,
Class<OUT> outputClass,
MapperOptions mapperOptions) |
CassandraPojoOutputFormat(ClusterBuilder builder,
Class<OUT> outputClass,
MapperOptions mapperOptions,
int maxConcurrentRequests,
java.time.Duration maxConcurrentRequestsTimeout) |
Modifier and Type | Method and Description |
---|---|
void |
configure(Configuration parameters)
Configure the connection to Cassandra.
|
protected static <T> CompletableFuture<T> |
listenableFutureToCompletableFuture(com.google.common.util.concurrent.ListenableFuture<T> listenableFuture) |
protected void |
postClose()
Closes all resources used.
|
protected void |
postOpen()
Opens a Session to Cassandra and initializes the prepared statement.
|
protected CompletionStage<Void> |
send(OUT record)
Send the actual record for writing.
|
close, open, writeRecord
getRuntimeContext, setRuntimeContext
public CassandraPojoOutputFormat(ClusterBuilder builder, Class<OUT> outputClass)
public CassandraPojoOutputFormat(ClusterBuilder builder, Class<OUT> outputClass, MapperOptions mapperOptions)
public CassandraPojoOutputFormat(ClusterBuilder builder, Class<OUT> outputClass, MapperOptions mapperOptions, int maxConcurrentRequests, java.time.Duration maxConcurrentRequestsTimeout)
protected void postOpen()
protected CompletionStage<Void> send(OUT record)
OutputFormatBase
send
in class OutputFormatBase<OUT,Void>
protected void postClose()
public void configure(Configuration parameters)
parameters
- The configuration with all parameters.protected static <T> CompletableFuture<T> listenableFutureToCompletableFuture(com.google.common.util.concurrent.ListenableFuture<T> listenableFuture)
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.