When configuring RabbitMQ with conventional routing but with NamingSource.FromHandlerType, and having a handler type that handles multiple messages (such as a Saga implementation). The handler queue is only bound to one of the message type exchanges.
Steps to reproduce the behavior:
- Configure RabbitMQ with conventional routing using
NamingSource.FromHandlerType
- Create a handler type that handles two different message types
A single queue named after handler type but with bindings to the exchanges for all handled messages is expected. However the queue is just bound to one of the exchanges. I believe this is due to the check existing bindings in the RabbitMqMessageRoutingConvention.ApplyListenerRoutingDefaults method. In this case we expect mutliple bindings so not adding the binding due to an existing one seems incorrect.
I have a PR ready that has a fix and tests if this is deemed to be incorrect behaviour.
When configuring RabbitMQ with conventional routing but with
NamingSource.FromHandlerType, and having a handler type that handles multiple messages (such as a Saga implementation). The handler queue is only bound to one of the message type exchanges.Steps to reproduce the behavior:
NamingSource.FromHandlerTypeA single queue named after handler type but with bindings to the exchanges for all handled messages is expected. However the queue is just bound to one of the exchanges. I believe this is due to the check existing bindings in the
RabbitMqMessageRoutingConvention.ApplyListenerRoutingDefaultsmethod. In this case we expect mutliple bindings so not adding the binding due to an existing one seems incorrect.I have a PR ready that has a fix and tests if this is deemed to be incorrect behaviour.