log4j.logger.org.apache.kafka.streams.processor.internals.StandbyTask=ALL
StandbyTask
StandbyTask
is a concrete processor task that…FIXME
StandbyTask
is created when…FIXME
StandbyTask
is a concrete AbstractTask with isStandby flag on.
Tip
|
Enable Add the following line to Refer to Application Logging Using log4j. |
closeSuspended
Method
void closeSuspended(
final boolean clean,
final boolean isZombie,
final RuntimeException e)
Note
|
closeSuspended is part of Task Contract to…FIXME.
|
closeSuspended
…FIXME
Initializing State Stores — initializeStateStores
Method
boolean initializeStateStores()
Note
|
initializeStateStores is part of Task Contract to initialize state stores.
|
initializeStateStores
…FIXME
Closing Task — close
Method
void close(
final boolean clean,
final boolean isZombie)
Note
|
close is part of Task Contract to close the task.
|
close
prints out the following DEBUG message to the logs:
Closing
With the input clean
flag on, close
commit followed by closeStateManager (with writeCheckpoint
flag on when clean
was on and commit was successful).
close
marks the StandbyTask
as closed (i.e. sets taskClosed to true
).
close
returns immediately if the StandbyTask
has not been initialized yet, i.e. when StandbyTask
has not been requested to initializeStateStores yet.
Note
|
The input isZombie flag is ignored (and therefore never used) as StandbyTask can never be a zombie.
|
initializeTopology
Method
void initializeTopology()
Note
|
initializeTopology is part of Task Contract to…FIXME.
|
initializeTopology
does nothing (and is simply a noop).
Resuming Task — resume
Method
void resume()
Note
|
resume is part of the Task Contract to…FIXME.
|
resume
…FIXME
Creating StandbyTask Instance
StandbyTask
takes the following to be created:
-
Assigned Kafka TopicPartitions
-
Kafka Consumer (
Consumer<byte[], byte[]>
)
StandbyTask
initializes the internal properties.
flushAndCheckpointState
Internal Method
void flushAndCheckpointState()
flushAndCheckpointState
…FIXME
Updating Standby Replicas Of State Store (From Single Change Log Partition) — update
Method
List<ConsumerRecord<byte[], byte[]>> update(
final TopicPartition partition,
final List<ConsumerRecord<byte[], byte[]>> records)
update
prints out the following TRACE message to the logs:
Updating standby replicas of its state store for partition [partition]
update
then simply requests the ProcessorStateManager to updateStandbyStates and returns the result.
Note
|
update is used exclusively when StreamThread is requested to maybeUpdateStandbyTasks.
|