5100* tests strengthtenen work

This commit is contained in:
StellaOps Bot
2025-12-24 12:38:34 +02:00
parent 9a08d10b89
commit 02772c7a27
117 changed files with 29941 additions and 66 deletions

View File

@@ -38,6 +38,7 @@ using StellaOps.Notify.WebService.Services;
using StellaOps.Notify.WebService.Internal;
using StellaOps.Plugin.DependencyInjection;
using StellaOps.Notify.WebService.Contracts;
using StellaOps.Router.AspNet;
var builder = WebApplication.CreateBuilder(args);
@@ -100,6 +101,13 @@ ConfigureRateLimiting(builder, bootstrapOptions);
builder.Services.AddEndpointsApiExplorer();
// Stella Router integration
var routerOptions = builder.Configuration.GetSection("Notify:Router").Get<StellaRouterOptionsBase>();
builder.Services.TryAddStellaRouter(
serviceName: "notify",
version: typeof(Program).Assembly.GetName().Version?.ToString() ?? "1.0.0",
routerOptions: routerOptions);
var app = builder.Build();
var readyStatus = app.Services.GetRequiredService<ServiceStatus>();
@@ -110,6 +118,10 @@ await InitialiseAsync(app.Services, readyStatus, app.Logger, resolvedOptions);
ConfigureRequestPipeline(app, bootstrapOptions);
ConfigureEndpoints(app);
// Refresh Router endpoint cache
var notifyRouterOptions = app.Configuration.GetSection("Notify:Router").Get<StellaRouterOptionsBase>();
app.TryRefreshStellaRouterEndpoints(notifyRouterOptions);
await app.RunAsync();
static void ConfigureAuthentication(WebApplicationBuilder builder, NotifyWebServiceOptions options)
@@ -323,6 +335,10 @@ static void ConfigureRequestPipeline(WebApplication app, NotifyWebServiceOptions
app.UseAuthentication();
app.UseRateLimiter();
app.UseAuthorization();
// Stella Router integration
var routerOptions = app.Configuration.GetSection("Notify:Router").Get<StellaRouterOptionsBase>();
app.TryUseStellaRouter(routerOptions);
}
static void ConfigureEndpoints(WebApplication app)

View File

@@ -24,5 +24,6 @@
<ProjectReference Include="../../Authority/StellaOps.Authority/StellaOps.Auth.Abstractions/StellaOps.Auth.Abstractions.csproj" />
<ProjectReference Include="../../Authority/StellaOps.Authority/StellaOps.Auth.Client/StellaOps.Auth.Client.csproj" />
<ProjectReference Include="../../Authority/StellaOps.Authority/StellaOps.Auth.ServerIntegration/StellaOps.Auth.ServerIntegration.csproj" />
<ProjectReference Include="../../__Libraries/StellaOps.Router.AspNet/StellaOps.Router.AspNet.csproj" />
</ItemGroup>
</Project>