refactor(core): Port timeout config (#18722)

This commit is contained in:
Iván Ovejero
2025-08-26 11:31:11 +02:00
committed by GitHub
parent ede6f5b739
commit 85e3bfd3e4
10 changed files with 49 additions and 46 deletions

View File

@@ -39,6 +39,18 @@ class QueueRecoveryConfig {
@Config
export class ExecutionsConfig {
/**
* How long (seconds) a workflow execution may run for before timeout.
* On timeout, the execution will be forcefully stopped. `-1` for unlimited.
* Currently unlimited by default - this default will change in a future version.
*/
@Env('EXECUTIONS_TIMEOUT')
timeout: number = -1;
/** How long (seconds) a workflow execution may run for at most. */
@Env('EXECUTIONS_TIMEOUT_MAX')
maxTimeout: number = 3600; // 1h
/** Whether to delete past executions on a rolling basis. */
@Env('EXECUTIONS_DATA_PRUNE')
pruneData: boolean = true;

View File

@@ -302,6 +302,8 @@ describe('GlobalConfig', () => {
disableWebhookHtmlSandboxing: false,
},
executions: {
timeout: -1,
maxTimeout: 3600,
pruneData: true,
pruneDataMaxAge: 336,
pruneDataMaxCount: 10_000,