Adapt to Rabbit internal change
See gh-15271
This commit is contained in:
@@ -196,7 +196,8 @@ public class RabbitAutoConfiguration {
|
||||
.to(template::setReplyTimeout);
|
||||
map.from(properties::getExchange).to(template::setExchange);
|
||||
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;
|
||||
}
|
||||
|
||||
|
||||
@@ -326,8 +326,8 @@ public class RabbitAutoConfigurationTests {
|
||||
.withPropertyValues("spring.rabbitmq.template.queue:default-queue")
|
||||
.run((context) -> {
|
||||
RabbitTemplate rabbitTemplate = context.getBean(RabbitTemplate.class);
|
||||
assertThat(rabbitTemplate).hasFieldOrPropertyWithValue("queue",
|
||||
"default-queue");
|
||||
assertThat(rabbitTemplate).hasFieldOrPropertyWithValue(
|
||||
"defaultReceiveQueue", "default-queue");
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user