<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"Microsoft YaHei";
        panose-1:2 11 5 3 2 2 4 2 2 4;}
@font-face
        {font-family:"\@SimSun";
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:"\@Microsoft YaHei";
        panose-1:2 11 5 3 2 2 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        mso-fareast-language:ZH-CN;}
p.ecxmsonormal, li.ecxmsonormal, div.ecxmsonormal
        {mso-style-name:ecxmsonormal;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
p.ecxmsoacetate, li.ecxmsoacetate, div.ecxmsoacetate
        {mso-style-name:ecxmsoacetate;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
p.ecxmsolistparagraph, li.ecxmsolistparagraph, div.ecxmsolistparagraph
        {mso-style-name:ecxmsolistparagraph;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
p.ecxmsochpdefault, li.ecxmsochpdefault, div.ecxmsochpdefault
        {mso-style-name:ecxmsochpdefault;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
span.ecxmsohyperlink
        {mso-style-name:ecxmsohyperlink;}
span.ecxmsohyperlinkfollowed
        {mso-style-name:ecxmsohyperlinkfollowed;}
span.ecxemailstyle18
        {mso-style-name:ecxemailstyle18;}
span.ecxballoontextchar
        {mso-style-name:ecxballoontextchar;}
p.ecxmsonormal1, li.ecxmsonormal1, div.ecxmsonormal1
        {mso-style-name:ecxmsonormal1;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
span.ecxmsohyperlink1
        {mso-style-name:ecxmsohyperlink1;
        color:blue;
        text-decoration:underline;}
span.ecxmsohyperlinkfollowed1
        {mso-style-name:ecxmsohyperlinkfollowed1;
        color:purple;
        text-decoration:underline;}
p.ecxmsoacetate1, li.ecxmsoacetate1, div.ecxmsoacetate1
        {mso-style-name:ecxmsoacetate1;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        mso-fareast-language:ZH-CN;}
p.ecxmsolistparagraph1, li.ecxmsolistparagraph1, div.ecxmsolistparagraph1
        {mso-style-name:ecxmsolistparagraph1;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
span.ecxemailstyle181
        {mso-style-name:ecxemailstyle181;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.ecxballoontextchar1
        {mso-style-name:ecxballoontextchar1;
        font-family:"Tahoma","sans-serif";}
p.ecxmsochpdefault1, li.ecxmsochpdefault1, div.ecxmsochpdefault1
        {mso-style-name:ecxmsochpdefault1;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:10.0pt;
        font-family:SimSun;
        mso-fareast-language:ZH-CN;}
span.EmailStyle34
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";
        mso-fareast-language:ZH-CN;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>There’s not that much to say – and if you do a search you should find more information.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Basically only have the information that you need in memory. If you need to make calculations of previous state, rather than keeping the previous state all loaded up just have facts which record the state – perhaps an OrderTotal fact which contains the total of all the orders. When a new order arrives you update the value of that.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>It all depends on what you are trying to achieve and what you are doing. Without a concrete understanding of what sort of problem you are trying to solve and what you are planning to do we can’t give much more guidance beyond that there are various different solutions and approaches that are appropriate for various different problem spaces.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Thomas<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><div style='border:none;border-left:solid blue 1.5pt;padding:0cm 0cm 0cm 4.0pt'><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> rules-users-bounces@lists.jboss.org [mailto:rules-users-bounces@lists.jboss.org] <b>On Behalf Of </b>WangRamon<br><b>Sent:</b> 12 December 2011 09:50<br><b>To:</b> rules-users@lists.jboss.org<br><b>Subject:</b> Re: [rules-users] Can Drools supply large Knowledge Base?<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>Thanks Thomas!<br> <br>The solutions you provided are great, can you give more explanation on your second point "</span><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Use accumulating facts and only keep the data you need in memory</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>", thanks.<br> <br>Cheers<br>Ramon<br> <o:p></o:p></span></p><div><div class=MsoNormal align=center style='text-align:center'><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><hr size=2 width="100%" align=center id=stopSpelling></span></div><p class=MsoNormal style='margin-bottom:12.0pt'><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>From: TSwindells@nds.com<br>To: rules-users@lists.jboss.org<br>Date: Mon, 12 Dec 2011 09:24:14 +0000<br>Subject: Re: [rules-users] Can Drools supply large Knowledge Base?<o:p></o:p></span></p><div><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I think you are mixing up terms which doesn’t help.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I think you mean you may have 100GB of facts that will be in your distributed database. Unless you are planning to do some odd automatic rule generation you will have to write the rules by hand and so will only have a relatively small number of rules in your application – this will easily fit in memory.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>If 100GB is the size of the facts you have then clearly you can’t hold them all in memory of a single machine. Drools is effectively a special in memory database, in order to perform its processing it needs the relevant data.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>You basically have these options which of these will work depends on your use case and in reality you’ll probably need to combine them:</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal style='text-indent:-18.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>1.</span><span style='font-size:7.0pt;font-family:"Times New Roman","serif";color:#1F497D'> </span><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Use partitioning, rather than having 1 set of 100 gb of data, have 10 sets of 10 gbs running on ten machines. Many times you may be able to partition by customer ID or some other natural value which may give you good enough results.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal style='text-indent:-18.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>2.</span><span style='font-size:7.0pt;font-family:"Times New Roman","serif";color:#1F497D'> </span><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Use accumulating facts and only keep the data you need in memory, eg if you need to know how many orders a customer has made then don’t keep all the orders in memory, just a simple object containing the total.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal style='text-indent:-18.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>3.</span><span style='font-size:7.0pt;font-family:"Times New Roman","serif";color:#1F497D'> </span><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Don’t use drools, depending on what you are doing it may be better just to use normal db queries to extract the data you need. It may be you get the query results, insert them into a new short lived session, fire the rules and then get the results of the drools processing.</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Thomas</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p><div style='border:none;border-left:solid windowtext 1.5pt;padding:0cm 0cm 0cm 4.0pt;border-color:currentColor currentColor currentColor blue'><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:currentColor currentColor'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> rules-users-bounces@lists.jboss.org [mailto:rules-users-bounces@lists.jboss.org] <b>On Behalf Of </b>WangRamon<br><b>Sent:</b> 12 December 2011 09:11<br><b>To:</b> rules-users@lists.jboss.org<br><b>Subject:</b> Re: [rules-users] Can Drools supply large Knowledge Base?</span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p></o:p></span></p></div></div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'> <o:p></o:p></span></p><div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>Hi Guys<br> <br>I'm still confused about this question, let's say i may have a very large rule set, how can Drools support this case, will it load every rule into memory? Any idea? Thank you guys.<br> <br>Cheers<br>Ramon<br> <o:p></o:p></span></p><div><div class=MsoNormal align=center style='text-align:center'><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><hr size=2 width="100%" align=center></span></div><p class=MsoNormal style='margin-bottom:12.0pt'><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>From: ramon_wang@hotmail.com<br>To: rules-users@lists.jboss.org<br>Date: Thu, 8 Dec 2011 11:59:21 +0800<br>Subject: [rules-users] Can Drools supply large Knowledge Base?<o:p></o:p></span></p><div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'>Hi All <br> <br>I'm new to Drools, I will build a very large Knowledge Base, let's say it will be larger than 100GB, the files will be stored in a distribute database, so can Droools supply this large Knowledge Base? Any solution? Thank you very much. <br> <br>Cheers<br>Ramon<o:p></o:p></span></p></div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><br>_______________________________________________ rules-users mailing list <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a> <a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><o:p></o:p></span></p></div></div></div></div><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><o:p> </o:p></span></p><div class=MsoNormal align=center style='text-align:center'><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><hr size=2 width="100%" align=center></span></div><p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif";color:gray'><br>**************************************************************************************<br>This message is confidential and intended only for the addressee. If you have received this message in error, please immediately notify the <a href="mailto:postmaster@nds.com">postmaster@nds.com</a> and delete it from your system as well as any copies. The content of e-mails as well as traffic data may be monitored by NDS for employment and security purposes. To protect the environment please do not print this e-mail unless necessary.<br><br>NDS Limited. Registered Office: One London Road, Staines, Middlesex, TW18 4EX, United Kingdom. A company registered in England and Wales. Registered no. 3080780. VAT no. GB 603 8808 40-00<br>**************************************************************************************<br></span><span style='font-size:10.0pt;font-family:"Microsoft YaHei","sans-serif"'><br>_______________________________________________ rules-users mailing list <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a> <a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a><o:p></o:p></span></p></div></div></div></div></body></html>