Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 312694

Summary: task.setErrorHandlingOption(IEngineTask.CANCEL_ON_ERROR) does not cancel task
Product: z_Archived Reporter: herges <herges99>
Component: BIRTAssignee: Jun Ouyang <jouyang>
Status: VERIFIED WORKSFORME QA Contact: Xiaoying Gu <bluesoldier>
Severity: normal    
Priority: P3 CC: bluesoldier, wyan
Version: 2.5.2   
Target Milestone: 2.6.1   
Hardware: PC   
OS: Windows XP   
Whiteboard: Obsolete

Description herges CLA 2010-05-12 15:23:05 EDT
I set task.setErrorHandlingOption(IEngineTask.CANCEL_ON_ERROR).
It does not cancel the task,
the report is still written to the outputstream, followed by the errors.
I would expect that it cancels and throws an EngineException,
so that my application can handle it.

Maybe it does not have to throw the exception so that I can them from task.getErrors(),
but it should definitely cancel.
Comment 1 herges CLA 2010-05-17 05:32:20 EDT
Update: Seems to work for non html Outputs
Comment 2 Jun Ouyang CLA 2010-08-01 22:58:57 EDT
In 2.6.1, if this flag is set, the tasks ARE canceled when error occurs, and the exception can be gotten from task.getErrors().
Comment 3 Xiaoying Gu CLA 2010-08-13 03:01:38 EDT
Verified in 2.6.1.v20100812-0630 that tasks will be canceled with the flag set.
Contents after where the exception happens will not be output to the html file, but error message and contents before will be output the the html.