-
1. Re: Solution needed
swiderski.maciej Jan 25, 2012 1:49 AM (in response to jbpm_new)1. How to set the variables in the rule task node(drl file) and carry the same variables to further nodes.
you could try something like this:
when $process : WorkflowProcessInstance() then $process.setVariable("name", "value")
2. is it posssible to fire the drl file or rules by sending the drl file name as a parameter to a node as on-entry condition.
Why would you like to do that? In my opinion for such purpose you have bunsiness rule task
HTH
-
2. Re: Solution needed
jbpm_new Jan 26, 2012 10:12 AM (in response to swiderski.maciej)Hi Maciej thanks for replying.
i am convinced by the first answer thanks for that.
For my second question,, I have a scenario like, when reaching a node certain rule should only be fired.. Now what is happening is, whenever i use ksession.fireAllRules() all the rules are getting triggered which are loaded in the knowledge base, so i want to fire specific rules in a drl file or entire drl file by mentioning its name in a human task node.
Hope i made my doubt clear to you now.
Please do reply
Thanks
Mahesh
-
3. Re: Solution needed
swiderski.maciej Jan 26, 2012 12:42 PM (in response to jbpm_new)For selecting particular rule(s) while invoking fireAllRules you could use implementation of AgendaFilter.
A good out of the box implementation is org.drools.base.RuleNameEqualsAgendaFilter, that accepts name of the rule to execute as constructor argument.
HTH
-
4. Re: Solution needed
jbpm_new Jan 27, 2012 2:55 AM (in response to swiderski.maciej)Thanks for your valuable solutions.
I got it through your replies.
Thanks
Mahesh
-
5. Re: Solution needed
swiderski.maciej Jan 28, 2012 2:11 PM (in response to jbpm_new)Goodie, please mark question as answered if you feel it provided you with enough information.
Cheers
-
6. Re: Solution needed
jbpm_new Jan 31, 2012 10:15 AM (in response to swiderski.maciej)Hi Maciej ,
I have a requirement like, I need to pass a map to the drl.
I have seen examples, wherein we are taking the variables of class by forming the object.
Now I need to get and put the values from a map.
Please provide me one example.
Thanks