> For the complete documentation index, see [llms.txt](https://jack80342.gitbook.io/spring-boot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jack80342.gitbook.io/spring-boot/iv.-spring-boot-features/32.-messaging/32.2-amqp/32.2.1-rabbitmq-support.md).

# 32.2.1 RabbitMQ支持

[RabbitMQ](https://www.rabbitmq.com/)是一个基于AMQP协议的、轻量级的、可靠的、可扩展的和可移植的消息代理。Spring使用它进行消息传递。RabbitMQ配置被外部属性`spring.rabbitmq.*`控制。例如，在`application.properties`中声明以下片段：

```
spring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=admin
spring.rabbitmq.password=secret
```

更多选项参考[RabbitProperties](https://github.com/spring-projects/spring-boot/tree/v2.0.0.RELEASE/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/amqp/RabbitProperties.java)。

**注** 更多细节，请查看[理解AMQP，RabbitMQ使用的协议](https://spring.io/blog/2010/06/14/understanding-amqp-the-protocol-used-by-rabbitmq/)。
