public class SchemaSourceTask extends SourceTask
SourceTask.TransactionBoundary
Modifier and Type | Field and Description |
---|---|
static String |
ID_CONFIG |
static String |
MULTIPLE_SCHEMA_CONFIG |
static String |
NAME_CONFIG |
static String |
NUM_MSGS_CONFIG |
static String |
PARTITION_COUNT_CONFIG |
static String |
THROUGHPUT_CONFIG |
static String |
TOPIC_CONFIG |
context, TRANSACTION_BOUNDARY_CONFIG
Constructor and Description |
---|
SchemaSourceTask() |
Modifier and Type | Method and Description |
---|---|
List<SourceRecord> |
poll()
Poll this source task for new records.
|
void |
start(Map<String,String> props)
Start the Task.
|
void |
stop()
Signal this SourceTask to stop.
|
String |
version()
Get the version of this task.
|
commit, commitRecord, commitRecord, initialize
public static final String NAME_CONFIG
public static final String ID_CONFIG
public static final String TOPIC_CONFIG
public static final String NUM_MSGS_CONFIG
public static final String THROUGHPUT_CONFIG
public static final String MULTIPLE_SCHEMA_CONFIG
public static final String PARTITION_COUNT_CONFIG
public String version()
Task
Connector
class's version.public void start(Map<String,String> props)
SourceTask
start
in interface Task
start
in class SourceTask
props
- initial configurationpublic List<SourceRecord> poll()
SourceTask
null
) in
order for the task to transition to the PAUSED
state if requested to do so.
The task will be stopped
on a separate thread, and when that happens
this method is expected to unblock, quickly finish up any remaining processing, and
return.
poll
in class SourceTask
public void stop()
SourceTask
SourceTask.poll()
and
SourceTask.commit()
.
For example, if a task uses a Selector
to receive data over the network, this method
could set a flag that will force SourceTask.poll()
to exit immediately and invoke
wakeup()
to interrupt any ongoing requests.
stop
in interface Task
stop
in class SourceTask