ApplicationContext appContext = WorkflowUtil.getApplicationContext();
WorkflowHelper workflowMapper = (WorkflowHelper) appContext.getBean("workflowHelper");
try {
WorkflowDeadline workflowDeadline = new WorkflowDeadline();
workflowDeadline.setContext(context);
workflowDeadline.setDeadlineExpression(expr);
WorkflowDeadline newDeadline = workflowMapper.executeDeadlinePlugin(procId, actId, workflowDeadline, (Date) context.get(SharkConstants.PROCESS_STARTED_TIME), (Date) context.get(SharkConstants.ACTIVITY_ACCEPTED_TIME), (Date) context.get(SharkConstants.ACTIVITY_ACTIVATED_TIME));
expr = newDeadline.getDeadlineExpression();
} catch (Exception e) {
//ignore
}
}