TopicProducer

class lsst.ts.salkafka.TopicProducer(topic, kafka_factory, log)

Bases: object

Produce Kafka messages from DDS samples for one topic.

Parameters:
topicsalobj.topics.ReadTopic

Topic for which to produce kafka messages.

kafka_factoryKafkaProducerFactory

Information and clients for using Kafka.

loglogging.Logger

Parent log.

Methods Summary

__call__(data)

Forward one DDS sample (message) to Kafka.

close()

Close the Kafka producer.

start()

Start the Kafka producer.

Methods Documentation

async __call__(data)

Forward one DDS sample (message) to Kafka.

Parameters:
datadds sample

DDS sample.

async close()

Close the Kafka producer.

async start()

Start the Kafka producer.