Bug 1004681 - Task completion is not rolled back when Process Engine throws a Exception
Summary: Task completion is not rolled back when Process Engine throws a Exception
Keywords:
Status: VERIFIED
Alias: None
Product: JBoss Enterprise BRMS Platform 5
Classification: JBoss
Component: jBPM 5
Version: BRMS 5.3.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: GA
: ---
Assignee: Kris Verlaenen
QA Contact: Marek Baluch
URL:
Whiteboard:
Depends On:
Blocks: 1022758
TreeView+ depends on / blocked
 
Reported: 2013-09-05 08:34 UTC by Toshiya Kobayashi
Modified: 2020-04-27 01:16 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)
jBPMEx67_exception_after_task_completion.zip (794.22 KB, application/zip)
2013-09-05 08:45 UTC, Toshiya Kobayashi
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBPM-3882 0 Major Resolved Clean Tasks from DBMS when a Process is cancelled 2020-01-16 18:00:06 UTC

Description Toshiya Kobayashi 2013-09-05 08:34:09 UTC
Description of problem:

In TaskServiceSession.taskOperation(), Process notification is done after transaction commit. Because of this, task operation (completing a task) and process execution (triggered by task completion) are executed in different transactions. So there would be a case where process execution is rolled back but task completion is not rolled back.

Steps to Reproduce:
1. Run ProcessMainJPA.java in jBPMEx67_exception_after_task_completion.zip

This example process throws an RuntimeException in a Script Node after a User Task Node.

Actual results:

Task is completed.

Expected results:

Task is rolled back. (= InProgress)

Comment 1 Toshiya Kobayashi 2013-09-05 08:34:56 UTC
Fixed in master.

https://github.com/droolsjbpm/jbpm/commit/63afb97f395c165b2bc0ce24b2c8d4f447f3a41f

Comment 3 Toshiya Kobayashi 2013-09-05 08:45:50 UTC
Created attachment 794094 [details]
jBPMEx67_exception_after_task_completion.zip

Comment 6 Jiri Svitak 2014-02-11 15:01:04 UTC
Verified in 5.3.1.BRMS-P05.


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