Hello,

I need to run some code every time a task assignment changes, but I need the 
code to run after the new assignment has been made. I thought I could use an

<event type="task-assign"><action 
class="com.mycompany.MyActionHandler"></action></event>

in my jpdl task def, but the EVENTTYPE_TASK_ASSIGN is fired before the task 
assignment is made (see source for TaskInstance.setActorId(String, boolean)). 
For my purposes, I just changed this method so that the event is fired _after_ 
the task assignment is made, but I imagine that this in not the best way to 
accomplish what I want. It will certainly make it hard to upgrade my jbpm 
version!

In the jpdl spec at 
http://docs.jboss.org/jbpm/v3/userguide/jpdl.html#task.element in the 
description of supported event types it states "Especially for the task-assign 
we have added a non-persisted property previousActorId to the TaskInstance". 
But the previousActorId property is not set until after EVENTTYPE_TASK_ASSIGN 
is fired either. So if it's not set until after the event is fired I don't 
understand why the property was added "especially for the task-assign".

I fear that I'm missing something here and that there must be a way to fire an 
event after a task is assigned and I'm just not seeing it. Can anyone point out 
what I'm missing?

Thanks!

-Brian

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3924117#3924117

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3924117


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to