TopicPartition faststream.confluent.schemas.TopicPartition # TopicPartition(topic, partition=-1, offset=-1001, metadata=None, leader_epoch=None) Source code in faststream/confluent/schemas/partition.py 25 26 27 28 29 30 31 32 33 34 35 36 37def __init__( self, topic: str, partition: int = -1, offset: int = -1001, metadata: Optional[str] = None, leader_epoch: Optional[int] = None, ) -> None: self.topic = topic self.partition = partition self.offset = offset self.metadata = metadata self.leader_epoch = leader_epoch topic instance-attribute # topic = topic partition instance-attribute # partition = partition offset instance-attribute # offset = offset metadata instance-attribute # metadata = metadata leader_epoch instance-attribute # leader_epoch = leader_epoch to_confluent # to_confluent() Source code in faststream/confluent/schemas/partition.py 39 40 41 42 43 44 45 46 47 48 49def to_confluent(self) -> ConfluentPartition: kwargs: _TopicKwargs = { "topic": self.topic, "partition": self.partition, "offset": self.offset, } if self.metadata is not None: kwargs["metadata"] = self.metadata if self.leader_epoch is not None: kwargs["leader_epoch"] = self.leader_epoch return ConfluentPartition(**kwargs)