public class KafkaItemWriter<K,T> extends KeyValueItemWriter<K,T>
An ItemWriter implementation for Apache Kafka using a
KafkaTemplate with default topic configured.
delete, itemKeyMapper| Constructor and Description |
|---|
KafkaItemWriter() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
init()
afterPropertiesSet() hook
|
void |
setKafkaTemplate(org.springframework.kafka.core.KafkaTemplate<K,T> kafkaTemplate)
Set the
KafkaTemplate to use. |
protected void |
writeKeyValue(K key,
T value)
Subclasses implement this method to write each item to key value store
|
afterPropertiesSet, setDelete, setItemKeyMapper, writeprotected void writeKeyValue(K key, T value)
KeyValueItemWriterwriteKeyValue in class KeyValueItemWriter<K,T>key - the keyvalue - the itemprotected void init()
KeyValueItemWriterinit in class KeyValueItemWriter<K,T>