<p>@Wolfgang,</p>
<p>thanks a lot for ur wonderful explanation regarding the Dialect...<br>But i still cant find the better way<br>to know the exact error in some cases ,one case <br>i had mentioned in my previous post ...i want to highlight<br>
that my drl are loading from database so i cant put break point <br>in drl.</p>
<p>appreciate ur help.</p>
<div>thanks</div>
<div>Puneet<br><br> </div>
<div><span class="gmail_quote">On 5/4/10, <b class="gmail_sendername">Wolfgang Laun</b> &lt;<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Here, I&#39;ve found this for you, a comment from the Drools source file<br>org.drools.rule.builder.dialect.java.JavaDialectConfiguration<br>
<br>* There are options to use various flavours of runtime compilers.<br>* Apache JCI is used as the interface to all the runtime compilers.<br>*<br>* You can also use the system property &quot;drools.compiler&quot; to set the<br>
desired compiler.<br>* The valid values are &quot;ECLIPSE&quot; and &quot;JANINO&quot; only.<br>*<br>* drools.dialect.java.compiler = &lt;ECLIPSE|JANINO&gt;<br>* drools.dialect.java.lngLevel = &lt;1.5|1.6&gt;<br>*<br>* The default compiler is Eclipse and the default lngLevel is 1.5.<br>
* The lngLevel will attempt to autodiscover your system using the<br>* system property &quot;java.version&quot;<br>*<br>* The JavaDialectConfiguration will attempt to validate that the<br>specified compiler<br>* is in the classpath, using ClassLoader.loasClass(String). If you intented to<br>
* just Janino sa the compiler you must either overload the compiler<br>property before<br>* instantiating this class or the PackageBuilder, or make sure<br>Eclipse is in the<br>* classpath, as Eclipse is the default.<br><br>
Try it without the JANINO setting - it *should* flag the setter with<br>the incompatible types.<br><br>If you haven&#39;t used MVEL so far, I don&#39;t see any reason to start now.<br><br>-W<br><br><br>2010/5/4 Puneet duggal &lt;<a href="mailto:duggalpunit@gmail.com">duggalpunit@gmail.com</a>&gt;:<br>
&gt; @  Wolfgang Laun ,<br>&gt;<br>&gt; i am using just this statement:-<br>&gt;<br>&gt; javaConf.setCompiler( JavaDialectConfiguration.JANINO );<br>&gt;<br>&gt; I dont know the exact use of this statement .I  am not using the mvel<br>
&gt; , i tried to google abt it but couldnt find the use of this ...<br>&gt; can u through some light on this.<br>&gt;<br>&gt; Thanks<br>&gt;<br>&gt;<br>&gt; On 5/4/10, Wolfgang Laun &lt;<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>&gt;&gt; Actually, this kind of error isn&#39;t discovered by the Drools DRL compiler;<br>&gt;&gt; it would be flagged by the Java compiler. (You can verify: if you make the<br>&gt;&gt; same error in Java code, you&#39;ll get that error message.)<br>
&gt;&gt;<br>&gt;&gt; But if you are using dialect &quot;mvel&quot; (are you?), this is not flagged as an<br>&gt;&gt; error, and it would silently convert the Double to a String, and set<br>&gt;&gt; fid31003 to &quot;497.0&quot;. Is this what keeps your other rules from firing, i.e.,<br>
&gt;&gt; the excess &quot;.0&quot;?<br>&gt;&gt;<br>&gt;&gt; I suggest that you do not use &quot;mvel&quot; unless there is a compelling reason<br>&gt;&gt; (in other rules). Even then, you might restrict use &quot;mvel&quot; to those rules<br>
&gt;&gt; where it is really necessary.<br>&gt;&gt;<br>&gt;&gt; -W<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; 2010/5/4 Puneet duggal &lt;<a href="mailto:duggalpunit@gmail.com">duggalpunit@gmail.com</a>&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; drlFile = BusinessRuleUtils.createCombinedDrlDocument(id,map.get(id));<br>
&gt;&gt;&gt;<br>&gt;&gt;&gt;      PackageBuilder PACKAGE_BUILDER = new<br>&gt;&gt;&gt; PackageBuilder(BUILDER_CONFIGURATION);<br>&gt;&gt;&gt;      org.drools.rule.Package pkg = null;<br>&gt;&gt;&gt;      PACKAGE_BUILDER<br>
&gt;&gt;&gt;        .addPackageFromDrl(new StringReader(drlFile));<br>&gt;&gt;&gt;      if (PACKAGE_BUILDER.hasErrors()) {<br>&gt;&gt;&gt;       DSM_LOGGER<br>&gt;&gt;&gt;         .logFatal(&quot;Error has occured while building package. For<br>
&gt;&gt;&gt; Parameter ID : &quot;<br>&gt;&gt;&gt;           + id<br>&gt;&gt;&gt;           + &quot; Error details are : &quot;<br>&gt;&gt;&gt;           + PACKAGE_BUILDER.getErrors()<br>&gt;&gt;&gt;             .toString());<br>
&gt;&gt;&gt;      } else {<br>&gt;&gt;&gt;       pkg = PACKAGE_BUILDER.getPackage();<br>&gt;&gt;&gt;       RULEBASE.addPackage(pkg);<br>&gt;&gt;&gt;       DSM_LOGGER<br>&gt;&gt;&gt;         .logInfo(&quot;Package created for Component Prmr ID : &quot;<br>
&gt;&gt;&gt;           + id);<br>&gt;&gt;&gt;      }<br>&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; This is the code which i am using  at it is not giving<br>&gt;&gt;&gt; any error  at the time creating  the drl <a href="http://file.it">file.it</a> is also<br>
&gt;&gt;&gt; not giving any error at the time of calling of execute()<br>&gt;&gt;&gt; method , but rules are not executed .<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; On 5/4/10, Wolfgang Laun &lt;<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>&gt; wrote:<br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; Anatoly,<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; please note that I wrote &quot;please&quot; to Puneet, which is usually not<br>&gt;&gt;&gt;&gt; considered<br>&gt;&gt;&gt;&gt; as being &quot;impolite&quot;. Also, kindly note that I asked for more<br>
&gt;&gt;&gt;&gt; information, which,<br>&gt;&gt;&gt;&gt; in my book, is not &quot;inconsiderate&quot;, as simply deleting Puneet&#39;s post<br>&gt;&gt;&gt;&gt; might have been.<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; I do resent being called a &quot;hater&quot;, and I&#39;ll let the community judge<br>
&gt;&gt;&gt;&gt; whether<br>&gt;&gt;&gt;&gt; my (admittedly ironic) kidding is &quot;hateful&quot;. Somehow, however, posters<br>&gt;&gt;&gt;&gt; have to<br>&gt;&gt;&gt;&gt; be admonished to state their problem more detailed, without people on<br>
&gt;&gt;&gt;&gt; the<br>&gt;&gt;&gt;&gt; list having to waste their time playing guessing games or writing<br>&gt;&gt;&gt;&gt; replies begging<br>&gt;&gt;&gt;&gt; for more information.<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; -W<br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; PS: A you can see now, it was not a question of &quot;debugging&quot;, and so you<br>&gt;&gt;&gt;&gt; have wasted<br>&gt;&gt;&gt;&gt; your time on a &quot;simple question&quot;. :-)<br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; On Tue, May 4, 2010 at 5:10 AM, tolitius &lt;<a href="mailto:webakaunt@gmail.com">webakaunt@gmail.com</a>&gt; wrote:<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;&gt; @Wolfgang,<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt;    No need to be a hater Wolfgang, the question is simple. I agree,<br>&gt;&gt;&gt;&gt;&gt; examples would be helpful, but that is NOT how you grow a friendly<br>
&gt;&gt;&gt;&gt;&gt; community.<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt;    Community is the biggest problem JBoss has. Why is it so inhumanly<br>&gt;&gt;&gt;&gt;&gt; difficult to be polite and considerate?<br>&gt;&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;&gt; /Anatoly<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt; --<br>&gt;&gt;&gt;&gt;&gt; View this message in context:<br>&gt;&gt;&gt;&gt;&gt; <a href="http://drools-java-rules-engine.46999.n3.nabble.com/Rules-doubt-tp774023p775029.html">http://drools-java-rules-engine.46999.n3.nabble.com/Rules-doubt-tp774023p775029.html</a><br>
&gt;&gt;&gt;&gt;&gt; Sent from the Drools - User mailing list archive at Nabble.com.<br>&gt;&gt;&gt;&gt;&gt; _______________________________________________<br>&gt;&gt;&gt;&gt;&gt; rules-users mailing list<br>&gt;&gt;&gt;&gt;&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt;&gt;&gt;&gt;&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; _______________________________________________<br>
&gt;&gt;&gt;&gt; rules-users mailing list<br>&gt;&gt;&gt;&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>&gt;&gt;&gt;&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt;<br>&gt;&gt;&gt; _______________________________________________<br>&gt;&gt;&gt; rules-users mailing list<br>&gt;&gt;&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt;&gt;&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>&gt;&gt;&gt;<br>&gt;&gt;<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">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;&gt;<br>&gt;<br>&gt;<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">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;<br>&gt;<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">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br>