<br><font size=2 face="Trebuchet MS">I have set JAVA as compiler, but I
tried it with JANINO also but I got same exception..........</font>
<br>
<br><font size=2 face="Trebuchet MS">Hey Greg..... &nbsp;I am not finding
a proiper way to set the class path, I had used XBoot class path as I mentioned
in my previous mail.....</font>
<br>
<br><font size=2 face="Trebuchet MS">Thanks &amp; Regards:<br>
<br>
Pankaj Jain | L&amp;T infotech |Navi Mumbai<br>
Mobile: +91 9920218945<br>
Email : pankaj.jain@lntinfotech.com<br>
www.Lntinfotech.com<br>
<br>
&quot;Whatever the mind of man can conceive &amp; believe, it can achieve.&quot;<br>
<b><br>
Larsen &amp; Toubro Infotech Ltd.</b></font><font size=2 color=blue face="Trebuchet MS"><u><br>
</u></font><a href=http://www.lntinfotech.com/><font size=2 color=blue face="Trebuchet MS"><u>www.Lntinfotech.com</u></font></a><font size=2 face="Trebuchet MS"><br>
<br>
This Document is classified as: <br>
<br>
</font><input type=checkbox name=F1_chkbox checked value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Proprietary &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Confidential &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Internal Use Only &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech General Business &nbsp; <br>
<br>
This Email may contain confidential or privileged information for the intended
recipient (s) If you are not the intended recipient, please do not use
or disseminate the information, notify the sender and delete it from your
system. </font>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td width=40%><font size=1 face="Trebuchet MS"><b>Nicolas Héron &lt;nicolas.heron.java@gmail.com&gt;</b>
</font>
<br><font size=1 face="Trebuchet MS">Sent by: rules-users-bounces@lists.jboss.org</font>
<p><font size=1 face="Trebuchet MS">07/28/2009 12:34 PM</font>
<table border>
<tr valign=top>
<td bgcolor=white>
<div align=center><font size=1 face="Trebuchet MS">Please respond to<br>
Rules Users List &lt;rules-users@lists.jboss.org&gt;</font></div></table>
<br>
<td width=59%>
<table width=100%>
<tr valign=top>
<td>
<div align=right><font size=1 face="Trebuchet MS">To</font></div>
<td><font size=1 face="Trebuchet MS">Rules Users List &lt;rules-users@lists.jboss.org&gt;</font>
<tr valign=top>
<td>
<div align=right><font size=1 face="Trebuchet MS">cc</font></div>
<td>
<tr valign=top>
<td>
<div align=right><font size=1 face="Trebuchet MS">Subject</font></div>
<td><font size=1 face="Trebuchet MS">Re: [rules-users] Run Drool Application
From Command Prompt</font></table>
<br>
<table>
<tr valign=top>
<td>
<td></table>
<br></table>
<br>
<br>
<br><font size=3>Hello,<br>
did you set the java compiler name : &quot;JANINO&quot; or &quot;JAVA&quot;
?<br>
</font>
<br><font size=3>2009/7/28 &lt;</font><a href=mailto:Pankaj.Jain@lntinfotech.com><font size=3 color=blue><u>Pankaj.Jain@lntinfotech.com</u></font></a><font size=3>&gt;</font>
<br><font size=2 face="Trebuchet MS"><br>
Hi</font><font size=3> <br>
</font><font size=2 face="Trebuchet MS"><br>
I still have not got any solution of my problem that I posted previously.
I have included all required jar files and set proper class path .. Please
do help ?</font><font size=3> <br>
</font><font size=2 face="Trebuchet MS"><br>
problem: </font>
<table>
<tr valign=top>
<td><font size=2 face="Trebuchet MS">I am trying to integrate Drool with
ofbiz and run application from command prompt. In one way I have integrated
it properly and I am able to run it <b>successfully.</b></font><font size=3>
</font><font size=2 face="Trebuchet MS"><b><br>
<br>
Code :</b> Which I was using initially</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
<br>
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
<br>
<br>
or</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
<br>
PackageBuilderConfiguration cfg = new PackageBuilderConfiguration();</font><font size=3>
</font><font size=2 face="Trebuchet MS"><br>
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
<b><br>
<br>
Exception I got :</b></font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
<br>
org.drools.RuntimeDroolsException: Unable to load dialect 'org.drools.rule.builder.dialect.java.JavaDialectConfiguration:java
<br>
:org.drools.rule.builder.dialect.java.JavaDialectConfiguration'</font><font size=3>
</font><font size=2 face="Trebuchet MS"><br>
at org.drools.compiler.PackageBuilderConfiguration.addDialect(PackageBuilderConfiguration.java:274)
at org.drools.compiler.PackageBuilderConfiguration.buildDialectConfigurationMap(PackageBuilderConfiguration.java:259)
<br>
<br>
at org.drools.compiler.PackageBuilderConfiguration.init(PackageBuilderConfiguration.java:176)
at org.drools.compiler.PackageBuilderConfiguration.&lt;init&gt;(PackageBuilderConfiguration.java:153)
at org.drools.compiler.PackageBuilder.&lt;init&gt;(PackageBuilder.java:242)
<br>
.</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
.</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
.</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
Caused by: java.lang.NullPointerException</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
at org.drools.rule.builder.dialect.java.JavaDialectConfiguration.setCompiler(JavaDialectConfiguration.java:92)
at org.drools.rule.builder.dialect.java.JavaDialectConfiguration.init(JavaDialectConfiguration.java:55)
at org.drools.compiler.PackageBuilderConfiguration.addDialect(PackageBuilderConfiguration.java:270</font><font size=3>
</font><font size=2 face="Trebuchet MS"><b><br>
<br>
Problem I found : </b><br>
In the class JavaDialectConfiguration in jar file drools-compiler.jar there
is a method named &quot;setCompliler&quot;, &nbsp;in this method Null Pointer
Exception was coming.</font><font size=3> </font><font size=2 face="Trebuchet MS"><b><br>
<br>
Solution I provided :</b></font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
In my application I created my custom class CustomJavaDialectConfiguration
by extending to class JavaDialectConfiguration, In this class I overrided
the method setCompiler. My method was exactly same as that of method setCompiler
in JavaDialectConfiguration . To call my dialect class I also overrided
the method &quot;addDialect&quot; of PackageBuilderConfiguration class
. For that I created class CustomPackageBuilderConfiguration by extending
to PackageBuilderConfiguration. <br>
after that I wrote the code:</font><font size=3> </font><font size=2 face="Trebuchet MS"><br>
<br>
PackageBuilderConfiguration cfg = new CustomPackageBuilderConfiguration();</font><font size=3>
</font><font size=2 face="Trebuchet MS"><br>
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder(cfg);</font><font size=3>
<br>
</font><font size=2 face="Trebuchet MS"><br>
<br>
Now application is running perfectly fine from both eclipse and command
prompt without any exception.</font><font size=3> </font><font size=2 face="Trebuchet MS"><b><br>
<br>
I want to know as my overrided method &quot;setCompiler&quot; was exactly
same then why I had to override method, and In original code (ie in drools-compiler.jar
file) why it was giving exception &nbsp;??? &nbsp;Was that due to class
lader or something else ?? &nbsp;Please do help in this regard ....</b></font><font size=3>
</font></table>
<br><font size=2 face="Trebuchet MS"><br>
&nbsp;</font><font size=3> <br>
</font><font size=2 face="Trebuchet MS"><br>
Thanks &amp; Regards:<br>
<br>
Pankaj Jain | L&amp;T infotech |Navi Mumbai<br>
Mobile: +91 9920218945<br>
Email : </font><a href=mailto:pankaj.jain@lntinfotech.com target=_blank><font size=2 color=blue face="Trebuchet MS"><u>pankaj.jain@lntinfotech.com</u></font></a><font size=2 color=blue face="Trebuchet MS"><u><br>
</u></font><a href=http://www.lntinfotech.com/ target=_blank><font size=2 color=blue face="Trebuchet MS"><u>www.Lntinfotech.com</u></font></a><font size=2 face="Trebuchet MS"><br>
<br>
&quot;Whatever the mind of man can conceive &amp; believe, it can achieve.&quot;<b><br>
<br>
Larsen &amp; Toubro Infotech Ltd.</b></font><font size=3 color=blue><u><br>
</u></font><a href=http://www.lntinfotech.com/ target=_blank><font size=2 color=blue face="Trebuchet MS"><u>www.Lntinfotech.com</u></font></a><font size=2 face="Trebuchet MS"><br>
<br>
This Document is classified as: <br>
</font><font size=3><br>
</font><input type=checkbox name=F1_chkbox checked value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Proprietary &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Confidential &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech Internal Use Only &nbsp; </font><input type=checkbox name=F1_chkbox value=on><font size=2 face="Trebuchet MS">L&amp;T
Infotech General Business &nbsp; <br>
<br>
This Email may contain confidential or privileged information for the intended
recipient (s) If you are not the intended recipient, please do not use
or disseminate the information, notify the sender and delete it from your
system. </font><font size=3><br>
______________________________________________________________________<br>
<br>
_______________________________________________<br>
rules-users mailing list</font><font size=3 color=blue><u><br>
</u></font><a href="mailto:rules-users@lists.jboss.org"><font size=3 color=blue><u>rules-users@lists.jboss.org</u></font></a><font size=3 color=blue><u><br>
</u></font><a href="https://lists.jboss.org/mailman/listinfo/rules-users" target=_blank><font size=3 color=blue><u>https://lists.jboss.org/mailman/listinfo/rules-users</u></font></a><font size=3><br>
</font>
<br><font size=3><br>
<br>
______________________________________________________________________</font><tt><font size=2>_______________________________________________<br>
rules-users mailing list<br>
rules-users@lists.jboss.org<br>
https://lists.jboss.org/mailman/listinfo/rules-users<br>
</font></tt>
<br>
<BR>
______________________________________________________________________<BR>