RabbitMQ支持的4种Exchange

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/hxg117/article/details/79260929
  1. Direct Exchange 
    默认方式。通过Routing Key将消息从Exchange转发到Queue
  2. Topic Exchange
    Routing Key可以包含 * 或者 #,来匹配Queue
  3. Fanout Exchange
    不需要Routing Key。将消息发给所有Queue
  4. Headers Exchange
    不适用Routing Key。通过消息头部转发。

BindingBuilder.bind(queue).to(exchange).with(routingKey);


猜你喜欢

转载自blog.csdn.net/hxg117/article/details/79260929