db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Watzek <mwa.t...@spree.de>
Subject JPOX bug related to pk fields of type Date
Date Thu, 03 Nov 2005 16:18:39 GMT
Hi Andy,

today I noticed a bug which shows up in CopyKeyFieldsFromObjectId and 
NewObjectIdInstance. I'm not sure, when the bug showed up the first 
time. Currently, JIRA is not available, that's why I do not know if we 
already filed a JIRA.

The test cases throws an error during teardown (see below). As a 
consequence, the database cannot be cleaned up. For that reason, the 
test cases throws a duplicate key exception when they are executed twice.

JPOX throws a JDOUserException in method 
org.jpox.sco.SCOUtils.newSCOInstance. This only happens for application 
identity. The test succeeds for datastore identity.

The failing PC class class has a primary key field of type 
java.util.Date. The test case is able to make an instance persistent but 
it fails calling getObjectById. Please have a look.

Regards,
Michael

     [java] 1) 
testSingleFieldIdentityDate(org.apache.jdo.tck.api.persistencecapable.CopyKeyFieldsFromObjectId)javax.jdo.
JDOFatalException: Exception during tearDown
     [java]      at org.apache.jdo.tck.JDO_Test.tearDown(JDO_Test.java:290)
     [java]      at org.apache.jdo.tck.JDO_Test.runBare(JDO_Test.java:218)
     [java]      at 
org.apache.jdo.tck.util.BatchTestRunner.start(BatchTestRunner.java:120)
     [java]      at 
org.apache.jdo.tck.util.BatchTestRunner.main(BatchTestRunner.java:95)
     [java] NestedThrowablesStackTrace:
     [java] javax.jdo.JDOUserException
     [java]      at org.jpox.sco.SCOUtils.newSCOInstance(SCOUtils.java:70)
     [java]      at 
org.jpox.state.StateManagerImpl.newSCOInstance(StateManagerImpl.java:2938)
     [java]      at 
org.jpox.state.StateManagerImpl.replaceSCOField(StateManagerImpl.java:2955)
     [java]      at 
org.jpox.store.rdbms.fieldmanager.ParameterSetter.storeObjectField(ParameterSetter.java:135)
     [java]      at 
org.jpox.state.StateManagerImpl.providedObjectField(StateManagerImpl.java:2462)
     [java]      at 
org.apache.jdo.tck.pc.singlefieldidentity.PCPointSingleFieldDate.jdoProvideField(PCPointSingleFieldDa
te.java)
     [java]      at 
org.apache.jdo.tck.pc.singlefieldidentity.PCPointSingleFieldDate.jdoProvideFields(PCPointSingleFieldD
ate.java)
     [java]      at 
org.jpox.state.StateManagerImpl.provideFields(StateManagerImpl.java:2799)
     [java]      at 
org.jpox.store.rdbms.request.FetchRequest.execute(FetchRequest.java:169)
     [java]      at 
org.jpox.store.rdbms.table.ClassTable.fetch(ClassTable.java:1907)
     [java]      at org.jpox.store.StoreManager.fetch(StoreManager.java:755)
     [java]      at 
org.jpox.state.StateManagerImpl.loadFieldsInFetchPlan(StateManagerImpl.java:1655)
     [java]      at 
org.jpox.state.StateManagerImpl.validate(StateManagerImpl.java:3940)
     [java]      at 
org.jpox.AbstractPersistenceManager.getObjectById(AbstractPersistenceManager.java:2435)
     [java]      at 
org.jpox.AbstractPersistenceManager.getObjectById(AbstractPersistenceManager.java:2328)
     [java]      at 
org.apache.jdo.tck.JDO_Test.deleteTearDownInstances(JDO_Test.java:345)
     [java]      at 
org.apache.jdo.tck.JDO_Test.localTearDown(JDO_Test.java:301)
     [java]      at org.apache.jdo.tck.JDO_Test.tearDown(JDO_Test.java:271)
     [java]      at org.apache.jdo.tck.JDO_Test.runBare(JDO_Test.java:218)
     [java]      at 
org.apache.jdo.tck.util.BatchTestRunner.start(BatchTestRunner.java:120)
     [java]      at 
org.apache.jdo.tck.util.BatchTestRunner.main(BatchTestRunner.java:95)
-- 
-------------------------------------------------------------------
Michael Watzek                  Tech@Spree Engineering GmbH
mailto:mwa.tech@spree.de        Buelowstr. 66
Tel.:  ++49/30/235 520 36       10783 Berlin - Germany
Fax.:  ++49/30/217 520 12       http://www.spree.de/
-------------------------------------------------------------------

Mime
View raw message