ReplicaFetcherManager is a manager of ReplicaFetcherThreads for ReplicaManager.

Figure 1. ReplicaFetcherManager

ReplicaFetcherManager uses num.replica.fetchers configuration property for the number of replica fetcher threads.


Enable ALL logging level for kafka.server.ReplicaFetcherManager logger to see what happens inside.

Add the following line to config/


Refer to Logging.

Performance Metrics

As an AbstractFetcherManager, ReplicaFetcherManager is a KafkaMetricsGroup.

The performance metrics are registered in kafka.server:type=ReplicaFetcherManager group.

ReplicaFetcherManager jconsole.png
Figure 2. ReplicaFetcherManager in jconsole

Creating ReplicaFetcherManager Instance

ReplicaFetcherManager takes the following to be created:

Creating ReplicaFetcherThread — createFetcherThread Method

  fetcherId: Int,
  sourceBroker: BrokerEndPoint): ReplicaFetcherThread
createFetcherThread is part of the AbstractFetcherManager contract to…​FIXME.

createFetcherThread creates a ReplicaFetcherThread with the thread name (that uses the threadNamePrefix if defined, the given fetcherId and the id of the BrokerEndPoint) as follows:


shutdown Method

shutdown(): Unit

shutdown prints out the following INFO message to the logs:

shutting down

shutdown closeAllFetchers.

In the end, shutdown prints out the following INFO message to the logs:

shutdown completed
shutdown is used when…​FIXME

results matching ""

    No results matching ""