camunda-bpm-platform
camunda-bpm-platform copied to clipboard
Tasklist Filter displays the Task Input Variables as Undefined despite them having values
Environment (Required on creation)
- The behaviour has been reproduced with
camunda-bpm-run-ee-7.20.5-ee
- The Relevant support ticket mentions
Camunda Platform 7.18.x, Camunda Platform 7.20.x
Description (Required on creation; please attach any relevant screenshots, stacktraces, log files, etc. to the ticket)
Given a Tasklist filter with two variables (FNAME
, LNAME
)
-
When a bpmn file (SUPPORT-21936-2.bpmn) is deployed with an Expanded SubProcess with the two variables as inputs, the filter demonstrates them correctly. ✔
-
When a second version of the above file (SUPPORT-21936_Output.bpmn) is deployed and a test output variable is added inside a user task, the filter displays the two variables as undefined ✘
Screenshots
1. Screenshot with two Local Variables - SUPPORT-21936-2.bpmn
2. Screenshot with two Local Variables and one Output Variable - SUPPORT-21936_Output.bpmn
3. Screenshot with Filter Variables that are Undefined
Steps to reproduce (Required on creation)
Create Filter
-
- Go to Tasklist, click on the
Create a filter+
option on the top left corner
- Go to Tasklist, click on the
-
- On the General tab, give the Filter a name e.g
My Filter
- On the General tab, give the Filter a name e.g
-
- Click on the
Variables
tab and tick theShow Undefined option
- Click on the
-
- Add two variable entries: a)
Name:
FNAME
,Description:
First Name
b)LNAME
,Description:
Last Name
- Add two variable entries: a)
-
- Click
Save
- Click
Deploy and View Filter Works
-
- Deploy
SUPPORT-21936-2.bpmn
toprocess-engine
and start a process-instance (e.g using thedesktop-modeler
)
- Deploy
-
- Go to the Tasklist page, click on
My Filter
, notice howtest task
displays the variableFirst Name
andLast Name
populated with date test data.
- Go to the Tasklist page, click on
Deploy and View Filter is Broken
-
- Deploy
SUPPORT-21936_Output.bpmn
toprocess-engine
and start a process-instance (e.g using thedesktop-modeler
)
- Deploy
-
- Go to the Tasklist page, click on
My Filter
, notice how the secondtest task
(top of the list) does displays undefined values for First Name and Last Name variables
- Go to the Tasklist page, click on
Observed Behavior (Required on creation)
SUPPORT-21936_Output.bpmn
process-instance creates a test task
with local variables (2 input, 1 output) which should be displayed in the Tasklist filtered list view. Instead, the variables are displayed as Undefined
.
Expected behavior (Required on creation)
The Tasklist View should display First Name
and Last Name
Filter Variables of the test task
related to SUPPORT-21936_Output.bpmn
with a populated value instead of Undefined
Root Cause (Required on prioritization)
The endpoint /camunda/api/engine/engine/{engine-name}/filter/{filter-id}/list which is used to visualise the filter:
- Returns the Input variables for the process-instances of the first deployable (
SUPPORT-21936-2.bpmn
) -
Does not return the input variables and the output variable for the second deployable (
SUPPORT-21936_Output
) -
FilterResourceImpl#convertToHalTaskList
Line 405- The
getVariableInstancesForTasks
call returns a map with variable entries ONLY for the task with two input variables; the task which includes theoutput variable
is not returned.
- The
Solution Ideas
Hints
- When the user clicks on the
test task
(any of the two created), claims the task and clicks on theLoad Variables
option, the input variablesFNAME
andLNAME
are returned successfully by the respective API- API used for the above operation:
camunda/api/engine/engine/{engine-id}/task/{task_id}/form-variables?deserializeValues=false
)
- API used for the above operation:
Links
- https://jira.camunda.com/browse/SUPPORT-21936
Breakdown
### Pull Requests
Dev2QA handover
- [ ] Does this ticket need a QA test and the testing goals are not clear from the description? Add a Dev2QA handover comment