Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
b76e136
Convert failedWorkflow input to a Map so nested references resolve
nikhiln64 Jul 15, 2026
b077f1e
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 15, 2026
65b2e7b
Merge upstream/main; adopt the static OBJECT_MAPPER introduced on main
nikhiln64 Jul 20, 2026
830deac
Merge branch 'fix/failed-workflow-input-map' of https://github.com/ni…
nikhiln64 Jul 20, 2026
f92c9ab
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 21, 2026
c09175d
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 21, 2026
abf7e81
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 21, 2026
7f605d4
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 21, 2026
e6fe880
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 23, 2026
d4424fc
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 25, 2026
e773ffc
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 28, 2026
49d7ac1
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 29, 2026
06d8138
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Jul 30, 2026
5dc7164
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Aug 7, 2026
f255e8f
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Aug 8, 2026
9130445
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Aug 12, 2026
cf09187
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Aug 14, 2026
aa71546
Merge branch 'main' into fix/failed-workflow-input-map
nikhiln64 Aug 14, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
import com.netflix.conductor.model.WorkflowModel;
import com.netflix.conductor.service.ExecutionLockService;

import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.common.base.Preconditions;

Expand Down Expand Up @@ -871,7 +872,13 @@ public WorkflowModel terminateWorkflow(
if (workflow.getFailedTaskId() != null) {
input.put("failureTaskId", workflow.getFailedTaskId());
}
input.put("failedWorkflow", workflow);
// Convert to a Map: the JsonPath provider used by ParametersUtils cannot traverse
// POJOs, so a raw WorkflowModel makes nested references like
// ${workflow.input.failedWorkflow.workflowId} silently resolve to null (#1164).
input.put(
"failedWorkflow",
OBJECT_MAPPER.convertValue(
workflow, new TypeReference<Map<String, Object>>() {}));

try {
String failureWFId = idGenerator.generate();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2660,6 +2660,19 @@ public void testTerminateWorkflowWithFailureWorkflow() {
// And verify that the failure workflow definition was fetched without version
verify(metadataDAO).getLatestWorkflowDef("failure_workflow");
assertNull(workflow.getWorkflowDefinition().getFailureWorkflowVersion());

// And the failure workflow input carries failedWorkflow as a Map, not a raw
// WorkflowModel POJO, so nested ${workflow.input.failedWorkflow.<field>} references
// are resolvable by JsonPath (issue #1164)
ArgumentCaptor<WorkflowModel> failureWorkflowCaptor =
ArgumentCaptor.forClass(WorkflowModel.class);
verify(executionDAOFacade, atLeastOnce()).createWorkflow(failureWorkflowCaptor.capture());
Object failedWorkflowInput =
failureWorkflowCaptor.getValue().getInput().get("failedWorkflow");
assertTrue(
"failedWorkflow input must be a Map, was: " + failedWorkflowInput.getClass(),
failedWorkflowInput instanceof Map);
assertEquals("1", ((Map<String, Object>) failedWorkflowInput).get("workflowId"));
}

@Test
Expand Down
Loading