Re: [rules-users] Uses of timer node

2009-10-08 Thread Renato Herebia
Thanks Alexandros and Kris!

It works!

-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Uses of timer node

2009-10-07 Thread Renato Herebia
anyone?

-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] Uses of timer node

2009-10-05 Thread Renato Herebia
Hi!

I'm testing the timer node and I did a simple flow with start node, action
node (System.out.println("action node 1");),
a timer node, other action node (System.out.println("action node 2");) and
the end node. When the process start,
the first action node is triggered, after that, the timer node is activated
and don't pass for the next action node after
the delay time programmed.

Has any configuration to do when working with timer nodes (handlers, etc.)?
Someone has a simple example like
this I'm testing?

Thanks!

-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Process variables in split/action nodes

2009-10-02 Thread Renato Herebia
Yes! It works with drools 5.1.0!

Thanks Kris!!


-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


Re: [rules-users] Process variables in split/action nodes

2009-10-01 Thread Renato Herebia
   at
org.drools.base.mvel.MVELReturnValueEvaluator.evaluate(MVELReturnValueEvaluator.java:110)
at
org.drools.workflow.instance.impl.ReturnValueConstraintEvaluator.evaluate(ReturnValueConstraintEvaluator.java:121)
... 36 more

With Java dialect I got a problem when I add the rule flow to the
KnowledgeBuilderFactory:

java.lang.RuntimeException: Process Compilation error :
org.drools.lang.descr.processde...@69695f
com/sample/Process_com_sample_0.java (9:387) : Incompatible operand
types String and int

at com.sample.ProcessTest.readKnowledgeBase(ProcessTest.java:81)
at com.sample.ProcessTest.main(ProcessTest.java:30)


Using action node, I could get the variable process with mvel dialect in
action just calling:

System.out.println("The counting is: " + count);

If I use Java dialect with the same System.out, I got this problem after add
the rule flow to the KnowledgeBuilderFactory:

java.lang.RuntimeException: unable to execute Action
at
org.drools.workflow.instance.node.ActionNodeInstance.internalTrigger(ActionNodeInstance.java:56)
at
org.drools.workflow.instance.impl.NodeInstanceImpl.trigger(NodeInstanceImpl.java:111)
at
org.drools.workflow.instance.impl.NodeInstanceImpl.triggerConnection(NodeInstanceImpl.java:141)
at
org.drools.workflow.instance.impl.NodeInstanceImpl.triggerCompleted(NodeInstanceImpl.java:128)
at
org.drools.workflow.instance.node.StartNodeInstance.triggerCompleted(StartNodeInstance.java:49)
at
org.drools.workflow.instance.node.StartNodeInstance.internalTrigger(StartNodeInstance.java:41)
at
org.drools.workflow.instance.impl.NodeInstanceImpl.trigger(NodeInstanceImpl.java:111)
at
org.drools.ruleflow.instance.RuleFlowProcessInstance.internalStart(RuleFlowProcessInstance.java:16)
at
org.drools.process.instance.impl.ProcessInstanceImpl.start(ProcessInstanceImpl.java:185)
at
org.drools.workflow.instance.impl.WorkflowProcessInstanceImpl.start(WorkflowProcessInstanceImpl.java:230)
at
org.drools.common.AbstractWorkingMemory.startProcess(AbstractWorkingMemory.java:1639)
at
org.drools.impl.StatefulKnowledgeSessionImpl.startProcess(StatefulKnowledgeSessionImpl.java:272)
at com.sample.ProcessTest.main(ProcessTest.java:42)
Caused by: java.lang.ClassCastException: java.lang.Integer cannot be cast to
java.lang.String
at
com.sample.Process_com_sample_0Action0Invoker.execute(Process_com_sample_0Action0Invoker.java:18)
at
org.drools.workflow.instance.node.ActionNodeInstance.internalTrigger(ActionNodeInstance.java:54)
... 12 more


In this scenario, my doubts are:
- It's necessary any configuration for the access in action/split nodes to
process variables?
- How can I do that?


Thanks in advance.

-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] Process variables in split/action nodes

2009-09-29 Thread Renato Herebia
Hi!

How can I access process variables inside split nodes, in fact, in split
contraints?

I accessed a process variable named "count" in an action node like that:

Integer c = (Integer) kcontext.getVariable("count");
kcontext.setVariable("count", ++c);

But, in a split constraint doesn't work. So, my doubts are:
- How is the way in split constraints?
- Is there a simpler way to access process variables in action node?

Thanks!

-- 
Renato Herebia
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users


[rules-users] Variables in human tasks

2009-09-28 Thread Renato Herebia
Hi all!

I'm developing a flow to controll what each actor must do in my system using
human tasks for that.
After verify pending tasks for an actor, I have to verify what is the
persistent object related to this flow.
The idea to resolve this situation is to attribute the persistent object id
to a flow variable before start
the process and then attribute the flow variable to task variable/parameter.
Thus, when I have the list
of pending tasks for an actor, I can get the id of persistent object and
restore this object.

In this scenario, my doubt is: how to get the task variable/parameter?

Thanks!

-- 
Renato Herebia
Desenvolvimento
Dextra Sistemas - MPS.Br Nível F!
www.dextra.com.br
+55 19 3256-6722 Ramal 27

Este email é confidencial. Mais informações em:
This message is confidential. More information at:
www.dextra.com.br/confidencial.htm
___
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users