<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> <<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>> wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Here, I'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 "drools.compiler" to set the<br>
desired compiler.<br>* The valid values are "ECLIPSE" and "JANINO" only.<br>*<br>* drools.dialect.java.compiler = <ECLIPSE|JANINO><br>* drools.dialect.java.lngLevel = <1.5|1.6><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 "java.version"<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't used MVEL so far, I don't see any reason to start now.<br><br>-W<br><br><br>2010/5/4 Puneet duggal <<a href="mailto:duggalpunit@gmail.com">duggalpunit@gmail.com</a>>:<br>
> @ Wolfgang Laun ,<br>><br>> i am using just this statement:-<br>><br>> javaConf.setCompiler( JavaDialectConfiguration.JANINO );<br>><br>> I dont know the exact use of this statement .I am not using the mvel<br>
> , i tried to google abt it but couldnt find the use of this ...<br>> can u through some light on this.<br>><br>> Thanks<br>><br>><br>> On 5/4/10, Wolfgang Laun <<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>> wrote:<br>
>><br>>> Actually, this kind of error isn't discovered by the Drools DRL compiler;<br>>> it would be flagged by the Java compiler. (You can verify: if you make the<br>>> same error in Java code, you'll get that error message.)<br>
>><br>>> But if you are using dialect "mvel" (are you?), this is not flagged as an<br>>> error, and it would silently convert the Double to a String, and set<br>>> fid31003 to "497.0". Is this what keeps your other rules from firing, i.e.,<br>
>> the excess ".0"?<br>>><br>>> I suggest that you do not use "mvel" unless there is a compelling reason<br>>> (in other rules). Even then, you might restrict use "mvel" to those rules<br>
>> where it is really necessary.<br>>><br>>> -W<br>>><br>>><br>>> 2010/5/4 Puneet duggal <<a href="mailto:duggalpunit@gmail.com">duggalpunit@gmail.com</a>><br>>>><br>>>> drlFile = BusinessRuleUtils.createCombinedDrlDocument(id,map.get(id));<br>
>>><br>>>> PackageBuilder PACKAGE_BUILDER = new<br>>>> PackageBuilder(BUILDER_CONFIGURATION);<br>>>> org.drools.rule.Package pkg = null;<br>>>> PACKAGE_BUILDER<br>
>>> .addPackageFromDrl(new StringReader(drlFile));<br>>>> if (PACKAGE_BUILDER.hasErrors()) {<br>>>> DSM_LOGGER<br>>>> .logFatal("Error has occured while building package. For<br>
>>> Parameter ID : "<br>>>> + id<br>>>> + " Error details are : "<br>>>> + PACKAGE_BUILDER.getErrors()<br>>>> .toString());<br>
>>> } else {<br>>>> pkg = PACKAGE_BUILDER.getPackage();<br>>>> RULEBASE.addPackage(pkg);<br>>>> DSM_LOGGER<br>>>> .logInfo("Package created for Component Prmr ID : "<br>
>>> + id);<br>>>> }<br>>>><br>>>><br>>>><br>>>> This is the code which i am using at it is not giving<br>>>> any error at the time creating the drl <a href="http://file.it">file.it</a> is also<br>
>>> not giving any error at the time of calling of execute()<br>>>> method , but rules are not executed .<br>>>><br>>>> On 5/4/10, Wolfgang Laun <<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>> wrote:<br>
>>>><br>>>>> Anatoly,<br>>>>><br>>>>> please note that I wrote "please" to Puneet, which is usually not<br>>>>> considered<br>>>>> as being "impolite". Also, kindly note that I asked for more<br>
>>>> information, which,<br>>>>> in my book, is not "inconsiderate", as simply deleting Puneet's post<br>>>>> might have been.<br>>>>><br>>>>> I do resent being called a "hater", and I'll let the community judge<br>
>>>> whether<br>>>>> my (admittedly ironic) kidding is "hateful". Somehow, however, posters<br>>>>> have to<br>>>>> be admonished to state their problem more detailed, without people on<br>
>>>> the<br>>>>> list having to waste their time playing guessing games or writing<br>>>>> replies begging<br>>>>> for more information.<br>>>>><br>>>>> -W<br>
>>>><br>>>>> PS: A you can see now, it was not a question of "debugging", and so you<br>>>>> have wasted<br>>>>> your time on a "simple question". :-)<br>
>>>><br>>>>><br>>>>> On Tue, May 4, 2010 at 5:10 AM, tolitius <<a href="mailto:webakaunt@gmail.com">webakaunt@gmail.com</a>> wrote:<br>>>>>><br>>>>>><br>
>>>>> @Wolfgang,<br>>>>>><br>>>>>> No need to be a hater Wolfgang, the question is simple. I agree,<br>>>>>> examples would be helpful, but that is NOT how you grow a friendly<br>
>>>>> community.<br>>>>>><br>>>>>> Community is the biggest problem JBoss has. Why is it so inhumanly<br>>>>>> difficult to be polite and considerate?<br>>>>>><br>
>>>>> /Anatoly<br>>>>>><br>>>>>> --<br>>>>>> View this message in context:<br>>>>>> <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>
>>>>> Sent from the Drools - User 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">https://lists.jboss.org/mailman/listinfo/rules-users</a><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">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">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">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">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">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br>