stela ops usage fixes roles propagation and timoeut, one account to support multi tenants, migrations consolidation, search to support documentation, doctor and open api vector db search
This commit is contained in:
@@ -24,6 +24,7 @@ using System.IO;
|
||||
using System.Net.Http;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
using StellaOps.Router.AspNet;
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Configuration.AddStellaOpsDefaults(options =>
|
||||
@@ -291,6 +292,12 @@ else
|
||||
}).AddScheme<AuthenticationSchemeOptions, AnonymousAuthenticationHandler>("Anonymous", static _ => { });
|
||||
}
|
||||
|
||||
// Stella Router integration
|
||||
var routerEnabled = builder.Services.AddRouterMicroservice(
|
||||
builder.Configuration,
|
||||
serviceName: "signals",
|
||||
version: System.Reflection.CustomAttributeExtensions.GetCustomAttribute<System.Reflection.AssemblyInformationalVersionAttribute>(System.Reflection.Assembly.GetExecutingAssembly())?.InformationalVersion ?? "1.0.0",
|
||||
routerOptionsSection: "Router");
|
||||
builder.TryAddStellaOpsLocalBinding("signals");
|
||||
var app = builder.Build();
|
||||
app.LogStellaOpsLocalHostname("signals");
|
||||
@@ -303,6 +310,7 @@ if (!bootstrap.Authority.Enabled)
|
||||
app.UseStellaOpsCors();
|
||||
app.UseAuthentication();
|
||||
app.UseAuthorization();
|
||||
app.TryUseStellaRouter(routerEnabled);
|
||||
|
||||
app.MapHealthChecks("/healthz").AllowAnonymous();
|
||||
app.MapGet("/readyz", (SignalsStartupState state, SignalsSealedModeMonitor sealedModeMonitor) =>
|
||||
@@ -350,7 +358,7 @@ signalsGroup.MapGet("/status", (HttpContext context, SignalsOptions options, Sig
|
||||
return Results.Ok(new
|
||||
{
|
||||
service = "signals",
|
||||
version = typeof(Program).Assembly.GetName().Version?.ToString() ?? "unknown",
|
||||
version = System.Reflection.CustomAttributeExtensions.GetCustomAttribute<System.Reflection.AssemblyInformationalVersionAttribute>(typeof(Program).Assembly)?.InformationalVersion ?? "1.0.0",
|
||||
sealedMode = new
|
||||
{
|
||||
enforced = sealedModeMonitor.EnforcementEnabled,
|
||||
@@ -1009,6 +1017,7 @@ signalsGroup.MapPost("/reachability/recompute", async Task<IResult> (
|
||||
}).WithName("SignalsReachabilityRecompute");
|
||||
|
||||
|
||||
app.TryRefreshStellaRouterEndpoints(routerEnabled);
|
||||
app.Run();
|
||||
|
||||
// Internal: avoids type conflict when this project is referenced from Platform.WebService.
|
||||
@@ -1075,3 +1084,4 @@ internal partial class Program
|
||||
}
|
||||
|
||||
// Primary Program partial declaration merged above
|
||||
|
||||
|
||||
@@ -27,4 +27,8 @@
|
||||
<ProjectReference Include="../../Router/__Libraries/StellaOps.Messaging/StellaOps.Messaging.csproj" />
|
||||
<ProjectReference Include="../StellaOps.Signals.RuntimeAgent/StellaOps.Signals.RuntimeAgent.csproj" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="StellaOpsReleaseVersion">
|
||||
<Version>1.0.0-alpha1</Version>
|
||||
<InformationalVersion>1.0.0-alpha1</InformationalVersion>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user