I have had to implement an actionHandler that replaces the action because I want to be able to dynamically update the dueDate (see
http://www.jboss.org/index.html?module=bb&op=viewtopic&t=85157
and
http://www.jboss.org/index.html?module=bb&op=viewtopic&t=82969
)
So I have done the following in an actionHandler:
jbpmContext = executionContext.getJbpmContext(); jbpmContext.save(executionContext.getProcessInstance()); CreateTimerAction cta = new CreateTimerAction(); //Timer and duedate are required fields cta.setTimerName(timerName); cta.setDueDate(strDueDate); if (transitionName != null) cta.setTransitionName(transitionName); if (repeat != null) cta.setRepeat(repeat); if (timerAction != null) //cta.setTimerAction((Action) Class.forName(timerAction).newInstance()); cta.setTimerAction(new Action(new Delegation(timerAction)));
<action class="com.homeq.payoffdemand.jbpm.actions.CreatePDWTimerActionHandler"> <timerName>UPES_Wait_for_Expiry</timerName> <dueDate>fidelityMaintWait</dueDate> <transitionName>UPES_Wait_for_Expiry_Decision</transitionName> <timerAction>com.homeq.payoffdemand.jbpm.actions.upes.CalcWaitForExpiryActionHandler</timerAction> </action>