Class TicketKafkaProducer
java.lang.Object
callofproject.dev.service.ticket.config.kafka.TicketKafkaProducer
@Service("callofproject.dev.service.ticket.config.kafka.TicketKafkaProducer")
public class TicketKafkaProducer
extends Object
- Author:
- Nuri Can ÖZTÜRK The ticket kafka producer. CopyRight(C) 2023 by Call Of Project Teams.
-
Constructor Summary
ConstructorsConstructorDescriptionTicketKafkaProducer
(org.apache.kafka.clients.admin.NewTopic topic, org.apache.kafka.clients.admin.NewTopic emailTopic, org.springframework.kafka.core.KafkaTemplate<String, NotificationKafkaDTO> notificationKafkaTemplate, org.springframework.kafka.core.KafkaTemplate<String, callofproject.dev.data.common.dto.EmailTopic> emailKafkaTemplate) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
sendEmail
(callofproject.dev.data.common.dto.EmailTopic emailTopic) Send email.void
sendNotification
(NotificationKafkaDTO notificationDTO) Send notification.
-
Constructor Details
-
TicketKafkaProducer
public TicketKafkaProducer(@Qualifier("notificationTopic") org.apache.kafka.clients.admin.NewTopic topic, @Qualifier("emailTopic") org.apache.kafka.clients.admin.NewTopic emailTopic, org.springframework.kafka.core.KafkaTemplate<String, NotificationKafkaDTO> notificationKafkaTemplate, org.springframework.kafka.core.KafkaTemplate<String, callofproject.dev.data.common.dto.EmailTopic> emailKafkaTemplate) Constructor.- Parameters:
topic
- represents the topicemailTopic
- represents the email topicnotificationKafkaTemplate
- represents the notification kafka templateemailKafkaTemplate
- represents the email kafka template
-
-
Method Details
-
sendNotification
Send notification.- Parameters:
notificationDTO
- represents the notification dto
-
sendEmail
public void sendEmail(callofproject.dev.data.common.dto.EmailTopic emailTopic) Send email.- Parameters:
emailTopic
- represents the email topic
-