You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can you also reproduce the problem with the latest version?
Yes
Environment
Irrelevant
Steps to Reproduce
(Write your steps here:)
Create 3 seperate projects (or use different namespaces)
Create Producer in project/ns 1 that produces a Message
Create a Consumer in project/ns 2 with a consumer class MessageConsumer : IConsumer
Create a Consumer in project/ns 3 with the same consumer class MessageConsumer : IConsumer
Expected Behavior
I Expect both consumers to get their own message
Actual Behavior
One consumer gets a message the other does not.
Reproducible Demo
If needed I can provide it. But I think its easy to reproduce. Just look at the DefaultEndpointNameFormatter class
Remarks
We can fix this with a custom endpoint name formatter, but I believe in "falling in the pit of success" and this is a timebomb waiting to happen in small or big teams if one happens to name consumers the same in different projects or even namespaces.
Why is not at least something like the namespace or something else included in the name by default? I'd like to see it at least mentioned in the docs in a red section since it can really screw up your day/week/weekend if not taken care of.
In my situation I've prefixed the consumers by overwriting the DefaultEndpointNameFormatter with the service name in the SanitizeName method, since I do want to preserve the rest of the default handling of endpoint names
The text was updated successfully, but these errors were encountered:
A change like this would break everyone currently using MassTransit. So it's unlikely to ever become the default behavior.
As you stated, the default endpoint name formatter can be replaced. Adding an option to the current name formatters to include the namespace (or even some arbitrary prefix) to the names would be a reasonable addition to the current behavior.
Yes, that also occurred to me it would probably break alot of projects if it was to be changed. An addition to the default formatter plus a warning/note in the docs is a welcome change :)
Is this a bug report?
I think it could be classified as a bug
Can you also reproduce the problem with the latest version?
Yes
Environment
Irrelevant
Steps to Reproduce
(Write your steps here:)
Expected Behavior
I Expect both consumers to get their own message
Actual Behavior
One consumer gets a message the other does not.
Reproducible Demo
If needed I can provide it. But I think its easy to reproduce. Just look at the DefaultEndpointNameFormatter class
Remarks
We can fix this with a custom endpoint name formatter, but I believe in "falling in the pit of success" and this is a timebomb waiting to happen in small or big teams if one happens to name consumers the same in different projects or even namespaces.
Why is not at least something like the namespace or something else included in the name by default? I'd like to see it at least mentioned in the docs in a red section since it can really screw up your day/week/weekend if not taken care of.
In my situation I've prefixed the consumers by overwriting the DefaultEndpointNameFormatter with the service name in the SanitizeName method, since I do want to preserve the rest of the default handling of endpoint names
The text was updated successfully, but these errors were encountered: