Skip to content

Instantly share code, notes, and snippets.

@MrMikeFloyd
Created December 15, 2021 12:42
Show Gist options
  • Save MrMikeFloyd/c3e5bb069c7ae69de73f6c44db1a6978 to your computer and use it in GitHub Desktop.
Save MrMikeFloyd/c3e5bb069c7ae69de73f6c44db1a6978 to your computer and use it in GitHub Desktop.
spring:
application:
name: kafka-telemetry-data-consumer
# Ignore type headers in kafka message
kafka.properties.spring.json.use.type.headers: false
cloud:
stream:
kafka:
binder:
brokers: "localhost:29092"
bindings:
# this has to match the consumer bean name with suffix in-0 (for consumer)
processNasaTelemetryData-in-0:
consumer:
configuration:
key.deserializer: org.apache.kafka.common.serialization.StringDeserializer
value.deserializer: de.codecentric.samples.kafkasamplesconsumer.serdes.TelemetryDataDeserializer
processEsaTelemetryData-in-0:
consumer:
configuration:
key.deserializer: org.apache.kafka.common.serialization.StringDeserializer
value.deserializer: de.codecentric.samples.kafkasamplesconsumer.serdes.TelemetryDataDeserializer
bindings:
processNasaTelemetryData-in-0:
group: ${spring.application.name}
destination: space-probe-aggregate-telemetry-data-nasa
processEsaTelemetryData-in-0:
group: ${spring.application.name}
destination: space-probe-aggregate-telemetry-data-esa
function:
# We define this explicitly since we have several consumer functions
definition: processNasaTelemetryData;processEsaTelemetryData
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment