Java Code Examples for org.springframework.kafka.support.converter.StringJsonMessageConverter
The following examples show how to use
org.springframework.kafka.support.converter.StringJsonMessageConverter. These examples are extracted from open source projects.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: grussell-spring-kafka Source File: CommonConfiguration.java License: Apache License 2.0 | 5 votes |
@Bean public ConcurrentKafkaListenerContainerFactory<String, String> jsonKafkaListenerContainerFactory() { ConcurrentKafkaListenerContainerFactory<String, String> factory = new ConcurrentKafkaListenerContainerFactory<>(); factory.setConsumerFactory(consumerFactory()); factory.setMessageConverter(new StringJsonMessageConverter()); return factory; }
Example 2
Source Project: spring-kafka Source File: SenderConfig.java License: MIT License | 5 votes |
@Bean public KafkaTemplate<String, String> kafkaTemplate() { KafkaTemplate<String, String> template = new KafkaTemplate<>(producerFactory()); template.setMessageConverter(new StringJsonMessageConverter()); return template; }
Example 3
Source Project: spring-kafka Source File: ReceiverConfig.java License: MIT License | 5 votes |
@Bean public ConcurrentKafkaListenerContainerFactory<String, String> kafkaListenerContainerFactory() { ConcurrentKafkaListenerContainerFactory<String, String> factory = new ConcurrentKafkaListenerContainerFactory<>(); factory.setConsumerFactory(consumerFactory()); factory.setMessageConverter(new StringJsonMessageConverter()); return factory; }
Example 4
Source Project: spring-boot-tutorial Source File: DunwuKafkaConfig.java License: Creative Commons Attribution Share Alike 4.0 International | 4 votes |
@Bean public RecordMessageConverter converter() { return new StringJsonMessageConverter(); }
Example 5
Source Project: loc-framework Source File: LocKafkaAutoConfiguration.java License: MIT License | 4 votes |
@Bean @ConditionalOnMissingBean public RecordMessageConverter recordMessageConverter() { return new StringJsonMessageConverter(objectMapper); }
Example 6
Source Project: spring-cloud-contract-samples Source File: Application.java License: Apache License 2.0 | 4 votes |
@Bean public RecordMessageConverter converter() { return new StringJsonMessageConverter(); }
Example 7
Source Project: spring-cloud-contract-samples Source File: Application.java License: Apache License 2.0 | 4 votes |
@Bean public RecordMessageConverter converter() { return new StringJsonMessageConverter(); }