[jBPM Development] - Issue #JBPM-2537
by sebastian.s
Hello Joram, hello everyone
https://jira.jboss.org/jira/browse/JBPM-2537
I have a question regarding this issue. I just saw that you have started to work on this in the trunk and I have two questions.
1) I don't understand the test case you've supplied. What's the reason for task2 and the second end state? They are not even connected to the start?? At first I thought I had misread the definition and so I copied it into a process definition file to visualize it with the GPD.
2) I did not know you've started to work on this and I tried to resolve this issue with my limited knowledge on my own right now. Within TimerImpl I checked if the activity of the execution was of type task and in case of this was true I retrieved the task-object and called OpenTask.delete().
| boolean activityIsTask = false;
| OpenTask task = null;
| ActivityImpl activity = execution.getActivity();
|
| // TODO: Is there a constant or something to access the element's XML-name??
| if(activity.getType().equals("task")) {
| task = execution.getTask();
| if(task == null) {
| // this should not happen or something is really wrong
| throw new JbpmException("activity is of type task but task could not be retrieved");
| }
| }
|
| .. after execution has moved on ..
|
| if(activityIsTask) {
| task.delete(this.getEventName());
| }
|
Afterwards I saw your test case failing since the task was now deleted and not completed but your test case checks if the task is closed/completed when the timer fires.
Wouldn't it make more sense to delete the task? Completing it does not seem right since it was open and not completed when the timer fired. Especially in from a reporting perspective it does not make sense, does it?
When you run a report on the gathered process data it seems as if this task was completed by its assignee although it was not.
Actually I thought you agreed on this view because you stated in the comments that deleting would be logical. :)
Thanks for any clarifications.
Have a nice weekend
Sebastian
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4263327#4263327
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4263327
15 years, 1 month