Probably the Drools Runtime configured in Eclipse is not same version as
what is used in your Guvnor. Make sure that you are using the same bits
on both sides and try again.
On 4/21/11 7:19 PM, MichaelBini wrote:
still don't working
the code -
private static KnowledgeBase readKnowledgeBase() throws Exception {
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
kbuilder.add( ResourceFactory.newFileResource(
"c:/com.jspeed.brms.fire.pkg" ),
ResourceType.PKG );
KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
kbase.addKnowledgePackages(kbuilder.getKnowledgePackages());
return kbase;
}
Error -
java.lang.RuntimeException: java.io.EOFException
at
org.drools.compiler.PackageBuilder.addKnowledgeResource(PackageBuilder.java:544)
at
org.drools.builder.impl.KnowledgeBuilderImpl.add(KnowledgeBuilderImpl.java:28)
at com.jspeed.brms.fire.Alarm2.readKnowledgeBase(Alarm2.java:75)
at com.jspeed.brms.fire.Alarm2.main(Alarm2.java:27)
Caused by: java.io.EOFException
at java.io.DataInputStream.readInt(Unknown Source)
at java.io.ObjectInputStream$BlockDataInputStream.readInt(Unknown Source)
at java.io.ObjectInputStream.readInt(Unknown Source)
at
org.drools.rule.JavaDialectRuntimeData.readExternal(JavaDialectRuntimeData.java:112)
at java.io.ObjectInputStream.readExternalData(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
--
View this message in context:
http://drools.46999.n3.nabble.com/how-to-run-pkg-from-java-tp2848164p2849...
Sent from the Drools: User forum mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users