[rules-users] Updating interval events

2010-11-11 Thread anais
Hello. I'm using Drools in a system of alarms. I have a drl file with rules in wich I have defined events that are java classes. I have defined timed events and interval events. My idea is that an external timer inserts some interval events time to time. Well, the thing is that I need update an

Re: [rules-users] Updating interval events

2010-11-11 Thread Anais Martinez
Thank you very much. That's what I need to know. -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Updating-interval-events-tp1881686p1882499.html Sent from the Drools - User mailing list archive at Nabble.com. ___ r

[rules-users] Reasoning with past events

2010-11-15 Thread Anais Martinez
I'm using Drools for a system of alarms on agriculture. I am considering several parcels, whose plants can be on different status (for example, sprouting, flowering, etc.). These statuses are updated automatically by rules, controled by several calendars. In the other hand, the farmer is allowed t

Re: [rules-users] Reasoning with past events

2010-11-15 Thread Anais Martinez
The system is receiving readings from real sensors of humidity, temperature, etc.. There are a lot of rules for deciding if a specific plague or illness affects (or can affect) to the plants or not: One condition of those rules is the plants' status, because the illnesses affect to the plant depe

Re: [rules-users] Reasoning with past events

2010-11-15 Thread Anais Martinez
Well, I'm in a dead end with my model, so I'm going to consider your idea. I think it is best solution. Thanks again. -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Reasoning-with-past-events-tp1903815p1904505.html Sent from the Drools - User mailing list a

[rules-users] Rules trace questions

2010-11-24 Thread Anais Martinez
Hello. I'm trying to get the rules trace in execution by using WorkingMemoryFileLogger. I am using the Hello word example, and I call the WorkingMemoryFileLogger.wirteToDisk() in the RHS of rules. My modified drl file is: import com.sample.DroolsTest.Message; global org.drools.audit.WorkingMem

Re: [rules-users] Rules trace questions

2010-11-24 Thread Anais Martinez
Thanks for your response. So, I have to change LogEvent.ACTIVATION_CREATED to LogEvent.AFTER_ACTIVATION_FIRE, right? >Triggering the writing of a log to disk by inserting a fact (Output) may >cause confusion since there's no guarantee that the firing according to >the new Output() will happen

Re: [rules-users] Rules trace questions

2010-11-24 Thread Anais Martinez
Sorry, change "Salida" to "Output", I have the drl in spanish... -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Rules-trace-questions-tp1960008p1960862.html Sent from the Drools - User mailing list archive at Nabble.com.

Re: [rules-users] Rules trace questions

2010-11-24 Thread Anais Martinez
Ah, ja ja ja . "no translations": I will remember next time... Well, thank you again. -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Rules-trace-questions-tp1960008p1961418.html Sent from the Drools - User mailing list archive at Nabble.com. __

[rules-users] Question about collect and sliding windows

2010-12-01 Thread Anais Martinez
Hello. I have two questions about collect and sliding windows. I have created this rule: rule "Active risk" when $n:Node() $readings: ArrayList(size==80) from collect( Reading( nodeID == $n.nodeID, (signalType == SignalType.PLUVIOSITY && value >= 10)|| (signalType == SignalType.AIR

Re: [rules-users] Question about collect and sliding windows

2010-12-01 Thread Anais Martinez
Yes, I use Stream mode and real clock. I have a thread wich call fireAllrules of the session. Do I change to fireUntilHalt? The size==80 is because each type of reading comes each 15 minutes (2 types of readings * 4 readings each hour * 10 hours). Right or I change to >=? I have one only entry-

Re: [rules-users] Question about collect and sliding windows

2010-12-01 Thread Anais Martinez
> What does your thread do after it returns from fireAllRules? My thread sleeps five minutes and then it fires again: (intervalLength = 5*60*1000): @Override public void run(){ while(!end){ try { Thread.sleep(intervalLength); int nRules =

Re: [rules-users] Question about collect and sliding windows

2010-12-02 Thread Anais Martinez
Well, I have tested it during 10 hours this night, by sending the readings each 15 minutes and it works, because the interval of sending is exactly what was needed. Therefore, you are right: the problem is in the delayed readings, and if the server changes the frequency of sending or sends all re

[rules-users] Error at inserting a fact

2010-12-09 Thread Anais Martinez
Hi. I want to test several rules and I'm using pseudo-clock and stream mode. When I insert the first fact, Drools generates an error of "timestamp must be greater 0". But if I use real clock, the message doesn't appears. The fact is a java class, but I haven't defined the timestamp. What is the

Re: [rules-users] Error at inserting a fact

2010-12-10 Thread Anais Martinez
I use ((SessionPseudoClock) session.getSessionClock()).advanceTime(value, units) to advance time, with value = 1, units = TimeUnit.DAYS. Do I have to set the clock to a variable instead of calling in this way? I have two facts. Their declarations are: declare Subparcel @role( fact) end

Re: [rules-users] Error at inserting a fact

2010-12-10 Thread Anais Martinez
The calendars are Annual calendars. I have just noticed that I have added the calendars after reading drl files. Is that the problem? I'm going to test each calendar... -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Error-at-inserting-a-fact-tp2058311p206