Spring Cloud Stream Kafka add headers to only one binding

Cobra1117

The reference manual for Spring Cloud Stream says that you can use the property "spring.cloud.stream.kafka.binder.headers" to set the headers for all bindings. Is there a way to set the headers for a specific binding? For example, something like this:

spring.cloud.stream:
  bindings:
    input:
      destination: input-topic
      headers: header-for-input-only
    output:
      destination: input-topic
      headers: header-for-output-only
Marius Bogoevici

Unfortunately not, it's a binder-wide setting. More granular settings could be a new feature.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

spring cloud stream kafka binding config

Does Spring Cloud Stream Kafka supports embedded headers?

Conditional (content-based) routing on Kafka headers in Spring Cloud Stream

Kafka - spring cloud stream

Why to use Spring Cloud Stream for binding with kafka/rabbitmq when you can use Spring Cloud Task for same?

Is multiple brokers possible in one Kafka Streams Topology(Spring Cloud Stream)?

Spring Cloud Stream binding visualisation

How to enable database + kafka transaction in Spring Cloud Stream for producer-only transactions (db + kafka)?

Understanding Spring Cloud Stream Kafka and Spring Retry

Spring Cloud Kafka Binding with Synchronous Rest Call

exactly once delivery Is it possible through spring-cloud-stream-binder-kafka or spring-kafka which one to use

Spring cloud stream (Kafka) autoCreateTopics not working

Spring Cloud Stream Kafka Error channel

Spring Cloud Stream embedded header format (Kafka)

Spring Cloud Stream Kafka consumer patterns

Multiple @EnableBinding with Kafka Spring Cloud Stream

Spring Cloud Stream Kafka - Method must be Declarative

Auto commit in kafka with spring cloud stream

Error Handling in Spring Cloud Stream - Kafka Binder

Kafka Sticky Partitioner using spring cloud stream

Multiple StreamListeners with Spring Cloud Stream connected to Kafka

Correctly manage DLQ in Spring Cloud Stream Kafka

Spring cloud stream - Kafka binder performance

Spring cloud stream and consume multiple kafka topics

Spring Cloud stream compatibility matrix with kafka

Kafka client id property with spring cloud stream

spring-cloud-stream kafka avro

jackson cannot deserialize (spring cloud stream kafka)

Using Kstream with spring cloud stream and kafka 1.0.1