Hey,
I have a class which spawns two threads which create a JDO object, gets a
database, then performs a Castor query. Problem is, 50% of the time, I get
the following error: -
java.lang.NullPointerException
at
org.exolab.castor.persist.ClassMolder.revertObject(ClassMolder.java:2389)
at
org.exolab.castor.persist.LockEngine.revertObject(LockEngine.java:864)
at
org.exolab.castor.persist.TransactionContext.rollback(TransactionContext.jav
a:1602)
at
org.exolab.castor.jdo.engine.DatabaseImpl.commit(DatabaseImpl.java:502)
at
com.spirentsystems.framework.persistence.tests.castortests.LazyLoad.execute(
LazyLoad.java:88)
at
com.spirentsystems.framework.persistence.tests.castortests.LazyLoad$1.run(La
zyLoad.java:206)
at java.lang.Thread.run(Thread.java:484)
On other occasions, the two threads complete successfully. I was under the
impression that JDO objects are thread-safe?. As both threads create their
own JDO objects, surely then the fact that Database objects are not
thread-safe is not an issue here?. Any information is greatly appreciated,
Glenn.
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev