cancel
Showing results for 
Search instead for 
Did you mean: 

Retrieve error code from boundary event (Java Api)

gribas
Champ in-the-making
Champ in-the-making
Hi folks,

I am a newbie on activity engine, I searched if is there a way to retrieve the error code in Java from a boundary event but I didn't find anything.

Basically I have a process similar to this (it's a reduced format of the main one):

[IMG]http://i59.tinypic.com/2i0syyq.png[/IMG]

Is there a way to know the Error code that has been thrown and it goes to the error start event? Is there a way to store the error code easily on the process?

I would like to know the error code because then I can present an error message to the user.

I checked the runtime service but there I didn't find anything for check the errors.

Thanks for your help,

Regards,
Gerard.
4 REPLIES 4

smirzai
Champ on-the-rise
Champ on-the-rise
Don't you need to mention the error code in your catching part, either error start event or a boundary event to catch it in first place ?
It means you will know the error code, becuase it is activated.

encircled
Champ in-the-making
Champ in-the-making
Hi,
I have the same question. The problem is that boundaryEvent returns workflow (for example) to previous user task and I can't find any built-in support for getting error code from user task.

Regards,
Vlad

jbarrez
Star Contributor
Star Contributor
Not sure if I'm following here. The fact that the event was catched, is the information. You could set a variable using a listener if you need it later on.

encircled
Champ in-the-making
Champ in-the-making
Yes, I need to save the error code (or anything else about the error) for later usage and was wondering if Activiti do it itself.
Will do it with listeners, thanks