I'm trying to run the verifier against a simple rule file I've created. My
rules live in a directory called "rules". The rules files are directly
under rules/.
rules/rule1.drl
rules/rule2.drl
My ant target looks like:
<target name="verifier" depends="compile">
<verifier
srcdir="rules"
tofile="${outputdir}"
classpathref="classpath-compile-deploy">
<include name="*.drl" />
</verifier>
</target>
I'm getting this exception:
java.lang.NullPointerException
at java.io.Reader.<init>(Reader.java:61)
at java.io.InputStreamReader.<init>(InputStreamReader.java:55)
at
org.drools.contrib.DroolsVerifierAntTask.compileAndAnalyzeFile(DroolsVerifierAntTask.java:125)
at
org.drools.contrib.DroolsVerifierAntTask.execute(DroolsVerifierAntTask.java:105)
The error occurs in compileAndAnalyzeFiles:
http://grepcode.com/file/repository.jboss.com/maven2/org.drools/drools-an...
The line it's bombing out seems to be trying to find my rules file relative
to the Verifier class:
org.drools.lang.descr.PackageDescr descr = (new DrlParser()).parse(new
InputStreamReader(org/drools/verifier/Verifier.getResourceAsStream(filename)));
Why does it do that? Why not just read the file I specify? Do I have to
muck with the classpath to get the verifier to work?
Thanks,
Adam
--
View this message in context:
http://n3.nabble.com/Problem-running-drools-verifier-ant-task-tp417853p41...
Sent from the Drools - User mailing list archive at
Nabble.com.