title: Drools: timer vs. duration attributes
body: <p>Drools' <a href="http://docs.jboss.org/drools/release/6.0.0.Final/drools-docs/html_single/index.html#d0e6607" rel="nofollow">documentation</a> says that <em>timer</em> attribute is preferred now over <em>duration</em>:</p>
  
  <blockquote>
    <p>Rules now support both interval and cron based timers, which replace the now deprecated duration attribute.</p>
  </blockquote>
  
  <p>But I've detected that such rule wouldn't work:</p>
  
  <pre><code>rule "Expired auth"
      timer(int: 5s)
  
      when
          $auth   : Authorized()
          $noauth : NotAuthorized()
      then
          retract($auth);
          retract($noauth);
  end
  </code></pre>
  
  <p>because when it gets evaluated a first time all the facts are being removed and the rule won't be scheduled as expected.
  But I've found that a rule with <em>duration</em> attribute works as it should:</p>
  
  <pre><code>rule "Expired auth"
      duration(5s)
  
      ...
  end
  </code></pre>
  
  <p>So is there any way to do it via <i>timer</i>s?</p>