have a simple Spring-Cloud-Stream project that I try to connect with RabbitMQ, It says its connected but It\'s not working. Did I do something wrong in the code?
To setup spring cloud stream with rabbitmq binder implementation you need to configure this in your pom.xml 1.
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-stream</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-stream-binder-rabbit</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-amqp</artifactId>
</dependency>
then you define this in your application.properties/yaml
2.
spring:
cloud:
stream:
bindings:
greetingChannel
destination: test.greeting
group: queue
rabbit:
bindings:
greetingChannel:
producer:
transacted: true //optional
EnableBinding(HelloBinding.class)
helloBinding.greeting().send(MessageBuilder
.withPayload(...)
.build());