1 package de.example.spring.kafka;
3 import org.springframework.context.annotation.Bean;
4 import org.springframework.context.annotation.Configuration;
7 public class ReceiverConfig {
10 public Receiver receiver(DummyService dummyService) {
11 return new Receiver(dummyService);
16 // public MessageConverter customMessageConverter(ObjectMapper objectMapper) {
17 // MyCustomMessageConverter converter = new MyCustomMessageConverter();
18 // converter.setSerializedPayloadClass(String.class);
19 // if (objectMapper != null) {
20 // converter.setObjectMapper(objectMapper);
28 // public MessageConverter avroMessageConverter() throws IOException {
29 // AvroSchemaMessageConverter converter = new AvroSchemaMessageConverter(MimeType.valueOf("avro/bytes"));
30 // //converter.setSchemaLocation(new ClassPathResource("schemas/User.avro"));