Class DefaultKafkaClientFactory

    • Constructor Detail

      • DefaultKafkaClientFactory

        public DefaultKafkaClientFactory()
    • Method Detail

      • getProducer

        public org.apache.kafka.clients.producer.Producer getProducer​(Properties kafkaProps)
        Description copied from interface: KafkaClientFactory
        Creates a new instance of the Kafka Producer class.
        Specified by:
        getProducer in interface KafkaClientFactory
        Parameters:
        kafkaProps - The producer configs.
        Returns:
        an instance of Kafka producer.
      • getConsumer

        public org.apache.kafka.clients.consumer.Consumer getConsumer​(Properties kafkaProps)
        Description copied from interface: KafkaClientFactory
        Creates a new instance of the Kafka Consumer class.
        Specified by:
        getConsumer in interface KafkaClientFactory
        Parameters:
        kafkaProps - The consumer configs.
        Returns:
        an instance of Kafka consumer.
      • getBrokers

        public String getBrokers​(KafkaConfiguration configuration)
        Description copied from interface: KafkaClientFactory
        URL of the Kafka brokers to use. The format is host1:port1,host2:port2, and the list can be a subset of brokers or a VIP pointing to a subset of brokers.

        This option is known as bootstrap.servers in the Kafka documentation.

        Specified by:
        getBrokers in interface KafkaClientFactory
        Parameters:
        configuration - the configuration