Hello, I have declared a fact type in a drl file:
package com.innovativeinfo.amacus.drools.model
declare AmacusUser
id : long
timeZone : String
end
which according to
http://downloads.jboss.com/drools/docs/5.0.1.26597.FINAL/drools-expert/ht...
should result in a generated class that implements Serializable.
However when I try to persist the KnowledgeSession, I get:
Caused by: java.io.NotSerializableException:
com.innovativeinfo.amacus.drools.model.AmacusUser
at
java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1081)
at
java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)
at
org.drools.marshalling.impl.SerializablePlaceholderResolverStrategy.write(SerializablePlaceholderResolverStrategy.java:37)
at
org.drools.marshalling.impl.OutputMarshaller.writeFactHandle(OutputMarshaller.java:278)
at
org.drools.marshalling.impl.OutputMarshaller.writeFactHandles(OutputMarshaller.java:242)
at
org.drools.marshalling.impl.OutputMarshaller.writeSession(OutputMarshaller.java:85)
at
org.drools.marshalling.impl.DefaultMarshaller.marshall(DefaultMarshaller.java:117)
at
org.drools.persistence.session.JPASessionMarshallingHelper.getSnapshot(JPASessionMarshallingHelper.java:76)
Is there a configuration option I need to set to generate Serializable fact
types? Or is this a bug in 5.0.1? I realize I can define "fact types" myself
as classes in Java, but would prefer to use the shortened syntax if
possible.
Any advice appreciated.
Cheers
--
View this message in context:
http://drools-java-rules-engine.46999.n3.nabble.com/drools-5-0-1-generati...
Sent from the Drools - User mailing list archive at
Nabble.com.