Hi,
I have set all the jars file in the classpath, but still m getting the
same exception.
The exception is caused by : Null pointer exception.
I am not able to understand why it is giving me this exception, while in
the mailing list I didn't found anybody having this
exception, everyone else I found has 'Class Not found Exception'.
This is my code snippet :
KnowledgeBuilderConfiguration config = KnowledgeBuilderFactory.
newKnowledgeBuilderConfiguration();
config.setProperty("drools.dialect.java.compiler", "ECLIPSE");
KnowledgeBuilder kbuilder =KnowledgeBuilderFactory.newKnowledgeBuilder(
config );
//KnowledgeBuilder kbuilder =
KnowledgeBuilderFactory.newKnowledgeBuilder();
kbuilder.add(ResourceFactory.newClassPathResource(
"shopingdiscount.drl"), ResourceType.DRL);
This is my exception:
Drools config: unable to use the drools.compiler property. Using default.
It was set to:0
org.drools.RuntimeDroolsException: Unable to load dialect
'org.drools.rule.builder.dialect.java.JavaDialectConfiguration:jav
:org.drools.rule.builder.dialect.java.JavaDialectConfiguration'
at
org.drools.compiler.PackageBuilderConfiguration.addDialect(PackageBuilderConfiguration.java:274)
at
org.drools.compiler.PackageBuilderConfiguration.buildDialectConfigurationMap(PackageBuilderConfiguration.java:259
at
org.drools.compiler.PackageBuilderConfiguration.init(PackageBuilderConfiguration.java:176)
at
org.drools.compiler.PackageBuilderConfiguration.<init>(PackageBuilderConfiguration.java:153)
at
org.drools.builder.impl.KnowledgeBuilderProviderImpl.newKnowledgeBuilderConfiguration(KnowledgeBuilderProviderImp
.java:17)
at
org.drools.builder.KnowledgeBuilderFactory.newKnowledgeBuilderConfiguration(KnowledgeBuilderFactory.java:57)
a
.
.
.
.
Caused by: java.lang.NullPointerException
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)
... 69 more
Am I missing anything that is to initialized , so that I can get through
this Null Pointer Exception.
Please help me to through of this situation. I am stuck in this.
Thanks & Regards
Pardeep Ruhil
______________________________________________________________________
Show replies by date