Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

NuGet NuGet License

简化Web API事件总线引入,只需要引入一个包:

NuGet\Install-Package CodeWF.AspNetCore.EventBus

使用:

using CodeWF.EventBus;

var builder = WebApplication.CreateBuilder(args);
builder.Services.AddControllers();
builder.Services.AddEndpointsApiExplorer();

Register EventBus
builder.Services.AddEventBus(Assembly.GetExecutingAssembly());

var app = builder.Build();

app.UseAuthorization();

app.MapControllers();

// Use EventBus
app.UseEventBus(Assembly.GetExecutingAssembly());

app.Run();