public static class JdbcOutputFormat.Builder extends Object
JdbcOutputFormat
.Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
JdbcOutputFormat<Tuple2<Boolean,Row>,Row,JdbcBatchStatementExecutor<Row>> |
build()
Finalizes the configuration and checks validity.
|
JdbcOutputFormat.Builder |
setFieldNames(String[] fieldNames)
required, field names of this jdbc sink.
|
JdbcOutputFormat.Builder |
setFieldTypes(int[] fieldTypes)
required, field types of this jdbc sink.
|
JdbcOutputFormat.Builder |
setFlushIntervalMills(long flushIntervalMills)
optional, flush interval mills, over this time, asynchronous threads will flush data.
|
JdbcOutputFormat.Builder |
setFlushMaxSize(int flushMaxSize)
optional, flush max size (includes all append, upsert and delete records), over this
number of records, will flush data.
|
JdbcOutputFormat.Builder |
setKeyFields(String[] keyFields)
required, upsert unique keys.
|
JdbcOutputFormat.Builder |
setMaxRetryTimes(int maxRetryTimes)
optional, max retry times for jdbc connector.
|
JdbcOutputFormat.Builder |
setOptions(JdbcConnectorOptions options)
required, jdbc options.
|
public JdbcOutputFormat.Builder setOptions(JdbcConnectorOptions options)
public JdbcOutputFormat.Builder setFieldNames(String[] fieldNames)
public JdbcOutputFormat.Builder setKeyFields(String[] keyFields)
public JdbcOutputFormat.Builder setFieldTypes(int[] fieldTypes)
public JdbcOutputFormat.Builder setFlushMaxSize(int flushMaxSize)
public JdbcOutputFormat.Builder setFlushIntervalMills(long flushIntervalMills)
public JdbcOutputFormat.Builder setMaxRetryTimes(int maxRetryTimes)
public JdbcOutputFormat<Tuple2<Boolean,Row>,Row,JdbcBatchStatementExecutor<Row>> build()
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.