Cassandra Sink

The Cassandra sink plugin is available in the Hub.

Plugin version: 2.3.4

The Cassandra sink takes the structured record from the input source and converts each field to a byte buffer, and then puts it in the keyspace and column family specified by the user.

Apache Cassandra v. 2.1.0 is the only supported version of Apache Cassandra.

Configuration

Property

Macro Enabled?

Description

Property

Macro Enabled?

Description

Reference Name

No

Required. Used to uniquely identify this sink for lineage, annotating metadata, etc.

Initial Address

Yes

Required. The initial address to connect to.

Port

Yes

Optional. The RPC port for Cassandra. Check the configuration to make sure that start_rpc is true in cassandra.yaml.

Keyspace

Yes

Required. The keyspace to select data from.

Partitioner

Yes

Required. The partitioner for the keyspace.

Column Family

Yes

Required. The column family or table to select data from.

Primary Key

Yes

Required. A comma-separated list of primary keys.

Columns

Yes

Required. A comma-separated list of columns in the column family. The columns should be listed in the same order as they are stored in the column family.

Example

This example connects to Apache Cassandra, which is running locally, and writes the data to the specified column family (employees), which is in the megacorp keyspace. This column family has four columns and two primary keys, and Apache Cassandra uses the default Murmur3 partitioner:

Property

Value

Property

Value

Reference Name

cassandrasink

Initial Address

localhost

Port

9160

Keyspace

megacorp

Partitioner

org.apache.cassandra.dht.Murmur3Partitioner

Column Family

employees

Primary Key

fname,lname

Columns

fname,lname,age,salary

 

Created in 2020 by Google Inc.