mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-14 00:24:07 -08:00
refactor: remove startmetata
This commit is contained in:
parent
ba0502e589
commit
83abcea9ac
|
@ -397,11 +397,9 @@ export class RetrieverWorkflow implements INodeType {
|
|||
items,
|
||||
config?.getChild(),
|
||||
{
|
||||
startMetadata: {
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -455,11 +455,9 @@ export class ToolWorkflow implements INodeType {
|
|||
let receivedData: ExecuteWorkflowData;
|
||||
try {
|
||||
receivedData = await this.executeWorkflow(workflowInfo, items, runManager?.getChild(), {
|
||||
startMetadata: {
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
});
|
||||
subExecutionId = receivedData.executionId;
|
||||
|
|
|
@ -36,8 +36,8 @@ import type {
|
|||
ExecuteWorkflowOptions,
|
||||
IWorkflowExecutionDataProcess,
|
||||
EnvProviderState,
|
||||
ITaskMetadata,
|
||||
ExecuteWorkflowData,
|
||||
RelatedExecution,
|
||||
} from 'n8n-workflow';
|
||||
import { Container } from 'typedi';
|
||||
|
||||
|
@ -684,7 +684,7 @@ function hookFunctionsSaveWorker(): IWorkflowExecuteHooks {
|
|||
export async function getRunData(
|
||||
workflowData: IWorkflowBase,
|
||||
inputData?: INodeExecutionData[],
|
||||
metadata?: ITaskMetadata,
|
||||
parentExecution?: RelatedExecution,
|
||||
): Promise<IWorkflowExecutionDataProcess> {
|
||||
const mode = 'integrated';
|
||||
|
||||
|
@ -704,7 +704,7 @@ export async function getRunData(
|
|||
data: {
|
||||
main: [inputData],
|
||||
},
|
||||
metadata,
|
||||
metadata: { parentExecution },
|
||||
source: null,
|
||||
});
|
||||
|
||||
|
@ -785,7 +785,7 @@ export async function executeWorkflow(
|
|||
|
||||
const runData =
|
||||
options.loadedRunData ??
|
||||
(await getRunData(workflowData, options.inputData, options.startMetadata));
|
||||
(await getRunData(workflowData, options.inputData, options.parentExecution));
|
||||
|
||||
const executionId = await activeExecutions.add(runData);
|
||||
|
||||
|
|
|
@ -111,6 +111,7 @@ import type {
|
|||
ISupplyDataFunctions,
|
||||
WebhookType,
|
||||
SchedulingFunctions,
|
||||
RelatedExecution,
|
||||
} from 'n8n-workflow';
|
||||
import {
|
||||
NodeConnectionType,
|
||||
|
@ -3646,7 +3647,7 @@ export function getExecuteFunctions(
|
|||
parentCallbackManager?: CallbackManager,
|
||||
options?: {
|
||||
doNotWaitToFinish?: boolean;
|
||||
startMetadata?: ITaskMetadata;
|
||||
parentExecution?: RelatedExecution;
|
||||
},
|
||||
): Promise<ExecuteWorkflowData> {
|
||||
return await additionalData
|
||||
|
@ -3982,7 +3983,7 @@ export function getSupplyDataFunctions(
|
|||
parentCallbackManager?: CallbackManager,
|
||||
options?: {
|
||||
doNotWaitToFinish?: boolean;
|
||||
startMetadata?: ITaskMetadata;
|
||||
parentExecution?: RelatedExecution;
|
||||
},
|
||||
): Promise<ExecuteWorkflowData> =>
|
||||
await additionalData
|
||||
|
|
|
@ -231,11 +231,9 @@ export class ExecuteWorkflow implements INodeType {
|
|||
[items[i]],
|
||||
undefined,
|
||||
{
|
||||
startMetadata: {
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
},
|
||||
);
|
||||
|
@ -265,11 +263,9 @@ export class ExecuteWorkflow implements INodeType {
|
|||
undefined,
|
||||
{
|
||||
doNotWaitToFinish: true,
|
||||
startMetadata: {
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
},
|
||||
);
|
||||
|
@ -324,11 +320,9 @@ export class ExecuteWorkflow implements INodeType {
|
|||
undefined,
|
||||
{
|
||||
doNotWaitToFinish: !waitForSubWorkflow,
|
||||
startMetadata: {
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
parentExecution: {
|
||||
executionId: workflowProxy.$execution.id,
|
||||
workflowId: workflowProxy.$workflow.id,
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -956,7 +956,7 @@ export type IExecuteFunctions = ExecuteFunctions.GetNodeParameterFn &
|
|||
parentCallbackManager?: CallbackManager,
|
||||
options?: {
|
||||
doNotWaitToFinish?: boolean;
|
||||
startMetadata?: ITaskMetadata;
|
||||
parentExecution?: RelatedExecution;
|
||||
},
|
||||
): Promise<ExecuteWorkflowData>;
|
||||
getInputConnectionData(
|
||||
|
@ -2283,8 +2283,8 @@ export interface ExecuteWorkflowOptions {
|
|||
loadedRunData?: IWorkflowExecutionDataProcess;
|
||||
parentWorkflowSettings?: IWorkflowSettings;
|
||||
parentCallbackManager?: CallbackManager;
|
||||
startMetadata?: ITaskMetadata;
|
||||
doNotWaitToFinish?: boolean;
|
||||
parentExecution?: RelatedExecution;
|
||||
}
|
||||
|
||||
export type AiEvent =
|
||||
|
|
Loading…
Reference in a new issue