Bases: ProducerProto[KafkaPublishCommand]
A class to represent Kafka producer.
connect
connect(producer, serializer)
Source code in faststream/confluent/publisher/producer.py
| def connect(
self,
producer: "AsyncConfluentProducer",
serializer: Optional["SerializerProto"],
) -> None: ...
|
disconnect
async
Source code in faststream/confluent/publisher/producer.py
| async def disconnect(self) -> None:
return None
|
flush
async
Source code in faststream/confluent/publisher/producer.py
| async def flush(self) -> None:
return None
|
ping
abstractmethod
async
Source code in faststream/confluent/publisher/producer.py
| @abstractmethod
async def ping(self, timeout: float) -> bool:
return False
|
publish
abstractmethod
async
Source code in faststream/confluent/publisher/producer.py
| @override
@abstractmethod
async def publish(
self,
cmd: "KafkaPublishCommand",
) -> "asyncio.Future[Message | None] | Message | None": ...
|
publish_batch
abstractmethod
async
Source code in faststream/confluent/publisher/producer.py
| @override
@abstractmethod
async def publish_batch(self, cmd: "KafkaPublishCommand") -> None: ...
|
request
async
Source code in faststream/confluent/publisher/producer.py
| @override
async def request(self, cmd: "KafkaPublishCommand") -> Any:
msg = "Kafka doesn't support `request` method without test client."
raise FeatureNotSupportedException(msg)
|