in ddm-notification-service/src/it/java/com/epam/digital/data/platform/notification/config/TestKafkaConfig.java [34:44]
public KafkaTemplate<String, Object> kafkaTemplate(KafkaProperties kafkaProperties) {
Map<String, Object> producerProps =
Map.of(
ProducerConfig.BOOTSTRAP_SERVERS_CONFIG,
kafkaProperties.getBootstrap(),
ProducerConfig.KEY_SERIALIZER_CLASS_CONFIG,
StringSerializer.class,
ProducerConfig.VALUE_SERIALIZER_CLASS_CONFIG,
JsonSerializer.class);
return new KafkaTemplate<>(new DefaultKafkaProducerFactory<>(producerProps));
}