Spring RabbitTemplate - How to create queues automatically upon send
问题 I am using RabbitMQ together with Spring's RabbitTemplate. When sending messages to queues using the template send methods, I want the queue to automatically be created/declared if it is not already exists. It is very important since according to our business logic queue names are generated on run-time and I cannot declare them in advance. Previously we have used JmsTemplate and any call to send or receive automatically created the queue. 回答1: Yes, you can use a RabbitAdmin and admin