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:
@@ -9,6 +9,7 @@ using StellaOps.Cryptography.Plugin.SmSoft;
|
||||
using System.Linq;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
using StellaOps.Router.AspNet;
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Services.AddLogging();
|
||||
@@ -31,6 +32,13 @@ builder.Services.AddEndpointsApiExplorer();
|
||||
|
||||
builder.Services.AddStellaOpsCors(builder.Environment, builder.Configuration);
|
||||
|
||||
// Stella Router integration
|
||||
var routerEnabled = builder.Services.AddRouterMicroservice(
|
||||
builder.Configuration,
|
||||
serviceName: "smremote",
|
||||
version: System.Reflection.CustomAttributeExtensions.GetCustomAttribute<System.Reflection.AssemblyInformationalVersionAttribute>(System.Reflection.Assembly.GetExecutingAssembly())?.InformationalVersion ?? "1.0.0",
|
||||
routerOptionsSection: "Router");
|
||||
|
||||
if (builder.Environment.IsDevelopment())
|
||||
{
|
||||
builder.TryAddStellaOpsLocalBinding("smremote");
|
||||
@@ -42,6 +50,7 @@ if (app.Environment.IsDevelopment())
|
||||
}
|
||||
|
||||
app.UseStellaOpsCors();
|
||||
app.TryUseStellaRouter(routerEnabled);
|
||||
|
||||
app.MapGet("/health", () => Results.Ok(new SmHealthResponse("ok")));
|
||||
|
||||
@@ -162,6 +171,7 @@ app.MapPost("/verify", async (VerifyRequest req, ICryptoProviderRegistry registr
|
||||
return Results.Ok(new VerifyResponse(ok));
|
||||
});
|
||||
|
||||
app.TryRefreshStellaRouterEndpoints(routerEnabled);
|
||||
app.Run();
|
||||
|
||||
static ICryptoProvider ResolveProvider(ICryptoProviderRegistry registry)
|
||||
@@ -285,3 +295,4 @@ public sealed record VerifyResponse([property: JsonPropertyName("valid")] bool V
|
||||
|
||||
// Expose Program class for WebApplicationFactory in tests
|
||||
public partial class Program;
|
||||
|
||||
|
||||
@@ -12,4 +12,8 @@
|
||||
<ProjectReference Include="..\\..\\__Libraries\\StellaOps.Cryptography.DependencyInjection\\StellaOps.Cryptography.DependencyInjection.csproj" />
|
||||
<ProjectReference Include="..\\..\\Authority\\StellaOps.Authority\\StellaOps.Auth.ServerIntegration\\StellaOps.Auth.ServerIntegration.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