Created attachment 994315 [details]
Screenshot illustrating the issue
Description of problem:
I have a process with 1 HumanTask in which I test Form Modeler's document field (i.e. file attachment support). I upload the document in the task list using FM Form and complete the task (that completes the process).
When I navigate to Documents tab in Process Instance Details perspective, there is a notification with exception and the documents table is not loaded (see screenshot).
Version-Release number of selected component (if applicable):
BPM Suite 6.1.0 ER5
Steps to Reproduce:
1. Create simple "start -> HumanTask -> end" process which uses Form modeler form with document field.
2. Deploy the project and start the process.
3. Upload some doc in human task and complete the task
4. Navigate to Process Instances Perspective and check completed process instances. Open Process Instance details panel and switch to Documents tab
Error notification is displayed. Unfortunately there's nothing in server log. I underlined the root cause in the screenshot (SessionNotFoundException - seems to be simliar issue as in bug #1195142)
Documents are listed in the tab, no error notification.
Fixed in 6.2.x jbpm and jbpm-console-ng:
Checking with BPM Suite 6.1.0 ER6. I can see the download link in the Process Instance Details > Documents Tab, but this link is now working ONLY for processes instances that are completed.
For running process instances that have some document uploaded (e.g. a process for which document was uploaded via process start form), the document link is there, but it has invalid URL (of the form "http://localhost:8080/business-central/org.kie.workbench.KIEWebappnull"). Clicking this link naturally causes HTTP 404.
Interesting is, that when I COMPLETE that process, the document link becomes valid. See the behavior in the video I attach and please review the fix.
Created attachment 1000322 [details]
VIdeo illustrating new issue
Fixed changes Document creation in order to make the MarshallingStrategy generate it with the link & identifier.
Checking with BPM Suite 6.1 CR1.
This is still not working as expected. Now the document links in Process Instance Details > Documents tab are NEVER displayed (not for running process, nor for completed process).
Please see the current behavior in the 2 videos attached:
1) DocProcess - document uploaded on process start. After that checking Process Instance Details > Documents tab, there is no link to download document (even thought the document link is present in Process Variables tab - but just as a text, not as clickable link)
2) HTDocUpload - document uploaded in task list as a part of human task. After that the process completes. Agan, Process Instance Details > Documents tab does not list any documents (but it's present in the Proc. Variables tab - as in case 1)
Please see the videos attached for steps to reproduce.
The sources of the 2 processes used & their corresponding forms can be found in our repo of testing artifacts:
Created attachment 1006678 [details]
Video: CR1 still has the issue
Created attachment 1006679 [details]
Video: CR1 still has the issue 2
There was an error related with date parsing and the computer locale. Forced a pattern to store the document last modified date.
Reopened based on https://github.com/droolsjbpm/jbpm/commit/dd7f970385fa910a1cead8b15279ae392debf7c9#commitcomment-10436193
Changed the properties separator for documents from "," to a more complex expression "####" to avoid errors on with the file naming.
It requires to specify in the documentation that the uploaded files shouldn't have the #### token on it's name.
Now it's working fine. Verified with BPM Suite 6.1.0 CR2