Skip to main content

metadata_partitions_for

Function metadata_partitions_for 

Source
pub fn metadata_partitions_for<'a, I>(
    tps: I,
    partition_count: i32,
) -> Result<Vec<i32>, MetadataLogError>
where I: IntoIterator<Item = &'a TopicIdPartition>,
Expand description

Deduped, sorted set of __remote_log_metadata partitions that carry metadata for the given user-topic-partitions, for the metadata topic’s partition_count.

This is the set a broker must consume to serve remote reads for the partitions it leads or follows.

§Errors

Returns MetadataLogError::NonPositivePartitionCount when partition_count <= 0, even for an empty tps.