From 9a4d45fd0d8dee3e27c413a82d7f82528ec73909 Mon Sep 17 00:00:00 2001 From: Nicolas Adment <39568358+nadment@users.noreply.github.com> Date: Wed, 7 Feb 2024 00:12:36 +0100 Subject: [PATCH] Record action execution duration #3606 Indirectly fix "actionDuration" always null in workflow logging --- engine/src/main/java/org/apache/hop/workflow/Workflow.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/engine/src/main/java/org/apache/hop/workflow/Workflow.java b/engine/src/main/java/org/apache/hop/workflow/Workflow.java index 7c9cec65871..924cb49128a 100644 --- a/engine/src/main/java/org/apache/hop/workflow/Workflow.java +++ b/engine/src/main/java/org/apache/hop/workflow/Workflow.java @@ -655,6 +655,9 @@ private Result executeFromStart( newResult = cloneJei.execute(prevResult, nr); log.snap(Metrics.METRIC_ACTION_STOP, cloneJei.toString()); + // Action execution duration + newResult.setElapsedTimeMillis(System.currentTimeMillis()-start); + if (interactive) { getActiveActions().remove(actionMeta); }