feat: persist workflow controls and settle stopped branches
This commit is contained in:
@@ -55,6 +55,12 @@ func (r *WorkflowRuntime) advanceClock(ctx context.Context, tx *sql.Tx, g *workf
|
||||
if row.view.State != weave.StepActive && row.view.State != weave.StepWaiting {
|
||||
return false, deleteWorkflowClock(ctx, tx, g, row)
|
||||
}
|
||||
if g.view.StopKind != nil {
|
||||
if err := saveWorkflowAdvance(ctx, tx, g, now); err != nil {
|
||||
return false, err
|
||||
}
|
||||
return false, deleteWorkflowClock(ctx, tx, g, row)
|
||||
}
|
||||
var activated time.Time
|
||||
if err := tx.QueryRowContext(ctx, `SELECT created_at FROM weave_activations WHERE namespace_id=? AND id=? AND workflow_id=? AND step_id=?`, c.ns, checkpoint.ActivationID, c.workflow, step).Scan(&activated); err != nil {
|
||||
return false, err
|
||||
|
||||
Reference in New Issue
Block a user