<div dir="ltr">BRMS can be setup to use a DB, but it is not a "normal" table structure. Remember that BRMS stores everything in a JCR (Java Content Repository), so it is a JCR data model, not BRMS'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"><<a href="mailto:techluver007@gmail.com">techluver007@gmail.com</a>></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'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>
><br>
> BRMS is more of a design time feature - what you are talking is<br>
> logging an audit trail of rules execution - you can do that with event<br>
> listeners in your code (so your rules don't even have to be aware of<br>
> it) then as rules fire, you can grab the details (from the listener<br>
> APIs) and log it as you please !<br>
><br>
><br>
> Michael.<br>
><br>
> On Thu, Oct 2, 2008 at 5:01 AM, techluver <<a href="mailto:techluver007@gmail.com">techluver007@gmail.com</a>> wrote:<br>
>><br>
>> I'm new to drools world. Kindly clarify following things<br>
>><br>
>> My requirement is to log each data in the DB(that meets any of the<br>
>> business<br>
>> rule) along with rule info.<br>
>><br>
>> if I use BRMS ( i think it maintains the rules separately in its own db<br>
>> table)<br>
>><br>
>> How I can associate each log with the rule info?<br>
>><br>
>> Approach 1. Can I access BRMS's rules directly and associate it in my<br>
>> logging?<br>
>><br>
>> Approach 2. I can't do Approach 1, then I'm thinking to have RULES table<br>
>> in<br>
>> my app db.Then whenever any rule is added using BRMS, Then add an entry<br>
>> into<br>
>> RULES table and use this table for my logging<br>
>><br>
>> Please advise me on the right approach.<br>
>><br>
>> Thanks in advance.<br>
>> --<br>
>> View this message in context:<br>
>> <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>
>> 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>
>><br>
><br>
><br>
><br>
> --<br>
> Michael D Neale<br>
> home: <a href="http://www.michaelneale.net" target="_blank">www.michaelneale.net</a><br>
> blog: <a href="http://michaelneale.blogspot.com" target="_blank">michaelneale.blogspot.com</a><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>
><br>
><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>