Reputation: 4897
Is there any way to intercept Azure service bus messages in a generic way on both sides (sending and receiving)? I would like to generically add properties to messages as they are sent, and read properties as they are received, without having to change the sending or receiving code.
I have found some references to WCF interfaces IClientMessageInspector
and IDispatchMessageInspector
in the context of service bus, but I have yet to find a real working sample that connects all the dots.
Upvotes: 0
Views: 579
Reputation: 26057
With the new .NET Standard client for Azure Service Bus, there are incoming and outgoing pipelines intended exactly for that purpose. You can have a look at some of the already available plugins to get an idea how it works.
Upvotes: 1