Package org.apache.kafka.common
Class PartitionInfo
java.lang.Object
org.apache.kafka.common.PartitionInfo
public class PartitionInfo extends Object
This is used to describe per-partition state in the MetadataResponse.
-
Constructor Summary
-
Method Summary
Modifier and Type Method Description Node[]
inSyncReplicas()
The subset of the replicas that are in sync, that is caught-up to the leader and ready to take over as leader if the leader should failNode
leader()
The node id of the node currently acting as a leader for this partition or null if there is no leaderNode[]
offlineReplicas()
The subset of the replicas that are offlineint
partition()
The partition idNode[]
replicas()
The complete set of replicas for this partition regardless of whether they are alive or up-to-dateString
topic()
The topic nameString
toString()
-
Constructor Details
-
PartitionInfo
-
PartitionInfo
-
-
Method Details
-
topic
The topic name -
partition
public int partition()The partition id -
leader
The node id of the node currently acting as a leader for this partition or null if there is no leader -
replicas
The complete set of replicas for this partition regardless of whether they are alive or up-to-date -
inSyncReplicas
The subset of the replicas that are in sync, that is caught-up to the leader and ready to take over as leader if the leader should fail -
offlineReplicas
The subset of the replicas that are offline -
toString
-