diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..945df88 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/mysql-connector-java-5.1.25-nojars.tar.xz diff --git a/.mysql-connector-java.metadata b/.mysql-connector-java.metadata new file mode 100644 index 0000000..c012f44 --- /dev/null +++ b/.mysql-connector-java.metadata @@ -0,0 +1 @@ +90c97d16f400ac4e17e647dc111bbd67f179ccb9 SOURCES/mysql-connector-java-5.1.25-nojars.tar.xz diff --git a/SOURCES/generate-tarball.sh b/SOURCES/generate-tarball.sh new file mode 100755 index 0000000..2931510 --- /dev/null +++ b/SOURCES/generate-tarball.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +VERSION=$1 + +rm -rf mysql-connector-java-$VERSION + +tar xfz mysql-connector-java-$VERSION.tar.gz || exit 1 + +find mysql-connector-java-$VERSION -name '*.jar' -exec rm {} \; + +tar cfJ mysql-connector-java-$VERSION-nojars.tar.xz mysql-connector-java-$VERSION || exit 1 + +rm -rf mysql-connector-java-$VERSION + +exit 0 diff --git a/SOURCES/mysql-connector-java-jdbc-4.1.patch b/SOURCES/mysql-connector-java-jdbc-4.1.patch new file mode 100644 index 0000000..f5213e2 --- /dev/null +++ b/SOURCES/mysql-connector-java-jdbc-4.1.patch @@ -0,0 +1,1956 @@ +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/CallableStatement.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/CallableStatement.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/CallableStatement.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/CallableStatement.java 2013-04-08 16:29:34.250742605 +0200 +@@ -31,11 +31,15 @@ import java.net.URL; + import java.sql.Array; + import java.sql.Blob; + import java.sql.Clob; ++import java.sql.NClob; + import java.sql.Date; + import java.sql.ParameterMetaData; + import java.sql.Ref; + import java.sql.ResultSet; ++import java.sql.RowId; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; + import java.sql.Time; + import java.sql.Timestamp; + import java.sql.Types; +@@ -426,11 +430,11 @@ public class CallableStatement extends P + * @throws java.sql.SQLException If no object found that implements the interface + * @since 1.6 + */ +- public Object unwrap(Class iface) throws java.sql.SQLException { ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { + try { + // This works for classes that aren't actually wrapping + // anything +- return Util.cast(iface, this); ++ return iface.cast(this); + } catch (ClassCastException cce) { + throw SQLError.createSQLException("Unable to unwrap to " + iface.toString(), + SQLError.SQL_STATE_ILLEGAL_ARGUMENT, getExceptionInterceptor()); +@@ -2665,4 +2669,95 @@ public class CallableStatement extends P + } + } + } ++ ++ @Override ++ public void setNClob(String parameterName, NClob value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(String parameterName, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(String parameterName, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getCharacterStream(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getCharacterStream(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setSQLXML(String parameterName, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob (int parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob (String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNString(String parameterName, String value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setRowId(String parameterName, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ConnectionImpl.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ConnectionImpl.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ConnectionImpl.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ConnectionImpl.java 2013-04-08 16:29:34.252742605 +0200 +@@ -34,11 +34,16 @@ import java.nio.charset.Charset; + import java.nio.charset.CharsetEncoder; + import java.sql.Blob; + import java.sql.DatabaseMetaData; ++import java.sql.NClob; + import java.sql.ResultSet; + import java.sql.SQLException; ++import java.sql.SQLXML; + import java.sql.SQLPermission; + import java.sql.SQLWarning; + import java.sql.Savepoint; ++import java.sql.SQLClientInfoException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.Struct; + import java.util.ArrayList; + import java.util.Calendar; + import java.util.Collections; +@@ -6101,4 +6106,71 @@ public class ConnectionImpl extends Conn + return getSocketTimeout(); + } + } ++ ++ @Override ++ public Struct createStruct(String typeName, Object[] attributes) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.sql.Array createArrayOf(String typeName, Object[] elements) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getClientInfo(String name) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Properties getClientInfo() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClientInfo(String name, String value) ++ throws SQLClientInfoException { ++ //throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClientInfo(Properties properties) throws SQLClientInfoException { ++ //throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isValid(int timeout) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML createSQLXML() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob createNClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Blob createBlob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Clob createClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/DatabaseMetaData.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/DatabaseMetaData.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/DatabaseMetaData.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/DatabaseMetaData.java 2013-04-08 16:29:34.265742606 +0200 +@@ -30,6 +30,8 @@ import java.sql.ResultSet; + import java.sql.SQLException; + import java.sql.Statement; + import java.sql.Types; ++import java.sql.RowIdLifetime; ++import java.sql.SQLFeatureNotSupportedException; + import java.util.ArrayList; + import java.util.Collections; + import java.util.HashMap; +@@ -8540,4 +8542,37 @@ public class DatabaseMetaData implements + throws SQLException { + return true; + } ++ ++ @Override ++ public ResultSet getFunctions(String catalog, String schemaPattern, ++ String functionNamePattern) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public ResultSet getClientInfoProperties() ++ throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean autoCommitFailureClosesAllResultSets() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowIdLifetime getRowIdLifetime() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/Driver.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/Driver.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/Driver.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/Driver.java 2013-04-08 16:29:34.323742612 +0200 +@@ -26,6 +26,8 @@ + package com.mysql.jdbc; + + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.util.logging.Logger; + + /** + * The Java SQL framework allows for multiple database drivers. Each driver +@@ -78,4 +80,9 @@ public class Driver extends NonRegisteri + public Driver() throws SQLException { + // Required for Class.forName().newInstance() + } ++ ++ @Override ++ public Logger getParentLogger() throws SQLFeatureNotSupportedException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/CallableStatementWrapper.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/CallableStatementWrapper.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/CallableStatementWrapper.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/CallableStatementWrapper.java 2013-04-08 16:29:34.353742614 +0200 +@@ -35,8 +35,12 @@ import java.sql.Blob; + import java.sql.CallableStatement; + import java.sql.Clob; + import java.sql.Date; ++import java.sql.NClob; + import java.sql.Ref; ++import java.sql.RowId; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; + import java.sql.Time; + import java.sql.Timestamp; + import java.util.Calendar; +@@ -2636,4 +2640,169 @@ public class CallableStatementWrapper ex + // throw SQLError.notImplemented(); + // } + ++ @Override ++ public T getObject(int parameterIndex, Class type) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T getObject(String parameterName, Class type) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBlob(String parameterName, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClob(String parameterName, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNCharacterStream(String parameterName, Reader value) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setCharacterStream(String parameterName, java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBinaryStream(String parameterName, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setAsciiStream(String parameterName, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setCharacterStream(String parameterName, java.io.Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBinaryStream(String parameterName, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setAsciiStream(String parameterName, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClob (String parameterName, Clob x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBlob (String parameterName, Blob x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getCharacterStream(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getCharacterStream(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setSQLXML(String parameterName, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob (String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob (int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(String parameterName, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBlob(String parameterName, InputStream inputStream, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClob(String parameterName, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(String parameterName, NClob value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNCharacterStream(String parameterName, Reader value, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNString(String parameterName, String value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setRowId(String parameterName, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(String parameterName) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(int parameterIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/ConnectionWrapper.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/ConnectionWrapper.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/ConnectionWrapper.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/ConnectionWrapper.java 2013-04-08 16:29:34.354742614 +0200 +@@ -26,8 +26,15 @@ + package com.mysql.jdbc.jdbc2.optional; + + import java.lang.reflect.Constructor; ++import java.sql.Blob; ++import java.sql.Clob; ++import java.sql.NClob; + import java.sql.SQLException; ++import java.sql.SQLXML; + import java.sql.Savepoint; ++import java.sql.SQLClientInfoException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.Struct; + import java.sql.Statement; + import java.util.Map; + import java.util.Properties; +@@ -2834,4 +2841,68 @@ public class ConnectionWrapper extends W + return this.mc.getConnectionMutex(); + } + +-} +\ No newline at end of file ++ @Override ++ public Struct createStruct(String typeName, Object[] attributes) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.sql.Array createArrayOf(String typeName, Object[] elements) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getClientInfo(String name) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Properties getClientInfo() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ @Override ++ public void setClientInfo(String name, String value) throws SQLClientInfoException { ++ //throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClientInfo(Properties properties) throws SQLClientInfoException { ++ //throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isValid(int timeout) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML createSQLXML() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob createNClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Blob createBlob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Clob createClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++} +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/MysqlDataSource.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/MysqlDataSource.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/MysqlDataSource.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/MysqlDataSource.java 2013-04-08 16:29:34.355742615 +0200 +@@ -28,8 +28,10 @@ package com.mysql.jdbc.jdbc2.optional; + import java.io.PrintWriter; + import java.io.Serializable; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.util.Iterator; + import java.util.Properties; ++import java.util.logging.Logger; + + import javax.naming.NamingException; + import javax.naming.Reference; +@@ -450,4 +452,19 @@ public class MysqlDataSource extends Con + // public T unwrap(Class iface) throws SQLException { + // throw SQLError.notImplemented(); + // } ++ ++ @Override ++ public Logger getParentLogger() throws SQLFeatureNotSupportedException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/MysqlPooledConnection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/MysqlPooledConnection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/MysqlPooledConnection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/MysqlPooledConnection.java 2013-04-08 16:29:34.356742615 +0200 +@@ -27,6 +27,7 @@ package com.mysql.jdbc.jdbc2.optional; + import java.lang.reflect.Constructor; + import java.sql.Connection; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.util.HashMap; + import java.util.Iterator; + import java.util.Map; +@@ -34,6 +35,7 @@ import java.util.Map; + import javax.sql.ConnectionEvent; + import javax.sql.ConnectionEventListener; + import javax.sql.PooledConnection; ++import javax.sql.StatementEventListener; + + import com.mysql.jdbc.ExceptionInterceptor; + import com.mysql.jdbc.SQLError; +@@ -254,4 +256,13 @@ public class MysqlPooledConnection imple + protected ExceptionInterceptor getExceptionInterceptor() { + return this.exceptionInterceptor; + } +-} +\ No newline at end of file ++ ++ @Override ++ public void addStatementEventListener(StatementEventListener listener) { ++ } ++ ++ @Override ++ public void removeStatementEventListener(StatementEventListener listener) { ++ } ++ ++} +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/PreparedStatementWrapper.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/PreparedStatementWrapper.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/PreparedStatementWrapper.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/PreparedStatementWrapper.java 2013-04-08 16:29:34.357742615 +0200 +@@ -34,12 +34,16 @@ import java.sql.Array; + import java.sql.Blob; + import java.sql.Clob; + import java.sql.Date; ++import java.sql.NClob; + import java.sql.ParameterMetaData; + import java.sql.PreparedStatement; + import java.sql.Ref; + import java.sql.ResultSet; + import java.sql.ResultSetMetaData; ++import java.sql.RowId; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; + import java.sql.Time; + import java.sql.Timestamp; + import java.util.Calendar; +@@ -1224,4 +1228,107 @@ public class PreparedStatementWrapper ex + // public Object unwrap(Class arg0) throws SQLException { + // throw SQLError.notImplemented(); + // } ++ ++ public void setNClob(String parameterName, NClob value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setNClob(String parameterName, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setNClob(String parameterName, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(int parameterName, NClob value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(int parameterName, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(int parameterName, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBlob(int parameterIndex, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClob(int parameterIndex, Reader reader) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNCharacterStream(int parameterIndex, Reader value) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setCharacterStream(int parameterIndex, java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBinaryStream(int parameterIndex, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setAsciiStream(int parameterIndex, java.io.InputStream x) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setCharacterStream(int parameterIndex, java.io.Reader reader, long length) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBinaryStream(int parameterIndex, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setAsciiStream(int parameterIndex, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setBlob(int parameterIndex, InputStream inputStream, long length) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClob(int parameterIndex, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNCharacterStream(int parameterIndex, Reader value, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNString(int parameterIndex, String value) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setRowId(int parameterIndex, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/StatementWrapper.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/StatementWrapper.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/jdbc2/optional/StatementWrapper.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/jdbc2/optional/StatementWrapper.java 2013-04-08 16:29:34.358742615 +0200 +@@ -29,6 +29,7 @@ import java.lang.reflect.Constructor; + import java.sql.Connection; + import java.sql.ResultSet; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.sql.SQLWarning; + import java.sql.Statement; + +@@ -866,4 +867,41 @@ public class StatementWrapper extends Wr + checkAndFireConnectionError(sqlEx); + } + } ++ ++ @Override ++ public boolean isCloseOnCompletion() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void closeOnCompletion() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isPoolable() throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setPoolable(boolean poolable) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isClosed() throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4Connection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4Connection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4Connection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4Connection.java 2013-04-08 16:29:34.358742615 +0200 +@@ -28,9 +28,11 @@ import java.sql.Blob; + import java.sql.Clob; + import java.sql.SQLClientInfoException; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.sql.SQLXML; + import java.sql.NClob; + import java.sql.Struct; ++import java.util.concurrent.Executor; + import java.util.Properties; + import java.util.TimerTask; + +@@ -200,7 +202,8 @@ public class JDBC4Connection extends Con + /** + * @see java.sql.Connection#createClob() + */ +- public Clob createClob() { ++ @Override ++ public com.mysql.jdbc.Clob createClob() throws SQLException { + return new com.mysql.jdbc.Clob(getExceptionInterceptor()); + } + +@@ -238,4 +241,25 @@ public class JDBC4Connection extends Con + return this.infoProvider; + } + } ++ ++ public int getNetworkTimeout() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setNetworkTimeout(Executor executor, int millis) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void abort(Executor executor) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public String getSchema() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setSchema(String schema) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4LoadBalancedMySQLConnection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4LoadBalancedMySQLConnection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4LoadBalancedMySQLConnection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4LoadBalancedMySQLConnection.java 2013-04-08 16:29:34.359742615 +0200 +@@ -29,9 +29,11 @@ import java.sql.Blob; + import java.sql.Clob; + import java.sql.SQLClientInfoException; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.sql.SQLXML; + import java.sql.NClob; + import java.sql.Struct; ++import java.util.concurrent.Executor; + import java.util.Properties; + import java.util.TimerTask; + +@@ -109,21 +111,24 @@ public class JDBC4LoadBalancedMySQLConne + /** + * @see java.sql.Connection#createBlob() + */ +- public Blob createBlob() { ++ @Override ++ public Blob createBlob() throws SQLException { + return this.getJDBC4Connection().createBlob(); + } + + /** + * @see java.sql.Connection#createClob() + */ +- public Clob createClob() { ++ @Override ++ public Clob createClob() throws SQLException { + return this.getJDBC4Connection().createClob(); + } + + /** + * @see java.sql.Connection#createNClob() + */ +- public NClob createNClob() { ++ @Override ++ public NClob createNClob() throws SQLException { + return this.getJDBC4Connection().createNClob(); + } + +@@ -133,6 +138,26 @@ public class JDBC4LoadBalancedMySQLConne + } + + } ++ ++ public int getNetworkTimeout() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setNetworkTimeout(Executor executor, int millis) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void abort(Executor executor) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public String getSchema() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ public void setSchema(String schema) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + + + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4MySQLConnection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4MySQLConnection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/JDBC4MySQLConnection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/JDBC4MySQLConnection.java 2013-04-08 16:29:34.360742615 +0200 +@@ -63,11 +63,14 @@ public interface JDBC4MySQLConnection ex + + public T unwrap(java.lang.Class iface) throws java.sql.SQLException; + +- public Blob createBlob(); ++ @Override ++ public Blob createBlob() throws SQLException; + +- public Clob createClob(); ++ @Override ++ public Clob createClob() throws SQLException; + +- public NClob createNClob(); ++ @Override ++ public NClob createNClob() throws SQLException; + + + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/LoadBalancedMySQLConnection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/LoadBalancedMySQLConnection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/LoadBalancedMySQLConnection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/LoadBalancedMySQLConnection.java 2013-04-08 16:29:34.361742615 +0200 +@@ -29,6 +29,14 @@ import java.sql.SQLException; + import java.sql.SQLWarning; + import java.sql.Savepoint; + import java.sql.Statement; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLClientInfoException; ++import java.sql.Struct; ++import java.sql.Array; ++import java.sql.Blob; ++import java.sql.Clob; ++import java.sql.NClob; ++import java.sql.SQLXML; + import java.util.Calendar; + import java.util.List; + import java.util.Map; +@@ -2546,34 +2554,34 @@ public class LoadBalancedMySQLConnection + getActiveMySQLConnection().setIncludeThreadNamesAsStatementComment(flag); + } + +- public boolean isServerLocal() throws SQLException { +- return getActiveMySQLConnection().isServerLocal(); +- } +- +- public void setAuthenticationPlugins(String authenticationPlugins) { +- getActiveMySQLConnection().setAuthenticationPlugins(authenticationPlugins); +- } +- +- public String getAuthenticationPlugins() { +- return getActiveMySQLConnection().getAuthenticationPlugins(); +- } +- +- public void setDisabledAuthenticationPlugins( +- String disabledAuthenticationPlugins) { +- getActiveMySQLConnection().setDisabledAuthenticationPlugins(disabledAuthenticationPlugins); +- } +- +- public String getDisabledAuthenticationPlugins() { +- return getActiveMySQLConnection().getDisabledAuthenticationPlugins(); +- } +- +- public void setDefaultAuthenticationPlugin( +- String defaultAuthenticationPlugin) { +- getActiveMySQLConnection().setDefaultAuthenticationPlugin(defaultAuthenticationPlugin); +- } +- +- public String getDefaultAuthenticationPlugin() { +- return getActiveMySQLConnection().getDefaultAuthenticationPlugin(); ++ public boolean isServerLocal() throws SQLException { ++ return getActiveMySQLConnection().isServerLocal(); ++ } ++ ++ public void setAuthenticationPlugins(String authenticationPlugins) { ++ getActiveMySQLConnection().setAuthenticationPlugins(authenticationPlugins); ++ } ++ ++ public String getAuthenticationPlugins() { ++ return getActiveMySQLConnection().getAuthenticationPlugins(); ++ } ++ ++ public void setDisabledAuthenticationPlugins( ++ String disabledAuthenticationPlugins) { ++ getActiveMySQLConnection().setDisabledAuthenticationPlugins(disabledAuthenticationPlugins); ++ } ++ ++ public String getDisabledAuthenticationPlugins() { ++ return getActiveMySQLConnection().getDisabledAuthenticationPlugins(); ++ } ++ ++ public void setDefaultAuthenticationPlugin( ++ String defaultAuthenticationPlugin) { ++ getActiveMySQLConnection().setDefaultAuthenticationPlugin(defaultAuthenticationPlugin); ++ } ++ ++ public String getDefaultAuthenticationPlugin() { ++ return getActiveMySQLConnection().getDefaultAuthenticationPlugin(); + } + + public void setParseInfoCacheFactory(String factoryClassname) { +@@ -2624,4 +2632,66 @@ public class LoadBalancedMySQLConnection + public Object getConnectionMutex() { + return getActiveMySQLConnection().getConnectionMutex(); + } ++ ++ @Override ++ public Struct createStruct(String typeName, Object[] attributes) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Array createArrayOf(String typeName, Object[] elements) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ @Override ++ public String getClientInfo(String name) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Properties getClientInfo() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClientInfo(Properties properties) throws SQLClientInfoException { ++ } ++ ++ @Override ++ public void setClientInfo(String name, String value) throws SQLClientInfoException { ++ } ++ @Override ++ public boolean isValid(int timeout) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML createSQLXML() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob createNClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Blob createBlob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Clob createClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/MysqlParameterMetadata.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/MysqlParameterMetadata.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/MysqlParameterMetadata.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/MysqlParameterMetadata.java 2013-04-08 16:29:34.364742616 +0200 +@@ -26,6 +26,7 @@ package com.mysql.jdbc; + + import java.sql.ParameterMetaData; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.sql.Types; + + public class MysqlParameterMetadata implements ParameterMetaData { +@@ -202,11 +203,11 @@ public class MysqlParameterMetadata impl + * @throws java.sql.SQLException If no object found that implements the interface + * @since 1.6 + */ +- public Object unwrap(Class iface) throws java.sql.SQLException { ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { + try { + // This works for classes that aren't actually wrapping + // anything +- return Util.cast(iface, this); ++ return iface.cast(this); + } catch (ClassCastException cce) { + throw SQLError.createSQLException("Unable to unwrap to " + iface.toString(), + SQLError.SQL_STATE_ILLEGAL_ARGUMENT, this.exceptionInterceptor); +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/NonRegisteringDriver.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/NonRegisteringDriver.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/NonRegisteringDriver.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/NonRegisteringDriver.java 2013-04-08 16:29:34.365742616 +0200 +@@ -33,6 +33,7 @@ import java.lang.ref.ReferenceQueue; + import java.net.URLDecoder; + import java.sql.DriverPropertyInfo; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.util.ArrayList; + import java.util.Iterator; + import java.util.List; +@@ -40,6 +41,9 @@ import java.util.Locale; + import java.util.Properties; + import java.util.StringTokenizer; + import java.util.concurrent.ConcurrentHashMap; ++ ++import java.util.logging.Logger; ++ + /** + * The Java SQL framework allows for multiple database drivers. Each driver + * should supply a class that implements the Driver interface +@@ -937,4 +941,9 @@ public class NonRegisteringDriver implem + } + } + } ++ ++ @Override ++ public Logger getParentLogger() throws SQLFeatureNotSupportedException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/PreparedStatement.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/PreparedStatement.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/PreparedStatement.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/PreparedStatement.java 2013-04-08 16:29:34.368742616 +0200 +@@ -40,6 +40,7 @@ import java.nio.charset.Charset; + import java.nio.charset.CharsetEncoder; + import java.sql.Array; + import java.sql.Clob; ++import java.sql.NClob; + import java.sql.DatabaseMetaData; + import java.sql.Date; + import java.sql.ParameterMetaData; +@@ -48,6 +49,9 @@ import java.sql.SQLException; + import java.sql.Time; + import java.sql.Timestamp; + import java.sql.Types; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; ++import java.sql.RowId; + import java.text.ParsePosition; + import java.text.SimpleDateFormat; + import java.util.ArrayList; +@@ -5757,4 +5761,20 @@ public class PreparedStatement extends c + statementStartPos, sql, "SELECT", "\"'`", + "\"'`", false) == -1 && rewritableOdku; + } ++ ++ @Override ++ public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException{ ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setNClob(int parameterIndex, NClob value) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setRowId(int parameterIndex, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ReplicationConnection.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ReplicationConnection.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ReplicationConnection.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ReplicationConnection.java 2013-04-08 16:29:34.463742625 +0200 +@@ -21,6 +21,12 @@ + */ + package com.mysql.jdbc; + ++import java.sql.Blob; ++import java.sql.NClob; ++import java.sql.SQLXML; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLClientInfoException; ++import java.sql.Struct; + import java.sql.CallableStatement; + import java.sql.DatabaseMetaData; + import java.sql.PreparedStatement; +@@ -2643,4 +2649,67 @@ public class ReplicationConnection imple + public Object getConnectionMutex() { + return getCurrentConnection().getConnectionMutex(); + } ++ ++ @Override ++ public Struct createStruct(String typeName, Object[] attributes) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.sql.Array createArrayOf(String typeName, Object[] elements) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getClientInfo(String name) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Properties getClientInfo() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void setClientInfo(String name, String value) throws SQLClientInfoException { ++ } ++ ++ @Override ++ public void setClientInfo(Properties properties) throws SQLClientInfoException { ++ } ++ ++ @Override ++ public boolean isValid(int timeout) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML createSQLXML() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob createNClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Blob createBlob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public Clob createClob() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ResultSetImpl.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ResultSetImpl.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ResultSetImpl.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ResultSetImpl.java 2013-04-08 16:29:34.493742627 +0200 +@@ -29,6 +29,7 @@ import java.io.ByteArrayInputStream; + import java.io.IOException; + import java.io.InputStream; + import java.io.ObjectInputStream; ++import java.io.Reader; + import java.io.StringReader; + import java.io.UnsupportedEncodingException; + import java.lang.reflect.Constructor; +@@ -38,9 +39,13 @@ import java.net.MalformedURLException; + import java.net.URL; + import java.sql.Array; + import java.sql.Date; ++import java.sql.NClob; + import java.sql.Ref; ++import java.sql.RowId; + import java.sql.SQLException; + import java.sql.SQLWarning; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; + import java.sql.Time; + import java.sql.Timestamp; + import java.sql.Types; +@@ -8747,4 +8752,258 @@ public class ResultSetImpl implements Re + protected ExceptionInterceptor getExceptionInterceptor() { + return this.exceptionInterceptor; + } ++ ++ @Override ++ public void updateNClob(int columnIndex, NClob nClob) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(int columnIndex, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(int columnIndex, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(int columnIndex, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(String columnLabel, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(int columnIndex, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(String columnLabel, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(int columnIndex, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(String columnLabel, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(String columnLabel, java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(String columnLabel, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateAsciiStream(String columnLabel, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(int columnIndex, java.io.Reader x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(int columnIndex, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateAsciiStream(int columnIndex, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(String columnLabel, java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(int columnIndex, java.io.Reader x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateBlob(int columnIndex, InputStream inputStream, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(String columnLabel, InputStream inputStream, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(String columnLabel, java.io.Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(String columnLabel, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateAsciiStream(String columnLabel, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(int columnIndex, java.io.Reader x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(int columnIndex, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateAsciiStream(int columnIndex, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(String columnLabel, java.io.Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(int columnIndex, java.io.Reader x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateSQLXML(int columnIndex, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateSQLXML(String columnLabel, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(String columnLabel) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob(String columnLabel) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, NClob nClob) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNString(String columnLabel, String nString) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNString(int columnLabel, String nString) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isClosed() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public int getHoldability() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateRowId(int columnIndex, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateRowId(String columnLabel, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ResultSetMetaData.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ResultSetMetaData.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/ResultSetMetaData.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/ResultSetMetaData.java 2013-04-08 16:29:34.515742630 +0200 +@@ -23,7 +23,9 @@ + */ + package com.mysql.jdbc; + ++import java.sql.NClob; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; + import java.sql.Types; + + /** +@@ -849,14 +851,18 @@ public class ResultSetMetaData implement + * @throws java.sql.SQLException If no object found that implements the interface + * @since 1.6 + */ +- public Object unwrap(Class iface) throws java.sql.SQLException { ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { + try { + // This works for classes that aren't actually wrapping + // anything +- return Util.cast(iface, this); ++ return iface.cast(this); + } catch (ClassCastException cce) { + throw SQLError.createSQLException("Unable to unwrap to " + iface.toString(), + SQLError.SQL_STATE_ILLEGAL_ARGUMENT, this.exceptionInterceptor); + } + } ++ ++ public void updateNClob(int columnIndex, NClob nClob) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + } +diff -rup mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/StatementImpl.java mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/StatementImpl.java +--- mysql-connector-java-5.1.24-nopatch/src/com/mysql/jdbc/StatementImpl.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/com/mysql/jdbc/StatementImpl.java 2013-04-08 16:29:34.543742632 +0200 +@@ -29,6 +29,8 @@ import java.sql.ResultSet; + import java.sql.SQLException; + import java.sql.SQLWarning; + import java.sql.Types; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.*; + import java.util.ArrayList; + import java.util.Calendar; + import java.util.Collections; +@@ -2971,16 +2973,16 @@ public class StatementImpl implements St + * @throws java.sql.SQLException If no object found that implements the interface + * @since 1.6 + */ +- public Object unwrap(Class iface) throws java.sql.SQLException { ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { + try { + // This works for classes that aren't actually wrapping + // anything +- return Util.cast(iface, this); ++ return iface.cast(this); + } catch (ClassCastException cce) { + throw SQLError.createSQLException("Unable to unwrap to " + iface.toString(), + SQLError.SQL_STATE_ILLEGAL_ARGUMENT, getExceptionInterceptor()); + } +- } ++ } + + protected int findStartOfStatement(String sql) { + int statementStartPos = 0; +@@ -3051,4 +3053,4 @@ public class StatementImpl implements St + return closeOnCompletion; + } + } +-} +\ No newline at end of file ++} +diff -rup mysql-connector-java-5.1.24-nopatch/src/testsuite/regression/StatementRegressionTest.java mysql-connector-java-5.1.24-patched/src/testsuite/regression/StatementRegressionTest.java +--- mysql-connector-java-5.1.24-nopatch/src/testsuite/regression/StatementRegressionTest.java 2013-03-11 07:20:52.000000000 +0100 ++++ mysql-connector-java-5.1.24-patched/src/testsuite/regression/StatementRegressionTest.java 2013-04-08 16:29:34.592742637 +0200 +@@ -55,6 +55,11 @@ import java.sql.Ref; + import java.sql.ResultSet; + import java.sql.ResultSetMetaData; + import java.sql.SQLException; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.NClob; ++import java.sql.RowId; ++import java.sql.SQLFeatureNotSupportedException; ++import java.sql.SQLXML; + import java.sql.SQLWarning; + import java.sql.Statement; + import java.sql.Time; +@@ -2546,7 +2551,8 @@ public class StatementRegressionTest ext + try { + pStmt = this.conn + .prepareStatement("INSERT INTO testNullClob VALUES (?)"); +- pStmt.setClob(1, null); ++ Clob x = null; ++ pStmt.setClob(1, x); + pStmt.executeUpdate(); + } finally { + if (pStmt != null) { +@@ -5273,6 +5279,276 @@ public class StatementRegressionTest ext + public int getBytesSize() throws SQLException { + return 0; + } ++ @Override ++ public T getObject(int columnIndex, Class type) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ @Override ++ public T getObject(String columnLabel, Class type) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ @Override ++ public void updateNClob(int columnIndex, NClob nClob) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(int columnIndex, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(int columnIndex, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(int columnIndex, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(String columnLabel, Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(int columnIndex, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateClob(String columnLabel, Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(int columnIndex, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(String columnLabel, InputStream inputStream) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(String columnLabel, java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(String columnLabel, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateAsciiStream(String columnLabel, java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(int columnIndex, ++ java.io.Reader x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(int columnIndex, ++ java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateAsciiStream(int columnIndex, ++ java.io.InputStream x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(String columnLabel, ++ java.io.Reader reader) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(int columnIndex, ++ java.io.Reader x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateBlob(int columnIndex, InputStream inputStream, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBlob(String columnLabel, InputStream inputStream, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(String columnLabel, java.io.Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(String columnLabel, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateAsciiStream(String columnLabel, java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateCharacterStream(int columnIndex, ++ java.io.Reader x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateBinaryStream(int columnIndex, ++ java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ ++ @Override ++ public void updateAsciiStream(int columnIndex, ++ java.io.InputStream x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(String columnLabel, ++ java.io.Reader reader, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNCharacterStream(int columnIndex, ++ java.io.Reader x, long length) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public java.io.Reader getNCharacterStream(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public String getNString(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateSQLXML(int columnIndex, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateSQLXML(String columnLabel, SQLXML xmlObject) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public SQLXML getSQLXML(String columnLabel) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public NClob getNClob(String columnLabel) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNClob(String columnLabel, NClob nClob) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNString(String columnLabel, String nString) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateNString(int columnLabel, String nString) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isClosed() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public int getHoldability() throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateRowId(int columnIndex, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public void updateRowId(String columnLabel, RowId x) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(int columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public RowId getRowId(String columnIndex) throws SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public boolean isWrapperFor(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } ++ ++ @Override ++ public T unwrap(java.lang.Class iface) throws java.sql.SQLException { ++ throw new SQLFeatureNotSupportedException("Not supported"); ++ } + }; + } + +@@ -6896,4 +7172,5 @@ public class StatementRegressionTest ext + + } + ++ + } diff --git a/SPECS/mysql-connector-java.spec b/SPECS/mysql-connector-java.spec new file mode 100644 index 0000000..139de45 --- /dev/null +++ b/SPECS/mysql-connector-java.spec @@ -0,0 +1,307 @@ +%global builddir build-mysql-jdbc +%global distdir dist-mysql-jdbc +%global java6_rtpath %{java_home}/jre/lib/rt.jar +%global java6_javacpath /usr/bin/javac +%global java6_javapath /usr/bin/javac + +Summary: Official JDBC driver for MySQL +Name: mysql-connector-java +Version: 5.1.25 +Release: 3%{?dist} +Epoch: 1 + +# MySQL FLOSS Exception +License: GPLv2 with exceptions +Group: System Environment/Libraries +URL: http://dev.mysql.com/downloads/connector/j/ + +# Mysql has a mirror redirector for its downloads +# You can get this tarball by following a link from: +# http://dev.mysql.com/get/Downloads/Connector-J/%{name}-%{version}.zip/from/pick#mirrors +# +# Following prebuilt jars and sources have been removed from the tarball: +# +# %{name}-%{version}-bin.jar +# src/lib/ant-contrib.jar +# src/lib/c3p0-0.9.1-pre6.jar +# src/lib/c3p0-0.9.1-pre6.src.zip +# src/lib/jboss-common-jdbc-wrapper.jar +# src/lib/jboss-common-jdbc-wrapper-src.jar +# src/lib/slf4j-api-1.6.1.jar +# +# See http://bugs.mysql.com/bug.php?id=28512 for details. +Source0: %{name}-%{version}-nojars.tar.xz + +# To make it easier a script generate-tarball.sh has been created: +# ./generate-tarball.sh version +# will create a new tarball compressed with xz and without those jar files. +Source1: generate-tarball.sh + +# Patch to build with JDBC 4.1/Java 7 +Patch0: %{name}-jdbc-4.1.patch + +BuildArch: noarch + +BuildRequires: java-devel >= 1:1.6.0 +BuildRequires: ant >= 1.6.0 +BuildRequires: ant-contrib >= 1.0 +BuildRequires: jpackage-utils >= 1.6 +BuildRequires: jta >= 1.0 +BuildRequires: junit +BuildRequires: slf4j +BuildRequires: apache-commons-logging + +Requires: java >= 1:1.6.0 +Requires: jta >= 1.0 +Requires: slf4j +Requires: jpackage-utils + +%description +MySQL Connector/J is a native Java driver that converts JDBC (Java Database +Connectivity) calls into the network protocol used by the MySQL database. +It lets developers working with the Java programming language easily build +programs and applets that interact with MySQL and connect all corporate +data, even in a heterogeneous environment. MySQL Connector/J is a Type +IV JDBC driver and has a complete JDBC feature set that supports the +capabilities of MySQL. + +%prep +%setup -q -n %{name}-%{version} + +# Remove duplicate README.txt files +rm README README.txt + +# fix line endings +sed -i 's/\r//' docs/README.txt + +%patch0 -p1 -F3 + +%build + +# We need both JDK1.5 (for JDBC3.0; appointed by $JAVA_HOME) and JDK1.6 (for JDBC4.0; appointed in the build.xml) +export CLASSPATH=$(build-classpath jdbc-stdext jta junit slf4j commons-logging.jar) + +# We currently need to disable jboss integration because of missing jboss-common-jdbc-wrapper.jar (built from sources). +# See BZ#480154 and BZ#471915 for details. +rm -rf src/com/mysql/jdbc/integration/jboss +rm src/testsuite/regression/ConnectionRegressionTest.java +rm src/testsuite/regression/DataSourceRegressionTest.java +rm src/testsuite/simple/ReadOnlyCallableStatementTest.java +rm src/testsuite/simple/jdbc4/StatementsTest.java + +ant -DbuildDir=%{builddir} -DdistDir=%{distdir} -Dcom.mysql.jdbc.java6.rtjar=%{java6_rtpath} -Dcom.mysql.jdbc.java6.javac=%{java6_javacpath} -Dcom.mysql.jdbc.java6.java=%{java6_javapath} + +%install +install -d -m 755 $RPM_BUILD_ROOT%{_javadir} +install -m 644 %{builddir}/%{name}-%{version}-SNAPSHOT/%{name}-%{version}-SNAPSHOT-bin.jar \ + $RPM_BUILD_ROOT%{_javadir}/%{name}.jar + +# Install the Maven build information +install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir} +install -pm 644 src/doc/sources/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom +sed -i 's/>@.*%{version} - 1:5.1.25-3 +- Mass rebuild 2013-12-27 + +* Mon Nov 4 2013 Honza Horak - 1:5.1.25-2 +- Remove versioned jars and some spec clean-up + Resolves: #1023005 + +* Fri Jul 19 2013 Honza Horak - 1:5.1.25-1 +- Update to 5.1.25 +- Spec file clean-up, removing gcj support + +* Mon Apr 8 2013 Honza Horak - 1:5.1.24-1 +- Update to 5.1.24 + +* Thu Feb 14 2013 Fedora Release Engineering - 1:5.1.22-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Tue Sep 11 2012 Miloš Jakubíček - 1:5.1.22-1 +- Update to 5.1.22 + +* Fri Jul 20 2012 Fedora Release Engineering - 1:5.1.21-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Tue Jul 10 2012 Miloš Jakubíček - 1:5.1.21-2 +- More fuzz for mysql-connector-java-jdbc-4.1.patch + +* Tue Jul 10 2012 Miloš Jakubíček - 1:5.1.21-1 +- Update to 5.1.21 + +* Sat May 5 2012 Tom Lane 1:5.1.17-5 +- Switch to noarch (non-GCJ) build +Resolves: #688937, #819139 +- Fix mysql-connector-java-jdbc-4.1.patch to cover both driver classes +Related: #816696 + +* Wed Jan 25 2012 Deepak Bhole - 1:5.1.17-4 +- Removed java-1.6.0-openjdk-devel requirement + +* Wed Jan 25 2012 Deepak Bhole - 1:5.1.17-3 +- Added patch to support build with JDBC 4.1/Java 7 + +* Fri Jan 13 2012 Fedora Release Engineering - 1:5.1.17-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Sat Aug 20 2011 Miloš Jakubíček - 1:5.1.17-1 +- Update to 5.1.17 + +* Thu Feb 10 2011 Miloš Jakubíček - 1:5.1.15-1 +- Update to 5.1.15, fix BZ#676464, changed BR: log4j to BR: slf4j + +* Tue Feb 08 2011 Fedora Release Engineering - 1:5.1.14-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Tue Jan 18 2011 Milos Jakubicek - 1:5.1.14-1 +- Update to 5.1.14 + +* Fri Feb 19 2010 Milos Jakubicek - 1:5.1.12-1 +- Update to 5.1.12 + +* Fri Jan 29 2010 Milos Jakubicek 1:5.1.11-1 +- Update to 5.1.11 + +* Thu Jan 21 2010 Tom Lane 1:5.1.8-3 +- Clean up rpmlint complaints (/usr/lib/ references, old provides/obsoletes, + tab usage) + +* Fri Dec 4 2009 Mary Ellen Foster - 1:5.1.8-2 +- Add Maven POM and depmap fragment + +* Wed Aug 26 2009 Milos Jakubicek - 1:5.1.8-1 +- Update to 5.1.8 (resolves BZ#480154) with jboss integration disabled. +- Added BR: java-1.6.0-openjdk-devel, java-1.5.0-gcj-devel, jakarta-commons-logging +- Minor spec file updates: %%global instead of %%define, tabs instead of spaces +- Dropped unnecessary patch-build.xml and mysql-connector-java-noSunAppletSecurity.patch + +* Sat Jul 25 2009 Fedora Release Engineering - 1:3.1.12-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Wed Feb 25 2009 Fedora Release Engineering - 1:3.1.12-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Mon Aug 11 2008 Tom "spot" Callaway 1:3.1.12-6 +- fix license tag + +* Fri Apr 04 2008 Andrew Overholt 1:3.1.12-5 +- Rebuild for rhbz #234286. + +* Tue Feb 19 2008 Fedora Release Engineering - 1:3.1.12-4 +- Autorebuild for GCC 4.3 + +* Thu Oct 05 2006 Christian Iseli 1:3.1.12-3 + - rebuilt for unwind info generation, broken in gcc-4.1.1-21 + +* Thu Sep 21 2006 Igor Foox 1:3.1.12-2 +- Remove jpp string from release. + +* Fri Sep 08 2006 Igor Foox 1:3.1.12-1jpp_5fc +- Add dist tag. + +* Thu Sep 07 2006 Igor Foox 1:3.1.12-1jpp_4fc +- Fix indentation of preamble. +- Fix version and epoch of jta Requires. +- Fix Group from Development/Libraries to System Environment/Libraries. + +* Wed Sep 06 2006 Igor Foox 1:3.1.12-1jpp_3fc +- Remove duplicate readme files. +- Remove binary jars from distributed tarball, since they have no source + attached to them, and are in violation of the LGPL. +- Change jta BR to 1.0 from 1.0.1 since geronimo-specs-compat is 1.0. +- Remove unneccessary 0 epoch from BRs. + +* Thu Jul 20 2006 Igor Foox 1:3.1.12-1jpp_2fc +- Fix line endings. +- Change Group to standard Development/Java. + +* Thu Jun 1 2006 Igor Foox 1:3.1.12-1jpp_1fc +- Natively compile +- Add mysql-connector-java-noSunAppletSecurity.patch to take out references +to sun classes +- Change BuildRoot to what Extras expects + +* Thu Feb 2 2006 Jason Corley 1:3.1.12-1jpp +- 3.1.12 +- add some more docs from the tarball +- correct url +- remove vendor and distribution, should be defined in ~/.rpmmacros instead + +* Sat May 14 2005 Jason Corley 1:3.1.8-0.a.1jpp +- 3.1.8a + +* Sun Feb 13 2005 Jason Corley 1:3.1.6-1jpp +- Update to 3.1.6 now that it's considered stable + +* Sat Feb 12 2005 Jason Corley 1:3.0.16-1jpp +- Update to 3.0.16 + +* Mon Aug 23 2004 Fernando Nasser 1:3.0.14-1jpp +- Update to 3.0.14 +- Rebuilt with Ant 1.6.2 + +* Wed Mar 24 2004 Kaj J. Niemi 1:3.0.11-1jpp +- Bumped epoch, back to a "stable" release + +* Fri Mar 19 2004 Kaj J. Niemi 0:3.1.1-1jpp +- 3.1.1, supports stored procedures and SAVEPOINTs among other things. +- Tidy .spec file: nicer description and don't own %%{_javadir} + +* Wed Jan 21 2004 David Walluck 0:3.0.10-1jpp +- 3.0.10 +- change group + +* Sun Oct 05 2003 Henri Gomez 0:3.0.9-1jpp +- mysql-connector-j 3.0.9 + +* Mon Jul 07 2003 Henri Gomez 3.0.8.2jpp +- mysql-connector-j 3.0.8 +- jar goes back in /usr/share/java + +* Sun May 11 2003 David Walluck 0:3.0.6-2jpp +- update for JPackage 1.5 + +* Tue Mar 25 2003 Nicolas Mailhot 3.0.6-1jpp +- For jpackage-utils 1.5 +- New project name +- Requires java >= 1.4.1 + +* Thu Jun 06 2002 Henri Gomez 2.0.14.1jpp +- mm.mysql 2.0.14 + +* Tue May 07 2002 Henri Gomez 2.0.13.1jpp +- mm.mysql 2.0.13 + +* Tue Mar 26 2002 Henri Gomez 2.0.11.2jpp +- correct changelog + +* Mon Feb 04 2002 Henri Gomez +- mm.mysql 2.0.11 + +* Thu Jan 17 2002 Henri Gomez +- mm.mysql 2.0.8 +- seriously patch build.xml to make it compile on Linux boxes + with both JDK 1.2/1.3 and 1.1 +- added javadoc generation to build.xml +- changed manual to javadoc package + +* Tue Feb 06 2001 Henri Gomez +- mm.mysql 2.0.4 +- Fixes to getDecimal to fix decimal place wrong bug + +* Mon Jan 15 2001 Henri Gomez +- Initial release mm.mysql 2.0.3 +- detect jdbc-2.0 extension jar (javax.sql) and if present + also build MysqlDataSource and MysqlDataSourceFactory +- build with IBM JDK 1.3.0 (cx130-20001114) and jikes 1.12 +- build CLASSPATH=/usr/share/java/jdbc2_0-stdext.jar