You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
796 B
26 lines
796 B
using Lion.AbpPro.AspNetCore;
|
|
using Volo.Abp.AspNetCore.Mvc;
|
|
|
|
namespace Lion.AbpPro.WebGateway;
|
|
|
|
[DependsOn(
|
|
typeof(AbpAspNetCoreMvcModule),
|
|
typeof(AbpProAspNetCoreModule))]
|
|
public class MyProjectNameWebGatewayModule : AbpModule
|
|
{
|
|
public override void ConfigureServices(ServiceConfigurationContext context)
|
|
{
|
|
context.Services.AddAbpProHealthChecks();
|
|
context.Services.AddAbpProOcelot();
|
|
}
|
|
|
|
public override void OnApplicationInitialization(ApplicationInitializationContext context)
|
|
{
|
|
var app = context.GetApplicationBuilder();
|
|
app.UseCorrelationId();
|
|
app.UseRouting();
|
|
app.UseConfiguredEndpoints(endpoints => { endpoints.MapHealthChecks("/health"); });
|
|
app.UseWebSockets();
|
|
app.UseOcelot().Wait();
|
|
}
|
|
}
|