cancel
Showing results for 
Search instead for 
Did you mean: 

retry servicetask that failed..

jcosano
Champ in-the-making
Champ in-the-making
How can I force to retry a serviceTask, that previosly failed?

I have some process Instance that failed, and now, are in this step, but I need to force a new execution (I solve java problem).
5 REPLIES 5

frederikherema1
Star Contributor
Star Contributor
Thats strange. I would expect the process to be in the original state, before the service-task was called. When an exception occurs,  the transaction is not comitted and the process should be in the state where the execution began (eg. task, waitstate, start-event).

So the active activity ID in the DB points to a serviceTask?

jcosano
Champ in-the-making
Champ in-the-making
I have a servicetask that I'm casting from exection to ExecutionImpl and with 5.1 fails this cast… now is ExecutionEntity…

String key = ((ExecutionEntity)execution).getProcessInstance().getId();
Then… this code is launched by a boundaryEvent…

After crash, this processinstance actual activity was the servicetask that crash..


Same occurs with a groovy script, when I move last moth to 5.0, groovy scripts fails because need a library that instalation don't move to tomcat… then..
processInstace keep in script node… and this script is launch via boundaryEvent too.

jbarrez
Star Contributor
Star Contributor
Could you post some of your process, I'm not quite following what goes wrong.

jcosano
Champ in-the-making
Champ in-the-making
All test works fine… I don't known what happen but I deleted some instances that failed and kept in wrong state.

If this happen again, I'll try to investigate more…

jollyja
Champ in-the-making
Champ in-the-making
managementService.createJobQuery().jobId(jobid).singleResult();
managementService.executeJob(jobid);