CDAP Table Dataset Sink (Deprecated)
Note: Datasets and the CDAP Table Dataset Sink are deprecated and will be removed in CDAP 7.0.0.
Writes records to a CDAP Table with one record field mapping to the Table rowkey, and all other record fields mapping to Table columns.
The sink is used whenever you need to write to a Table in batch. For example, you may want to periodically dump the contents of a relational database into a CDAP Table.
Configuration
Property | Macro Enabled? | Description |
---|---|---|
Name | Yes | Required. Name of the table dataset. If it does not already exist, one will be created. |
Row Field | Yes | Required. The name of the record field that should be used as the row key when writing to the table. |
Output Schema | Yes | Optional. Schema of the table as a JSON Object. If the table does not already exist, one will be created with this schema, which will allow the table to be explored through Hive. Output schema should have columns other than rowkey. |
Example
This example writes to a Table named users
:
Property | Value |
---|---|
Name |
|
Row Field |
|
It takes records with this schema as input:
field name | type |
---|---|
id | long |
name | string |
birthyear | int |
The id
field will be used as the rowkey when writing to the table. The name
and birthyear
record fields will be written to columns named ‘name’ and birthyear
.
Created in 2020 by Google Inc.