EasyCaching icon indicating copy to clipboard operation
EasyCaching copied to clipboard

Opinative exchange type is a anti-pattern

Open luizcarlosfaria opened this issue 3 years ago • 1 comments

Force type of exchange is a anti-pattern.

The type of a exchange is the unique responsibility of developer, never a generic publish can be opinative around this.

https://github.com/dotnetcore/EasyCaching/blob/bc4a0177cf2cc9c220afbee6aafc6065770af239/bus/EasyCaching.Bus.RabbitMQ/DefaultRabbitMQBus.cs#L93

luizcarlosfaria avatar Jun 14 '22 10:06 luizcarlosfaria

@luizcarlosfaria Thanks for your interest in this project.

The exchange type topic may be more suitable in the EasyCaching scenario.

Although we can choose to allow users to customize, but the bus is not universal and is specifically designed for multi-level caching.

So it is mandatory to specify this type.

catcherwong avatar Jun 14 '22 13:06 catcherwong