You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Douglas Siqueira Leite (JIRA)" <tu...@ws.apache.org> on 2008/05/06 20:06:55 UTC

[jira] Created: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Add support for data Collection interface to the implementation-data-xml
------------------------------------------------------------------------

                 Key: TUSCANY-2297
                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
             Project: Tuscany
          Issue Type: New Feature
          Components: Java SCA Java Implementation Extension
            Reporter: Douglas Siqueira Leite


Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Resolved: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Luciano Resende (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Luciano Resende resolved TUSCANY-2297.
--------------------------------------

       Resolution: Fixed
    Fix Version/s: Java-SCA-Next
         Assignee: Luciano Resende

Thanks Douglas. Patch applied under revision 654554.

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>            Assignee: Luciano Resende
>             Fix For: Java-SCA-Next
>
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Updated: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Douglas Siqueira Leite (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Douglas Siqueira Leite updated TUSCANY-2297:
--------------------------------------------

    Attachment: tuscany2297_douglas_2008_05_06.patch

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>         Attachments: tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Commented: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Luciano Resende (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596789#action_12596789 ] 

Luciano Resende commented on TUSCANY-2297:
------------------------------------------

Thanks Mark. I didn't see this problem locally and looks like couple others didn't see either.... maybe this is a issue with the order the tests were excuted.. anyway I'll take a look at this.

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>            Assignee: Luciano Resende
>             Fix For: Java-SCA-Next
>
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Reopened: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Mark Combellack (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Combellack reopened TUSCANY-2297:
--------------------------------------


It appears that applying the patch for this JIRA has broken the implementation-data-xml project. When I do a clean build on the project, I now get JUnit test failures (see below) 

The project is also failing on the Continuum server which is preventing Tuscany SCA from building.

If I roll back the project to before the patch for this Jira was applied, the project builds without error.


The errors I am getting are:

Running org.apache.tuscany.sca.implementation.data.DATAImplementationProcessorTestCase
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.394 sec
Running org.apache.tuscany.sca.implementation.data.DATACollectionTestCase
>testInsert
Number of rows inserted: 2
>testGet
<?xml version='1.0' encoding='UTF-8'?><resultSet><record><column name="ID">1</column><column name="NAME">ACME Publishing</column></record><record><column name="ID">2</column><column name="NAME">Do-rite plumbing</column></record><record><column name="ID">3</column><column name="NAME">MegaCorp</column></record><record><column name="ID">4</column><column name="NAME">New Coorporation I</column></record><record><column name="ID">5</column><column name="NAME">New Coorporation II</column></record></resultSet>
>testUpdate
>testGetByID
<?xml version='1.0' encoding='UTF-8'?><resultSet><record><column name="ID">4</column><column name="NAME">Update Coorporation</column></record></resultSet>
>testDeleteByID
>testDelete
recreating database...
done!
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 4.657 sec
Running org.apache.tuscany.sca.implementation.data.DATATestCase
>testInsert
Number of rows inserted: 2
>testGet
<?xml version='1.0' encoding='UTF-8'?><resultSet><record><column name="ID">6</column><column name="NAME">New Coorporation I</column></record><record><column name="ID">7</column><column name="NAME">New Coorporation II</column></record></resultSet>
>testUpdate
>testGetByID
<?xml version='1.0' encoding='UTF-8'?><resultSet />
>testDeleteByID
>testDelete
Tests run: 6, Failures: 3, Errors: 0, Skipped: 0, Time elapsed: 1.394 sec <<< FAILURE!
testUpdate(org.apache.tuscany.sca.implementation.data.DATATestCase)  Time elapsed: 0.229 sec  <<< FAILURE!
junit.framework.AssertionFailedError: expected:<0> but was:<1>
        at junit.framework.Assert.fail(Assert.java:47)
        at junit.framework.Assert.failNotEquals(Assert.java:277)
        at junit.framework.Assert.assertEquals(Assert.java:64)
        at junit.framework.Assert.assertEquals(Assert.java:195)
        at junit.framework.Assert.assertEquals(Assert.java:201)
        at org.apache.tuscany.sca.implementation.data.DATATestCase.testUpdate(DATATestCase.java:94)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at junit.framework.TestCase.runTest(TestCase.java:168)
        at junit.framework.TestCase.runBare(TestCase.java:134)
        at junit.framework.TestResult$1.protect(TestResult.java:110)
        at junit.framework.TestResult.runProtected(TestResult.java:128)
        at junit.framework.TestResult.run(TestResult.java:113)
        at junit.framework.TestCase.run(TestCase.java:124)
        at junit.framework.TestSuite.runTest(TestSuite.java:232)
        at junit.framework.TestSuite.run(TestSuite.java:227)
        at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35)
        at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:138)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:125)
        at org.apache.maven.surefire.Surefire.run(Surefire.java:132)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:308)
        at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:879)

testDeleteByID(org.apache.tuscany.sca.implementation.data.DATATestCase)  Time elapsed: 0.227 sec  <<< FAILURE!
junit.framework.AssertionFailedError: expected:<0> but was:<1>
        at junit.framework.Assert.fail(Assert.java:47)
        at junit.framework.Assert.failNotEquals(Assert.java:277)
        at junit.framework.Assert.assertEquals(Assert.java:64)
        at junit.framework.Assert.assertEquals(Assert.java:195)
        at junit.framework.Assert.assertEquals(Assert.java:201)
        at org.apache.tuscany.sca.implementation.data.DATATestCase.testDeleteByID(DATATestCase.java:117)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at junit.framework.TestCase.runTest(TestCase.java:168)
        at junit.framework.TestCase.runBare(TestCase.java:134)
        at junit.framework.TestResult$1.protect(TestResult.java:110)
        at junit.framework.TestResult.runProtected(TestResult.java:128)
        at junit.framework.TestResult.run(TestResult.java:113)
        at junit.framework.TestCase.run(TestCase.java:124)
        at junit.framework.TestSuite.runTest(TestSuite.java:232)
        at junit.framework.TestSuite.run(TestSuite.java:227)
        at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35)
        at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:138)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:125)
        at org.apache.maven.surefire.Surefire.run(Surefire.java:132)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:308)
        at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:879)

testDelete(org.apache.tuscany.sca.implementation.data.DATATestCase)  Time elapsed: 0.225 sec  <<< FAILURE!
junit.framework.AssertionFailedError: expected:<2> but was:<4>
        at junit.framework.Assert.fail(Assert.java:47)
        at junit.framework.Assert.failNotEquals(Assert.java:277)
        at junit.framework.Assert.assertEquals(Assert.java:64)
        at junit.framework.Assert.assertEquals(Assert.java:195)
        at junit.framework.Assert.assertEquals(Assert.java:201)
        at org.apache.tuscany.sca.implementation.data.DATATestCase.testDelete(DATATestCase.java:125)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at junit.framework.TestCase.runTest(TestCase.java:168)
        at junit.framework.TestCase.runBare(TestCase.java:134)
        at junit.framework.TestResult$1.protect(TestResult.java:110)
        at junit.framework.TestResult.runProtected(TestResult.java:128)
        at junit.framework.TestResult.run(TestResult.java:113)
        at junit.framework.TestCase.run(TestCase.java:124)
        at junit.framework.TestSuite.runTest(TestSuite.java:232)
        at junit.framework.TestSuite.run(TestSuite.java:227)
        at org.junit.internal.runners.OldTestClassRunner.run(OldTestClassRunner.java:35)
        at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:138)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:125)
        at org.apache.maven.surefire.Surefire.run(Surefire.java:132)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:308)
        at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:879)


Results :

Failed tests: 
  testUpdate(org.apache.tuscany.sca.implementation.data.DATATestCase)
  testDeleteByID(org.apache.tuscany.sca.implementation.data.DATATestCase)
  testDelete(org.apache.tuscany.sca.implementation.data.DATATestCase)

Tests run: 14, Failures: 3, Errors: 0, Skipped: 0


> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>            Assignee: Luciano Resende
>             Fix For: Java-SCA-Next
>
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Updated: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Douglas Siqueira Leite (JIRA)" <tu...@ws.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Douglas Siqueira Leite updated TUSCANY-2297:
--------------------------------------------

    Attachment: DATAInvoker.java

Attaching the DATAInvoker.java file as solicited by Luciano

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Commented: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Luciano Resende (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12595127#action_12595127 ] 

Luciano Resende commented on TUSCANY-2297:
------------------------------------------

I'm having issues with the DataInvoker.java while applying the patch. Would you mind attaching the new version of the java file.

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>         Attachments: tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Commented: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Mark Combellack (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596784#action_12596784 ] 

Mark Combellack commented on TUSCANY-2297:
------------------------------------------

Looking into it in more detail, the problem is that this patch introduces a new test case called DATACollectionTestCase that is a duplicate of DataTestCase. The problem is that these two test cases will not run one after the other.

What happens is:

1) Initially, the test data is loaded into the database by the Maven build script.
2) The DATACollectionTestCase runs which will delete the data from the database in the testDelete() test case.
3) The DataTestCase now runs. However, it will fail since the data has already been deleted by DATACollectionTestCase



I notice that in both JUnit test classes, the testDelete() suggests that it re-creates the database:

        System.out.println("recreating database...");
        //Helper.createDB();
        System.out.println("done!");

However, the above code is not going to restore the database.

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>            Assignee: Luciano Resende
>             Fix For: Java-SCA-Next
>
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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


[jira] Commented: (TUSCANY-2297) Add support for data Collection interface to the implementation-data-xml

Posted by "Mark Combellack (JIRA)" <tu...@ws.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596785#action_12596785 ] 

Mark Combellack commented on TUSCANY-2297:
------------------------------------------

What I have done to work around this issue is to rename DATACollectionTestCase to DATACollectionTestCaseFIXME. This will hopefully allow the main Continuum build to complete.

Deleting       implementation-data-xml/src/test/java/org/apache/tuscany/sca/implementation/data/DATACollectionTestCase.java
Adding         implementation-data-xml/src/test/java/org/apache/tuscany/sca/implementation/data/DATACollectionTestCaseFIXME.java
Transmitting file data .
Committed revision 656307.

> Add support for data Collection interface to the implementation-data-xml
> ------------------------------------------------------------------------
>
>                 Key: TUSCANY-2297
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2297
>             Project: Tuscany
>          Issue Type: New Feature
>          Components: Java SCA Java Implementation Extension
>            Reporter: Douglas Siqueira Leite
>            Assignee: Luciano Resende
>             Fix For: Java-SCA-Next
>
>         Attachments: DATAInvoker.java, tuscany2297_douglas_2008_05_06.patch
>
>
> Add support for data Collection interface from implementation-data to the implementation-data-xml module

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