8839 workflow follow up code step (#8856)
- add readonly mode - fix falsy stepOutput computation
This commit is contained in:
@ -319,6 +319,7 @@ export class LambdaDriver implements ServerlessDriver {
|
||||
await this.waitFunctionUpdates(functionToExecute.id, 10);
|
||||
|
||||
const startTime = Date.now();
|
||||
|
||||
const params: InvokeCommandInput = {
|
||||
FunctionName: functionName,
|
||||
Payload: JSON.stringify(payload),
|
||||
|
||||
@ -17,4 +17,11 @@ export class UpdateWorkflowVersionStepInput {
|
||||
nullable: false,
|
||||
})
|
||||
step: WorkflowAction;
|
||||
|
||||
@Field(() => Boolean, {
|
||||
description: 'Boolean to check if we need to update stepOutput',
|
||||
nullable: true,
|
||||
defaultValue: true,
|
||||
})
|
||||
shouldUpdateStepOutput: boolean;
|
||||
}
|
||||
|
||||
@ -36,12 +36,18 @@ export class WorkflowVersionStepResolver {
|
||||
@Mutation(() => WorkflowActionDTO)
|
||||
async updateWorkflowVersionStep(
|
||||
@AuthWorkspace() { id: workspaceId }: Workspace,
|
||||
@Args('input') { step, workflowVersionId }: UpdateWorkflowVersionStepInput,
|
||||
@Args('input')
|
||||
{
|
||||
step,
|
||||
workflowVersionId,
|
||||
shouldUpdateStepOutput,
|
||||
}: UpdateWorkflowVersionStepInput,
|
||||
): Promise<WorkflowActionDTO> {
|
||||
return this.workflowVersionStepWorkspaceService.updateWorkflowVersionStep({
|
||||
workspaceId,
|
||||
workflowVersionId,
|
||||
step,
|
||||
shouldUpdateStepOutput,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@ -45,9 +45,9 @@ export class WorkspaceEventEmitter {
|
||||
});
|
||||
}
|
||||
|
||||
public emitCustomBatchEvent(
|
||||
public emitCustomBatchEvent<T extends object>(
|
||||
eventName: CustomEventName,
|
||||
events: object[],
|
||||
events: T[],
|
||||
workspaceId: string,
|
||||
) {
|
||||
if (!events.length) {
|
||||
|
||||
Reference in New Issue
Block a user