Soumpanhaoudom
Soumpanhaoudom

Reputation: 81

The different between Kafka Topic, Spring-cloud-stream Channel and Spring-cloud-stream destination

Excuse me! I got the same questions from my teammates.They asked me that what is different point between Kafka Topic, Spring cloud stream channel and Spring Cloud stream destination. We tried to search on the Internet, but we could not get any clue.

Upvotes: 0

Views: 1038

Answers (1)

Oleg Zhurakousky
Oleg Zhurakousky

Reputation: 6106

  • Kafka Topic is as it says - Kafka topic
  • Message Channel is actually an EIP abstraction implemented by Spring Integration and used by Spring Cloud Stream.
  • Spring Cloud stream destination - I am assuming you are referring to destination binding property (e.g., spring.cloud.stream.bindings.input.destination=myDestination). If so it is simply a mapping instruction to map specific channel to specific broker destination. In the above example presuming you are using Kafka you're instructing the framework to bridge myDestination Kafka topic to input Message Channel.

In short, Spring Cloud Stream current binder implementations (rabbit, kafka etc) are message channel binders - that is they bind external destination such as Rabbit queues, Kafka topics to internal Message channels ensuring a consistent approach when writing message handlers.

Upvotes: 2

Related Questions