cancel
Showing results for 
Search instead for 
Did you mean: 

Broadcasting data by activiti to other systems

mady
Champ in-the-making
Champ in-the-making
Here's my situation: lets say a user creates a flow using the activiti designer, then adds some code to the xml by hand. After he finishes he uses activiti-explorer and the other apps to load it and start the process. Lets say that process has 2 tasks and that the user starts the first one (which will last for a certain amount of time). Is there a way (webservices etc.) to make activiti broadcast the fact that task1 is completed when it finishes? I'd like to notice my own application that task1 finished (and preferably lets the user to start task2). I know I can get the state of that task/process using REST, but I'd prefer not to have to request it ever X seconds/minutes/hours/whatever but to get it from activiti when the state changes.
2 REPLIES 2

frederikherema1
Star Contributor
Star Contributor
Hi,

I think you are looking for task-listeners. This way, you can execute java-code (or evaluate expression) when a task is created or ended.
Check out this section in the userguide: http://activiti.org/userguide/index.html#taskListeners

mady
Champ in-the-making
Champ in-the-making
Thanks frederikheremans,

I already noticed that there is a possibility of using listeners and special java tasks and I know I can use those. I was just wondering is there an in-built mechanism (in activiti) for what I want to do.