Thanks Wolfgang for adding completeness to my response.<div><br></div><div>Best Regards,<br clear="all"><br>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<br><br>Esteban Aliverti<br>- Blog @ <a href="http://ilesteban.wordpress.com" target="_blank">http://ilesteban.wordpress.com</a><br>
<br><br><div class="gmail_quote">On Tue, Oct 30, 2012 at 11:07 AM, Wolfgang Laun <span dir="ltr"><<a href="mailto:wolfgang.laun@gmail.com" target="_blank">wolfgang.laun@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
See below.<br>
<div class="im"><br>
On 30/10/2012, Esteban Aliverti <<a href="mailto:esteban.aliverti@gmail.com">esteban.aliverti@gmail.com</a>> wrote:<br>
> For simple validation rules the main benefit of using drools is the<br>
> decoupling of your business logic from your application. Another benefit is<br>
> the power of DRL language. For example, implementing the 'exists',<br>
> 'collect', 'accumulate', 'from' etc. behavior in plain java is not a<br>
> trivial task.<br>
<br>
</div>This enumeration omits the most important feature available in a rule's<br>
condition: the dynamic creations of all Cartesian products of facts<br>
matching the constraints. Example:<br>
<br>
$p: Person( age >= 60 )<br>
Car( owner == $p )<br>
<br>
This finds all cars owned by persons over 60, which relieves you from the task<br>
of writing loops to determine all matching combinations, which can become quite<br>
cumbersome with increasing complexity.<br>
<div class="im"><br>
> In Drools you already have all that power and you can create<br>
> really complex rules with just a few lines of DRL.<br>
> For more complex scenarios, you can use Drools for:<br>
><br>
</div>> - make inference (impossible to do in java without implementing some<br>
> kind of inference engine).<br>
> - use temporal patterns in your rules.<br>
> - Use TMS<br>
> - more...<br>
<br>
There is the option of creating a domain specific language on top<br>
of DRL, which is one way of making your business logic intellegible<br>
to non-programmers, so that they can at least understand what's<br>
going on.<br>
<span class="HOEnZb"><font color="#888888"><br>
-W<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
><br>
> Best Regards,<br>
><br>
> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<br>
><br>
> Esteban Aliverti<br>
> - Blog @ <a href="http://ilesteban.wordpress.com" target="_blank">http://ilesteban.wordpress.com</a><br>
><br>
><br>
> On Tue, Oct 30, 2012 at 9:43 AM, cheikh dhib <<a href="mailto:dhib.cheikh@gmail.com">dhib.cheikh@gmail.com</a>> wrote:<br>
><br>
>> Hello,<br>
>> This is what i think (has to be confirmed from specialist)<br>
>><br>
>> Every thing you do in Drools you can do it as well in Java. But if you<br>
>> have a modification on your java code, you have to modify, then compile<br>
>> and deploy. contrary to the Drl rules which are interpreted, so after<br>
>> modification you don't need to do any thing just save your modification.<br>
>> So in the case of drools you have some flexibility which means that the<br>
>> rules can be managed directly by the decider and not the developer.<br>
>><br>
>> regards,<br>
>> Cheikh<br>
>><br>
>><br>
>> Le 29/10/2012 23:57, kina06 a écrit :<br>
>> > Please don't ignore this question as routine, did google and read<br>
>> posting,<br>
>> > didn't get satisfying answer, hope you guys can help.<br>
>> ><br>
>> > I have seen some drool rules in our company, I know drools provide<br>
>> > declarative rules, easy to modify etc etc, but I see it does need some<br>
>> > programming knowledge, so why not put all your rule logic into Java<br>
>> > code,<br>
>> > what is drools doing different can't be implemented in Java a separate<br>
>> > package (like your logic package). Except losing flexibility of modify<br>
>> > code/logic in text file I don't see much benefit.<br>
>> ><br>
>> > Please help me understand, whats the major benefit of drools rules that<br>
>> > can't be done in Java with same set of concise code.<br>
>> ><br>
>> ><br>
>> ><br>
>> > --<br>
>> > View this message in context:<br>
>> <a href="http://drools.46999.n3.nabble.com/Drool-rules-vs-java-code-effiency-tp4020549.html" target="_blank">http://drools.46999.n3.nabble.com/Drool-rules-vs-java-code-effiency-tp4020549.html</a><br>
>> > Sent from the Drools: User forum mailing list archive at Nabble.com.<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>
>> 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>
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>