Add JobEngine deployment compatibility store and scheduler persistence

Introduce PostgresDeploymentCompatibilityStore with migration 011, in-memory
fallback, deployment endpoints, and Postgres fixture for integration tests.
Update Scheduler repository with connection policy adoption.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
master
2026-04-06 08:52:50 +03:00
parent 285f761c77
commit 59eca36429
19 changed files with 1599 additions and 396 deletions

View File

@@ -40,6 +40,20 @@ public static class ServiceCollectionExtensions
.Bind(configuration.GetSection(JobEngineServiceOptions.SectionName))
.PostConfigure(options =>
{
var explicitConnection = configuration[$"{JobEngineServiceOptions.SectionName}:Database:ConnectionString"];
if (!string.IsNullOrWhiteSpace(explicitConnection))
{
options.Database.ConnectionString = explicitConnection;
return;
}
var orchestratorConnection = configuration["Orchestrator:Database:ConnectionString"];
if (ShouldReplaceConnectionString(options.Database.ConnectionString)
&& !string.IsNullOrWhiteSpace(orchestratorConnection))
{
options.Database.ConnectionString = orchestratorConnection;
}
var fallbackConnection =
configuration.GetConnectionString("Default")
?? configuration["ConnectionStrings:Default"];