Commit a240e225 authored by Stephane Nicoll's avatar Stephane Nicoll

Adapt to Rabbit internal change

See gh-15271
parent cf525dab
...@@ -196,7 +196,8 @@ public class RabbitAutoConfiguration { ...@@ -196,7 +196,8 @@ public class RabbitAutoConfiguration {
.to(template::setReplyTimeout); .to(template::setReplyTimeout);
map.from(properties::getExchange).to(template::setExchange); map.from(properties::getExchange).to(template::setExchange);
map.from(properties::getRoutingKey).to(template::setRoutingKey); map.from(properties::getRoutingKey).to(template::setRoutingKey);
map.from(properties::getQueue).whenNonNull().to(template::setQueue); map.from(properties::getQueue).whenNonNull()
.to(template::setDefaultReceiveQueue);
return template; return template;
} }
......
...@@ -326,8 +326,8 @@ public class RabbitAutoConfigurationTests { ...@@ -326,8 +326,8 @@ public class RabbitAutoConfigurationTests {
.withPropertyValues("spring.rabbitmq.template.queue:default-queue") .withPropertyValues("spring.rabbitmq.template.queue:default-queue")
.run((context) -> { .run((context) -> {
RabbitTemplate rabbitTemplate = context.getBean(RabbitTemplate.class); RabbitTemplate rabbitTemplate = context.getBean(RabbitTemplate.class);
assertThat(rabbitTemplate).hasFieldOrPropertyWithValue("queue", assertThat(rabbitTemplate).hasFieldOrPropertyWithValue(
"default-queue"); "defaultReceiveQueue", "default-queue");
}); });
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment