8000 Preserve Workflow Definition Snapshot in Workflow Instances to Ensure Execution Consistency · Issue #6627 · elsa-workflows/elsa-core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Preserve Workflow Definition Snapshot in Workflow Instances to Ensure Execution Consistency #6627

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
TimNguyenVN opened this issue May 5, 2025 · 0 comments

Comments

@TimNguyenVN
Copy link

Enhancement Request

Enhancement Overview

When executing a workflow definition, the resulting workflow instance reflects live changes made to the workflow definition, even after execution. For example, if a workflow definition initially has 3 activities and a workflow instance is created from it, then later a 4th activity is added to the definition, the previously created instance (which should remain immutable) also reflects the 4th activity. This results in inconsistencies, as the workflow instance does not preserve the graph it originally executed.

Proposed Enhancement

Describe the enhancement you'd like
Workflow instances should retain a snapshot of the workflow definition graph at the time of execution. Once a workflow instance is created and execution has begun (or completed), any subsequent modifications to the definition should not impact existing instances.

We also need to consider that when using ScheduleChildActivity, the workflow execution context should resolve and execute based on the persisted graph of the workflow instance, not the latest definition. This would guarantee that child workflows maintain logical consistency and behave as expected even if the parent definition has changed.

Solutions

Replicate column StringData from the workflow definition table to the workflow instance when executing the workflow
The input, output, and variable also need to be replicated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant
0