<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
<br>
Hi Rob,<br>
<br>
another approach we're considering to version rulesets used to
perform mortgage risk assessment looks roughly as follows:<br>
<br>
- each of the rulesets is versioned as a whole (i. e. compile all
*.drl pertaining to a ruleset into a *.pkg file and give this *.pkg
a version number).<br>
- the scoring service is aware that rules evolve and selects the
ruleset which fits the "processing date". the processing date is
part of the scoring request we send to the service<br>
- scoring service loads selected ruleset and performs risk
assessment, sending back risk indicators<br>
<br>
We don't like the idea of time-dependent rules very much, as this
introduces *versioning* into the rule source code itself, which is
additional complexity we'd like to keep out of the *.drl files. We
want to be able to drop old rules from the source code once they are
not valid any more, but still have them compiled with a version
number somewhere in a repository, just in case a mortgage
application needs re-scoring based on an older version of the rules.
We can afford this rather "static" approach as our rules don't
change too often (like a few rules every week or two).<br>
<br>
Best regards<br>
<br>
Ansgar<br>
<br>
<br>
Am 24.08.2011 21:42, schrieb Rob Fisher:
<blockquote
cite="mid:46E27C67C2D6944DA71106BF2E0C33290A364B@WPSDGQGF.OPR.STATEFARM.ORG"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
<font face="Calibri" size="2"><span style="font-size: 11pt;">
<div>Looking for best practice recommendations around the
versioning of a rule. Our application will have 50-60 rule
sets comprised of up to 70 rules each. The activation of
many of the rules will be based on a processing date
(inserted fact attribute).
The application processing date can be prior, equal, or
after the system date.</div>
<div><font face="Times New Roman"> </font></div>
<div> </div>
<div>For example, 2 rules, with slightly different logic</div>
<div><font face="Times New Roman"> </font></div>
<div>Eligibility rule version 1</div>
<div>//to be potentially activated for application processing
time period prior to 2011</div>
<div>When</div>
<div> Car(color = “blue”)</div>
<div>Then</div>
<div style="text-indent: 9pt;">Terms(eligible = “yes”)</div>
<div><font face="Times New Roman"> </font></div>
<div>Eligibility rule version 2</div>
<div>//to be potentially activated for application processing
time period 2011 and forward</div>
<div>When</div>
<div> Car(color = “blue”, type=”coupe”)</div>
<div>Then</div>
<div> Terms(eligible = “yes”)</div>
<div><font face="Times New Roman"> </font></div>
<div>We’ve come up with a couple of different ways to handle
this:</div>
<ol style="margin: 0pt; padding-left: 36pt;">
<li>Add Date logic to LHS of the rule . i.e add
“Control(processingDate < ‘01/01/2011’)” to 1st rule
and “Control(processingDate >= ‘01/01/2011’)” to 2<font
size="1"><span style="font-size: 7.3pt;"><sup>nd</sup></span></font>
rule. First rule would activate
with processing date = 12/31/2010 and 2<font size="1"><span
style="font-size: 7.3pt;"><sup>nd</sup></span></font>
rule would activate with processing date = 07/31/2011.
When originally authored, first rule would be written
without date logic. When 2<font size="1"><span
style="font-size: 7.3pt;"><sup>nd</sup></span></font>
rule is authored, data logic will need to get added to
both. </li>
<li>We explored a way of setting the session clock to the
processing date and using the ‘date-effective’ and
‘date-expires’ attributes to do the filtering. i.e. 1<font
size="1"><span style="font-size: 7.3pt;"><sup>st</sup></span></font>
rule is effective until
12/31/2010 and 2<font size="1"><span style="font-size:
7.3pt;"><sup>nd</sup></span></font> rule is effective
from 01/01/2011 to 12/31/9999. However, we could only
figure out how to do this with a stateful knowledge
session. Is it possible in a Stateless?</li>
<li>We added metadata to the rules (@EffectiveDate and
@ExpirationDate), and using agendafilter, we compared
processing date to the metadata and return true or false
dependent on comparison.</li>
</ol>
<div style="text-indent: 9pt;"><font face="Times New Roman"> </font></div>
<div>What are your opinions on these three methods? What are
other options?</div>
<div><font face="Times New Roman"> </font></div>
<div>Thanks </div>
<div><font size="3"><span style="font-size: 12pt;">Rob</span></font></div>
<div><font face="Times New Roman"> </font></div>
<div><font face="Times New Roman"> </font></div>
<div><font face="Times New Roman"> </font></div>
</span></font>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
rules-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
</blockquote>
<br>
</body>
</html>