-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
6u37
FULL PRODUCT VERSION :
java version " 1.6.0_37 "
Java(TM) SE Runtime Environment (build 1.6.0_37-b06)
Java HotSpot(TM) 64-Bit Server VM (build 20.12-b01, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.1.7601]
EXTRA RELEVANT SYSTEM CONFIGURATION :
Microsoft SQL Server 2008 R2 (SP2) - 10.50.4000.0 (X64) Jun 28 2012 08:36:30 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)
A DESCRIPTION OF THE PROBLEM :
Creating a JDBC connection through Microsoft jTDS 1.2.7 driver to a Microsoft SQL server 2008R2 SP2 database using JDK 1.6.0_34 and up results in an indefinite wait for a connection.
This worked fine on all previous versions upto 1.6.0_33.
The application worked fine on the same database server running on a Windows 2003 server.
Note that Microsoft SQL server has Force Encryption Setting turn ON. Turning it Off will also work.
REGRESSION. Last worked in version 6u31
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Turn On Force Encryption on MS SQL Server 2008 R2.
Run the source with one jTDS drivers 1.2.x with version 1.6.0_34 and up, this program will up to the getConnection part and will stay there indefinitely.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Will see a line " Connection Completed "
ACTUAL -
It will display only " Test DB " and program will run indefinitely, and needs to be stopped forcibly.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
package test;
import java.sql.*;
/**
* Created with IntelliJ IDEA.
* User: pkua
* Date: 11/9/12
* Time: 9:20 PM
*/
public class Hello {
public static void main(String[] args) {
System.out.println( " Test DB " );
try {
String str = " Select Name from Client " ;
Class.forName( " net.sourceforge.jtds.jdbc.Driver " );
Connection con= DriverManager.getConnection( " jdbc:jtds:sqlserver://localhost:1433/CriticalDataManager;user=sa;password=password;ssl=request " );
System.out.println( " Connection Open " );
Statement stmt=con.createStatement();
ResultSet rs=stmt.executeQuery(str);
while (rs.next())
{
String name=rs.getString( " Name " );
System.out.println(name);
}
System.out.println( " Connection Completed " );
} catch (Exception ex) {
ex.printStackTrace();
}
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Use previous versions of JDK upto 1.6.0_33.
Replacing jsse.jar with an old working jar will also work.
java version " 1.6.0_37 "
Java(TM) SE Runtime Environment (build 1.6.0_37-b06)
Java HotSpot(TM) 64-Bit Server VM (build 20.12-b01, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.1.7601]
EXTRA RELEVANT SYSTEM CONFIGURATION :
Microsoft SQL Server 2008 R2 (SP2) - 10.50.4000.0 (X64) Jun 28 2012 08:36:30 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)
A DESCRIPTION OF THE PROBLEM :
Creating a JDBC connection through Microsoft jTDS 1.2.7 driver to a Microsoft SQL server 2008R2 SP2 database using JDK 1.6.0_34 and up results in an indefinite wait for a connection.
This worked fine on all previous versions upto 1.6.0_33.
The application worked fine on the same database server running on a Windows 2003 server.
Note that Microsoft SQL server has Force Encryption Setting turn ON. Turning it Off will also work.
REGRESSION. Last worked in version 6u31
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Turn On Force Encryption on MS SQL Server 2008 R2.
Run the source with one jTDS drivers 1.2.x with version 1.6.0_34 and up, this program will up to the getConnection part and will stay there indefinitely.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Will see a line " Connection Completed "
ACTUAL -
It will display only " Test DB " and program will run indefinitely, and needs to be stopped forcibly.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
package test;
import java.sql.*;
/**
* Created with IntelliJ IDEA.
* User: pkua
* Date: 11/9/12
* Time: 9:20 PM
*/
public class Hello {
public static void main(String[] args) {
System.out.println( " Test DB " );
try {
String str = " Select Name from Client " ;
Class.forName( " net.sourceforge.jtds.jdbc.Driver " );
Connection con= DriverManager.getConnection( " jdbc:jtds:sqlserver://localhost:1433/CriticalDataManager;user=sa;password=password;ssl=request " );
System.out.println( " Connection Open " );
Statement stmt=con.createStatement();
ResultSet rs=stmt.executeQuery(str);
while (rs.next())
{
String name=rs.getString( " Name " );
System.out.println(name);
}
System.out.println( " Connection Completed " );
} catch (Exception ex) {
ex.printStackTrace();
}
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Use previous versions of JDK upto 1.6.0_33.
Replacing jsse.jar with an old working jar will also work.
- duplicates
-
JDK-8014272 jTDS JDBC SSL connections hang with JRE 6u34 and 7u6
-
- Closed
-