Bug 818936 - Human Task with potential owner who is not known to the HT service is not written to database
Summary: Human Task with potential owner who is not known to the HT service is not wri...
Keywords:
Status: CLOSED DUPLICATE of bug 800514
Alias: None
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: jBPM 5
Version: BRMS 5.3.0.GA
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: ---
Assignee: Marco Rietveld
QA Contact: Radovan Synek
URL: https://issues.jboss.org/browse/JBPM-...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-04 12:34 UTC by Radovan Synek
Modified: 2016-09-20 05:04 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-05-22 14:36:26 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
process definition (4.62 KB, application/octet-stream)
2012-05-04 12:34 UTC, Radovan Synek
no flags Details
server log (25.74 KB, text/x-log)
2012-05-04 12:34 UTC, Radovan Synek
no flags Details
H2 server log (26.80 KB, text/x-log)
2012-05-07 13:48 UTC, Radovan Synek
no flags Details

Description Radovan Synek 2012-05-04 12:34:01 UTC
Created attachment 582110 [details]
process definition

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):
BRMS 5.3.0.ER6

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

Expected results:
No org.hibernate.exception.GenericJDBCException or java.sql.SQLException. The task should be stored in database, but not visible to unknown user.

Comment 1 Radovan Synek 2012-05-04 12:34:42 UTC
Created attachment 582111 [details]
server log

Comment 2 Marco Rietveld 2012-05-04 20:06:09 UTC
Which version of HSQLDB is being used? 

The internets seem to indicate that there's a well known bug in HSQLDB batching: 

http://forum.springsource.org/archive/index.php/t-28645.html
http://stackoverflow.com/questions/7526729/genericjdbcexception-in-hsql
http://sourceforge.net/tracker/?func=detail&atid=378131&aid=1407528&group_id=23316

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?

Comment 3 Radovan Synek 2012-05-07 13:48:15 UTC
Created attachment 582670 [details]
H2 server log

Comment 4 Radovan Synek 2012-05-07 13:53:19 UTC
(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
> batching: 
> 
> http://forum.springsource.org/archive/index.php/t-28645.html
> http://stackoverflow.com/questions/7526729/genericjdbcexception-in-hsql
> http://sourceforge.net/tracker/?func=detail&atid=378131&aid=1407528&group_id=23316
> 
> 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?

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

Comment 5 Marco Rietveld 2012-05-09 15:50:29 UTC
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.

Comment 6 Prakash Aradhya 2012-05-09 15:57:14 UTC
Will defer it to next release.

Comment 7 Marco Rietveld 2012-05-22 14:36:26 UTC
See the discussion in BZ 800514 for more information about this issue.

*** This bug has been marked as a duplicate of bug 800514 ***


Note You need to log in before you can comment on or make changes to this bug.