public PartitionRegistration getPartition(Uuid id, int partitionId) {
        TopicImage topicImage = topicsById.get(id);
        if (topicImage == null) return null;
        return topicImage.partitions().get(partitionId);
    }
Represents the topics in the metadata image.

This class is thread-safe.
metadata/src/main/java/org/apache/kafka/image/TopicsImage.java