[rules-users] duration attribute & other rule language features issue

Prashant Badhe prashant.badhe at gmail.com
Fri Nov 25 14:44:53 EST 2011


Hi,

we were using drools engine 5.0.1 version with rules having 'duration',
'agenda-group' attributes and now we want to upgrade drools engine to 5.1.1
or latest 5.3.0 but we find 'duration' feature not working. What are the
equivalents of those features in 5.1.1 and in 5.3.0?


>From drools-expert document, 'duration' seems as deprecated with 'timer'.
But even 'timer' is not working. Putting 'timer' attribute as:


rule "test timer attribute"
    agenda-group "enrichment"
    auto-focus true
    no-loop
    salience 140
    timer ( int: 5s )
    //duration ( 5000 )
    when
          ......
   then
         ......
   end

gives "Error: java.lang.ArrayStoreException" Drools compilation error.
"timer ( 5s )" compiles, but the rule never fires.

We are also planning to use @expires in declare. But facts are not seems to
be expiring.

What am I missing here? What are the equivalent for 'duration' in
5.1.1/5.3.0 and how to use @expires in declare?
Please point us to some sample rules that uses these semantics and are
working.

Thanks in advance,
Prashant B.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20111126/6aa3adf4/attachment.html 


More information about the rules-users mailing list