Red Hat Bugzilla – Bug 818936
Human Task with potential owner who is not known to the HT service is not written to database
Last modified: 2016-09-20 01:04:30 EDT
Created attachment 582110 [details]
Description of problem:
Simple process definition: start->human task->end with potential owner, that is not known to the HT service is run in the JBPM Console.
When the process instance starts, exception occurs in the server.log (see an attachment).
There is a root cause:
java.sql.SQLException: Integrity constraint violation - no parent FK27A9A59E619A0 table: TASK in statement [update Task set allowedToDelegate=?, taskInitiator_id=?, priority=?, activationTime=?, actualOwner_id=?, createdBy_id=?, createdOn=?, documentAccessType=?, documentContentId=?, documentType=?, expirationTime=?, faultAccessType=?, faultContentId=?, faultName=?, faultType=?, outputAccessType=?, outputContentId=?, outputType=?, parentId=?, previousStatus=?, processId=?, processInstanceId=?, processSessionId=?, skipable=?, status=?, workItemId=?, OPTLOCK=? where id=? and OPTLOCK=?]
From my point of view:
1. The task cannot be seen by unknownUser - that's right, it should not be.
2. There is the process instance waiting for the task completion. The only way is to terminate this process instance -> the user can lost his data.
3. There should be an option to assign the task to other user which is known to the HT service (for example by some Task Server admin). But this is not possible - the task is not stored in database and therefore, it can't be seen by any user.
4. If there is more than one potential owner specified in the process definition and only one is unknown to the HT service, still even the known owners are unable to access the task.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. run the attached BPMN2 process (assuming the "unknownUser" is not defined in the running task service) in JBPM Console
2. see server log for the exception
No org.hibernate.exception.GenericJDBCException or java.sql.SQLException. The task should be stored in database, but not visible to unknown user.
Created attachment 582111 [details]
Which version of HSQLDB is being used?
The internets seem to indicate that there's a well known bug in HSQLDB batching:
I can't tell whether or not this was ever fixed in HSQLDB (the above mentioned bug was rejected aka set to "invalid").
It would be great if you could replicate this bug on another database, maybe H2?
Created attachment 582670 [details]
H2 server log
(In reply to comment #2)
> Which version of HSQLDB is being used?
> The internets seem to indicate that there's a well known bug in HSQLDB
> I can't tell whether or not this was ever fixed in HSQLDB (the above mentioned
> bug was rejected aka set to "invalid").
> It would be great if you could replicate this bug on another database, maybe
It seems these issues are about generic exception without the detail information about the cause when batch execution is enabled.
But I have tried once more with H2 database and the problem still occurs. Here is the new log file https://bugzilla.redhat.com/attachment.cgi?id=582670
This looks like added functionality, and given the deadlines/timeframe and other prio's/bugs, I'm not sure there's time to implement the solution proposed.
Will defer it to next release.
See the discussion in BZ 800514 for more information about this issue.
*** This bug has been marked as a duplicate of bug 800514 ***