question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

An abstract base class or Interface creates a new Azure Service BusTopic

See original GitHub issue

When you add an interface or an abstract base class to a class that is used to publish data with MassTransit, it causes MassTransit to create an undesirable “extra” Service Bus Topic. For example:

This is fine:

public EventData {
 public string Text {get;set;]
}

There will be one Azure Service Bus Topic created called “EventData”.

However, if you add an interface:

public EventData : IHasText {
 public string Text {get;set;]
}

Then MassTransit will create an extra Topic called “IHasText”.

Is this by design? Is there a way to disable this behavior? I think it causes some quirky behavior when using temporary queues, but I’d have to verify (I’m using a named queue).

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

4reactions
joshmouchcommented, Apr 29, 2019

Confusing and complicated to implement? It definitely makes looking at the queues and topics more confusing. There’s no business-driven reason to ever publish something to an IHasText consumer, so it ends up just being extra clutter in Azure Service Bus.

2reactions
mburumaxwellcommented, Oct 1, 2020

Happy to see this resolved in the latest 7.0.4 release.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Introduction to Azure Service Bus, an enterprise message ...
This article provides a high-level overview of Azure Service Bus, a fully managed enterprise integration serverless message broker.
Read more >
Microservices Communication Using Azure Service Bus | Kambu
Let's create our base class called 'Event' under the Models folder – this will be our base model placed inside Azure Service Bus...
Read more >
Inheriting from abstract class in old Azure library (Microsoft. ...
ServiceBus.Messaging is an older API whose QueueClient class can only be created using one of the QueueClient.Create factory methods, eg : var ...
Read more >
Azure Service Bus message handling | Arcus
To have access to the Azure Service Bus operations, you have to implement the abstract AzureServiceBusMessageHandler<T> class. Behind the screens it implements ...
Read more >
Implementing IHostedService in ASP.NET Core 2.0
Exploring an example of using the new IHostedService interface from ... of our service lives in an abstract base class called HostedService.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found