Replace inheritVariables with explicit in-mappings for undeployAppSubProcess - #1897
Merged
Conversation
…Process All 5 call sites of undeployAppSubProcess across 4 BPMN files previously used flowable:inheritVariables="true", which implicitly passes the entire parent process variable scope into the subprocess. This creates hidden coupling and can cause variables to leak unintentionally between process instances in multi-instance scenarios. Replace with flowable:inheritVariables="false" and an explicit list of 27 flowable:in variable mappings on each call site, consistent with the same pattern applied to the processBatches subprocess in #1893. Affected files: - rollback-mta.bpmn (1 call site) - xs2-bg-deploy.bpmn (2 call sites) - xs2-deploy.bpmn (1 call site) - xs2-undeploy.bpmn (1 call site) JIRA:LMCROSSITXSADEPLOY-3028
The appToProcess variable is set as the multi-instance elementVariable by the parent call activity (flowable:elementVariable="appToProcess"), but with inheritVariables="false" it must be listed explicitly in flowable:in to be available inside the subprocess. Without it, UndeployAppStep.executeStepInternal() reads a null APP_TO_PROCESS, causing a NullPointerException in getStepErrorMessage() when DeleteApplicationRoutesStep runs. JIRA:LMCROSSITXSADEPLOY-3028
stiv03
requested changes
Aug 17, 2026
| <flowable:in source="namespace" target="namespace"></flowable:in> | ||
| <flowable:in source="keepFiles" target="keepFiles"></flowable:in> | ||
| <flowable:in source="appArchiveId" target="appArchiveId"></flowable:in> | ||
| <flowable:in source="mtaExtDescriptorId" target="mtaExtDescriptorId"></flowable:in> |
Contributor
There was a problem hiding this comment.
Are keepFiles/ appArchiveId/ mtaExtDescriptorId needed here in the undeploy diagram?
stiv03
approved these changes
Aug 18, 2026
|
vkalapov
approved these changes
Aug 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Description:
Removes the implicit full-scope variable inheritance from every
undeployAppSubProcesscall activity in the process definitions. All 5 call sites previously usedflowable:inheritVariables="true", which passes the entire parent process variable scope into the subprocess. This creates hidden coupling and can cause variables to leak unintentionally between process instances in multi-instance scenarios.What changed: each call site now sets
flowable:inheritVariables="false"and declares an explicit list of 27flowable:invariable mappings, so the subprocess receives exactly the variables it needs and nothing more. This mirrors the pattern already applied to theprocessBatchessubprocess in #1893.Affected BPMN files (4 files, 5 call sites):
rollback-mta.bpmn(1 call site)xs2-bg-deploy.bpmn(2 call sites)xs2-deploy.bpmn(1 call site)xs2-undeploy.bpmn(1 call site)Areas to focus on: please verify the 27-variable
flowable:inlist is complete for each call site — a missing mapping would surface as an unset variable insideundeployAppSubProcessat runtime rather than at build time.Reference: JIRA:LMCROSSITXSADEPLOY-3028
Issue: