public class GlobalStreamThread
extends java.lang.Thread
Modifier and Type | Class and Description |
---|---|
static class |
GlobalStreamThread.State
The states that the global stream thread can be in
|
Constructor and Description |
---|
GlobalStreamThread(ProcessorTopology topology,
StreamsConfig config,
org.apache.kafka.clients.consumer.Consumer<byte[],byte[]> globalConsumer,
StateDirectory stateDirectory,
long cacheSizeBytes,
org.apache.kafka.common.metrics.Metrics metrics,
org.apache.kafka.common.utils.Time time,
java.lang.String threadClientId,
StateRestoreListener stateRestoreListener) |
Modifier and Type | Method and Description |
---|---|
java.util.Map<org.apache.kafka.common.MetricName,org.apache.kafka.common.Metric> |
consumerMetrics() |
void |
run() |
void |
setStateListener(StreamThread.StateListener listener)
Set the
StreamThread.StateListener to be notified when state changes. |
void |
shutdown() |
void |
start() |
GlobalStreamThread.State |
state() |
boolean |
stillRunning() |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yield
public GlobalStreamThread(ProcessorTopology topology, StreamsConfig config, org.apache.kafka.clients.consumer.Consumer<byte[],byte[]> globalConsumer, StateDirectory stateDirectory, long cacheSizeBytes, org.apache.kafka.common.metrics.Metrics metrics, org.apache.kafka.common.utils.Time time, java.lang.String threadClientId, StateRestoreListener stateRestoreListener)
public void setStateListener(StreamThread.StateListener listener)
StreamThread.StateListener
to be notified when state changes. Note this API is internal to
Kafka Streams and is not intended to be used by an external application.public GlobalStreamThread.State state()
public boolean stillRunning()
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
public void start()
start
in class java.lang.Thread
public void shutdown()
public java.util.Map<org.apache.kafka.common.MetricName,org.apache.kafka.common.Metric> consumerMetrics()