Class PostgreSqlFlowOrchestratorMigrator
- Namespace
- FlowOrchestrator.PostgreSQL
- Assembly
- FlowOrchestrator.PostgreSQL.dll
Hosted service that runs idempotent PostgreSQL schema migrations at startup.
Creates the flow_definitions, flow_runs, flow_steps,
flow_step_attempts, flow_outputs, and related tables if they do not already exist.
Safe to run on every startup — all statements use IF NOT EXISTS guards.
public sealed class PostgreSqlFlowOrchestratorMigrator : IHostedService
- Inheritance
-
PostgreSqlFlowOrchestratorMigrator
- Implements
- Inherited Members
Constructors
PostgreSqlFlowOrchestratorMigrator(string, ILogger<PostgreSqlFlowOrchestratorMigrator>)
public PostgreSqlFlowOrchestratorMigrator(string connectionString, ILogger<PostgreSqlFlowOrchestratorMigrator> logger)
Parameters
connectionStringstringloggerILogger<PostgreSqlFlowOrchestratorMigrator>
Methods
StartAsync(CancellationToken)
Triggered when the application host is ready to start the service.
public Task StartAsync(CancellationToken cancellationToken)
Parameters
cancellationTokenCancellationTokenIndicates that the start process has been aborted.
Returns
StopAsync(CancellationToken)
Triggered when the application host is performing a graceful shutdown.
public Task StopAsync(CancellationToken cancellationToken)
Parameters
cancellationTokenCancellationTokenIndicates that the shutdown process should no longer be graceful.