@shipfox/api-workflows 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +2 -0
- package/.turbo/turbo-type$colon$emit.log +1 -0
- package/.turbo/turbo-type.log +1 -0
- package/CHANGELOG.md +311 -0
- package/LICENSE +21 -0
- package/dist/core/agent-tool-capability-warning.d.ts +7 -0
- package/dist/core/agent-tool-capability-warning.d.ts.map +1 -0
- package/dist/core/agent-tool-capability-warning.js +149 -0
- package/dist/core/agent-tool-capability-warning.js.map +1 -0
- package/dist/core/agent-tools.d.ts +51 -0
- package/dist/core/agent-tools.d.ts.map +1 -0
- package/dist/core/agent-tools.js +296 -0
- package/dist/core/agent-tools.js.map +1 -0
- package/dist/core/checkout.d.ts +29 -0
- package/dist/core/checkout.d.ts.map +1 -0
- package/dist/core/checkout.js +42 -0
- package/dist/core/checkout.js.map +1 -0
- package/dist/core/condition-trace.d.ts +13 -0
- package/dist/core/condition-trace.d.ts.map +1 -0
- package/dist/core/condition-trace.js +51 -0
- package/dist/core/condition-trace.js.map +1 -0
- package/dist/core/entities/index.d.ts +5 -0
- package/dist/core/entities/index.d.ts.map +1 -0
- package/dist/core/entities/index.js +3 -0
- package/dist/core/entities/index.js.map +1 -0
- package/dist/core/entities/job-execution.d.ts +30 -0
- package/dist/core/entities/job-execution.d.ts.map +1 -0
- package/dist/core/entities/job-execution.js +3 -0
- package/dist/core/entities/job-execution.js.map +1 -0
- package/dist/core/entities/job-listener-event.d.ts +15 -0
- package/dist/core/entities/job-listener-event.d.ts.map +1 -0
- package/dist/core/entities/job-listener-event.js +3 -0
- package/dist/core/entities/job-listener-event.js.map +1 -0
- package/dist/core/entities/job.d.ts +54 -0
- package/dist/core/entities/job.d.ts.map +1 -0
- package/dist/core/entities/job.js +29 -0
- package/dist/core/entities/job.js.map +1 -0
- package/dist/core/entities/step.d.ts +86 -0
- package/dist/core/entities/step.d.ts.map +1 -0
- package/dist/core/entities/step.js +12 -0
- package/dist/core/entities/step.js.map +1 -0
- package/dist/core/entities/workflow-run-attempt.d.ts +20 -0
- package/dist/core/entities/workflow-run-attempt.d.ts.map +1 -0
- package/dist/core/entities/workflow-run-attempt.js +3 -0
- package/dist/core/entities/workflow-run-attempt.js.map +1 -0
- package/dist/core/entities/workflow-run.d.ts +66 -0
- package/dist/core/entities/workflow-run.d.ts.map +1 -0
- package/dist/core/entities/workflow-run.js +10 -0
- package/dist/core/entities/workflow-run.js.map +1 -0
- package/dist/core/errors.d.ts +85 -0
- package/dist/core/errors.d.ts.map +1 -0
- package/dist/core/errors.js +134 -0
- package/dist/core/errors.js.map +1 -0
- package/dist/core/index.d.ts +14 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +9 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/job-execution-outcome.d.ts +29 -0
- package/dist/core/job-execution-outcome.d.ts.map +1 -0
- package/dist/core/job-execution-outcome.js +31 -0
- package/dist/core/job-execution-outcome.js.map +1 -0
- package/dist/core/job-execution.d.ts +37 -0
- package/dist/core/job-execution.d.ts.map +1 -0
- package/dist/core/job-execution.js +425 -0
- package/dist/core/job-execution.js.map +1 -0
- package/dist/core/job-transition/decide-job-activation.d.ts +29 -0
- package/dist/core/job-transition/decide-job-activation.d.ts.map +1 -0
- package/dist/core/job-transition/decide-job-activation.js +51 -0
- package/dist/core/job-transition/decide-job-activation.js.map +1 -0
- package/dist/core/job-transition/derive-job-execution-outputs.d.ts +18 -0
- package/dist/core/job-transition/derive-job-execution-outputs.d.ts.map +1 -0
- package/dist/core/job-transition/derive-job-execution-outputs.js +23 -0
- package/dist/core/job-transition/derive-job-execution-outputs.js.map +1 -0
- package/dist/core/job-transition/derive-job-success.d.ts +16 -0
- package/dist/core/job-transition/derive-job-success.d.ts.map +1 -0
- package/dist/core/job-transition/derive-job-success.js +47 -0
- package/dist/core/job-transition/derive-job-success.js.map +1 -0
- package/dist/core/job-transition/index.d.ts +5 -0
- package/dist/core/job-transition/index.d.ts.map +1 -0
- package/dist/core/job-transition/index.js +6 -0
- package/dist/core/job-transition/index.js.map +1 -0
- package/dist/core/job-transition/runtime-completion-status-for-job.d.ts +4 -0
- package/dist/core/job-transition/runtime-completion-status-for-job.d.ts.map +1 -0
- package/dist/core/job-transition/runtime-completion-status-for-job.js +8 -0
- package/dist/core/job-transition/runtime-completion-status-for-job.js.map +1 -0
- package/dist/core/listener-execution-materialization.d.ts +30 -0
- package/dist/core/listener-execution-materialization.d.ts.map +1 -0
- package/dist/core/listener-execution-materialization.js +87 -0
- package/dist/core/listener-execution-materialization.js.map +1 -0
- package/dist/core/run-workflow.d.ts +11 -0
- package/dist/core/run-workflow.d.ts.map +1 -0
- package/dist/core/run-workflow.js +28 -0
- package/dist/core/run-workflow.js.map +1 -0
- package/dist/core/source-control.d.ts +5 -0
- package/dist/core/source-control.d.ts.map +1 -0
- package/dist/core/source-control.js +19 -0
- package/dist/core/source-control.js.map +1 -0
- package/dist/core/step-config/agent.d.ts +49 -0
- package/dist/core/step-config/agent.d.ts.map +1 -0
- package/dist/core/step-config/agent.js +337 -0
- package/dist/core/step-config/agent.js.map +1 -0
- package/dist/core/step-config/assemble-run-context.d.ts +94 -0
- package/dist/core/step-config/assemble-run-context.d.ts.map +1 -0
- package/dist/core/step-config/assemble-run-context.js +393 -0
- package/dist/core/step-config/assemble-run-context.js.map +1 -0
- package/dist/core/step-config/complete-step-dispatch-config.d.ts +13 -0
- package/dist/core/step-config/complete-step-dispatch-config.d.ts.map +1 -0
- package/dist/core/step-config/complete-step-dispatch-config.js +38 -0
- package/dist/core/step-config/complete-step-dispatch-config.js.map +1 -0
- package/dist/core/step-config/fields.d.ts +38 -0
- package/dist/core/step-config/fields.d.ts.map +1 -0
- package/dist/core/step-config/fields.js +72 -0
- package/dist/core/step-config/fields.js.map +1 -0
- package/dist/core/step-config/index.d.ts +8 -0
- package/dist/core/step-config/index.d.ts.map +1 -0
- package/dist/core/step-config/index.js +7 -0
- package/dist/core/step-config/index.js.map +1 -0
- package/dist/core/step-config/materialize-job-execution-steps.d.ts +35 -0
- package/dist/core/step-config/materialize-job-execution-steps.d.ts.map +1 -0
- package/dist/core/step-config/materialize-job-execution-steps.js +92 -0
- package/dist/core/step-config/materialize-job-execution-steps.js.map +1 -0
- package/dist/core/step-config/materialize-workflow-model.d.ts +42 -0
- package/dist/core/step-config/materialize-workflow-model.d.ts.map +1 -0
- package/dist/core/step-config/materialize-workflow-model.js +96 -0
- package/dist/core/step-config/materialize-workflow-model.js.map +1 -0
- package/dist/core/step-config/resolve-job-execution-name.d.ts +18 -0
- package/dist/core/step-config/resolve-job-execution-name.d.ts.map +1 -0
- package/dist/core/step-config/resolve-job-execution-name.js +36 -0
- package/dist/core/step-config/resolve-job-execution-name.js.map +1 -0
- package/dist/core/step-config/resolve-step-config.d.ts +33 -0
- package/dist/core/step-config/resolve-step-config.d.ts.map +1 -0
- package/dist/core/step-config/resolve-step-config.js +164 -0
- package/dist/core/step-config/resolve-step-config.js.map +1 -0
- package/dist/core/step-config/run.d.ts +39 -0
- package/dist/core/step-config/run.d.ts.map +1 -0
- package/dist/core/step-config/run.js +360 -0
- package/dist/core/step-config/run.js.map +1 -0
- package/dist/core/step-config/workflow-evaluation-context.d.ts +6 -0
- package/dist/core/step-config/workflow-evaluation-context.d.ts.map +1 -0
- package/dist/core/step-config/workflow-evaluation-context.js +3 -0
- package/dist/core/step-config/workflow-evaluation-context.js.map +1 -0
- package/dist/core/step-transition/apply-step-transition.d.ts +26 -0
- package/dist/core/step-transition/apply-step-transition.d.ts.map +1 -0
- package/dist/core/step-transition/apply-step-transition.js +141 -0
- package/dist/core/step-transition/apply-step-transition.js.map +1 -0
- package/dist/core/step-transition/decide-step-transition.d.ts +71 -0
- package/dist/core/step-transition/decide-step-transition.d.ts.map +1 -0
- package/dist/core/step-transition/decide-step-transition.js +110 -0
- package/dist/core/step-transition/decide-step-transition.js.map +1 -0
- package/dist/core/step-transition/evaluate-gate.d.ts +28 -0
- package/dist/core/step-transition/evaluate-gate.d.ts.map +1 -0
- package/dist/core/step-transition/evaluate-gate.js +159 -0
- package/dist/core/step-transition/evaluate-gate.js.map +1 -0
- package/dist/core/step-transition/read-step-outputs.d.ts +3 -0
- package/dist/core/step-transition/read-step-outputs.d.ts.map +1 -0
- package/dist/core/step-transition/read-step-outputs.js +24 -0
- package/dist/core/step-transition/read-step-outputs.js.map +1 -0
- package/dist/core/workflow-run-creation.d.ts +43 -0
- package/dist/core/workflow-run-creation.d.ts.map +1 -0
- package/dist/core/workflow-run-creation.js +80 -0
- package/dist/core/workflow-run-creation.js.map +1 -0
- package/dist/core/workflow-scheduling/index.d.ts +5 -0
- package/dist/core/workflow-scheduling/index.d.ts.map +1 -0
- package/dist/core/workflow-scheduling/index.js +4 -0
- package/dist/core/workflow-scheduling/index.js.map +1 -0
- package/dist/core/workflow-scheduling/run-progress.d.ts +20 -0
- package/dist/core/workflow-scheduling/run-progress.d.ts.map +1 -0
- package/dist/core/workflow-scheduling/run-progress.js +40 -0
- package/dist/core/workflow-scheduling/run-progress.js.map +1 -0
- package/dist/core/workflow-scheduling/runtime-dag.d.ts +10 -0
- package/dist/core/workflow-scheduling/runtime-dag.d.ts.map +1 -0
- package/dist/core/workflow-scheduling/runtime-dag.js +3 -0
- package/dist/core/workflow-scheduling/runtime-dag.js.map +1 -0
- package/dist/core/workflow-scheduling/runtime-scheduling-command.d.ts +16 -0
- package/dist/core/workflow-scheduling/runtime-scheduling-command.d.ts.map +1 -0
- package/dist/core/workflow-scheduling/runtime-scheduling-command.js +3 -0
- package/dist/core/workflow-scheduling/runtime-scheduling-command.js.map +1 -0
- package/dist/core/workflow-scheduling/schedule-runtime-dag.d.ts +9 -0
- package/dist/core/workflow-scheduling/schedule-runtime-dag.d.ts.map +1 -0
- package/dist/core/workflow-scheduling/schedule-runtime-dag.js +72 -0
- package/dist/core/workflow-scheduling/schedule-runtime-dag.js.map +1 -0
- package/dist/db/db.d.ts +4959 -0
- package/dist/db/db.d.ts.map +1 -0
- package/dist/db/db.js +37 -0
- package/dist/db/db.js.map +1 -0
- package/dist/db/index.d.ts +9 -0
- package/dist/db/index.d.ts.map +1 -0
- package/dist/db/index.js +10 -0
- package/dist/db/index.js.map +1 -0
- package/dist/db/job-listener-events.d.ts +18 -0
- package/dist/db/job-listener-events.d.ts.map +1 -0
- package/dist/db/job-listener-events.js +59 -0
- package/dist/db/job-listener-events.js.map +1 -0
- package/dist/db/job-listeners.d.ts +55 -0
- package/dist/db/job-listeners.d.ts.map +1 -0
- package/dist/db/job-listeners.js +358 -0
- package/dist/db/job-listeners.js.map +1 -0
- package/dist/db/outbox-writes.d.ts +12 -0
- package/dist/db/outbox-writes.d.ts.map +1 -0
- package/dist/db/outbox-writes.js +20 -0
- package/dist/db/outbox-writes.js.map +1 -0
- package/dist/db/runner-lease-table.d.ts +469 -0
- package/dist/db/runner-lease-table.d.ts.map +1 -0
- package/dist/db/runner-lease-table.js +42 -0
- package/dist/db/runner-lease-table.js.map +1 -0
- package/dist/db/schema/common.d.ts +2 -0
- package/dist/db/schema/common.d.ts.map +1 -0
- package/dist/db/schema/common.js +4 -0
- package/dist/db/schema/common.js.map +1 -0
- package/dist/db/schema/job-executions.d.ts +311 -0
- package/dist/db/schema/job-executions.d.ts.map +1 -0
- package/dist/db/schema/job-executions.js +76 -0
- package/dist/db/schema/job-executions.js.map +1 -0
- package/dist/db/schema/job-listener-events.d.ts +200 -0
- package/dist/db/schema/job-listener-events.d.ts.map +1 -0
- package/dist/db/schema/job-listener-events.js +50 -0
- package/dist/db/schema/job-listener-events.js.map +1 -0
- package/dist/db/schema/jobs.d.ts +542 -0
- package/dist/db/schema/jobs.d.ts.map +1 -0
- package/dist/db/schema/jobs.js +121 -0
- package/dist/db/schema/jobs.js.map +1 -0
- package/dist/db/schema/outbox.d.ts +195 -0
- package/dist/db/schema/outbox.d.ts.map +1 -0
- package/dist/db/schema/outbox.js +5 -0
- package/dist/db/schema/outbox.js.map +1 -0
- package/dist/db/schema/step-attempts.d.ts +330 -0
- package/dist/db/schema/step-attempts.d.ts.map +1 -0
- package/dist/db/schema/step-attempts.js +80 -0
- package/dist/db/schema/step-attempts.js.map +1 -0
- package/dist/db/schema/steps.d.ts +352 -0
- package/dist/db/schema/steps.d.ts.map +1 -0
- package/dist/db/schema/steps.js +80 -0
- package/dist/db/schema/steps.js.map +1 -0
- package/dist/db/schema/workflow-run-attempts.d.ts +239 -0
- package/dist/db/schema/workflow-run-attempts.d.ts.map +1 -0
- package/dist/db/schema/workflow-run-attempts.js +53 -0
- package/dist/db/schema/workflow-run-attempts.js.map +1 -0
- package/dist/db/schema/workflow-runs.d.ts +360 -0
- package/dist/db/schema/workflow-runs.d.ts.map +1 -0
- package/dist/db/schema/workflow-runs.js +85 -0
- package/dist/db/schema/workflow-runs.js.map +1 -0
- package/dist/db/workflow-runs/job-executions.d.ts +49 -0
- package/dist/db/workflow-runs/job-executions.d.ts.map +1 -0
- package/dist/db/workflow-runs/job-executions.js +271 -0
- package/dist/db/workflow-runs/job-executions.js.map +1 -0
- package/dist/db/workflow-runs/jobs.d.ts +60 -0
- package/dist/db/workflow-runs/jobs.d.ts.map +1 -0
- package/dist/db/workflow-runs/jobs.js +288 -0
- package/dist/db/workflow-runs/jobs.js.map +1 -0
- package/dist/db/workflow-runs/outbox.d.ts +20 -0
- package/dist/db/workflow-runs/outbox.d.ts.map +1 -0
- package/dist/db/workflow-runs/outbox.js +68 -0
- package/dist/db/workflow-runs/outbox.js.map +1 -0
- package/dist/db/workflow-runs/queries.d.ts +71 -0
- package/dist/db/workflow-runs/queries.d.ts.map +1 -0
- package/dist/db/workflow-runs/queries.js +253 -0
- package/dist/db/workflow-runs/queries.js.map +1 -0
- package/dist/db/workflow-runs/run-create.d.ts +32 -0
- package/dist/db/workflow-runs/run-create.d.ts.map +1 -0
- package/dist/db/workflow-runs/run-create.js +288 -0
- package/dist/db/workflow-runs/run-create.js.map +1 -0
- package/dist/db/workflow-runs/run-graph.d.ts +27 -0
- package/dist/db/workflow-runs/run-graph.d.ts.map +1 -0
- package/dist/db/workflow-runs/run-graph.js +63 -0
- package/dist/db/workflow-runs/run-graph.js.map +1 -0
- package/dist/db/workflow-runs/run-rerun.d.ts +8 -0
- package/dist/db/workflow-runs/run-rerun.d.ts.map +1 -0
- package/dist/db/workflow-runs/run-rerun.js +207 -0
- package/dist/db/workflow-runs/run-rerun.js.map +1 -0
- package/dist/db/workflow-runs/run-status.d.ts +24 -0
- package/dist/db/workflow-runs/run-status.d.ts.map +1 -0
- package/dist/db/workflow-runs/run-status.js +249 -0
- package/dist/db/workflow-runs/run-status.js.map +1 -0
- package/dist/db/workflow-runs/runs.d.ts +7 -0
- package/dist/db/workflow-runs/runs.d.ts.map +1 -0
- package/dist/db/workflow-runs/runs.js +5 -0
- package/dist/db/workflow-runs/runs.js.map +1 -0
- package/dist/db/workflow-runs/shared.d.ts +24 -0
- package/dist/db/workflow-runs/shared.d.ts.map +1 -0
- package/dist/db/workflow-runs/shared.js +50 -0
- package/dist/db/workflow-runs/shared.js.map +1 -0
- package/dist/db/workflow-runs/steps.d.ts +83 -0
- package/dist/db/workflow-runs/steps.d.ts.map +1 -0
- package/dist/db/workflow-runs/steps.js +246 -0
- package/dist/db/workflow-runs/steps.js.map +1 -0
- package/dist/db/workflow-runs.d.ts +12 -0
- package/dist/db/workflow-runs.d.ts.map +1 -0
- package/dist/db/workflow-runs.js +8 -0
- package/dist/db/workflow-runs.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +54 -0
- package/dist/index.js.map +1 -0
- package/dist/metrics/index.d.ts +2 -0
- package/dist/metrics/index.d.ts.map +1 -0
- package/dist/metrics/index.js +3 -0
- package/dist/metrics/index.js.map +1 -0
- package/dist/metrics/instance.d.ts +20 -0
- package/dist/metrics/instance.d.ts.map +1 -0
- package/dist/metrics/instance.js +127 -0
- package/dist/metrics/instance.js.map +1 -0
- package/dist/metrics/service.d.ts +2 -0
- package/dist/metrics/service.d.ts.map +1 -0
- package/dist/metrics/service.js +30 -0
- package/dist/metrics/service.js.map +1 -0
- package/dist/presentation/dto/checkout-token.d.ts +6 -0
- package/dist/presentation/dto/checkout-token.d.ts.map +1 -0
- package/dist/presentation/dto/checkout-token.js +74 -0
- package/dist/presentation/dto/checkout-token.js.map +1 -0
- package/dist/presentation/dto/index.d.ts +4 -0
- package/dist/presentation/dto/index.d.ts.map +1 -0
- package/dist/presentation/dto/index.js +5 -0
- package/dist/presentation/dto/index.js.map +1 -0
- package/dist/presentation/dto/job.d.ts +6 -0
- package/dist/presentation/dto/job.d.ts.map +1 -0
- package/dist/presentation/dto/job.js +59 -0
- package/dist/presentation/dto/job.js.map +1 -0
- package/dist/presentation/dto/step.d.ts +6 -0
- package/dist/presentation/dto/step.d.ts.map +1 -0
- package/dist/presentation/dto/step.js +162 -0
- package/dist/presentation/dto/step.js.map +1 -0
- package/dist/presentation/dto/workflow-run.d.ts +6 -0
- package/dist/presentation/dto/workflow-run.d.ts.map +1 -0
- package/dist/presentation/dto/workflow-run.js +35 -0
- package/dist/presentation/dto/workflow-run.js.map +1 -0
- package/dist/presentation/index.d.ts +3 -0
- package/dist/presentation/index.d.ts.map +1 -0
- package/dist/presentation/index.js +4 -0
- package/dist/presentation/index.js.map +1 -0
- package/dist/presentation/routes/agent-runtime-config.d.ts +2 -0
- package/dist/presentation/routes/agent-runtime-config.d.ts.map +1 -0
- package/dist/presentation/routes/agent-runtime-config.js +71 -0
- package/dist/presentation/routes/agent-runtime-config.js.map +1 -0
- package/dist/presentation/routes/cancel-run.d.ts +2 -0
- package/dist/presentation/routes/cancel-run.d.ts.map +1 -0
- package/dist/presentation/routes/cancel-run.js +46 -0
- package/dist/presentation/routes/cancel-run.js.map +1 -0
- package/dist/presentation/routes/checkout-token.d.ts +2 -0
- package/dist/presentation/routes/checkout-token.d.ts.map +1 -0
- package/dist/presentation/routes/checkout-token.js +64 -0
- package/dist/presentation/routes/checkout-token.js.map +1 -0
- package/dist/presentation/routes/get-run-aggregates.d.ts +2 -0
- package/dist/presentation/routes/get-run-aggregates.d.ts.map +1 -0
- package/dist/presentation/routes/get-run-aggregates.js +60 -0
- package/dist/presentation/routes/get-run-aggregates.js.map +1 -0
- package/dist/presentation/routes/get-run.d.ts +2 -0
- package/dist/presentation/routes/get-run.d.ts.map +1 -0
- package/dist/presentation/routes/get-run.js +60 -0
- package/dist/presentation/routes/get-run.js.map +1 -0
- package/dist/presentation/routes/get-step-secrets.d.ts +2 -0
- package/dist/presentation/routes/get-step-secrets.d.ts.map +1 -0
- package/dist/presentation/routes/get-step-secrets.js +115 -0
- package/dist/presentation/routes/get-step-secrets.js.map +1 -0
- package/dist/presentation/routes/index.d.ts +4 -0
- package/dist/presentation/routes/index.d.ts.map +1 -0
- package/dist/presentation/routes/index.js +41 -0
- package/dist/presentation/routes/index.js.map +1 -0
- package/dist/presentation/routes/leased-step.d.ts +14 -0
- package/dist/presentation/routes/leased-step.d.ts.map +1 -0
- package/dist/presentation/routes/leased-step.js +50 -0
- package/dist/presentation/routes/leased-step.js.map +1 -0
- package/dist/presentation/routes/list-run-attempts.d.ts +2 -0
- package/dist/presentation/routes/list-run-attempts.d.ts.map +1 -0
- package/dist/presentation/routes/list-run-attempts.js +35 -0
- package/dist/presentation/routes/list-run-attempts.js.map +1 -0
- package/dist/presentation/routes/list-runs.d.ts +2 -0
- package/dist/presentation/routes/list-runs.d.ts.map +1 -0
- package/dist/presentation/routes/list-runs.js +70 -0
- package/dist/presentation/routes/list-runs.js.map +1 -0
- package/dist/presentation/routes/next-step.d.ts +2 -0
- package/dist/presentation/routes/next-step.d.ts.map +1 -0
- package/dist/presentation/routes/next-step.js +65 -0
- package/dist/presentation/routes/next-step.js.map +1 -0
- package/dist/presentation/routes/report-step.d.ts +2 -0
- package/dist/presentation/routes/report-step.d.ts.map +1 -0
- package/dist/presentation/routes/report-step.js +73 -0
- package/dist/presentation/routes/report-step.js.map +1 -0
- package/dist/presentation/routes/require-accessible-run.d.ts +7 -0
- package/dist/presentation/routes/require-accessible-run.d.ts.map +1 -0
- package/dist/presentation/routes/require-accessible-run.js +25 -0
- package/dist/presentation/routes/require-accessible-run.js.map +1 -0
- package/dist/presentation/routes/rerun-run.d.ts +2 -0
- package/dist/presentation/routes/rerun-run.d.ts.map +1 -0
- package/dist/presentation/routes/rerun-run.js +56 -0
- package/dist/presentation/routes/rerun-run.js.map +1 -0
- package/dist/presentation/subscribers/index.d.ts +8 -0
- package/dist/presentation/subscribers/index.d.ts.map +1 -0
- package/dist/presentation/subscribers/index.js +9 -0
- package/dist/presentation/subscribers/index.js.map +1 -0
- package/dist/presentation/subscribers/on-job-event-delivered.d.ts +3 -0
- package/dist/presentation/subscribers/on-job-event-delivered.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-job-event-delivered.js +24 -0
- package/dist/presentation/subscribers/on-job-event-delivered.js.map +1 -0
- package/dist/presentation/subscribers/on-job-steps-settled.d.ts +3 -0
- package/dist/presentation/subscribers/on-job-steps-settled.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-job-steps-settled.js +36 -0
- package/dist/presentation/subscribers/on-job-steps-settled.js.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-claimed.d.ts +3 -0
- package/dist/presentation/subscribers/on-runner-job-claimed.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-claimed.js +20 -0
- package/dist/presentation/subscribers/on-runner-job-claimed.js.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-lease-expired.d.ts +3 -0
- package/dist/presentation/subscribers/on-runner-job-lease-expired.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-lease-expired.js +35 -0
- package/dist/presentation/subscribers/on-runner-job-lease-expired.js.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-queued.d.ts +3 -0
- package/dist/presentation/subscribers/on-runner-job-queued.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-runner-job-queued.js +20 -0
- package/dist/presentation/subscribers/on-runner-job-queued.js.map +1 -0
- package/dist/presentation/subscribers/on-workflow-run-attempt-created.d.ts +3 -0
- package/dist/presentation/subscribers/on-workflow-run-attempt-created.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-workflow-run-attempt-created.js +35 -0
- package/dist/presentation/subscribers/on-workflow-run-attempt-created.js.map +1 -0
- package/dist/presentation/subscribers/on-workflow-run-cancelled.d.ts +3 -0
- package/dist/presentation/subscribers/on-workflow-run-cancelled.d.ts.map +1 -0
- package/dist/presentation/subscribers/on-workflow-run-cancelled.js +25 -0
- package/dist/presentation/subscribers/on-workflow-run-cancelled.js.map +1 -0
- package/dist/temporal/activities/index.d.ts +23 -0
- package/dist/temporal/activities/index.d.ts.map +1 -0
- package/dist/temporal/activities/index.js +26 -0
- package/dist/temporal/activities/index.js.map +1 -0
- package/dist/temporal/activities/orchestration-activities.d.ts +130 -0
- package/dist/temporal/activities/orchestration-activities.d.ts.map +1 -0
- package/dist/temporal/activities/orchestration-activities.js +188 -0
- package/dist/temporal/activities/orchestration-activities.js.map +1 -0
- package/dist/temporal/constants.d.ts +7 -0
- package/dist/temporal/constants.d.ts.map +1 -0
- package/dist/temporal/constants.js +8 -0
- package/dist/temporal/constants.js.map +1 -0
- package/dist/temporal/index.d.ts +3 -0
- package/dist/temporal/index.d.ts.map +1 -0
- package/dist/temporal/index.js +4 -0
- package/dist/temporal/index.js.map +1 -0
- package/dist/temporal/workflow-not-found.d.ts +2 -0
- package/dist/temporal/workflow-not-found.d.ts.map +1 -0
- package/dist/temporal/workflow-not-found.js +10 -0
- package/dist/temporal/workflow-not-found.js.map +1 -0
- package/dist/temporal/workflows/deadline.d.ts +3 -0
- package/dist/temporal/workflows/deadline.d.ts.map +1 -0
- package/dist/temporal/workflows/deadline.js +8 -0
- package/dist/temporal/workflows/deadline.js.map +1 -0
- package/dist/temporal/workflows/index.d.ts +4 -0
- package/dist/temporal/workflows/index.d.ts.map +1 -0
- package/dist/temporal/workflows/index.js +5 -0
- package/dist/temporal/workflows/index.js.map +1 -0
- package/dist/temporal/workflows/job-execution-orchestration.d.ts +27 -0
- package/dist/temporal/workflows/job-execution-orchestration.d.ts.map +1 -0
- package/dist/temporal/workflows/job-execution-orchestration.js +265 -0
- package/dist/temporal/workflows/job-execution-orchestration.js.map +1 -0
- package/dist/temporal/workflows/job-listener-orchestration.d.ts +40 -0
- package/dist/temporal/workflows/job-listener-orchestration.d.ts.map +1 -0
- package/dist/temporal/workflows/job-listener-orchestration.js +332 -0
- package/dist/temporal/workflows/job-listener-orchestration.js.map +1 -0
- package/dist/temporal/workflows/run-orchestration.d.ts +8 -0
- package/dist/temporal/workflows/run-orchestration.d.ts.map +1 -0
- package/dist/temporal/workflows/run-orchestration.js +243 -0
- package/dist/temporal/workflows/run-orchestration.js.map +1 -0
- package/dist/temporal/workflows/test-env.d.ts +114 -0
- package/dist/temporal/workflows/test-env.d.ts.map +1 -0
- package/dist/temporal/workflows/test-env.js +323 -0
- package/dist/temporal/workflows/test-env.js.map +1 -0
- package/dist/tsconfig.test.tsbuildinfo +1 -0
- package/drizzle/0000_initial.sql +211 -0
- package/drizzle/0001_agent_tool_materialization.sql +1 -0
- package/drizzle/meta/0000_snapshot.json +1613 -0
- package/drizzle/meta/_journal.json +20 -0
- package/drizzle.config.ts +7 -0
- package/package.json +91 -0
- package/src/core/README.md +79 -0
- package/src/core/agent-tool-capability-warning.test.ts +280 -0
- package/src/core/agent-tool-capability-warning.ts +200 -0
- package/src/core/agent-tools.ts +422 -0
- package/src/core/checkout.test.ts +112 -0
- package/src/core/checkout.ts +63 -0
- package/src/core/condition-trace.ts +64 -0
- package/src/core/entities/index.ts +9 -0
- package/src/core/entities/job-execution.ts +32 -0
- package/src/core/entities/job-listener-event.ts +15 -0
- package/src/core/entities/job.ts +91 -0
- package/src/core/entities/step.ts +126 -0
- package/src/core/entities/workflow-run-attempt.ts +21 -0
- package/src/core/entities/workflow-run.ts +94 -0
- package/src/core/errors.test.ts +45 -0
- package/src/core/errors.ts +209 -0
- package/src/core/index.ts +54 -0
- package/src/core/job-execution-outcome.ts +64 -0
- package/src/core/job-execution.test.ts +1560 -0
- package/src/core/job-execution.ts +581 -0
- package/src/core/job-transition/decide-job-activation.test.ts +196 -0
- package/src/core/job-transition/decide-job-activation.ts +79 -0
- package/src/core/job-transition/derive-job-execution-outputs.ts +41 -0
- package/src/core/job-transition/derive-job-success.test.ts +133 -0
- package/src/core/job-transition/derive-job-success.ts +67 -0
- package/src/core/job-transition/index.ts +11 -0
- package/src/core/job-transition/runtime-completion-status-for-job.ts +14 -0
- package/src/core/listener-execution-materialization.test.ts +49 -0
- package/src/core/listener-execution-materialization.ts +162 -0
- package/src/core/run-workflow.test.ts +229 -0
- package/src/core/run-workflow.ts +41 -0
- package/src/core/source-control.test.ts +17 -0
- package/src/core/source-control.ts +22 -0
- package/src/core/step-config/agent.ts +459 -0
- package/src/core/step-config/assemble-run-context.test.ts +1021 -0
- package/src/core/step-config/assemble-run-context.ts +535 -0
- package/src/core/step-config/complete-step-dispatch-config.test.ts +354 -0
- package/src/core/step-config/complete-step-dispatch-config.ts +40 -0
- package/src/core/step-config/fields.ts +111 -0
- package/src/core/step-config/index.ts +41 -0
- package/src/core/step-config/materialize-job-execution-steps.test.ts +494 -0
- package/src/core/step-config/materialize-job-execution-steps.ts +136 -0
- package/src/core/step-config/materialize-workflow-model.test.ts +1214 -0
- package/src/core/step-config/materialize-workflow-model.ts +140 -0
- package/src/core/step-config/resolve-job-execution-name.test.ts +94 -0
- package/src/core/step-config/resolve-job-execution-name.ts +51 -0
- package/src/core/step-config/resolve-step-config.ts +199 -0
- package/src/core/step-config/run.ts +467 -0
- package/src/core/step-config/workflow-evaluation-context.ts +6 -0
- package/src/core/step-transition/apply-step-transition.ts +163 -0
- package/src/core/step-transition/decide-step-transition.test.ts +307 -0
- package/src/core/step-transition/decide-step-transition.ts +200 -0
- package/src/core/step-transition/evaluate-gate.test.ts +317 -0
- package/src/core/step-transition/evaluate-gate.ts +168 -0
- package/src/core/step-transition/read-step-outputs.ts +27 -0
- package/src/core/workflow-run-creation.test.ts +155 -0
- package/src/core/workflow-run-creation.ts +131 -0
- package/src/core/workflow-scheduling/index.ts +15 -0
- package/src/core/workflow-scheduling/run-progress.test.ts +46 -0
- package/src/core/workflow-scheduling/run-progress.ts +68 -0
- package/src/core/workflow-scheduling/runtime-dag.ts +10 -0
- package/src/core/workflow-scheduling/runtime-scheduling-command.ts +20 -0
- package/src/core/workflow-scheduling/schedule-runtime-dag.test.ts +197 -0
- package/src/core/workflow-scheduling/schedule-runtime-dag.ts +115 -0
- package/src/db/db.ts +40 -0
- package/src/db/index.ts +86 -0
- package/src/db/job-listener-events.test.ts +113 -0
- package/src/db/job-listener-events.ts +73 -0
- package/src/db/job-listeners.test.ts +865 -0
- package/src/db/job-listeners.ts +564 -0
- package/src/db/outbox-writes.ts +40 -0
- package/src/db/rerun-listener.test.ts +64 -0
- package/src/db/run-timeout.test.ts +102 -0
- package/src/db/runner-lease-table.ts +39 -0
- package/src/db/schema/common.ts +3 -0
- package/src/db/schema/job-executions.ts +85 -0
- package/src/db/schema/job-listener-events.ts +58 -0
- package/src/db/schema/jobs.ts +136 -0
- package/src/db/schema/outbox.ts +4 -0
- package/src/db/schema/step-attempts.ts +99 -0
- package/src/db/schema/steps.ts +99 -0
- package/src/db/schema/workflow-run-attempts.ts +59 -0
- package/src/db/schema/workflow-runs.ts +112 -0
- package/src/db/workflow-runs/job-executions.test.ts +99 -0
- package/src/db/workflow-runs/job-executions.ts +421 -0
- package/src/db/workflow-runs/job-status.test.ts +532 -0
- package/src/db/workflow-runs/jobs.test.ts +194 -0
- package/src/db/workflow-runs/jobs.ts +418 -0
- package/src/db/workflow-runs/outbox.ts +109 -0
- package/src/db/workflow-runs/queries.test.ts +256 -0
- package/src/db/workflow-runs/queries.ts +437 -0
- package/src/db/workflow-runs/run-create.test.ts +1281 -0
- package/src/db/workflow-runs/run-create.ts +373 -0
- package/src/db/workflow-runs/run-graph.ts +95 -0
- package/src/db/workflow-runs/run-rerun.test.ts +625 -0
- package/src/db/workflow-runs/run-rerun.ts +266 -0
- package/src/db/workflow-runs/run-status.test.ts +425 -0
- package/src/db/workflow-runs/run-status.ts +391 -0
- package/src/db/workflow-runs/runs.ts +17 -0
- package/src/db/workflow-runs/shared.ts +84 -0
- package/src/db/workflow-runs/steps.test.ts +191 -0
- package/src/db/workflow-runs/steps.ts +476 -0
- package/src/db/workflow-runs.ts +111 -0
- package/src/index.ts +99 -0
- package/src/metrics/index.ts +1 -0
- package/src/metrics/instance.ts +160 -0
- package/src/metrics/service.ts +30 -0
- package/src/presentation/dto/checkout-token.test.ts +107 -0
- package/src/presentation/dto/checkout-token.ts +85 -0
- package/src/presentation/dto/index.ts +3 -0
- package/src/presentation/dto/job.test.ts +108 -0
- package/src/presentation/dto/job.ts +64 -0
- package/src/presentation/dto/step.test.ts +307 -0
- package/src/presentation/dto/step.ts +145 -0
- package/src/presentation/dto/workflow-run.ts +38 -0
- package/src/presentation/index.ts +10 -0
- package/src/presentation/routes/agent-runtime-config.test.ts +478 -0
- package/src/presentation/routes/agent-runtime-config.ts +81 -0
- package/src/presentation/routes/cancel-run.test.ts +156 -0
- package/src/presentation/routes/cancel-run.ts +37 -0
- package/src/presentation/routes/checkout-token.test.ts +366 -0
- package/src/presentation/routes/checkout-token.ts +61 -0
- package/src/presentation/routes/get-run-aggregates.test.ts +114 -0
- package/src/presentation/routes/get-run-aggregates.ts +69 -0
- package/src/presentation/routes/get-run.test.ts +604 -0
- package/src/presentation/routes/get-run.ts +66 -0
- package/src/presentation/routes/get-step-secrets.test.ts +260 -0
- package/src/presentation/routes/get-step-secrets.ts +117 -0
- package/src/presentation/routes/index.test.ts +71 -0
- package/src/presentation/routes/index.ts +42 -0
- package/src/presentation/routes/leased-step.ts +54 -0
- package/src/presentation/routes/list-run-attempts.test.ts +163 -0
- package/src/presentation/routes/list-run-attempts.ts +27 -0
- package/src/presentation/routes/list-runs.test.ts +244 -0
- package/src/presentation/routes/list-runs.ts +83 -0
- package/src/presentation/routes/next-step.test.ts +366 -0
- package/src/presentation/routes/next-step.ts +62 -0
- package/src/presentation/routes/report-step.test.ts +374 -0
- package/src/presentation/routes/report-step.ts +61 -0
- package/src/presentation/routes/require-accessible-run.ts +27 -0
- package/src/presentation/routes/rerun-run.test.ts +202 -0
- package/src/presentation/routes/rerun-run.ts +48 -0
- package/src/presentation/subscribers/index.ts +7 -0
- package/src/presentation/subscribers/on-job-event-delivered.test.ts +71 -0
- package/src/presentation/subscribers/on-job-event-delivered.ts +30 -0
- package/src/presentation/subscribers/on-job-steps-settled.test.ts +75 -0
- package/src/presentation/subscribers/on-job-steps-settled.ts +42 -0
- package/src/presentation/subscribers/on-runner-job-claimed.test.ts +57 -0
- package/src/presentation/subscribers/on-runner-job-claimed.ts +23 -0
- package/src/presentation/subscribers/on-runner-job-lease-expired.test.ts +73 -0
- package/src/presentation/subscribers/on-runner-job-lease-expired.ts +36 -0
- package/src/presentation/subscribers/on-runner-job-queued.test.ts +57 -0
- package/src/presentation/subscribers/on-runner-job-queued.ts +23 -0
- package/src/presentation/subscribers/on-workflow-run-attempt-created.test.ts +69 -0
- package/src/presentation/subscribers/on-workflow-run-attempt-created.ts +40 -0
- package/src/presentation/subscribers/on-workflow-run-cancelled.test.ts +59 -0
- package/src/presentation/subscribers/on-workflow-run-cancelled.ts +29 -0
- package/src/temporal/activities/index.ts +45 -0
- package/src/temporal/activities/orchestration-activities.test.ts +115 -0
- package/src/temporal/activities/orchestration-activities.ts +305 -0
- package/src/temporal/constants.ts +6 -0
- package/src/temporal/index.ts +6 -0
- package/src/temporal/workflow-not-found.ts +9 -0
- package/src/temporal/workflows/deadline.ts +7 -0
- package/src/temporal/workflows/index.ts +11 -0
- package/src/temporal/workflows/job-execution-orchestration-timeout.test.ts +165 -0
- package/src/temporal/workflows/job-execution-orchestration.test.ts +311 -0
- package/src/temporal/workflows/job-execution-orchestration.ts +314 -0
- package/src/temporal/workflows/job-listener-orchestration-continuation.test.ts +93 -0
- package/src/temporal/workflows/job-listener-orchestration.test.ts +406 -0
- package/src/temporal/workflows/job-listener-orchestration.ts +490 -0
- package/src/temporal/workflows/run-orchestration.test.ts +409 -0
- package/src/temporal/workflows/run-orchestration.ts +283 -0
- package/src/temporal/workflows/test-env.ts +409 -0
- package/test/env.ts +11 -0
- package/test/factories/job.ts +83 -0
- package/test/factories/project.ts +16 -0
- package/test/factories/workflow-model.test.ts +26 -0
- package/test/factories/workflow-model.ts +268 -0
- package/test/factories/workflow-run.ts +58 -0
- package/test/fixtures/active-lease-token.ts +85 -0
- package/test/fixtures/job-with-steps.ts +42 -0
- package/test/fixtures/lease-token.ts +44 -0
- package/test/fixtures/strip-setup-step.ts +23 -0
- package/test/globalSetup.ts +54 -0
- package/test/helpers/workflow-runs.ts +210 -0
- package/test/index.ts +3 -0
- package/test/setup.ts +17 -0
- package/tsconfig.build.json +9 -0
- package/tsconfig.build.tsbuildinfo +1 -0
- package/tsconfig.json +3 -0
- package/tsconfig.test.json +8 -0
- package/vitest.config.ts +12 -0
|
@@ -0,0 +1,352 @@
|
|
|
1
|
+
import type { WorkflowExpression } from '@shipfox/expression';
|
|
2
|
+
import { type PersistedEvaluationTraceEntry, type Step, type StepConfigDispatchPlan } from '#core/entities/step.js';
|
|
3
|
+
export declare const stepStatusEnum: import("drizzle-orm/pg-core").PgEnum<["pending", "running", "succeeded", "failed", "cancelled", "skipped"]>;
|
|
4
|
+
export declare const stepStatusReasonEnum: import("drizzle-orm/pg-core").PgEnum<["default_gate_rejected", "condition_rejected", "condition_errored"]>;
|
|
5
|
+
export declare const steps: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
6
|
+
name: "steps";
|
|
7
|
+
schema: undefined;
|
|
8
|
+
columns: {
|
|
9
|
+
id: import("drizzle-orm/pg-core").PgColumn<{
|
|
10
|
+
name: "id";
|
|
11
|
+
tableName: "steps";
|
|
12
|
+
dataType: "string";
|
|
13
|
+
columnType: "PgUUID";
|
|
14
|
+
data: string;
|
|
15
|
+
driverParam: string;
|
|
16
|
+
notNull: true;
|
|
17
|
+
hasDefault: true;
|
|
18
|
+
isPrimaryKey: true;
|
|
19
|
+
isAutoincrement: false;
|
|
20
|
+
hasRuntimeDefault: false;
|
|
21
|
+
enumValues: undefined;
|
|
22
|
+
baseColumn: never;
|
|
23
|
+
identity: undefined;
|
|
24
|
+
generated: undefined;
|
|
25
|
+
}, {}, {}>;
|
|
26
|
+
jobExecutionId: import("drizzle-orm/pg-core").PgColumn<{
|
|
27
|
+
name: "job_execution_id";
|
|
28
|
+
tableName: "steps";
|
|
29
|
+
dataType: "string";
|
|
30
|
+
columnType: "PgUUID";
|
|
31
|
+
data: string;
|
|
32
|
+
driverParam: string;
|
|
33
|
+
notNull: true;
|
|
34
|
+
hasDefault: false;
|
|
35
|
+
isPrimaryKey: false;
|
|
36
|
+
isAutoincrement: false;
|
|
37
|
+
hasRuntimeDefault: false;
|
|
38
|
+
enumValues: undefined;
|
|
39
|
+
baseColumn: never;
|
|
40
|
+
identity: undefined;
|
|
41
|
+
generated: undefined;
|
|
42
|
+
}, {}, {}>;
|
|
43
|
+
key: import("drizzle-orm/pg-core").PgColumn<{
|
|
44
|
+
name: "key";
|
|
45
|
+
tableName: "steps";
|
|
46
|
+
dataType: "string";
|
|
47
|
+
columnType: "PgText";
|
|
48
|
+
data: string;
|
|
49
|
+
driverParam: string;
|
|
50
|
+
notNull: false;
|
|
51
|
+
hasDefault: false;
|
|
52
|
+
isPrimaryKey: false;
|
|
53
|
+
isAutoincrement: false;
|
|
54
|
+
hasRuntimeDefault: false;
|
|
55
|
+
enumValues: [string, ...string[]];
|
|
56
|
+
baseColumn: never;
|
|
57
|
+
identity: undefined;
|
|
58
|
+
generated: undefined;
|
|
59
|
+
}, {}, {}>;
|
|
60
|
+
name: import("drizzle-orm/pg-core").PgColumn<{
|
|
61
|
+
name: "name";
|
|
62
|
+
tableName: "steps";
|
|
63
|
+
dataType: "string";
|
|
64
|
+
columnType: "PgText";
|
|
65
|
+
data: string;
|
|
66
|
+
driverParam: string;
|
|
67
|
+
notNull: true;
|
|
68
|
+
hasDefault: false;
|
|
69
|
+
isPrimaryKey: false;
|
|
70
|
+
isAutoincrement: false;
|
|
71
|
+
hasRuntimeDefault: false;
|
|
72
|
+
enumValues: [string, ...string[]];
|
|
73
|
+
baseColumn: never;
|
|
74
|
+
identity: undefined;
|
|
75
|
+
generated: undefined;
|
|
76
|
+
}, {}, {}>;
|
|
77
|
+
sourceLocation: import("drizzle-orm/pg-core").PgColumn<{
|
|
78
|
+
name: "source_location";
|
|
79
|
+
tableName: "steps";
|
|
80
|
+
dataType: "json";
|
|
81
|
+
columnType: "PgJsonb";
|
|
82
|
+
data: import("#core/entities/step.js").StepSourceLocation | null;
|
|
83
|
+
driverParam: unknown;
|
|
84
|
+
notNull: false;
|
|
85
|
+
hasDefault: false;
|
|
86
|
+
isPrimaryKey: false;
|
|
87
|
+
isAutoincrement: false;
|
|
88
|
+
hasRuntimeDefault: false;
|
|
89
|
+
enumValues: undefined;
|
|
90
|
+
baseColumn: never;
|
|
91
|
+
identity: undefined;
|
|
92
|
+
generated: undefined;
|
|
93
|
+
}, {}, {
|
|
94
|
+
$type: import("#core/entities/step.js").StepSourceLocation | null;
|
|
95
|
+
}>;
|
|
96
|
+
status: import("drizzle-orm/pg-core").PgColumn<{
|
|
97
|
+
name: "status";
|
|
98
|
+
tableName: "steps";
|
|
99
|
+
dataType: "string";
|
|
100
|
+
columnType: "PgEnumColumn";
|
|
101
|
+
data: "pending" | "running" | "succeeded" | "failed" | "cancelled" | "skipped";
|
|
102
|
+
driverParam: string;
|
|
103
|
+
notNull: true;
|
|
104
|
+
hasDefault: true;
|
|
105
|
+
isPrimaryKey: false;
|
|
106
|
+
isAutoincrement: false;
|
|
107
|
+
hasRuntimeDefault: false;
|
|
108
|
+
enumValues: ["pending", "running", "succeeded", "failed", "cancelled", "skipped"];
|
|
109
|
+
baseColumn: never;
|
|
110
|
+
identity: undefined;
|
|
111
|
+
generated: undefined;
|
|
112
|
+
}, {}, {}>;
|
|
113
|
+
statusReason: import("drizzle-orm/pg-core").PgColumn<{
|
|
114
|
+
name: "status_reason";
|
|
115
|
+
tableName: "steps";
|
|
116
|
+
dataType: "string";
|
|
117
|
+
columnType: "PgEnumColumn";
|
|
118
|
+
data: "default_gate_rejected" | "condition_rejected" | "condition_errored";
|
|
119
|
+
driverParam: string;
|
|
120
|
+
notNull: false;
|
|
121
|
+
hasDefault: false;
|
|
122
|
+
isPrimaryKey: false;
|
|
123
|
+
isAutoincrement: false;
|
|
124
|
+
hasRuntimeDefault: false;
|
|
125
|
+
enumValues: ["default_gate_rejected", "condition_rejected", "condition_errored"];
|
|
126
|
+
baseColumn: never;
|
|
127
|
+
identity: undefined;
|
|
128
|
+
generated: undefined;
|
|
129
|
+
}, {}, {}>;
|
|
130
|
+
evaluationTrace: import("drizzle-orm/pg-core").PgColumn<{
|
|
131
|
+
name: "evaluation_trace";
|
|
132
|
+
tableName: "steps";
|
|
133
|
+
dataType: "json";
|
|
134
|
+
columnType: "PgJsonb";
|
|
135
|
+
data: readonly PersistedEvaluationTraceEntry[];
|
|
136
|
+
driverParam: unknown;
|
|
137
|
+
notNull: false;
|
|
138
|
+
hasDefault: false;
|
|
139
|
+
isPrimaryKey: false;
|
|
140
|
+
isAutoincrement: false;
|
|
141
|
+
hasRuntimeDefault: false;
|
|
142
|
+
enumValues: undefined;
|
|
143
|
+
baseColumn: never;
|
|
144
|
+
identity: undefined;
|
|
145
|
+
generated: undefined;
|
|
146
|
+
}, {}, {
|
|
147
|
+
$type: readonly PersistedEvaluationTraceEntry[];
|
|
148
|
+
}>;
|
|
149
|
+
type: import("drizzle-orm/pg-core").PgColumn<{
|
|
150
|
+
name: "type";
|
|
151
|
+
tableName: "steps";
|
|
152
|
+
dataType: "string";
|
|
153
|
+
columnType: "PgText";
|
|
154
|
+
data: string;
|
|
155
|
+
driverParam: string;
|
|
156
|
+
notNull: true;
|
|
157
|
+
hasDefault: false;
|
|
158
|
+
isPrimaryKey: false;
|
|
159
|
+
isAutoincrement: false;
|
|
160
|
+
hasRuntimeDefault: false;
|
|
161
|
+
enumValues: [string, ...string[]];
|
|
162
|
+
baseColumn: never;
|
|
163
|
+
identity: undefined;
|
|
164
|
+
generated: undefined;
|
|
165
|
+
}, {}, {}>;
|
|
166
|
+
config: import("drizzle-orm/pg-core").PgColumn<{
|
|
167
|
+
name: "config";
|
|
168
|
+
tableName: "steps";
|
|
169
|
+
dataType: "json";
|
|
170
|
+
columnType: "PgJsonb";
|
|
171
|
+
data: Record<string, unknown>;
|
|
172
|
+
driverParam: unknown;
|
|
173
|
+
notNull: true;
|
|
174
|
+
hasDefault: false;
|
|
175
|
+
isPrimaryKey: false;
|
|
176
|
+
isAutoincrement: false;
|
|
177
|
+
hasRuntimeDefault: false;
|
|
178
|
+
enumValues: undefined;
|
|
179
|
+
baseColumn: never;
|
|
180
|
+
identity: undefined;
|
|
181
|
+
generated: undefined;
|
|
182
|
+
}, {}, {
|
|
183
|
+
$type: Record<string, unknown>;
|
|
184
|
+
}>;
|
|
185
|
+
condition: import("drizzle-orm/pg-core").PgColumn<{
|
|
186
|
+
name: "condition";
|
|
187
|
+
tableName: "steps";
|
|
188
|
+
dataType: "json";
|
|
189
|
+
columnType: "PgJsonb";
|
|
190
|
+
data: WorkflowExpression;
|
|
191
|
+
driverParam: unknown;
|
|
192
|
+
notNull: false;
|
|
193
|
+
hasDefault: false;
|
|
194
|
+
isPrimaryKey: false;
|
|
195
|
+
isAutoincrement: false;
|
|
196
|
+
hasRuntimeDefault: false;
|
|
197
|
+
enumValues: undefined;
|
|
198
|
+
baseColumn: never;
|
|
199
|
+
identity: undefined;
|
|
200
|
+
generated: undefined;
|
|
201
|
+
}, {}, {
|
|
202
|
+
$type: WorkflowExpression;
|
|
203
|
+
}>;
|
|
204
|
+
configPlan: import("drizzle-orm/pg-core").PgColumn<{
|
|
205
|
+
name: "config_plan";
|
|
206
|
+
tableName: "steps";
|
|
207
|
+
dataType: "json";
|
|
208
|
+
columnType: "PgJsonb";
|
|
209
|
+
data: StepConfigDispatchPlan;
|
|
210
|
+
driverParam: unknown;
|
|
211
|
+
notNull: false;
|
|
212
|
+
hasDefault: false;
|
|
213
|
+
isPrimaryKey: false;
|
|
214
|
+
isAutoincrement: false;
|
|
215
|
+
hasRuntimeDefault: false;
|
|
216
|
+
enumValues: undefined;
|
|
217
|
+
baseColumn: never;
|
|
218
|
+
identity: undefined;
|
|
219
|
+
generated: undefined;
|
|
220
|
+
}, {}, {
|
|
221
|
+
$type: StepConfigDispatchPlan;
|
|
222
|
+
}>;
|
|
223
|
+
authoredConfig: import("drizzle-orm/pg-core").PgColumn<{
|
|
224
|
+
name: "authored_config";
|
|
225
|
+
tableName: "steps";
|
|
226
|
+
dataType: "json";
|
|
227
|
+
columnType: "PgJsonb";
|
|
228
|
+
data: Record<string, unknown>;
|
|
229
|
+
driverParam: unknown;
|
|
230
|
+
notNull: false;
|
|
231
|
+
hasDefault: false;
|
|
232
|
+
isPrimaryKey: false;
|
|
233
|
+
isAutoincrement: false;
|
|
234
|
+
hasRuntimeDefault: false;
|
|
235
|
+
enumValues: undefined;
|
|
236
|
+
baseColumn: never;
|
|
237
|
+
identity: undefined;
|
|
238
|
+
generated: undefined;
|
|
239
|
+
}, {}, {
|
|
240
|
+
$type: Record<string, unknown>;
|
|
241
|
+
}>;
|
|
242
|
+
error: import("drizzle-orm/pg-core").PgColumn<{
|
|
243
|
+
name: "error";
|
|
244
|
+
tableName: "steps";
|
|
245
|
+
dataType: "json";
|
|
246
|
+
columnType: "PgJsonb";
|
|
247
|
+
data: Record<string, unknown>;
|
|
248
|
+
driverParam: unknown;
|
|
249
|
+
notNull: false;
|
|
250
|
+
hasDefault: false;
|
|
251
|
+
isPrimaryKey: false;
|
|
252
|
+
isAutoincrement: false;
|
|
253
|
+
hasRuntimeDefault: false;
|
|
254
|
+
enumValues: undefined;
|
|
255
|
+
baseColumn: never;
|
|
256
|
+
identity: undefined;
|
|
257
|
+
generated: undefined;
|
|
258
|
+
}, {}, {
|
|
259
|
+
$type: Record<string, unknown>;
|
|
260
|
+
}>;
|
|
261
|
+
position: import("drizzle-orm/pg-core").PgColumn<{
|
|
262
|
+
name: "position";
|
|
263
|
+
tableName: "steps";
|
|
264
|
+
dataType: "number";
|
|
265
|
+
columnType: "PgInteger";
|
|
266
|
+
data: number;
|
|
267
|
+
driverParam: string | number;
|
|
268
|
+
notNull: true;
|
|
269
|
+
hasDefault: false;
|
|
270
|
+
isPrimaryKey: false;
|
|
271
|
+
isAutoincrement: false;
|
|
272
|
+
hasRuntimeDefault: false;
|
|
273
|
+
enumValues: undefined;
|
|
274
|
+
baseColumn: never;
|
|
275
|
+
identity: undefined;
|
|
276
|
+
generated: undefined;
|
|
277
|
+
}, {}, {}>;
|
|
278
|
+
version: import("drizzle-orm/pg-core").PgColumn<{
|
|
279
|
+
name: "version";
|
|
280
|
+
tableName: "steps";
|
|
281
|
+
dataType: "number";
|
|
282
|
+
columnType: "PgInteger";
|
|
283
|
+
data: number;
|
|
284
|
+
driverParam: string | number;
|
|
285
|
+
notNull: true;
|
|
286
|
+
hasDefault: true;
|
|
287
|
+
isPrimaryKey: false;
|
|
288
|
+
isAutoincrement: false;
|
|
289
|
+
hasRuntimeDefault: false;
|
|
290
|
+
enumValues: undefined;
|
|
291
|
+
baseColumn: never;
|
|
292
|
+
identity: undefined;
|
|
293
|
+
generated: undefined;
|
|
294
|
+
}, {}, {}>;
|
|
295
|
+
currentAttempt: import("drizzle-orm/pg-core").PgColumn<{
|
|
296
|
+
name: "current_attempt";
|
|
297
|
+
tableName: "steps";
|
|
298
|
+
dataType: "number";
|
|
299
|
+
columnType: "PgInteger";
|
|
300
|
+
data: number;
|
|
301
|
+
driverParam: string | number;
|
|
302
|
+
notNull: true;
|
|
303
|
+
hasDefault: true;
|
|
304
|
+
isPrimaryKey: false;
|
|
305
|
+
isAutoincrement: false;
|
|
306
|
+
hasRuntimeDefault: false;
|
|
307
|
+
enumValues: undefined;
|
|
308
|
+
baseColumn: never;
|
|
309
|
+
identity: undefined;
|
|
310
|
+
generated: undefined;
|
|
311
|
+
}, {}, {}>;
|
|
312
|
+
createdAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
313
|
+
name: "created_at";
|
|
314
|
+
tableName: "steps";
|
|
315
|
+
dataType: "date";
|
|
316
|
+
columnType: "PgTimestamp";
|
|
317
|
+
data: Date;
|
|
318
|
+
driverParam: string;
|
|
319
|
+
notNull: true;
|
|
320
|
+
hasDefault: true;
|
|
321
|
+
isPrimaryKey: false;
|
|
322
|
+
isAutoincrement: false;
|
|
323
|
+
hasRuntimeDefault: false;
|
|
324
|
+
enumValues: undefined;
|
|
325
|
+
baseColumn: never;
|
|
326
|
+
identity: undefined;
|
|
327
|
+
generated: undefined;
|
|
328
|
+
}, {}, {}>;
|
|
329
|
+
updatedAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
330
|
+
name: "updated_at";
|
|
331
|
+
tableName: "steps";
|
|
332
|
+
dataType: "date";
|
|
333
|
+
columnType: "PgTimestamp";
|
|
334
|
+
data: Date;
|
|
335
|
+
driverParam: string;
|
|
336
|
+
notNull: true;
|
|
337
|
+
hasDefault: true;
|
|
338
|
+
isPrimaryKey: false;
|
|
339
|
+
isAutoincrement: false;
|
|
340
|
+
hasRuntimeDefault: false;
|
|
341
|
+
enumValues: undefined;
|
|
342
|
+
baseColumn: never;
|
|
343
|
+
identity: undefined;
|
|
344
|
+
generated: undefined;
|
|
345
|
+
}, {}, {}>;
|
|
346
|
+
};
|
|
347
|
+
dialect: "pg";
|
|
348
|
+
}>;
|
|
349
|
+
export type StepDb = typeof steps.$inferSelect;
|
|
350
|
+
export type StepCreateDb = typeof steps.$inferInsert;
|
|
351
|
+
export declare function toStep(row: StepDb): Step;
|
|
352
|
+
//# sourceMappingURL=steps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"steps.d.ts","sourceRoot":"","sources":["../../../src/db/schema/steps.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,kBAAkB,EAAC,MAAM,qBAAqB,CAAC;AAe5D,OAAO,EACL,KAAK,6BAA6B,EAElC,KAAK,IAAI,EACT,KAAK,sBAAsB,EAE5B,MAAM,wBAAwB,CAAC;AAIhC,eAAO,MAAM,cAAc,6GAOzB,CAAC;AAEH,eAAO,MAAM,oBAAoB,4GAA8D,CAAC;AAEhG,eAAO,MAAM,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmCjB,CAAC;AAEF,MAAM,MAAM,MAAM,GAAG,OAAO,KAAK,CAAC,YAAY,CAAC;AAC/C,MAAM,MAAM,YAAY,GAAG,OAAO,KAAK,CAAC,YAAY,CAAC;AAErD,wBAAgB,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAsBxC"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { uuidv7PrimaryKey } from '@shipfox/node-drizzle';
|
|
2
|
+
import { sql } from 'drizzle-orm';
|
|
3
|
+
import { check, foreignKey, index, integer, jsonb, pgEnum, text, timestamp, uniqueIndex, uuid } from 'drizzle-orm/pg-core';
|
|
4
|
+
import { STEP_STATUS_REASONS, toStepStatusReason } from '#core/entities/step.js';
|
|
5
|
+
import { pgTable } from './common.js';
|
|
6
|
+
import { jobExecutions } from './job-executions.js';
|
|
7
|
+
export const stepStatusEnum = pgEnum('workflows_step_status', [
|
|
8
|
+
'pending',
|
|
9
|
+
'running',
|
|
10
|
+
'succeeded',
|
|
11
|
+
'failed',
|
|
12
|
+
'cancelled',
|
|
13
|
+
'skipped'
|
|
14
|
+
]);
|
|
15
|
+
export const stepStatusReasonEnum = pgEnum('workflows_step_status_reason', STEP_STATUS_REASONS);
|
|
16
|
+
export const steps = pgTable('steps', {
|
|
17
|
+
id: uuidv7PrimaryKey(),
|
|
18
|
+
jobExecutionId: uuid('job_execution_id').notNull(),
|
|
19
|
+
key: text('key'),
|
|
20
|
+
name: text('name').notNull(),
|
|
21
|
+
sourceLocation: jsonb('source_location').$type(),
|
|
22
|
+
status: stepStatusEnum('status').notNull().default('pending'),
|
|
23
|
+
statusReason: stepStatusReasonEnum('status_reason'),
|
|
24
|
+
evaluationTrace: jsonb('evaluation_trace').$type(),
|
|
25
|
+
type: text('type').notNull(),
|
|
26
|
+
config: jsonb('config').notNull().$type(),
|
|
27
|
+
condition: jsonb('condition').$type(),
|
|
28
|
+
configPlan: jsonb('config_plan').$type(),
|
|
29
|
+
authoredConfig: jsonb('authored_config').$type(),
|
|
30
|
+
error: jsonb('error').$type(),
|
|
31
|
+
position: integer('position').notNull(),
|
|
32
|
+
version: integer('version').notNull().default(1),
|
|
33
|
+
// Execution-attempt identity, distinct from the optimistic `version` counter.
|
|
34
|
+
// Starts at 1 and is bumped only on durable rewind.
|
|
35
|
+
currentAttempt: integer('current_attempt').notNull().default(1),
|
|
36
|
+
createdAt: timestamp('created_at', {
|
|
37
|
+
withTimezone: true
|
|
38
|
+
}).notNull().defaultNow(),
|
|
39
|
+
updatedAt: timestamp('updated_at', {
|
|
40
|
+
withTimezone: true
|
|
41
|
+
}).notNull().defaultNow()
|
|
42
|
+
}, (table)=>[
|
|
43
|
+
index('workflows_steps_job_execution_id_idx').on(table.jobExecutionId),
|
|
44
|
+
uniqueIndex('workflows_steps_id_job_execution_id_uq').on(table.id, table.jobExecutionId),
|
|
45
|
+
check('workflows_steps_current_attempt_positive_ck', sql`${table.currentAttempt} > 0`),
|
|
46
|
+
foreignKey({
|
|
47
|
+
name: 'workflows_steps_job_execution_id_workflows_job_executions_id_fk',
|
|
48
|
+
columns: [
|
|
49
|
+
table.jobExecutionId
|
|
50
|
+
],
|
|
51
|
+
foreignColumns: [
|
|
52
|
+
jobExecutions.id
|
|
53
|
+
]
|
|
54
|
+
}).onDelete('cascade')
|
|
55
|
+
]);
|
|
56
|
+
export function toStep(row) {
|
|
57
|
+
return {
|
|
58
|
+
id: row.id,
|
|
59
|
+
jobExecutionId: row.jobExecutionId,
|
|
60
|
+
key: row.key,
|
|
61
|
+
name: row.name,
|
|
62
|
+
sourceLocation: row.sourceLocation ?? null,
|
|
63
|
+
status: row.status,
|
|
64
|
+
statusReason: toStepStatusReason(row.statusReason),
|
|
65
|
+
evaluationTrace: row.evaluationTrace ?? null,
|
|
66
|
+
type: row.type,
|
|
67
|
+
config: row.config,
|
|
68
|
+
condition: row.condition ?? null,
|
|
69
|
+
configPlan: row.configPlan ?? null,
|
|
70
|
+
authoredConfig: row.authoredConfig ?? null,
|
|
71
|
+
error: row.error ?? null,
|
|
72
|
+
position: row.position,
|
|
73
|
+
version: row.version,
|
|
74
|
+
currentAttempt: row.currentAttempt,
|
|
75
|
+
createdAt: row.createdAt,
|
|
76
|
+
updatedAt: row.updatedAt
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
//# sourceMappingURL=steps.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/db/schema/steps.ts"],"sourcesContent":["import type {WorkflowExpression} from '@shipfox/expression';\nimport {uuidv7PrimaryKey} from '@shipfox/node-drizzle';\nimport {sql} from 'drizzle-orm';\nimport {\n check,\n foreignKey,\n index,\n integer,\n jsonb,\n pgEnum,\n text,\n timestamp,\n uniqueIndex,\n uuid,\n} from 'drizzle-orm/pg-core';\nimport {\n type PersistedEvaluationTraceEntry,\n STEP_STATUS_REASONS,\n type Step,\n type StepConfigDispatchPlan,\n toStepStatusReason,\n} from '#core/entities/step.js';\nimport {pgTable} from './common.js';\nimport {jobExecutions} from './job-executions.js';\n\nexport const stepStatusEnum = pgEnum('workflows_step_status', [\n 'pending',\n 'running',\n 'succeeded',\n 'failed',\n 'cancelled',\n 'skipped',\n]);\n\nexport const stepStatusReasonEnum = pgEnum('workflows_step_status_reason', STEP_STATUS_REASONS);\n\nexport const steps = pgTable(\n 'steps',\n {\n id: uuidv7PrimaryKey(),\n jobExecutionId: uuid('job_execution_id').notNull(),\n key: text('key'),\n name: text('name').notNull(),\n sourceLocation: jsonb('source_location').$type<Step['sourceLocation']>(),\n status: stepStatusEnum('status').notNull().default('pending'),\n statusReason: stepStatusReasonEnum('status_reason'),\n evaluationTrace: jsonb('evaluation_trace').$type<readonly PersistedEvaluationTraceEntry[]>(),\n type: text('type').notNull(),\n config: jsonb('config').notNull().$type<Record<string, unknown>>(),\n condition: jsonb('condition').$type<WorkflowExpression>(),\n configPlan: jsonb('config_plan').$type<StepConfigDispatchPlan>(),\n authoredConfig: jsonb('authored_config').$type<Record<string, unknown>>(),\n error: jsonb('error').$type<Record<string, unknown>>(),\n position: integer('position').notNull(),\n version: integer('version').notNull().default(1),\n // Execution-attempt identity, distinct from the optimistic `version` counter.\n // Starts at 1 and is bumped only on durable rewind.\n currentAttempt: integer('current_attempt').notNull().default(1),\n createdAt: timestamp('created_at', {withTimezone: true}).notNull().defaultNow(),\n updatedAt: timestamp('updated_at', {withTimezone: true}).notNull().defaultNow(),\n },\n (table) => [\n index('workflows_steps_job_execution_id_idx').on(table.jobExecutionId),\n uniqueIndex('workflows_steps_id_job_execution_id_uq').on(table.id, table.jobExecutionId),\n check('workflows_steps_current_attempt_positive_ck', sql`${table.currentAttempt} > 0`),\n foreignKey({\n name: 'workflows_steps_job_execution_id_workflows_job_executions_id_fk',\n columns: [table.jobExecutionId],\n foreignColumns: [jobExecutions.id],\n }).onDelete('cascade'),\n ],\n);\n\nexport type StepDb = typeof steps.$inferSelect;\nexport type StepCreateDb = typeof steps.$inferInsert;\n\nexport function toStep(row: StepDb): Step {\n return {\n id: row.id,\n jobExecutionId: row.jobExecutionId,\n key: row.key,\n name: row.name,\n sourceLocation: row.sourceLocation ?? null,\n status: row.status,\n statusReason: toStepStatusReason(row.statusReason),\n evaluationTrace: row.evaluationTrace ?? null,\n type: row.type,\n config: row.config as Record<string, unknown>,\n condition: (row.condition as WorkflowExpression) ?? null,\n configPlan: row.configPlan ?? null,\n authoredConfig: (row.authoredConfig as Record<string, unknown>) ?? null,\n error: (row.error as Record<string, unknown>) ?? null,\n position: row.position,\n version: row.version,\n currentAttempt: row.currentAttempt,\n createdAt: row.createdAt,\n updatedAt: row.updatedAt,\n };\n}\n"],"names":["uuidv7PrimaryKey","sql","check","foreignKey","index","integer","jsonb","pgEnum","text","timestamp","uniqueIndex","uuid","STEP_STATUS_REASONS","toStepStatusReason","pgTable","jobExecutions","stepStatusEnum","stepStatusReasonEnum","steps","id","jobExecutionId","notNull","key","name","sourceLocation","$type","status","default","statusReason","evaluationTrace","type","config","condition","configPlan","authoredConfig","error","position","version","currentAttempt","createdAt","withTimezone","defaultNow","updatedAt","table","on","columns","foreignColumns","onDelete","toStep","row"],"mappings":"AACA,SAAQA,gBAAgB,QAAO,wBAAwB;AACvD,SAAQC,GAAG,QAAO,cAAc;AAChC,SACEC,KAAK,EACLC,UAAU,EACVC,KAAK,EACLC,OAAO,EACPC,KAAK,EACLC,MAAM,EACNC,IAAI,EACJC,SAAS,EACTC,WAAW,EACXC,IAAI,QACC,sBAAsB;AAC7B,SAEEC,mBAAmB,EAGnBC,kBAAkB,QACb,yBAAyB;AAChC,SAAQC,OAAO,QAAO,cAAc;AACpC,SAAQC,aAAa,QAAO,sBAAsB;AAElD,OAAO,MAAMC,iBAAiBT,OAAO,yBAAyB;IAC5D;IACA;IACA;IACA;IACA;IACA;CACD,EAAE;AAEH,OAAO,MAAMU,uBAAuBV,OAAO,gCAAgCK,qBAAqB;AAEhG,OAAO,MAAMM,QAAQJ,QACnB,SACA;IACEK,IAAInB;IACJoB,gBAAgBT,KAAK,oBAAoBU,OAAO;IAChDC,KAAKd,KAAK;IACVe,MAAMf,KAAK,QAAQa,OAAO;IAC1BG,gBAAgBlB,MAAM,mBAAmBmB,KAAK;IAC9CC,QAAQV,eAAe,UAAUK,OAAO,GAAGM,OAAO,CAAC;IACnDC,cAAcX,qBAAqB;IACnCY,iBAAiBvB,MAAM,oBAAoBmB,KAAK;IAChDK,MAAMtB,KAAK,QAAQa,OAAO;IAC1BU,QAAQzB,MAAM,UAAUe,OAAO,GAAGI,KAAK;IACvCO,WAAW1B,MAAM,aAAamB,KAAK;IACnCQ,YAAY3B,MAAM,eAAemB,KAAK;IACtCS,gBAAgB5B,MAAM,mBAAmBmB,KAAK;IAC9CU,OAAO7B,MAAM,SAASmB,KAAK;IAC3BW,UAAU/B,QAAQ,YAAYgB,OAAO;IACrCgB,SAAShC,QAAQ,WAAWgB,OAAO,GAAGM,OAAO,CAAC;IAC9C,8EAA8E;IAC9E,oDAAoD;IACpDW,gBAAgBjC,QAAQ,mBAAmBgB,OAAO,GAAGM,OAAO,CAAC;IAC7DY,WAAW9B,UAAU,cAAc;QAAC+B,cAAc;IAAI,GAAGnB,OAAO,GAAGoB,UAAU;IAC7EC,WAAWjC,UAAU,cAAc;QAAC+B,cAAc;IAAI,GAAGnB,OAAO,GAAGoB,UAAU;AAC/E,GACA,CAACE,QAAU;QACTvC,MAAM,wCAAwCwC,EAAE,CAACD,MAAMvB,cAAc;QACrEV,YAAY,0CAA0CkC,EAAE,CAACD,MAAMxB,EAAE,EAAEwB,MAAMvB,cAAc;QACvFlB,MAAM,+CAA+CD,GAAG,CAAC,EAAE0C,MAAML,cAAc,CAAC,IAAI,CAAC;QACrFnC,WAAW;YACToB,MAAM;YACNsB,SAAS;gBAACF,MAAMvB,cAAc;aAAC;YAC/B0B,gBAAgB;gBAAC/B,cAAcI,EAAE;aAAC;QACpC,GAAG4B,QAAQ,CAAC;KACb,EACD;AAKF,OAAO,SAASC,OAAOC,GAAW;IAChC,OAAO;QACL9B,IAAI8B,IAAI9B,EAAE;QACVC,gBAAgB6B,IAAI7B,cAAc;QAClCE,KAAK2B,IAAI3B,GAAG;QACZC,MAAM0B,IAAI1B,IAAI;QACdC,gBAAgByB,IAAIzB,cAAc,IAAI;QACtCE,QAAQuB,IAAIvB,MAAM;QAClBE,cAAcf,mBAAmBoC,IAAIrB,YAAY;QACjDC,iBAAiBoB,IAAIpB,eAAe,IAAI;QACxCC,MAAMmB,IAAInB,IAAI;QACdC,QAAQkB,IAAIlB,MAAM;QAClBC,WAAW,AAACiB,IAAIjB,SAAS,IAA2B;QACpDC,YAAYgB,IAAIhB,UAAU,IAAI;QAC9BC,gBAAgB,AAACe,IAAIf,cAAc,IAAgC;QACnEC,OAAO,AAACc,IAAId,KAAK,IAAgC;QACjDC,UAAUa,IAAIb,QAAQ;QACtBC,SAASY,IAAIZ,OAAO;QACpBC,gBAAgBW,IAAIX,cAAc;QAClCC,WAAWU,IAAIV,SAAS;QACxBG,WAAWO,IAAIP,SAAS;IAC1B;AACF"}
|
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
import type { WorkflowModel } from '@shipfox/api-definitions';
|
|
2
|
+
import type { AgentToolMaterializationSnapshot } from '#core/agent-tools.js';
|
|
3
|
+
import type { WorkflowRunAttempt } from '#core/entities/workflow-run-attempt.js';
|
|
4
|
+
export declare const workflowRunAttempts: import("drizzle-orm/pg-core").PgTableWithColumns<{
|
|
5
|
+
name: "workflow_run_attempts";
|
|
6
|
+
schema: undefined;
|
|
7
|
+
columns: {
|
|
8
|
+
id: import("drizzle-orm/pg-core").PgColumn<{
|
|
9
|
+
name: "id";
|
|
10
|
+
tableName: "workflow_run_attempts";
|
|
11
|
+
dataType: "string";
|
|
12
|
+
columnType: "PgUUID";
|
|
13
|
+
data: string;
|
|
14
|
+
driverParam: string;
|
|
15
|
+
notNull: true;
|
|
16
|
+
hasDefault: true;
|
|
17
|
+
isPrimaryKey: true;
|
|
18
|
+
isAutoincrement: false;
|
|
19
|
+
hasRuntimeDefault: false;
|
|
20
|
+
enumValues: undefined;
|
|
21
|
+
baseColumn: never;
|
|
22
|
+
identity: undefined;
|
|
23
|
+
generated: undefined;
|
|
24
|
+
}, {}, {}>;
|
|
25
|
+
workflowRunId: import("drizzle-orm/pg-core").PgColumn<{
|
|
26
|
+
name: "workflow_run_id";
|
|
27
|
+
tableName: "workflow_run_attempts";
|
|
28
|
+
dataType: "string";
|
|
29
|
+
columnType: "PgUUID";
|
|
30
|
+
data: string;
|
|
31
|
+
driverParam: string;
|
|
32
|
+
notNull: true;
|
|
33
|
+
hasDefault: false;
|
|
34
|
+
isPrimaryKey: false;
|
|
35
|
+
isAutoincrement: false;
|
|
36
|
+
hasRuntimeDefault: false;
|
|
37
|
+
enumValues: undefined;
|
|
38
|
+
baseColumn: never;
|
|
39
|
+
identity: undefined;
|
|
40
|
+
generated: undefined;
|
|
41
|
+
}, {}, {}>;
|
|
42
|
+
attempt: import("drizzle-orm/pg-core").PgColumn<{
|
|
43
|
+
name: "attempt";
|
|
44
|
+
tableName: "workflow_run_attempts";
|
|
45
|
+
dataType: "number";
|
|
46
|
+
columnType: "PgInteger";
|
|
47
|
+
data: number;
|
|
48
|
+
driverParam: string | number;
|
|
49
|
+
notNull: true;
|
|
50
|
+
hasDefault: false;
|
|
51
|
+
isPrimaryKey: false;
|
|
52
|
+
isAutoincrement: false;
|
|
53
|
+
hasRuntimeDefault: false;
|
|
54
|
+
enumValues: undefined;
|
|
55
|
+
baseColumn: never;
|
|
56
|
+
identity: undefined;
|
|
57
|
+
generated: undefined;
|
|
58
|
+
}, {}, {}>;
|
|
59
|
+
status: import("drizzle-orm/pg-core").PgColumn<{
|
|
60
|
+
name: "status";
|
|
61
|
+
tableName: "workflow_run_attempts";
|
|
62
|
+
dataType: "string";
|
|
63
|
+
columnType: "PgEnumColumn";
|
|
64
|
+
data: "pending" | "running" | "succeeded" | "failed" | "cancelled";
|
|
65
|
+
driverParam: string;
|
|
66
|
+
notNull: true;
|
|
67
|
+
hasDefault: true;
|
|
68
|
+
isPrimaryKey: false;
|
|
69
|
+
isAutoincrement: false;
|
|
70
|
+
hasRuntimeDefault: false;
|
|
71
|
+
enumValues: ["pending", "running", "succeeded", "failed", "cancelled"];
|
|
72
|
+
baseColumn: never;
|
|
73
|
+
identity: undefined;
|
|
74
|
+
generated: undefined;
|
|
75
|
+
}, {}, {}>;
|
|
76
|
+
rerunMode: import("drizzle-orm/pg-core").PgColumn<{
|
|
77
|
+
name: "rerun_mode";
|
|
78
|
+
tableName: "workflow_run_attempts";
|
|
79
|
+
dataType: "string";
|
|
80
|
+
columnType: "PgEnumColumn";
|
|
81
|
+
data: "failed" | "all";
|
|
82
|
+
driverParam: string;
|
|
83
|
+
notNull: false;
|
|
84
|
+
hasDefault: false;
|
|
85
|
+
isPrimaryKey: false;
|
|
86
|
+
isAutoincrement: false;
|
|
87
|
+
hasRuntimeDefault: false;
|
|
88
|
+
enumValues: ["all", "failed"];
|
|
89
|
+
baseColumn: never;
|
|
90
|
+
identity: undefined;
|
|
91
|
+
generated: undefined;
|
|
92
|
+
}, {}, {}>;
|
|
93
|
+
rerunByUserId: import("drizzle-orm/pg-core").PgColumn<{
|
|
94
|
+
name: "rerun_by_user_id";
|
|
95
|
+
tableName: "workflow_run_attempts";
|
|
96
|
+
dataType: "string";
|
|
97
|
+
columnType: "PgUUID";
|
|
98
|
+
data: string;
|
|
99
|
+
driverParam: string;
|
|
100
|
+
notNull: false;
|
|
101
|
+
hasDefault: false;
|
|
102
|
+
isPrimaryKey: false;
|
|
103
|
+
isAutoincrement: false;
|
|
104
|
+
hasRuntimeDefault: false;
|
|
105
|
+
enumValues: undefined;
|
|
106
|
+
baseColumn: never;
|
|
107
|
+
identity: undefined;
|
|
108
|
+
generated: undefined;
|
|
109
|
+
}, {}, {}>;
|
|
110
|
+
model: import("drizzle-orm/pg-core").PgColumn<{
|
|
111
|
+
name: "model";
|
|
112
|
+
tableName: "workflow_run_attempts";
|
|
113
|
+
dataType: "json";
|
|
114
|
+
columnType: "PgJsonb";
|
|
115
|
+
data: WorkflowModel;
|
|
116
|
+
driverParam: unknown;
|
|
117
|
+
notNull: false;
|
|
118
|
+
hasDefault: false;
|
|
119
|
+
isPrimaryKey: false;
|
|
120
|
+
isAutoincrement: false;
|
|
121
|
+
hasRuntimeDefault: false;
|
|
122
|
+
enumValues: undefined;
|
|
123
|
+
baseColumn: never;
|
|
124
|
+
identity: undefined;
|
|
125
|
+
generated: undefined;
|
|
126
|
+
}, {}, {
|
|
127
|
+
$type: WorkflowModel;
|
|
128
|
+
}>;
|
|
129
|
+
agentToolMaterialization: import("drizzle-orm/pg-core").PgColumn<{
|
|
130
|
+
name: "agent_tool_materialization";
|
|
131
|
+
tableName: "workflow_run_attempts";
|
|
132
|
+
dataType: "json";
|
|
133
|
+
columnType: "PgJsonb";
|
|
134
|
+
data: AgentToolMaterializationSnapshot;
|
|
135
|
+
driverParam: unknown;
|
|
136
|
+
notNull: false;
|
|
137
|
+
hasDefault: false;
|
|
138
|
+
isPrimaryKey: false;
|
|
139
|
+
isAutoincrement: false;
|
|
140
|
+
hasRuntimeDefault: false;
|
|
141
|
+
enumValues: undefined;
|
|
142
|
+
baseColumn: never;
|
|
143
|
+
identity: undefined;
|
|
144
|
+
generated: undefined;
|
|
145
|
+
}, {}, {
|
|
146
|
+
$type: AgentToolMaterializationSnapshot;
|
|
147
|
+
}>;
|
|
148
|
+
version: import("drizzle-orm/pg-core").PgColumn<{
|
|
149
|
+
name: "version";
|
|
150
|
+
tableName: "workflow_run_attempts";
|
|
151
|
+
dataType: "number";
|
|
152
|
+
columnType: "PgInteger";
|
|
153
|
+
data: number;
|
|
154
|
+
driverParam: string | number;
|
|
155
|
+
notNull: true;
|
|
156
|
+
hasDefault: true;
|
|
157
|
+
isPrimaryKey: false;
|
|
158
|
+
isAutoincrement: false;
|
|
159
|
+
hasRuntimeDefault: false;
|
|
160
|
+
enumValues: undefined;
|
|
161
|
+
baseColumn: never;
|
|
162
|
+
identity: undefined;
|
|
163
|
+
generated: undefined;
|
|
164
|
+
}, {}, {}>;
|
|
165
|
+
createdAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
166
|
+
name: "created_at";
|
|
167
|
+
tableName: "workflow_run_attempts";
|
|
168
|
+
dataType: "date";
|
|
169
|
+
columnType: "PgTimestamp";
|
|
170
|
+
data: Date;
|
|
171
|
+
driverParam: string;
|
|
172
|
+
notNull: true;
|
|
173
|
+
hasDefault: true;
|
|
174
|
+
isPrimaryKey: false;
|
|
175
|
+
isAutoincrement: false;
|
|
176
|
+
hasRuntimeDefault: false;
|
|
177
|
+
enumValues: undefined;
|
|
178
|
+
baseColumn: never;
|
|
179
|
+
identity: undefined;
|
|
180
|
+
generated: undefined;
|
|
181
|
+
}, {}, {}>;
|
|
182
|
+
updatedAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
183
|
+
name: "updated_at";
|
|
184
|
+
tableName: "workflow_run_attempts";
|
|
185
|
+
dataType: "date";
|
|
186
|
+
columnType: "PgTimestamp";
|
|
187
|
+
data: Date;
|
|
188
|
+
driverParam: string;
|
|
189
|
+
notNull: true;
|
|
190
|
+
hasDefault: true;
|
|
191
|
+
isPrimaryKey: false;
|
|
192
|
+
isAutoincrement: false;
|
|
193
|
+
hasRuntimeDefault: false;
|
|
194
|
+
enumValues: undefined;
|
|
195
|
+
baseColumn: never;
|
|
196
|
+
identity: undefined;
|
|
197
|
+
generated: undefined;
|
|
198
|
+
}, {}, {}>;
|
|
199
|
+
startedAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
200
|
+
name: "started_at";
|
|
201
|
+
tableName: "workflow_run_attempts";
|
|
202
|
+
dataType: "date";
|
|
203
|
+
columnType: "PgTimestamp";
|
|
204
|
+
data: Date;
|
|
205
|
+
driverParam: string;
|
|
206
|
+
notNull: false;
|
|
207
|
+
hasDefault: false;
|
|
208
|
+
isPrimaryKey: false;
|
|
209
|
+
isAutoincrement: false;
|
|
210
|
+
hasRuntimeDefault: false;
|
|
211
|
+
enumValues: undefined;
|
|
212
|
+
baseColumn: never;
|
|
213
|
+
identity: undefined;
|
|
214
|
+
generated: undefined;
|
|
215
|
+
}, {}, {}>;
|
|
216
|
+
finishedAt: import("drizzle-orm/pg-core").PgColumn<{
|
|
217
|
+
name: "finished_at";
|
|
218
|
+
tableName: "workflow_run_attempts";
|
|
219
|
+
dataType: "date";
|
|
220
|
+
columnType: "PgTimestamp";
|
|
221
|
+
data: Date;
|
|
222
|
+
driverParam: string;
|
|
223
|
+
notNull: false;
|
|
224
|
+
hasDefault: false;
|
|
225
|
+
isPrimaryKey: false;
|
|
226
|
+
isAutoincrement: false;
|
|
227
|
+
hasRuntimeDefault: false;
|
|
228
|
+
enumValues: undefined;
|
|
229
|
+
baseColumn: never;
|
|
230
|
+
identity: undefined;
|
|
231
|
+
generated: undefined;
|
|
232
|
+
}, {}, {}>;
|
|
233
|
+
};
|
|
234
|
+
dialect: "pg";
|
|
235
|
+
}>;
|
|
236
|
+
export type WorkflowRunAttemptDb = typeof workflowRunAttempts.$inferSelect;
|
|
237
|
+
export type WorkflowRunAttemptCreateDb = typeof workflowRunAttempts.$inferInsert;
|
|
238
|
+
export declare function toWorkflowRunAttempt(row: WorkflowRunAttemptDb): WorkflowRunAttempt;
|
|
239
|
+
//# sourceMappingURL=workflow-run-attempts.d.ts.map
|