diff --git a/src/main/java/org/opensearch/flowframework/workflow/WorkflowStepFactory.java b/src/main/java/org/opensearch/flowframework/workflow/WorkflowStepFactory.java index ece942a04..c30bdf87c 100644 --- a/src/main/java/org/opensearch/flowframework/workflow/WorkflowStepFactory.java +++ b/src/main/java/org/opensearch/flowframework/workflow/WorkflowStepFactory.java @@ -63,6 +63,6 @@ public WorkflowStep createStep(String type) { * @return the step map */ public Map getStepMap() { - return this.stepMap; + return Map.copyOf(this.stepMap); } }