RabbitMQ ——消息属性Properties

简介

发送消息可以为消息指定一些参数

  • Delivery mode: 是否持久化,1 - Non-persistent,2 - Persistent
  • Headers:Headers can have any name. Only long string headers can be set here.
  • Properties: You can set other message properties here (delivery mode and headers are pulled out as the most common cases). Invalid properties will be ignored. Valid properties are: 
  1. content_type : 消息内容的类型
  2. content_encoding: 消息内容的编码格式
  3. priority: 消息的优先级
  4. correlation_id:关联id
  5. reply_to: 用于指定回复的队列的名称
  6. expiration: 消息的失效时间
  7. message_id: 消息id
  8. timestamp:消息的时间戳
  9. type: 类型
  10. user_id: 用户id
  11. app_id: 应用程序id
  12. cluster_id: 集群id
  13. Payload: 消息内容

猜你喜欢

转载自blog.csdn.net/ctwy291314/article/details/83183633
今日推荐