On 1 December 2010 17:19, Anais Martinez <amartinez(a)iti.upv.es> wrote:
> What does your thread do after it returns from fireAllRules?
My thread sleeps five minutes and then it fires again: (intervalLength =
5*60*1000):
You might as well let the Engine sleep, waiting for news.
If you turn it on, every now and then, you'll get all sorts of delays. Say,
an event arrives 1ms after you've returned from an unsuccessful
fireAllRules()
(there's no "fireRules()" method, is there?), then you won't get any
reaction
until next time round, i.e., 5 minutes later. This may not be as expected.
Regards
-W
@Override
public void run(){
while(!end){
try {
Thread.sleep(intervalLength);
int nRules = ksession.fireRules();
if(nRules > 0){
logger.debug(nRules + " reglas disparadas.");
}
}
catch (InterruptedException e) {
logger.error(e);
}
}
}
>Well, if the events arrive on schedule it should be OK, but what about the
delayed arrivals?
Ah, ok...
Thank you, again.
--
View this message in context:
http://drools-java-rules-engine.46999.n3.nabble.com/Question-about-collec...
Sent from the Drools - User mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users