[jboss-user] [jBPM] - Re: can i use rule task in embedded sub-process?
hardawaycg
do-not-reply at jboss.com
Thu Jan 12 22:39:22 EST 2012
hardawaycg [https://community.jboss.org/people/hardawaycg] created the discussion
"Re: can i use rule task in embedded sub-process?"
To view the discussion, visit: https://community.jboss.org/message/646596#646596
--------------------------------------------------------------
sorry,after kinds of test,i found this is not because of embedded sub-process,but signal event.
rule task doesn't work on a flow file if these is signal event,this is my test case:
scene1: just like below,it works:
https://community.jboss.org/servlet/JiveServlet/showImage/2-646596-17769/%E6%9C%AA%E5%91%BD%E5%90%8D.jpg https://community.jboss.org/servlet/JiveServlet/downloadImage/2-646596-17769/450-149/%E6%9C%AA%E5%91%BD%E5%90%8D.jpg
with java code like this,the console print run,it works.
ProcessInstance process = ksession.startProcess("test2Flow");
ksession.fireAllRules();
ksession.signalEvent("event1", null,process.getId());
scene2:
1、replace the script task with a rule task,and set ruleflowgroup as sub1
https://community.jboss.org/servlet/JiveServlet/showImage/2-646596-17770/22%E5%90%8D.jpg https://community.jboss.org/servlet/JiveServlet/downloadImage/2-646596-17770/450-125/22%E5%90%8D.jpg
2、create a drl file and write a rule name "rule1":
rule "rule1"
ruleflow-group "sub1"
when
then
System.out.println("sub1");
end
3、add the drl resource on java code ,then run code like before.
the result is console print nothing ? why ?
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/646596#646596]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120112/fc88553e/attachment.html
More information about the jboss-user
mailing list