mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 12:44:07 -08:00
fix(core): Allow grace period for binary data deletion after manual execution (#7889)
https://linear.app/n8n/issue/PAY-1079
This commit is contained in:
parent
ade3acf800
commit
61d8aebeaf
|
@ -430,10 +430,16 @@ function hookFunctionsSave(parentProcessMode?: string): IWorkflowExecuteHooks {
|
||||||
const saveSettings = toSaveSettings(this.workflowData.settings);
|
const saveSettings = toSaveSettings(this.workflowData.settings);
|
||||||
|
|
||||||
if (isManualMode && !saveSettings.manual && !fullRunData.waitTill) {
|
if (isManualMode && !saveSettings.manual && !fullRunData.waitTill) {
|
||||||
await Container.get(ExecutionRepository).hardDelete({
|
/**
|
||||||
workflowId: this.workflowData.id as string,
|
* When manual executions are not being saved, we only soft-delete
|
||||||
executionId: this.executionId,
|
* the execution so that the user can access its binary data
|
||||||
});
|
* while building their workflow.
|
||||||
|
*
|
||||||
|
* The manual execution and its binary data will be hard-deleted
|
||||||
|
* on the next pruning cycle after the grace period set by
|
||||||
|
* `EXECUTIONS_DATA_HARD_DELETE_BUFFER`.
|
||||||
|
*/
|
||||||
|
await Container.get(ExecutionRepository).softDelete(this.executionId);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue