[jbpm-dev] Question about workitems and abort

Mauricio Salatino salaboy at gmail.com
Tue Jan 24 16:50:57 EST 2012


Hi Giovanni,
My question to you is exactly what do you mean by the previous safe state?
The previous safe state sounds like right after calling the EJB in
your case. Are you doing sync calls before that error? Can you
describe a little bit more about your scenario and how your activities
are being executed?
Cheers

On Tue, Jan 24, 2012 at 6:38 PM, Giovanni Marigi <gmarigi at redhat.com> wrote:
> Hi all,
> my question is about the completion of a custom workitem; my scenario:
>
> - process reaches and executes a custom work item
> - work item throws an exception (under the hood it calls an ejb that throws an exception)
> - the exception is catched inside the work item
> - inside the catch block the method manager.abortWorkItem is called
>
> In case of abortion of a work item I'm wondering why the nest step inside a process is anyway called?
> In case of abortion of a work item IMHO the process should not go on but "roll back" to the previous safe state
> This is the scenario my customer need.
>
> Actually I'm facing this situation not calling the method manager.abortWorkItem but throwing inside the work item a
> throw new IllegalStateException("****EJBControlWorkItemHandler:ILLEGAL STATE EXCEPTION!!!****")
>
> Maybe a solution could be an evaluation of the work item status after the completion of the work item. Anyway how can I handle an automatically rollback to a previous safe state?
>
> Thanks,
> Giovanni
>
> --
> Giovanni Marigi
> Red Hat - JBoss Consultant -
> email: gmarigi at redhat.com
> Mobile: +39 3423175986
> Office: +39 0687502315
>
> Red Hat Italy
> Via Andrea Doria 41m
> 00192 Roma - Italy
> www.redhat.com
>
> Prima di stampare, pensa all'ambiente ** Think about the environment before printing
>
> --
> Giovanni Marigi
> Red Hat - JBoss Consultant -
> email: gmarigi at redhat.com
> Mobile: +39 3423175986
> Office: +39 0687502315
>
> Red Hat Italy
> Via Andrea Doria 41m
> 00192 Roma - Italy
> www.redhat.com
>
> Prima di stampare, pensa all'ambiente ** Think about the environment before printing
> _______________________________________________
> jbpm-dev mailing list
> jbpm-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jbpm-dev



-- 
 - CTO @ http://www.plugtree.com
 - MyJourney @ http://salaboy.wordpress.com
 - Co-Founder @ http://www.jugargentina.org
 - Co-Founder @ http://www.jbug.com.ar

 - Salatino "Salaboy" Mauricio -



More information about the jbpm-dev mailing list