You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jdo-dev@db.apache.org by "Michelle Caisse (JIRA)" <ji...@apache.org> on 2007/07/03 02:01:10 UTC

[jira] Created: (JDO-507) Completeness test for persistent interface fails with annotations

 Completeness test for persistent interface fails with annotations
------------------------------------------------------------------

                 Key: JDO-507
                 URL: https://issues.apache.org/jira/browse/JDO-507
             Project: JDO
          Issue Type: Bug
          Components: tck2
    Affects Versions: JDO 2.0 TCK challenge fixes
            Reporter: Michelle Caisse


Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
    [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
    [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
ass!
...
When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12511304 ] 

Craig Russell commented on JDO-507:
-----------------------------------

Here's a sample of the code needed to reflectively invoke methods:

    protected void setAddrid(Object obj, long addrid) {
        set (obj, addrid, "setAddrid");
    }

    protected void set(Object obj, long value, String methodName) {
        Method method = getMethod(obj, methodName, long.class);
        invokeMethod(method, obj, value);
    }

    protected Map<Class, Map<String, Method>> classMethodMap = 
            new HashMap<Class, Map<String, Method>>();

    protected Method getMethod(Object obj, String methodName, 
            Class parameterClass) {
        Class clazz = obj.getClass();
        Map<String, Method> methodMap = classMethodMap.get(clazz);
        if (methodMap == null) {
            methodMap = new HashMap<String, Method>();
            classMethodMap.put(clazz, methodMap);
        }
        Method result = methodMap.get(methodName);
        if (result == null) {
            try {
                result = clazz.getMethod(methodName, parameterClass);
                methodMap.put(methodName, result);
            } catch (NoSuchMethodException ex) {
                throw new RuntimeException("Unable to find method " +
                        methodName + "in class " + clazz.getName(), ex);
            }
        }
        return result;
    }

    private void invokeMethod(Method method, Object obj, Object value) {
        try {
            method.invoke(obj, value);
        } catch (IllegalArgumentException ex) {
            throw ex;
        } catch (IllegalAccessException ex) {
            throw new RuntimeException("Illegal Access", ex);
        } catch (InvocationTargetException ex) {
            throw new RuntimeException("Invocation Target", ex);
        }
    }


>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>         Attachments: jdo-507.patch
>
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Craig Russell updated JDO-507:
------------------------------

    Attachment: jdo-507.patch

This patch partially implements the strategy of making the CompanyFactory return Object instead of interfaces. All the factories would simply implement the newXXX() methods instead of the newXXX(long, String, etc.) methods. The xml beans would use the newXXX methods without parameters and all members would be set via the setters (reflection).

The alternative is to create a new set of CompanyFactory and Reader classes (like we did for the Set and List tests) for each of the new packages.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>         Attachments: jdo-507.patch
>
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Michelle Caisse (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michelle Caisse resolved JDO-507.
---------------------------------

    Resolution: Fixed

Works now.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>         Attachments: jdo-507.patch
>
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Andy Jefferson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509935 ] 

Andy Jefferson commented on JDO-507:
------------------------------------

The classes in SVN use @PersistenceCapable, @Field whereas they need to use @PersistentInterface, @Property

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510448 ] 

Craig Russell commented on JDO-507:
-----------------------------------

As an experiment, I changed the CompanyFactory contract to return Object instead of interfaces, and ran the tck which gave the same results as before.

Without the changes I made to extend PIAddress with IAddress, once we had an instance successfully returned by PM.newInstance it would fail the cast. So I was just anticipating the future problem.

Please let me know if you are ok with changing the CompanyFactory to return Object and remove the "extends ICompany" from the PI interfaces. I'll attach a patch.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510230 ] 

Craig Russell commented on JDO-507:
-----------------------------------

I just updated these classes. Didn't know if Michelle was going to be working on our national holiday. ;-)

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510436 ] 

Craig Russell commented on JDO-507:
-----------------------------------

The issue is the CompanyFactory interface that defines the methods in terms of the company interfaces.
    IAddress newAddress(long addrid, String street, String city, 
            String state, String zipcode, String country);
And then the implementation does this:
    public IAddress newAddress() {
        return (IAddress)pm.newInstance(addressClass);
    }
Looking at the requirements for the xml bean factory, it might be possible to remove the interfaces from the factory and just use Object as the return type. The requirements for the xml bean factory is for a constructor method and setter methods without any requirements on the return types at all. This would be similar to what we did with the convenience methods that return Object instead of Address or IAddress.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Michelle Caisse (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510229 ] 

Michelle Caisse commented on JDO-507:
-------------------------------------

Yes, cut and paste error.  Expect bugs.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510256 ] 

Craig Russell commented on JDO-507:
-----------------------------------

The interfaces have been updated to the latest comments, and the enhancer still fails with the latest JPOX code (July 4.)

One thing I noticed:
public interface PICompany extends ICompany {
    
    @Property(persistenceModifier=FieldPersistenceModifier.PERSISTENT)
    @Embedded(nullIndicatorColumn="COUNTRY",
        fields={
            @Field(name="addrid", columns=@Column(name="ADDRID")),
            @Field(name="street", columns=@Column(name="STREET")),
            @Field(name="city", columns=@Column(name="CITY")),
            @Field(name="state", columns=@Column(name="STATE")),
            @Field(name="zipcode", columns=@Column(name="ZIPCODE")),
            @Field(name="country", columns=@Column(name="COUNTRY"))
    })
    PIAddress getAddress();

I just added Property[ ] properties() to @Embedded. Doesn't seem to help ;-)

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510451 ] 

Craig Russell commented on JDO-507:
-----------------------------------

Oops, forgot to clean build. The issue is the way we do CompanyFactoryAbstractImpl where we do this:
    public IAddress newAddress(long addrid, String street, String city, 
            String state, String zipcode, String country) {
        IAddress result = newAddress();
        if (debug) logger.debug("newAddress returned" + result);
        result.setAddrid(addrid);
        result.setStreet(street);
        result.setCity(city);
        result.setState(state);
        result.setZipcode(zipcode);
        result.setCountry(country);
        return result;
    }

To allow PICompany to be used here we would need to either rewrite CompanyFactoryAbstractImpl to use reflection (much as xml bean factory does) or rewrite the xml bean data files to use simple constructors and setters for all the fields.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Craig Russell updated JDO-507:
------------------------------

    Attachment: jdo-507.patch

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>         Attachments: jdo-507.patch
>
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510410 ] 

Craig Russell commented on JDO-507:
-----------------------------------

The reason to extend ICompany with PICompany is to reuse the test classes from the company model, which allows us to reuse the test data from the Completeness test. The intent was not to override the originals but just to use the non-persistent aspects of the model. 

I guess that ICompany is itself persistent with jdo metadata and this is confusing things. We might need to revert the "extends ICompany" changes and copy/paste/edit the company classes.



>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Andy Jefferson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509759 ] 

Andy Jefferson commented on JDO-507:
------------------------------------

I closed that JPOX JIRA a few days ago. @PersistentInterface, @Property are processed by JPOX.

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Andy Jefferson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510227 ] 

Andy Jefferson commented on JDO-507:
------------------------------------

In the PI* classes under "src/java/org/apache/jdo/tck/pc/companyAnnotatedDS" why do they not have @DatastoreIdentity to specify the column name? Also in PIProject.java in that directory it has a field marked as primary key, yet these are for datastore identity. Cut and paste error ?

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Michelle Caisse (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michelle Caisse updated JDO-507:
--------------------------------

           Issue Type: Task  (was: Bug)
    Affects Version/s:     (was: JDO 2.0 TCK challenge fixes)
                       JDO 2 maintenance release 1

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Michelle Caisse (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510416 ] 

Michelle Caisse commented on JDO-507:
-------------------------------------

I'm confused.. What copy/paste/edit is required?  I think that use of the test data is independent of whether the PI* classes extend the I* classes. Was there an issue that was addressed by adding "extends ICompany"?

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Andy Jefferson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12510306 ] 

Andy Jefferson commented on JDO-507:
------------------------------------

> I just added Property[ ] properties() to @Embedded. Doesn't seem to help ;-)

No reason that it would since we (currently) interpret @Embedded "fields" as the properties to be embedded (in the absence of a separate "properties") and dont process some "properties" annotation element that didnt exist ;-)


Why does PICompany extend ICompany ? (same comment applies to all PIXXX classes). If the test is to be a straight copy of "companyPMInterface.conf" but using annotations then it should be a straight interface with no extend of some other persistent interface that already declared methods persistent using XML. If it is to be a test of XML+annotations then it should at least attempt to override something (IMHO)

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (JDO-507) Completeness test for persistent interface fails with annotations

Posted by "Craig Russell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JDO-507?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Craig Russell updated JDO-507:
------------------------------

    Attachment:     (was: jdo-507.patch)

>  Completeness test for persistent interface fails with annotations
> ------------------------------------------------------------------
>
>                 Key: JDO-507
>                 URL: https://issues.apache.org/jira/browse/JDO-507
>             Project: JDO
>          Issue Type: Task
>          Components: tck2
>    Affects Versions: JDO 2 maintenance release 1
>            Reporter: Michelle Caisse
>         Attachments: jdo-507.patch
>
>
> Annotations on persistent interfaces have not yet been implemented by jpox. I have added the test to configurations.list, so it gets run on any complete test run, but I have not yet added the classes to the list of jdo metadata files in project.properties because that causes enhancement to fail. Therefore, the test currently gives the following error: 
>     [java] Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the class!
>     [java] org.jpox.metadata.InvalidMetaDataException: Class org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany has field org.apache.jdo.tck.pc.companyAnnotatedDS.PICompany.address declared in MetaData, but this field doesnt exist in the cl
> ass!
> ...
> When the feature is implemented, project.properties must be edited to include PI*.class in the list for enhancement.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.