Package io.debezium.connector.cassandra
Class AbstractProcessor
java.lang.Object
io.debezium.connector.cassandra.AbstractProcessor
- Direct Known Subclasses:
CommitLogIdxProcessor,CommitLogPostProcessor,CommitLogProcessor,QueueProcessor,SnapshotProcessor
An abstract processor designed to be a convenient superclass for all concrete processors for Cassandra
connector task. The class handles concurrency control for starting and stopping the processor.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddestroy()Override destroy to clean up resources after stopping the processorgetName()voidOverride initialize to initialize resources before starting the processorbooleanabstract voidprocess()The actual work the processor is doing.voidstart()voidstop()
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
name
-
delayMs
private final long delayMs -
running
private boolean running
-
-
Constructor Details
-
AbstractProcessor
-
-
Method Details
-
process
The actual work the processor is doing. This method will be executed in a while loop until processor stops or encounters exception.- Throws:
InterruptedExceptionIOException
-
initialize
Override initialize to initialize resources before starting the processor- Throws:
Exception
-
destroy
Override destroy to clean up resources after stopping the processor- Throws:
Exception
-
isRunning
public boolean isRunning() -
start
- Throws:
Exception
-
stop
public void stop() -
getName
-