[rules-users] Rules trace questions
Anais Martinez
amartinez at iti.upv.es
Wed Nov 24 09:10:11 EST 2010
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 *next*. Other activations may result in
firings
>in between.
You mean that if I write in the RHS, the event trace will contain
activations of another traces?
Is WorkingMemoryInMemoryLogger unstable too? I just have tested it by
sending the
result of getEvents from RHS to a java class (which controles the string). I
have change the filter too. In the main method:
Message message = new Message();
message.setMessage("Message 1 hello");
message.setStatus(Message.HELLO);
ksession.insert(message);
Message message2 = new Message();
message2.setMessage("Message 2 goodbye");
message2.setStatus(Message.GOODBYE);
ksession.insert(message2);
ksession.fireAllRules();
The result of getEvents() is:
<object-stream>
<list>
<org.drools.audit.event.ActivationLogEvent>
<type>7</type>
<activationId>GoodBye [2]</activationId>
<rule>GoodBye</rule>
<declarations>myMessage=Message 2 goodbye(2)</declarations>
</org.drools.audit.event.ActivationLogEvent>
<org.drools.audit.event.ActivationLogEvent>
<type>7</type>
<activationId>regla final [3]</activationId>
<rule>regla final</rule>
<declarations>s=Salida( text=Message 2 goodbye )(3)</declarations>
</org.drools.audit.event.ActivationLogEvent>
<org.drools.audit.event.ActivationLogEvent>
<type>7</type>
<activationId>Hello World [1]</activationId>
<rule>Hello World</rule>
<declarations>myMessage=Message 1 hello(1); m=Message 1
hello(1)</declarations>
</org.drools.audit.event.ActivationLogEvent>
<org.drools.audit.event.ActivationLogEvent>
<type>7</type>
<activationId>GoodBye [1]</activationId>
<rule>GoodBye</rule>
<declarations>myMessage=Message 1 hello(1)</declarations>
</org.drools.audit.event.ActivationLogEvent>
</list>
</object-stream>
Thank you again.
--
View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Rules-trace-questions-tp1960008p1960828.html
Sent from the Drools - User mailing list archive at Nabble.com.
More information about the rules-users
mailing list