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

@@ -125,10 +125,10 @@ public static class KpiEndpoints
}
private static async Task<IResult> GetKpiTrend(
[FromQuery] int days = 30,
[FromQuery] string? tenant = null,
[FromServices] IKpiTrendService trendService,
CancellationToken ct)
CancellationToken ct,
[FromQuery] int days = 30,
[FromQuery] string? tenant = null)
{
var trend = await trendService.GetTrendAsync(days, tenant, ct);
return Results.Ok(trend);

View File

@@ -9,6 +9,7 @@ using StellaOps.Orchestrator.WebService.Endpoints;
using StellaOps.Orchestrator.WebService.Services;
using StellaOps.Orchestrator.WebService.Streaming;
using StellaOps.Telemetry.Core;
using StellaOps.Router.AspNet;
var builder = WebApplication.CreateBuilder(args);
@@ -91,6 +92,13 @@ builder.Services.AddSingleton<ScaleMetrics>();
builder.Services.AddSingleton<LoadShedder>(sp => new LoadShedder(sp.GetRequiredService<ScaleMetrics>()));
builder.Services.AddSingleton<StartupProbe>();
// Stella Router integration
var routerOptions = builder.Configuration.GetSection("Orchestrator:Router").Get<StellaRouterOptionsBase>();
builder.Services.TryAddStellaRouter(
serviceName: "orchestrator",
version: typeof(Program).Assembly.GetName().Version?.ToString() ?? "1.0.0",
routerOptions: routerOptions);
var app = builder.Build();
if (app.Environment.IsDevelopment())
@@ -104,6 +112,7 @@ app.UseStellaOpsTelemetryContext();
// Enable WebSocket support for streaming endpoints
app.UseWebSockets();
app.TryUseStellaRouter(routerOptions);
// OpenAPI discovery endpoints (available in all environments)
app.MapOpenApiEndpoints();
@@ -129,6 +138,9 @@ app.MapStreamEndpoints();
// Register worker endpoints (claim, heartbeat, progress, complete)
app.MapWorkerEndpoints();
// Refresh Router endpoint cache
app.TryRefreshStellaRouterEndpoints(routerOptions);
app.Run();
public partial class Program;

View File

@@ -40,7 +40,7 @@
<ProjectReference Include="..\..\..\__Libraries\StellaOps.Messaging.Transport.Postgres\StellaOps.Messaging.Transport.Postgres.csproj" />
<ProjectReference Include="..\..\..\__Libraries\StellaOps.Messaging.Transport.Valkey\StellaOps.Messaging.Transport.Valkey.csproj" />
<ProjectReference Include="..\..\..\__Libraries\StellaOps.Metrics\StellaOps.Metrics.csproj" />
<ProjectReference Include="..\..\..\__Libraries\StellaOps.Router.AspNet\StellaOps.Router.AspNet.csproj" />
</ItemGroup>