getPartitions

Description

public function getPartitions(): Collection {}

Topic partitions reported by broker

Example

$conf = new SimpleKafkaClient\Configuration();
$conf->set('auto.offset.reset', 'earliest');
$producer = new SimpleKafkaClient\Producer($conf);
$metadata = $producer->getMetadata(false, 10000);
$topicPartitionsMetadata = $metadata->getTopics()->current()->getPartitions();