Default switch

This is actually a Direct exchange with no name (empty string). Each new queue is bound to the switch by default. The binding’s routing key name is the same as the queue name

Direct (Direct connection switch)

It is used most often, and matches exactly according to RoutingKey. Directly connected switches can distribute tasks to multiple workers

Topic (Topic exchange)

Messages are distributed to one or more queues (Dimited by Dots) by fuzzy matching according to the RoutingKey. A routingKey can have wildcards ‘*’,’#’. * matches one word, and # matches zero or more words.

Due to the troublesome binding relationship, this type is only used in some queue systems with complex business.

FANOUT (Sector Switch)

The consumption is distributed to all bound queues, regardless of the RoutingKey. Advantage is the fastest forwarding message, the best performance. This is typically used to handle broadcast routing.

HEADERS (header switch)

Similar to a direct-connected switch. The difference with header switches is that routing rules are based on header properties instead of routing keys. Generally development is less used