You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Vemund Østgaard (JIRA)" <ji...@apache.org> on 2007/01/31 12:00:18 UTC

[jira] Created: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
-----------------------------------------------------------------

                 Key: DERBY-2279
                 URL: https://issues.apache.org/jira/browse/DERBY-2279
             Project: Derby
          Issue Type: Bug
          Components: JDBC
    Affects Versions: 10.2.2.0
         Environment: jdk1.7
            Reporter: Vemund Østgaard
         Assigned To: Vemund Østgaard


When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.

The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:

-                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
-                                               id = 5;
+                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
+                                               id = J2SE_16;


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


[jira] Resolved: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

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

Kristian Waagan resolved DERBY-2279.
------------------------------------

       Resolution: Fixed
    Fix Version/s: 10.3.0.0
                   10.0.2.2
       Derby Info:   (was: [Patch Available])

Committed patch to trunk with revision 501833.
Merged to 10..2 with revision 501841.

Thanks!

> JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
> -----------------------------------------------------------------
>
>                 Key: DERBY-2279
>                 URL: https://issues.apache.org/jira/browse/DERBY-2279
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.2.0
>         Environment: jdk1.7
>            Reporter: Vemund Østgaard
>         Assigned To: Vemund Østgaard
>             Fix For: 10.0.2.2, 10.3.0.0
>
>         Attachments: 2279-diff, 2279-diff.stat
>
>
> When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.
> The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:
> -                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
> -                                               id = 5;
> +                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
> +                                               id = J2SE_16;

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


[jira] Updated: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

Posted by "Vemund Østgaard (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2279?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vemund Østgaard updated DERBY-2279:
-----------------------------------

    Attachment: 2279-diff.stat
                2279-diff

Attached a patch that makes sure that JDBC4 is used when running in a jvm with a java version > 1.6.

Running derbyall and suites.All with this patch reduced the number of failures for jdk1.7 significantly.

> JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
> -----------------------------------------------------------------
>
>                 Key: DERBY-2279
>                 URL: https://issues.apache.org/jira/browse/DERBY-2279
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.2.0
>         Environment: jdk1.7
>            Reporter: Vemund Østgaard
>         Assigned To: Vemund Østgaard
>         Attachments: 2279-diff, 2279-diff.stat
>
>
> When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.
> The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:
> -                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
> -                                               id = 5;
> +                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
> +                                               id = J2SE_16;

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


[jira] Updated: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

Posted by "Vemund Østgaard (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2279?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vemund Østgaard updated DERBY-2279:
-----------------------------------

    Derby Info: [Patch Available]

> JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
> -----------------------------------------------------------------
>
>                 Key: DERBY-2279
>                 URL: https://issues.apache.org/jira/browse/DERBY-2279
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.2.0
>         Environment: jdk1.7
>            Reporter: Vemund Østgaard
>         Assigned To: Vemund Østgaard
>         Attachments: 2279-diff, 2279-diff.stat
>
>
> When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.
> The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:
> -                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
> -                                               id = 5;
> +                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
> +                                               id = J2SE_16;

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


[jira] Updated: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

Posted by "Myrna van Lunteren (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2279?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Myrna van Lunteren updated DERBY-2279:
--------------------------------------

    Fix Version/s:     (was: 10.0.2.2)
                   10.2.2.1

> JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
> -----------------------------------------------------------------
>
>                 Key: DERBY-2279
>                 URL: https://issues.apache.org/jira/browse/DERBY-2279
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.2.0
>         Environment: jdk1.7
>            Reporter: Vemund Østgaard
>         Assigned To: Vemund Østgaard
>             Fix For: 10.2.2.1, 10.3.0.0
>
>         Attachments: 2279-diff, 2279-diff.stat
>
>
> When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.
> The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:
> -                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
> -                                               id = 5;
> +                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
> +                                               id = J2SE_16;

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


[jira] Closed: (DERBY-2279) JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7

Posted by "Vemund Østgaard (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-2279?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vemund Østgaard closed DERBY-2279.
----------------------------------


> JDBC3 driver is loaded instead of JDBC4 when running with jdk1.7 
> -----------------------------------------------------------------
>
>                 Key: DERBY-2279
>                 URL: https://issues.apache.org/jira/browse/DERBY-2279
>             Project: Derby
>          Issue Type: Bug
>          Components: JDBC
>    Affects Versions: 10.2.2.0
>         Environment: jdk1.7
>            Reporter: Vemund Østgaard
>            Assignee: Vemund Østgaard
>             Fix For: 10.2.2.1, 10.3.1.4
>
>         Attachments: 2279-diff, 2279-diff.stat
>
>
> When running tests with jdk1.7 I discovered that the test harness used 1.6 master files and tested JDBC4 functionality, but Derby loaded a JDBC3 driver, causing a lot of failures.
> The problem is caused by code in engine/org/apache/derby/iapi/services/info/JVMInfo.java that controls what version of JDBC to use, based on the version of java that the jvm is running. A check at the end seems to be intended to make sure that Derby is compatible with future jdk versions, but it is outdated and makes sure that any "unknown" jvm newer than 1.4 uses JDBC3. The check should be changed to make sure that any jvm newer than 1.6 uses JDBC4:
> -                                       if (Float.valueOf(javaVersion).floatValue() > 1.4f)
> -                                               id = 5;
> +                                       if (Float.valueOf(javaVersion).floatValue() > 1.6f)
> +                                               id = J2SE_16;

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