Fix multi-binder sample to update the extended properties changes
This commit is contained in:
@@ -30,6 +30,8 @@ import org.springframework.amqp.rabbit.core.RabbitAdmin;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.test.SpringApplicationConfiguration;
|
||||
import org.springframework.cloud.stream.binder.BinderFactory;
|
||||
import org.springframework.cloud.stream.binder.ExtendedConsumerProperties;
|
||||
import org.springframework.cloud.stream.binder.ExtendedProducerProperties;
|
||||
import org.springframework.cloud.stream.binder.ProducerProperties;
|
||||
import org.springframework.cloud.stream.binder.rabbit.RabbitConsumerProperties;
|
||||
import org.springframework.cloud.stream.binder.rabbit.RabbitMessageChannelBinder;
|
||||
@@ -82,11 +84,11 @@ public class RabbitAndRedisBinderApplicationTests {
|
||||
public void messagingWorks() {
|
||||
DirectChannel dataProducer = new DirectChannel();
|
||||
((RedisMessageChannelBinder)binderFactory.getBinder("redis"))
|
||||
.bindProducer("dataIn", dataProducer, new ProducerProperties());
|
||||
.bindProducer("dataIn", dataProducer, new ExtendedProducerProperties<>(new ProducerProperties()));
|
||||
|
||||
QueueChannel dataConsumer = new QueueChannel();
|
||||
((RabbitMessageChannelBinder)binderFactory.getBinder("rabbit")).bindConsumer("dataOut", this.randomGroup,
|
||||
dataConsumer, new RabbitConsumerProperties());
|
||||
dataConsumer, new ExtendedConsumerProperties<>(new RabbitConsumerProperties()));
|
||||
|
||||
String testPayload = "testFoo" + this.randomGroup;
|
||||
dataProducer.send(MessageBuilder.withPayload(testPayload).build());
|
||||
|
||||
Reference in New Issue
Block a user