[JBoss jBPM] - Decision Handler to result in default transition
by jgemski
We've run into a problem on upgrading from 3.1.4 to any version >= 3.2.3.
Our DecisionHandler.decide used to return a null, which indicated to the Decision code to use the default transition.
Upon upgrading, we're now getting:
org.jbpm.JbpmException: decision 'mid' selected non existing transition 'null'
at org.jbpm.graph.node.Decision.execute(Decision.java:91)
at org.jbpm.graph.def.Node.enter(Node.java:318)
at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:197)
.
.
.
Looking at the code, it looks like this is no longer possible.
In Decision.java
String transitionName = decisionHandler.decide(executionContext);
| transition = getLeavingTransition(transitionName);
| if (transition == null) {
| throw new JbpmException("decision '" + name + "' selected non existing transition '" + transitionName + "'");
| }
|
which prevents later code from running:
if (transition == null) {
| transition = getDefaultLeavingTransition();
| log.debug("decision didn't select transition, taking default " + transition);
| }
Was this intentionally taken away? Is there a way to accomplish the same behavior, which is to default the "default" transition if the DecisionHandler doesn't evaluate?
Thanks,
John
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4196307#4196307
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4196307
17 years, 3 months
[JBoss jBPM] - Re: HTML support in mail templates
by kukeltje
anonymous wrote : Funny, that's not written in the documentation.
That probably because task-assign and task-reminder should be in the mail templates by default.
anonymous wrote : What if I don't use templates - does that mean notify won't work ??
Yes, because that is the way they work.... If you don't have a car can you drive one?
anonymous wrote :
| My scenario is that a user pulls a task from a pool. The notify causes an email to be fired to himself. Isn't very useful. I would want an admin guy to assign tasks to people and they should be notified via email. Have you implemented anything like that ?
Don't think anybody implemented it, but it would be a nice addition..... In combination with sending mail to the pooled actors to don't send a mail if the current actor is pulling a task from the pool and assign it to himself, but do send it if a manager/admin guy does it. Feel free to implement that in jBPM and contribute it and file a Jira issue.
You can also just file a jira and hope it attracts enough attention to be implemented.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4196304#4196304
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4196304
17 years, 3 months