<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.6000.16735" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>At this point, no specific improvements have been
implemented for the audit log.</FONT></DIV>
<DIV><FONT face=Arial size=2>It is indeed true that the audit log uses
toString() to get a snapshot of the relevant elements / variables.</FONT></DIV>
<DIV><FONT face=Arial size=2>This seems a good default, but any improvements to
make this more configurable are welcome of course.</FONT></DIV>
<DIV><FONT face=Arial size=2>The user could for example register a translator
that translates elements of a given Class to a String.</FONT></DIV>
<DIV><FONT face=Arial size=2>The introspection you mention could be one of the
options.</FONT></DIV>
<DIV><FONT face=Arial size=2>And we welcome any contributions !
:D</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Kris</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=zenzin@intalio.com href="mailto:zenzin@intalio.com">Oleg Zenzin</A>
</DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=rules-dev@lists.jboss.org
href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Monday, October 27, 2008 12:53
AM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> [rules-dev] audit logging:
better describe facts</DIV>
<DIV><BR></DIV>
<P>Best greatings to drools community!<BR></P>
<P>I'm using drools 4.0.4, my current aim is to generate audit log. </P>
<P>Using <EM>WorkingMemoryLogger</EM> and Drools Eclipse IDE Audit View I was
able to fulfil the requirement. Looks pretty nice, thanx for your work!<BR>I
have a couple of notes, but think it's better to keep them under different
threads. The first one is about <EM>facts</EM> output. Currently
<EM>WorkingMemoryLogger</EM> uses <EM>toString()</EM> to output information
about <EM>facts</EM> inserted, updated or retracted. In addition there's
information about <EM>facts</EM> in ActivationLogEvent, collected again using
<EM>toString() </EM>default method. In my code I've implemented simple
static method to introspect <EM>fact</EM> objects and produce
Map<String, Object> of properties. That made the log much more
informative.</P>
<P>Question: are there any enhacements (planned) in next versions of Drools?
Would you like me contribute my code into the
<EM>WorkingMemoryLogger</EM>?</P>
<P>Thanks!<BR>Oleg<BR></P>
<P>
<HR>
<P></P>_______________________________________________<BR>rules-dev mailing
list<BR>rules-dev@lists.jboss.org<BR>https://lists.jboss.org/mailman/listinfo/rules-dev<BR></BLOCKQUOTE></BODY></HTML>