DotNetBrightener.Plugins.EventPubSub.AzureServiceBus 2024.0.14.6-rc-242840501

This is a prerelease version of DotNetBrightener.Plugins.EventPubSub.AzureServiceBus.
There is a newer version of this package available.
See the version list below for details.
dotnet add package DotNetBrightener.Plugins.EventPubSub.AzureServiceBus --version 2024.0.14.6-rc-242840501
                    
NuGet\Install-Package DotNetBrightener.Plugins.EventPubSub.AzureServiceBus -Version 2024.0.14.6-rc-242840501
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="DotNetBrightener.Plugins.EventPubSub.AzureServiceBus" Version="2024.0.14.6-rc-242840501" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DotNetBrightener.Plugins.EventPubSub.AzureServiceBus" Version="2024.0.14.6-rc-242840501" />
                    
Directory.Packages.props
<PackageReference Include="DotNetBrightener.Plugins.EventPubSub.AzureServiceBus" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add DotNetBrightener.Plugins.EventPubSub.AzureServiceBus --version 2024.0.14.6-rc-242840501
                    
#r "nuget: DotNetBrightener.Plugins.EventPubSub.AzureServiceBus, 2024.0.14.6-rc-242840501"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#addin nuget:?package=DotNetBrightener.Plugins.EventPubSub.AzureServiceBus&version=2024.0.14.6-rc-242840501&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=DotNetBrightener.Plugins.EventPubSub.AzureServiceBus&version=2024.0.14.6-rc-242840501&prerelease
                    
Install as a Cake Tool

Azure Service Bus Integration for Event PubSub Library

© 2024 DotNet Brightener

Versions

Library Version
EventPubSub Core NuGet Version
EventPubSub Distributed Library NuGet Version
Dependency Injection Library NuGet Version
Azure Service Bus Integration Library NuGet Version
RabbitMq Integration Library NuGet Version

Installation

dotnet package add DotNetBrightener.Plugins.EventPubSub
dotnet package add DotNetBrightener.Plugins.EventPubSub.DependencyInjection
dotnet package add DotNetBrightener.Plugins.EventPubSub.Distributed
dotnet package add DotNetBrightener.Plugins.EventPubSub.AzureServiceBus
# or 
dotnet add package DotNetBrightener.Plugins.EventPubSub.RabbitMq

Usage

Configuration

Option 1: Use IConfiguration to configure the service bus

// Initialize EventPubSubService
var eventPubSubConfig = builder.Services
                               .AddEventPubSubService()
                                // scan for event messages in the given assembly
                               .AddEventMessagesFromAssemblies(typeof(DistributedTestMessage).Assembly)
                                // scan for event handlers in the given assembly
                               .AddEventHandlersFromAssemblies(Assembly.GetExecutingAssembly());

// Add Azure Service Bus
eventPubSubConfig.UseAzureServiceBus(builder.Configuration)
                 .Finalize();

In your appsettings.json file, add the the following configuration:

  "ServiceBusConfiguration": {
    "ConnectionString": "<your-endpoint-to-azure-service-bus>",
    "SubscriptionName": "<application-name>",
    "IncludeNamespaceForTopicName": false
  }
Option 2: Configure from code

// Initialize EventPubSubService
var eventPubSubConfig = builder.Services
                               .AddEventPubSubService()
                                // scan for event messages in the given assembly
                               .AddEventMessagesFromAssemblies(Assembly.GetExecutingAssembly(), typeof(DistributedTestMessage).Assembly)
                                // scan for event handlers in the given assembly
                               .AddEventHandlersFromAssemblies(Assembly.GetExecutingAssembly());

var distributedIntegrations = eventPubSubConfig.EnableDistributedIntegrations();

distributedIntegrations.SetSubscriptionName("<application-name>");
// if you want to exclude namespace in entity name
distributedIntegrations.ExcludeNamespaceInEntityName();

// Add Azure Service Bus
distributedIntegrations.UseAzureServiceBus("<azure-connection-string>");

// this should be called before builder.Build(), or before exiting ConfigureServices method
distributedIntegrations.Finalize();

Refer to the Event PubSub Library, MassTransit Integration Library for more details on how to configure the event messages, request/response messages and how to implement handlers for them.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2025.0.4-preview-304 5 7/1/2025
2025.0.4-preview-299 108 5/31/2025
2025.0.4-preview-298 85 5/30/2025
2025.0.4-preview-296 121 5/30/2025
2025.0.4-preview-295 135 5/29/2025
2025.0.4-preview-293 132 5/26/2025
2025.0.4-preview-292 133 5/26/2025
2025.0.3 108 2/10/2025
2025.0.3-preview-288 101 2/10/2025
2025.0.2 108 1/21/2025
2025.0.2-preview-278 84 1/21/2025
2025.0.2-preview-277 94 12/16/2024
2025.0.1-rc-243301701 368 11/25/2024
2024.0.14.6 117 11/25/2024
2024.0.14.6-rc-243031001 169 10/29/2024
2024.0.14.6-rc-243030701 101 10/29/2024
2024.0.14.6-rc-242840501 90 10/10/2024
2024.0.14.6-rc-242820305 96 10/8/2024
2024.0.14.6-rc-242771401 190 10/3/2024
2024.0.14.6-rc-242770501 93 10/3/2024
2024.0.14.6-rc-242770201 108 10/3/2024
2024.0.14.6-rc-242761801 94 10/2/2024
2024.0.14.6-rc-242761601 108 10/2/2024
2024.0.14.6-rc-242761501 98 10/2/2024
2024.0.14.6-rc-242761401 109 10/2/2024
2024.0.14.6-rc-242760701 113 10/2/2024
2024.0.14.6-rc-242751002 95 10/1/2024
2024.0.14.6-rc-242750901 114 10/1/2024
2024.0.14.6-rc-242750502 108 10/1/2024
2024.0.14.6-rc-242750201 98 10/1/2024
2024.0.14.6-rc-242741501 89 9/30/2024
2024.0.14.6-rc-242730701 121 9/29/2024
2024.0.14.6-preview-2730501 81 9/29/2024
2024.0.14.6-preview-2701501 125 9/26/2024
2024.0.14.6-preview-2620901 139 9/18/2024
2024.0.14.6-preview-2570701 103 9/13/2024
2024.0.14.6-preview-2510703 155 9/7/2024
2024.0.14.6-preview-2480501 107 9/4/2024
2024.0.14.6-preview-2430401 121 8/30/2024
2024.0.14.6-preview-242730701 89 9/29/2024
2024.0.14.6-preview-2421703 99 8/29/2024
2024.0.14.6-preview-2421701 95 8/29/2024
2024.0.14.6-preview-2420901 94 8/29/2024
2024.0.14.6-preview-2390101 105 8/26/2024
2024.0.14.6-preview-2381603 120 8/25/2024
2024.0.14.6-preview-2341601 142 8/21/2024
2024.0.14.6-preview-2321602 120 8/20/2024
2024.0.14.6-preview-2190801 125 8/6/2024
2024.0.14.6-preview-2041501 106 7/22/2024
2024.0.14.6-preview-1920603 163 7/10/2024
2024.0.14.6-preview-1920301 100 7/10/2024
2024.0.14.6-preview-1911302 111 7/9/2024
2024.0.14.6-preview-1901001 121 7/8/2024
2024.0.14.6-preview-1900901 106 7/8/2024
2024.0.14.6-preview-1900801 99 7/8/2024
2024.0.14.6-preview-1860304 104 7/4/2024
2024.0.14.5 164 7/1/2024
2024.0.14.5-preview-1811601 100 6/29/2024
2024.0.14.5-preview-1810501 121 6/29/2024
2024.0.14.5-preview-180132 109 6/28/2024
2024.0.14.5-preview-180131 111 6/28/2024
2024.0.14.5-preview-180121 93 6/28/2024
2024.0.14.4 123 6/27/2024
2024.0.14.4-preview-7 101 6/27/2024
2024.0.14.3 121 6/21/2024
2024.0.14.1 119 6/6/2024
2024.0.14.1-preview 97 6/6/2024
2024.0.14-preview-1 107 6/6/2024
2024.0.13.8-preview 117 6/6/2024
2024.0.13.1-preview-0146 117 6/6/2024
2024.0.12.15803-preview-03 102 6/6/2024
2024.0.12.15608 114 6/4/2024
2024.0.12.15515 195 6/3/2024
2024.0.12.15220 106 5/31/2024
2024.0.12.15220-alpha31-240... 96 5/31/2024
2024.0.12.14911 157 5/28/2024
2024.0.12.14910-alpha28-240... 107 5/28/2024
2024.0.12.14823 146 5/27/2024
2024.0.12.14522-alpha7-2405... 116 5/24/2024
2024.0.12.14514-alpha6-2405... 112 5/24/2024
2024.0.12.14511 131 5/24/2024
2024.0.12.14314 171 5/22/2024
2024.0.12.14114 166 5/20/2024