<div dir="ltr">BRMS can be setup to use a DB, but it is not a &quot;normal&quot; table structure. Remember that BRMS stores everything in a JCR (Java Content Repository), so it is a JCR data model, not BRMS&#39;s.<br><br>I agree with Michael. Use an agenda listener to keep track of the firing of different rules.<br>
<br><div class="gmail_quote">On Fri, Oct 3, 2008 at 10:35 AM, techluver <span dir="ltr">&lt;<a href="mailto:techluver007@gmail.com">techluver007@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Thanks Michael. that gives me some idea.<br>
<br>
It think BRMS has its own tables to manage the rules(please correct if I&#39;m<br>
wrong).<br>
1.Can I directly make/delete rule entry in those table without using BRMS.<br>
Will BRMS identify those rules without any issues?<br>
2. Can I reference the Ids(something rule_id) from these table as foreign<br>
key in my other app tables?<br>
Please clarify,<br>
<div><div></div><div class="Wj3C7c"><br>
<br>
<br>
Michael Neale wrote:<br>
&gt;<br>
&gt; BRMS is more of a design time feature - what you are talking is<br>
&gt; logging an audit trail of rules execution - you can do that with event<br>
&gt; listeners in your code (so your rules don&#39;t even have to be aware of<br>
&gt; it) then as rules fire, you can grab the details (from the listener<br>
&gt; APIs) and log it as you please !<br>
&gt;<br>
&gt;<br>
&gt; Michael.<br>
&gt;<br>
&gt; On Thu, Oct 2, 2008 at 5:01 AM, techluver &lt;<a href="mailto:techluver007@gmail.com">techluver007@gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; I&#39;m new to drools world. Kindly clarify following things<br>
&gt;&gt;<br>
&gt;&gt; My requirement is to log each data in the DB(that meets any of the<br>
&gt;&gt; business<br>
&gt;&gt; rule) along with rule info.<br>
&gt;&gt;<br>
&gt;&gt; if I use BRMS ( i think it maintains the rules separately in its own db<br>
&gt;&gt; table)<br>
&gt;&gt;<br>
&gt;&gt; How I can associate each log with the rule info?<br>
&gt;&gt;<br>
&gt;&gt; Approach 1. Can I access BRMS&#39;s rules directly and associate it in my<br>
&gt;&gt; logging?<br>
&gt;&gt;<br>
&gt;&gt; Approach 2. I can&#39;t do Approach 1, then I&#39;m thinking to have RULES table<br>
&gt;&gt; in<br>
&gt;&gt; my app db.Then whenever any rule is added using BRMS, Then add an entry<br>
&gt;&gt; into<br>
&gt;&gt; RULES table and use this table for my logging<br>
&gt;&gt;<br>
&gt;&gt; Please advise me on the right approach.<br>
&gt;&gt;<br>
&gt;&gt; Thanks in advance.<br>
&gt;&gt; --<br>
&gt;&gt; View this message in context:<br>
&gt;&gt; <a href="http://www.nabble.com/BRMS-rule-info-logging-tp19766982p19766982.html" target="_blank">http://www.nabble.com/BRMS-rule-info-logging-tp19766982p19766982.html</a><br>
&gt;&gt; Sent from the drools - user mailing list archive at Nabble.com.<br>
&gt;&gt;<br>
&gt;&gt; _______________________________________________<br>
&gt;&gt; rules-users mailing list<br>
&gt;&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt;&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; --<br>
&gt; Michael D Neale<br>
&gt; home: <a href="http://www.michaelneale.net" target="_blank">www.michaelneale.net</a><br>
&gt; blog: <a href="http://michaelneale.blogspot.com" target="_blank">michaelneale.blogspot.com</a><br>
&gt; _______________________________________________<br>
&gt; rules-users mailing list<br>
&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;<br>
&gt;<br>
<br>
</div></div><font color="#888888">--<br>
View this message in context: <a href="http://www.nabble.com/BRMS-rule-info-logging-tp19766982p19799028.html" target="_blank">http://www.nabble.com/BRMS-rule-info-logging-tp19766982p19799028.html</a><br>
</font><div><div></div><div class="Wj3C7c">Sent from the drools - user mailing list archive at Nabble.com.<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</div></div></blockquote></div><br></div>