Derby
  1. Derby
  2. DERBY-1830

optimizerOverrides.sql fails with wctme5.7 with CNFE java.sql.DriverManager.

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 10.2.1.6, 10.3.1.4
    • Fix Version/s: 10.2.1.6, 10.3.1.4
    • Component/s: Test
    • Labels:
      None
    • Bug behavior facts:
      Regression Test Failure

      Description

      Test failed with 10.3 jars 10.3.0.0 alpha - (439522).

          • Start: optimizerOverrides jdkJ2ME Foundation Specification v1.0 derbyall:derbylang 2006-09-03 12:47:49 ***
            1747a1748,1756
            > ERROR 38000: The exception 'java.sql.SQLException: The exception 'java.lang.reflect.InvocationTargetException' was thrown while evaluating an expression.' was thrown while evaluating an expression.
            > ERROR 38000: The exception 'java.lang.reflect.InvocationTargetException' was thrown while evaluating an expression.
            > ERROR XJ001: Java exception: ': java.lang.reflect.InvocationTargetException'.
            > ERROR XJ001: Java exception: 'java.sql.DriverManager: java.lang.NoClassDefFoundError'.
            > ij> select * from warehouse order by t1;
            > T1
            > -----------
            > ij> – cleanup
            > drop table warehouse;
            1749,1764d1757
            < ij> select * from warehouse order by t1;
            < T1
            < -----------
            < 1
            < 2
            < 3
            < 4
            < 5
            < 6
            < 7
            < 8
            < 9
            < 10
            < ij> – cleanup
            < drop table warehouse;
            < 0 rows inserted/updated/deleted
            Test Failed.
          • End: optimizerOverrides jdkJ2ME Foundation Specification v1.0 derbyall:derbylang 2006-09-03 12:48:06 ***

      This particular testcase was added as part of DERBY-1660.

      1. derby1830.stat.txt
        0.5 kB
        Sunitha Kambhampati
      2. derby1830.diff.txt
        8 kB
        Sunitha Kambhampati

        Activity

        Hide
        Sunitha Kambhampati added a comment -

        The testcase added for derby-1660 in optimizerOverrides.sql uses jdbc:default:connection and does not work with wctme5.7 foundation causing the diff mentioned in this jira. This testcase needs to be excluded and should run only in environments that have support for DriverManager.

        This patch (derby1830.diff.txt) converts this particular testcase into a junit test.

        1. Add a new Junit test in lang suite - VTITest.java
        2. Conditionally add the test fixture bulkInsertVtiTest if JDBC.vmSupportsJDBC2() is true.
        3. Since the problematic testcase is converted to junit test, remove this test from optimizerOverrides.sql and update the master files for embedded and server frameworks.

        derbyall ran cleanly on jdk142/windows.

        I ran the _Suite in lang and the VTITest using junit directly using the below commands.
        java -Dderby.system.home=$PWD junit.textui.TestRunner org.apache.derbyTesting.functionTests.tests.lang._Suite
        java -Dderby.system.home=$PWD junit.textui.TestRunner org.apache.derbyTesting.functionTests.tests.lang.VTITest

        The test passed OK for jdk142 vm.

        In wctme5.7, I ran the VTITest and the test is skipped as expected.
        Note: Using wctme5.7 for the entire lang _Suite does not work - this is related to Derby-1785

        My wctme5.7_foundation environment is having problems so I have not been able to run tests there. I am trying to get my env problems resolved.

        Meantime, I'd appreciate it if someone can try this patch out on a wctme5.7_foundation environment and post the results.

        Please take a look at this patch.

        Thanks.

        Show
        Sunitha Kambhampati added a comment - The testcase added for derby-1660 in optimizerOverrides.sql uses jdbc:default:connection and does not work with wctme5.7 foundation causing the diff mentioned in this jira. This testcase needs to be excluded and should run only in environments that have support for DriverManager. This patch (derby1830.diff.txt) converts this particular testcase into a junit test. 1. Add a new Junit test in lang suite - VTITest.java 2. Conditionally add the test fixture bulkInsertVtiTest if JDBC.vmSupportsJDBC2() is true. 3. Since the problematic testcase is converted to junit test, remove this test from optimizerOverrides.sql and update the master files for embedded and server frameworks. derbyall ran cleanly on jdk142/windows. I ran the _Suite in lang and the VTITest using junit directly using the below commands. java -Dderby.system.home=$PWD junit.textui.TestRunner org.apache.derbyTesting.functionTests.tests.lang._Suite java -Dderby.system.home=$PWD junit.textui.TestRunner org.apache.derbyTesting.functionTests.tests.lang.VTITest The test passed OK for jdk142 vm. In wctme5.7, I ran the VTITest and the test is skipped as expected. Note: Using wctme5.7 for the entire lang _Suite does not work - this is related to Derby-1785 My wctme5.7_foundation environment is having problems so I have not been able to run tests there. I am trying to get my env problems resolved. Meantime, I'd appreciate it if someone can try this patch out on a wctme5.7_foundation environment and post the results. Please take a look at this patch. Thanks.
        Hide
        Sunitha Kambhampati added a comment -

        derby1830.diff.txt available for review.

        Show
        Sunitha Kambhampati added a comment - derby1830.diff.txt available for review.
        Hide
        Sunitha Kambhampati added a comment -

        >My wctme5.7_foundation environment is having problems so I have not been able to run tests there. I am trying >to get my env problems resolved.

        I have resolved my env issues and I have successfuly run the lang/optimizerOverrides.sql test with wctme5.7_foundation and the test passes OK (as expected).

        derby1830.diff.txt is ready for review/commit. Thanks.

        Show
        Sunitha Kambhampati added a comment - >My wctme5.7_foundation environment is having problems so I have not been able to run tests there. I am trying >to get my env problems resolved. I have resolved my env issues and I have successfuly run the lang/optimizerOverrides.sql test with wctme5.7_foundation and the test passes OK (as expected). derby1830.diff.txt is ready for review/commit. Thanks.
        Hide
        Mike Matrigali added a comment -

        Committed this change to the trunk.

        m1_ibm142:133>svn commit

        Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe
        t\optimizerOverrides.out
        Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe
        tClient\optimizerOverrides.out
        Sending java\testing\org\apache\derbyTesting\functionTests\master\optimiz
        erOverrides.out
        Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang_Su
        ite.java
        Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang\opt
        imizerOverrides.sql
        Transmitting file data .....
        Committed revision 449114.

        Show
        Mike Matrigali added a comment - Committed this change to the trunk. m1_ibm142:133>svn commit Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe t\optimizerOverrides.out Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe tClient\optimizerOverrides.out Sending java\testing\org\apache\derbyTesting\functionTests\master\optimiz erOverrides.out Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang_Su ite.java Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang\opt imizerOverrides.sql Transmitting file data ..... Committed revision 449114.
        Hide
        Mike Matrigali added a comment -

        backported test only change to 10.2 branch.

        c:/p4/mv10_2/opensource
        m102_ibm142:28>svn commit

        Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe
        t\optimizerOverrides.out
        Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe
        tClient\optimizerOverrides.out
        Sending java\testing\org\apache\derbyTesting\functionTests\master\optimiz
        erOverrides.out
        Adding java\testing\org\apache\derbyTesting\functionTests\tests\lang\VTI
        Test.java
        Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang_Su
        ite.java
        Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang\opt
        imizerOverrides.sql
        Transmitting file data .....
        Committed revision 449500.

        Show
        Mike Matrigali added a comment - backported test only change to 10.2 branch. c:/p4/mv10_2/opensource m102_ibm142:28>svn commit Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe t\optimizerOverrides.out Sending java\testing\org\apache\derbyTesting\functionTests\master\DerbyNe tClient\optimizerOverrides.out Sending java\testing\org\apache\derbyTesting\functionTests\master\optimiz erOverrides.out Adding java\testing\org\apache\derbyTesting\functionTests\tests\lang\VTI Test.java Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang_Su ite.java Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang\opt imizerOverrides.sql Transmitting file data ..... Committed revision 449500.
        Hide
        Mike Matrigali added a comment -

        marking fixed in 10.2.1.4 - but really it is 10.2.1.5 (or later as release probably should be bumped now that another RC has been generated).

        Show
        Mike Matrigali added a comment - marking fixed in 10.2.1.4 - but really it is 10.2.1.5 (or later as release probably should be bumped now that another RC has been generated).
        Hide
        Sunitha Kambhampati added a comment -

        Unchecking patch available as this test only change has gone into both 10.2 branch and main(10.3)

        Show
        Sunitha Kambhampati added a comment - Unchecking patch available as this test only change has gone into both 10.2 branch and main(10.3)
        Hide
        Sunitha Kambhampati added a comment -

        Thanks Mike for the commits.

        Show
        Sunitha Kambhampati added a comment - Thanks Mike for the commits.
        Hide
        Andrew McIntyre added a comment -

        This issue has been resolved for over a year with no further movement. Closing.

        Show
        Andrew McIntyre added a comment - This issue has been resolved for over a year with no further movement. Closing.

          People

          • Assignee:
            Sunitha Kambhampati
            Reporter:
            Sunitha Kambhampati
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development