public class BatchCassandraSink extends ReferenceBatchSink<co.cask.cdap.api.data.format.StructuredRecord,Map<String,ByteBuffer>,List<ByteBuffer>>
BatchSink that writes data to Cassandra.
This BatchCassandraSink takes a StructuredRecord in,
converts it to columns, and writes it to the Cassandra server.| Modifier and Type | Class and Description |
|---|---|
static class |
BatchCassandraSink.Cassandra
Properties for Cassandra
|
static class |
BatchCassandraSink.CassandraBatchConfig
Config class for Batch Cassandra
|
PLUGIN_TYPE| Constructor and Description |
|---|
BatchCassandraSink(BatchCassandraSink.CassandraBatchConfig config) |
| Modifier and Type | Method and Description |
|---|---|
void |
prepareRun(BatchSinkContext context) |
void |
transform(co.cask.cdap.api.data.format.StructuredRecord record,
Emitter<co.cask.cdap.api.dataset.lib.KeyValue<Map<String,ByteBuffer>,List<ByteBuffer>>> emitter) |
configurePipelinedestroy, initializeonRunFinishpublic BatchCassandraSink(BatchCassandraSink.CassandraBatchConfig config)
public void prepareRun(BatchSinkContext context)
prepareRun in class BatchConfigurable<BatchSinkContext>public void transform(co.cask.cdap.api.data.format.StructuredRecord record,
Emitter<co.cask.cdap.api.dataset.lib.KeyValue<Map<String,ByteBuffer>,List<ByteBuffer>>> emitter)
throws Exception
transform in interface Transformation<co.cask.cdap.api.data.format.StructuredRecord,co.cask.cdap.api.dataset.lib.KeyValue<Map<String,ByteBuffer>,List<ByteBuffer>>>transform in class BatchSink<co.cask.cdap.api.data.format.StructuredRecord,Map<String,ByteBuffer>,List<ByteBuffer>>ExceptionCopyright © 2017 Cask Data, Inc. Licensed under the Apache License, Version 2.0.