Package org.apache.flink.table.sinks
Class CsvTableSink
java.lang.Object
org.apache.flink.table.sinks.CsvTableSink
- All Implemented Interfaces:
AppendStreamTableSink<org.apache.flink.types.Row>,StreamTableSink<org.apache.flink.types.Row>,org.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row>
@Internal
@Deprecated
public class CsvTableSink
extends Object
implements AppendStreamTableSink<org.apache.flink.types.Row>
Deprecated.
A simple
TableSink to emit data as CSV files.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDeprecated.Formats a Row into a String with fields separated by the field delimiter. -
Constructor Summary
ConstructorsConstructorDescriptionCsvTableSink(String path) Deprecated.A simpleTableSinkto emit data as CSV files using comma as field delimiter, with default parallelism and write mode.CsvTableSink(String path, String fieldDelim) Deprecated.A simpleTableSinkto emit data as CSV files, with default parallelism and write mode.CsvTableSink(String path, String fieldDelim, int numFiles, org.apache.flink.core.fs.FileSystem.WriteMode writeMode) Deprecated.A simpleTableSinkto emit data as CSV files.CsvTableSink(String path, String fieldDelim, int numFiles, org.apache.flink.core.fs.FileSystem.WriteMode writeMode, String[] fieldNames, org.apache.flink.table.types.DataType[] fieldTypes) Deprecated.A simpleTableSinkto emit data as CSV files. -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row>configure(String[] fieldNames, org.apache.flink.api.common.typeinfo.TypeInformation<?>[] fieldTypes) Deprecated.org.apache.flink.streaming.api.datastream.DataStreamSink<?>consumeDataStream(org.apache.flink.streaming.api.datastream.DataStream<org.apache.flink.types.Row> dataStream) Deprecated.Consumes the DataStream and return the sink transformationDataStreamSink.org.apache.flink.table.types.DataTypeDeprecated.org.apache.flink.table.legacy.api.TableSchemaDeprecated.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.flink.table.legacy.sinks.TableSink
getFieldNames, getFieldTypes, getOutputType
-
Constructor Details
-
CsvTableSink
public CsvTableSink(String path, String fieldDelim, int numFiles, org.apache.flink.core.fs.FileSystem.WriteMode writeMode, String[] fieldNames, org.apache.flink.table.types.DataType[] fieldTypes) Deprecated.A simpleTableSinkto emit data as CSV files.- Parameters:
path- The output path to write the Table to.fieldDelim- The field delimiternumFiles- The number of files to write towriteMode- The write mode to specify whether existing files are overwritten or not.fieldNames- The field names of the table to emit.fieldTypes- The field types of the table to emit.
-
CsvTableSink
public CsvTableSink(String path, String fieldDelim, int numFiles, org.apache.flink.core.fs.FileSystem.WriteMode writeMode) Deprecated.A simpleTableSinkto emit data as CSV files.- Parameters:
path- The output path to write the Table to.fieldDelim- The field delimiternumFiles- The number of files to write towriteMode- The write mode to specify whether existing files are overwritten or not.
-
CsvTableSink
Deprecated.A simpleTableSinkto emit data as CSV files using comma as field delimiter, with default parallelism and write mode.- Parameters:
path- The output path to write the Table to.
-
CsvTableSink
Deprecated.A simpleTableSinkto emit data as CSV files, with default parallelism and write mode.- Parameters:
path- The output path to write the Table to.fieldDelim- The field delimiter
-
-
Method Details
-
consumeDataStream
public org.apache.flink.streaming.api.datastream.DataStreamSink<?> consumeDataStream(org.apache.flink.streaming.api.datastream.DataStream<org.apache.flink.types.Row> dataStream) Deprecated.Description copied from interface:StreamTableSinkConsumes the DataStream and return the sink transformationDataStreamSink. The returnedDataStreamSinkwill be used to set resources for the sink operator.- Specified by:
consumeDataStreamin interfaceStreamTableSink<org.apache.flink.types.Row>
-
configure
public org.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row> configure(String[] fieldNames, org.apache.flink.api.common.typeinfo.TypeInformation<?>[] fieldTypes) Deprecated.- Specified by:
configurein interfaceorg.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row>
-
getConsumedDataType
public org.apache.flink.table.types.DataType getConsumedDataType()Deprecated.- Specified by:
getConsumedDataTypein interfaceorg.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row>
-
getTableSchema
public org.apache.flink.table.legacy.api.TableSchema getTableSchema()Deprecated.- Specified by:
getTableSchemain interfaceorg.apache.flink.table.legacy.sinks.TableSink<org.apache.flink.types.Row>
-
FileSink. It is kept only to support tests for the legacy connector stack.