db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig Russell <Craig.Russ...@Sun.COM>
Subject Re: fieldtypes metadata issues
Date Sat, 04 Jun 2005 21:50:29 GMT
Hi Erik,

On Jun 4, 2005, at 2:00 PM, erik@jpox.org wrote:

> Hi,
>  
> While running the tck tests I found these issues:
>  
> 1. Below the class name is incorrect
>  
> Index:  
> F:/eclipse-new/eclipse/workspace/tck20/test/orm/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/FieldsOfPrimitiveboolean-derby.orm
> ===================================================================
> ---  
> F:/eclipse-new/eclipse/workspace/tck20/test/orm/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/FieldsOfPrimitiveboolean- 
> derby.orm          (revision 179987)
> +++  
> F:/eclipse-new/eclipse/workspace/tck20/test/orm/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/FieldsOfPrimitiveboolean- 
> derby.orm            (working copy)
> @@ -2,7 +2,7 @@
>  <!DOCTYPE orm PUBLIC "-//Sun Microsystems, Inc.//DTD Java Data  
> Objects Mapping Metadata 2.0//EN"  
> "http://java.sun.com/dtd/orm_2_0.dtd">
>  <orm>
>      <package name="org.apache.jdo.tck.pc.fieldtypes">
> -        <class name="FieldsOfPrimitiveBoolean"  
> table="FIELDSOFPRIMITIVEBOOLEAN">
> +        <class name="FieldsOfPrimitiveboolean"  
> table="FIELDSOFPRIMITIVEBOOLEAN">
>              <datastore-identity strategy="identity"  
> column="IDENTIFIER"/>
>              <field name="boolean0" column="BOOLEAN0"/>
>              <field name="boolean1" column="BOOLEAN1"/>

Done fixed. Thanks.
>  
>  
> 2. In datastore tests, the id field is not persistent.
>  
> Index:  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/SimpleClass.jdo
> ===================================================================
> ---  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/SimpleClass.jdo            (revision  
> 179987)
> +++  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/pc/fieldtypes/SimpleClass.jdo            (working copy)
> @@ -4,6 +4,7 @@
>      <package name="org.apache.jdo.tck.pc.fieldtypes">
>          <class name="SimpleClass" identity-type="datastore">
>              <implements name="SimpleInterface"/>
> +            <field name="id"  persistence-modifier="none"/>
>          </class>
>      </package>
>  </jdo>

This is a bigger issue. All of the datastore identity jdo files have to  
be fixed to have the id fields be persistent, and add a column to be  
used for the datastore identity.
>  
> 3. Here the simple class definition was again defined, so I removed it
>  
>  
> Index:  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/package.jdo
> ===================================================================
> ---  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/package.jdo           (revision 179987)
> +++  
> F:/eclipse-new/eclipse/workspace/tck20/test/jdo/datastoreidentity/org/ 
> apache/jdo/tck/package.jdo        (working copy)
> @@ -26,9 +26,5 @@
>          <class name="NoAccessToFieldsAfterPredelete"  
> persistence-modifier="persistence-aware"/>
>          <class name="TestParts"  
> persistence-modifier="persistence-aware"/>
>      </package>
> -    <package name="org.apache.jdo.tck.pc.fieldtypes">
> -        <class name="SimpleClass" identity-type="datastore">
> -            <implements name="SimpleInterface"/>
> -        </class>
> -    </package>
> +
>  </jdo>

This was done to make sure the JDO implementation read the metadata for  
the class SimpleClass before it read any of the metadata that used the  
SimpleInterface. The duplicate definition in pc.fieldtypes should be  
ignored according to the specification.
>  
> 4. JPOX can’t find the implementation classes.
>  
> Fixed. Get the latest nightly build.

Great. Thanks.
>  
> 5. Fields of simple interface are using BLOB types to store data in  
> all fields.
>  
> It should only use LONG VARCHAR FOR BIT DATA types for the fields that  
> are marked as embedded in the metadata. For all non embedded fields,  
> the column should have a FK to the table Simple class.
>  
> CREATE TABLE FIELDSOFSIMPLEINTERFACE
> (
>     IDENTIFIER INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY,
>     SIMPLEINTERFACE1 LONG VARCHAR FOR BIT DATA,
>     SIMPLEINTERFACE102 LONG VARCHAR FOR BIT DATA,
> ….
>  
Do you happen to have a patch for this one? ;-)

Thanks for taking a look at these. Are you now able to run all the  
tests?

Craig
>  
>  
> Erik Bengtson
>  
>
Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!

Mime
View raw message