Class KafkaNotificationPublisher

java.lang.Object
com.reallifedeveloper.common.infrastructure.messaging.KafkaNotificationPublisher
All Implemented Interfaces:
NotificationPublisher

public final class KafkaNotificationPublisher extends Object implements NotificationPublisher
An implementation of the NotificationPublisher interface which uses Apache Kafka.
Author:
RealLifeDeveloper
  • Constructor Details

    • KafkaNotificationPublisher

      public KafkaNotificationPublisher(org.springframework.kafka.core.KafkaTemplate<String,String> kafkaTemplate, ObjectSerializer<String> objectSerializer)
      Creates a new KafkaNotificationPublisher which uses the given ObjectSerializer to serialize notifications, and the given KafkaTemplate to send them to Kafka.
      Parameters:
      kafkaTemplate - the KafkaTemplate to use
      objectSerializer - the ObjectSerializer to use
  • Method Details