Search in sources :

Example 1 with CommunicationsException

use of com.mysql.cj.jdbc.exceptions.CommunicationsException in project JavaSegundasQuintas by ecteruel.

the class StatementRegressionTest method testBug74998.

/**
 * Tests fix for BUG#74998 - readRemainingMultiPackets not computed correctly for rows larger than 16 MB.
 *
 * This bug is observed only when a multipacket uses packets 127 and 128. It happens due to the transition from positive to negative values in a signed byte
 * numeric value (127 + 1 == -128).
 *
 * The test case forces a multipacket to use packets 127, 128 and 129, where packet 129 is 0-length, this being another boundary case.
 * Query (*1) generates the following MySQL protocol packets from the server:
 * - Packets 1 to 4 contain protocol control data and results metadata info. (*2)
 * - Packets 5 to 126 contain each row "X". (*3)
 * - Packets 127 to 129 contain row "Y..." as a multipacket (size("Y...") = 32*1024*1024-15 requires 3 packets). (*4)
 * - Packet 130 contains row "Z". (*5)
 *
 * @throws Exception
 */
@Test
public void testBug74998() throws Exception {
    int maxAllowedPacketAtServer = Integer.parseInt(((JdbcConnection) this.conn).getSession().getServerSession().getServerVariable("max_allowed_packet"));
    int maxAllowedPacketMinimumForTest = 32 * 1024 * 1024;
    boolean changeMaxAllowedPacket = maxAllowedPacketAtServer < maxAllowedPacketMinimumForTest;
    if (!versionMeetsMinimum(5, 7)) {
        this.rs = this.stmt.executeQuery("SHOW VARIABLES LIKE 'innodb_log_file_size'");
        this.rs.next();
        long defaultInnodbLogFileSize = this.rs.getInt(2);
        assumeFalse(defaultInnodbLogFileSize < maxAllowedPacketMinimumForTest * 10, "This test requires innodb_log_file_size > " + (maxAllowedPacketMinimumForTest * 10));
    }
    // (*2)
    createTable("testBug74998", "(id INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY, data LONGBLOB)");
    Connection con1 = null;
    try {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketMinimumForTest);
        }
        StringBuilder query = new StringBuilder("INSERT INTO testBug74998 (data) VALUES ('X')");
        for (int i = 0; i < 121; i++) {
            query.append(",('X')");
        }
        Properties props = new Properties();
        props.setProperty(PropertyKey.useSSL.getKeyName(), "false");
        props.setProperty(PropertyKey.allowPublicKeyRetrieval.getKeyName(), "true");
        con1 = getConnectionWithProps(props);
        Statement st = con1.createStatement();
        // (*3)
        assertEquals(122, st.executeUpdate(query.toString()));
        // 32MB - 15Bytes causes an empty packet at the end of the multipacket sequence
        int lengthOfRowForMultiPacket = maxAllowedPacketMinimumForTest - 15;
        // (*4)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES (REPEAT('Y', " + lengthOfRowForMultiPacket + "))");
        // (*5)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES ('Z')");
        try {
            // (*1)
            this.rs = st.executeQuery("SELECT id, data FROM testBug74998 ORDER BY id");
        } catch (CJCommunicationsException | CommunicationsException e) {
            assertFalse(e.getCause() instanceof IOException && "Packets received out of order".compareTo(e.getCause().getMessage()) == 0, "Failed to correctly fetch all data from communications layer due to wrong processing of muli-packet number.");
        }
        // safety check
        for (int i = 1; i <= 122; i++) {
            assertTrue(this.rs.next());
            assertEquals(i, this.rs.getInt(1));
            assertEquals("X", this.rs.getString(2));
        }
        assertTrue(this.rs.next());
        assertEquals(123, this.rs.getInt(1));
        assertEquals("YYYYY", this.rs.getString(2).substring(0, 5));
        assertEquals("YYYYY", this.rs.getString(2).substring(lengthOfRowForMultiPacket - 5));
        assertTrue(this.rs.next());
        assertEquals(124, this.rs.getInt(1));
        assertEquals("Z", this.rs.getString(2));
        assertFalse(this.rs.next());
    } finally {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketAtServer);
        }
        if (con1 != null) {
            con1.close();
        }
    }
}
Also used : JdbcStatement(com.mysql.cj.jdbc.JdbcStatement) JdbcPreparedStatement(com.mysql.cj.jdbc.JdbcPreparedStatement) PreparedStatement(java.sql.PreparedStatement) Statement(java.sql.Statement) CallableStatement(java.sql.CallableStatement) ServerPreparedStatement(com.mysql.cj.jdbc.ServerPreparedStatement) ClientPreparedStatement(com.mysql.cj.jdbc.ClientPreparedStatement) ReplicationConnection(com.mysql.cj.jdbc.ha.ReplicationConnection) Connection(java.sql.Connection) XAConnection(javax.sql.XAConnection) JdbcConnection(com.mysql.cj.jdbc.JdbcConnection) MysqlConnection(com.mysql.cj.MysqlConnection) IOException(java.io.IOException) Properties(java.util.Properties) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) StatementsTest(testsuite.simple.StatementsTest) Test(org.junit.jupiter.api.Test)

Example 2 with CommunicationsException

use of com.mysql.cj.jdbc.exceptions.CommunicationsException in project ABC by RuiPinto96274.

the class StatementRegressionTest method testBug74998.

/**
 * Tests fix for BUG#74998 - readRemainingMultiPackets not computed correctly for rows larger than 16 MB.
 *
 * This bug is observed only when a multipacket uses packets 127 and 128. It happens due to the transition from positive to negative values in a signed byte
 * numeric value (127 + 1 == -128).
 *
 * The test case forces a multipacket to use packets 127, 128 and 129, where packet 129 is 0-length, this being another boundary case.
 * Query (*1) generates the following MySQL protocol packets from the server:
 * - Packets 1 to 4 contain protocol control data and results metadata info. (*2)
 * - Packets 5 to 126 contain each row "X". (*3)
 * - Packets 127 to 129 contain row "Y..." as a multipacket (size("Y...") = 32*1024*1024-15 requires 3 packets). (*4)
 * - Packet 130 contains row "Z". (*5)
 *
 * @throws Exception
 */
@Test
public void testBug74998() throws Exception {
    int maxAllowedPacketAtServer = Integer.parseInt(((JdbcConnection) this.conn).getSession().getServerSession().getServerVariable("max_allowed_packet"));
    int maxAllowedPacketMinimumForTest = 32 * 1024 * 1024;
    boolean changeMaxAllowedPacket = maxAllowedPacketAtServer < maxAllowedPacketMinimumForTest;
    if (!versionMeetsMinimum(5, 7)) {
        this.rs = this.stmt.executeQuery("SHOW VARIABLES LIKE 'innodb_log_file_size'");
        this.rs.next();
        long defaultInnodbLogFileSize = this.rs.getInt(2);
        assumeFalse(defaultInnodbLogFileSize < maxAllowedPacketMinimumForTest * 10, "This test requires innodb_log_file_size > " + (maxAllowedPacketMinimumForTest * 10));
    }
    // (*2)
    createTable("testBug74998", "(id INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY, data LONGBLOB)");
    Connection con1 = null;
    try {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketMinimumForTest);
        }
        StringBuilder query = new StringBuilder("INSERT INTO testBug74998 (data) VALUES ('X')");
        for (int i = 0; i < 121; i++) {
            query.append(",('X')");
        }
        Properties props = new Properties();
        props.setProperty(PropertyKey.useSSL.getKeyName(), "false");
        props.setProperty(PropertyKey.allowPublicKeyRetrieval.getKeyName(), "true");
        con1 = getConnectionWithProps(props);
        Statement st = con1.createStatement();
        // (*3)
        assertEquals(122, st.executeUpdate(query.toString()));
        // 32MB - 15Bytes causes an empty packet at the end of the multipacket sequence
        int lengthOfRowForMultiPacket = maxAllowedPacketMinimumForTest - 15;
        // (*4)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES (REPEAT('Y', " + lengthOfRowForMultiPacket + "))");
        // (*5)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES ('Z')");
        try {
            // (*1)
            this.rs = st.executeQuery("SELECT id, data FROM testBug74998 ORDER BY id");
        } catch (CJCommunicationsException | CommunicationsException e) {
            assertFalse(e.getCause() instanceof IOException && "Packets received out of order".compareTo(e.getCause().getMessage()) == 0, "Failed to correctly fetch all data from communications layer due to wrong processing of muli-packet number.");
        }
        // safety check
        for (int i = 1; i <= 122; i++) {
            assertTrue(this.rs.next());
            assertEquals(i, this.rs.getInt(1));
            assertEquals("X", this.rs.getString(2));
        }
        assertTrue(this.rs.next());
        assertEquals(123, this.rs.getInt(1));
        assertEquals("YYYYY", this.rs.getString(2).substring(0, 5));
        assertEquals("YYYYY", this.rs.getString(2).substring(lengthOfRowForMultiPacket - 5));
        assertTrue(this.rs.next());
        assertEquals(124, this.rs.getInt(1));
        assertEquals("Z", this.rs.getString(2));
        assertFalse(this.rs.next());
    } finally {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketAtServer);
        }
        if (con1 != null) {
            con1.close();
        }
    }
}
Also used : JdbcStatement(com.mysql.cj.jdbc.JdbcStatement) JdbcPreparedStatement(com.mysql.cj.jdbc.JdbcPreparedStatement) PreparedStatement(java.sql.PreparedStatement) Statement(java.sql.Statement) CallableStatement(java.sql.CallableStatement) ServerPreparedStatement(com.mysql.cj.jdbc.ServerPreparedStatement) ClientPreparedStatement(com.mysql.cj.jdbc.ClientPreparedStatement) ReplicationConnection(com.mysql.cj.jdbc.ha.ReplicationConnection) Connection(java.sql.Connection) XAConnection(javax.sql.XAConnection) JdbcConnection(com.mysql.cj.jdbc.JdbcConnection) MysqlConnection(com.mysql.cj.MysqlConnection) IOException(java.io.IOException) Properties(java.util.Properties) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) StatementsTest(testsuite.simple.StatementsTest) Test(org.junit.jupiter.api.Test)

Example 3 with CommunicationsException

use of com.mysql.cj.jdbc.exceptions.CommunicationsException in project aws-mysql-jdbc by awslabs.

the class ResultSetRegressionTest method testBug75309.

/**
 * Tests fix for BUG#75309 - mysql connector/J driver in streaming mode will in the blocking state.
 *
 * @throws Exception
 */
@Test
public void testBug75309() throws Exception {
    Properties props = new Properties();
    props.setProperty(PropertyKey.sslMode.getKeyName(), SslMode.DISABLED.name());
    props.setProperty(PropertyKey.allowPublicKeyRetrieval.getKeyName(), "true");
    props.setProperty(PropertyKey.socketTimeout.getKeyName(), "1000");
    Connection testConn = getConnectionWithProps(props);
    Statement testStmt = testConn.createStatement();
    // turn on streaming results.
    testStmt.setFetchSize(Integer.MIN_VALUE);
    final ResultSet testRs1 = testStmt.executeQuery("SELECT 1 + 18446744073709551615");
    assertThrows(SQLException.class, "Data truncation: BIGINT UNSIGNED value is out of range in '\\(1 \\+ 18446744073709551615\\)'", new Callable<Void>() {

        public Void call() throws Exception {
            testRs1.next();
            return null;
        }
    });
    try {
        testRs1.close();
    } catch (CJCommunicationsException | CommunicationsException ex) {
        fail("ResultSet.close() locked while trying to read remaining, nonexistent, streamed data.");
    }
    try {
        ResultSet testRs2 = testStmt.executeQuery("SELECT 1");
        assertTrue(testRs2.next());
        assertEquals(1, testRs2.getInt(1));
        testRs2.close();
    } catch (SQLException ex) {
        if (ex.getMessage().startsWith("Streaming result set")) {
            fail("There is a Streaming result set still active. No other statements can be issued on this connection.");
        } else {
            ex.printStackTrace();
            fail(ex.getMessage());
        }
    }
    testStmt.close();
    testConn.close();
}
Also used : SQLException(java.sql.SQLException) PreparedStatement(java.sql.PreparedStatement) CallableStatement(java.sql.CallableStatement) ServerPreparedStatement(com.mysql.cj.jdbc.ServerPreparedStatement) Statement(java.sql.Statement) Connection(java.sql.Connection) JdbcConnection(com.mysql.cj.jdbc.JdbcConnection) MysqlConnection(com.mysql.cj.MysqlConnection) ResultSet(java.sql.ResultSet) UpdatableResultSet(com.mysql.cj.jdbc.result.UpdatableResultSet) Properties(java.util.Properties) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) InvocationTargetException(java.lang.reflect.InvocationTargetException) SQLException(java.sql.SQLException) SQLDataException(java.sql.SQLDataException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) Test(org.junit.jupiter.api.Test)

Example 4 with CommunicationsException

use of com.mysql.cj.jdbc.exceptions.CommunicationsException in project aws-mysql-jdbc by awslabs.

the class ExceptionsTest method testConstructors.

@Test
public void testConstructors() {
    new CommunicationsException(TEST_MESSAGE, new Throwable());
    new CommunicationsException((JdbcConnection) this.conn, new PacketSentTimeHolder() {
    }, new PacketReceivedTimeHolder() {
    }, new Exception());
    new ConnectionFeatureNotAvailableException(TEST_MESSAGE, new Throwable());
    new ConnectionFeatureNotAvailableException((JdbcConnection) this.conn, new PacketSentTimeHolder() {
    }, new Exception());
    new MysqlDataTruncation(TEST_MESSAGE, 0, false, false, 0, 0, 0);
    new MySQLQueryInterruptedException();
    new MySQLQueryInterruptedException(TEST_MESSAGE);
    new MySQLQueryInterruptedException(TEST_MESSAGE, TEST_SQL_STATE);
    new MySQLQueryInterruptedException(TEST_MESSAGE, TEST_SQL_STATE, 0);
    new MySQLStatementCancelledException();
    new MySQLStatementCancelledException(TEST_MESSAGE);
    new MySQLStatementCancelledException(TEST_MESSAGE, TEST_SQL_STATE);
    new MySQLStatementCancelledException(TEST_MESSAGE, TEST_SQL_STATE, 0);
    new MySQLTimeoutException();
    new MySQLTimeoutException(TEST_MESSAGE);
    new MySQLTimeoutException(TEST_MESSAGE, TEST_SQL_STATE);
    new MySQLTimeoutException(TEST_MESSAGE, TEST_SQL_STATE, 0);
    new MySQLTransactionRollbackException();
    new MySQLTransactionRollbackException(TEST_MESSAGE);
    new MySQLTransactionRollbackException(TEST_MESSAGE, TEST_SQL_STATE);
    new MySQLTransactionRollbackException(TEST_MESSAGE, TEST_SQL_STATE, 0);
    new NotUpdatable(TEST_MESSAGE);
    new OperationNotSupportedException();
    new OperationNotSupportedException(TEST_MESSAGE);
    new PacketTooBigException(TEST_MESSAGE);
    new PacketTooBigException(0, 100);
    new SQLError();
}
Also used : OperationNotSupportedException(com.mysql.cj.jdbc.exceptions.OperationNotSupportedException) PacketTooBigException(com.mysql.cj.jdbc.exceptions.PacketTooBigException) ConnectionFeatureNotAvailableException(com.mysql.cj.jdbc.exceptions.ConnectionFeatureNotAvailableException) MysqlDataTruncation(com.mysql.cj.jdbc.exceptions.MysqlDataTruncation) MySQLTransactionRollbackException(com.mysql.cj.jdbc.exceptions.MySQLTransactionRollbackException) PacketReceivedTimeHolder(com.mysql.cj.protocol.PacketReceivedTimeHolder) MySQLStatementCancelledException(com.mysql.cj.jdbc.exceptions.MySQLStatementCancelledException) MySQLQueryInterruptedException(com.mysql.cj.jdbc.exceptions.MySQLQueryInterruptedException) OperationNotSupportedException(com.mysql.cj.jdbc.exceptions.OperationNotSupportedException) ConnectionFeatureNotAvailableException(com.mysql.cj.jdbc.exceptions.ConnectionFeatureNotAvailableException) MySQLTransactionRollbackException(com.mysql.cj.jdbc.exceptions.MySQLTransactionRollbackException) SQLException(java.sql.SQLException) PacketTooBigException(com.mysql.cj.jdbc.exceptions.PacketTooBigException) MySQLTimeoutException(com.mysql.cj.jdbc.exceptions.MySQLTimeoutException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) NotUpdatable(com.mysql.cj.jdbc.exceptions.NotUpdatable) MySQLTimeoutException(com.mysql.cj.jdbc.exceptions.MySQLTimeoutException) SQLError(com.mysql.cj.jdbc.exceptions.SQLError) PacketSentTimeHolder(com.mysql.cj.protocol.PacketSentTimeHolder) MySQLStatementCancelledException(com.mysql.cj.jdbc.exceptions.MySQLStatementCancelledException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) MySQLQueryInterruptedException(com.mysql.cj.jdbc.exceptions.MySQLQueryInterruptedException) Test(org.junit.jupiter.api.Test)

Example 5 with CommunicationsException

use of com.mysql.cj.jdbc.exceptions.CommunicationsException in project aws-mysql-jdbc by awslabs.

the class StatementRegressionTest method testBug74998.

/**
 * Tests fix for BUG#74998 - readRemainingMultiPackets not computed correctly for rows larger than 16 MB.
 *
 * This bug is observed only when a multipacket uses packets 127 and 128. It happens due to the transition from positive to negative values in a signed byte
 * numeric value (127 + 1 == -128).
 *
 * The test case forces a multipacket to use packets 127, 128 and 129, where packet 129 is 0-length, this being another boundary case.
 * Query (*1) generates the following MySQL protocol packets from the server:
 * - Packets 1 to 4 contain protocol control data and results metadata info. (*2)
 * - Packets 5 to 126 contain each row "X". (*3)
 * - Packets 127 to 129 contain row "Y..." as a multipacket (size("Y...") = 32*1024*1024-15 requires 3 packets). (*4)
 * - Packet 130 contains row "Z". (*5)
 *
 * @throws Exception
 */
@Test
public void testBug74998() throws Exception {
    int maxAllowedPacketAtServer = Integer.parseInt(((JdbcConnection) this.conn).getSession().getServerSession().getServerVariable("max_allowed_packet"));
    int maxAllowedPacketMinimumForTest = 32 * 1024 * 1024;
    boolean changeMaxAllowedPacket = maxAllowedPacketAtServer < maxAllowedPacketMinimumForTest;
    if (!versionMeetsMinimum(5, 7)) {
        this.rs = this.stmt.executeQuery("SHOW VARIABLES LIKE 'innodb_log_file_size'");
        this.rs.next();
        long defaultInnodbLogFileSize = this.rs.getInt(2);
        assumeFalse(defaultInnodbLogFileSize < maxAllowedPacketMinimumForTest * 10, "This test requires innodb_log_file_size > " + (maxAllowedPacketMinimumForTest * 10));
    }
    // (*2)
    createTable("testBug74998", "(id INTEGER NOT NULL AUTO_INCREMENT PRIMARY KEY, data LONGBLOB)");
    Connection con1 = null;
    try {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketMinimumForTest);
        }
        StringBuilder query = new StringBuilder("INSERT INTO testBug74998 (data) VALUES ('X')");
        for (int i = 0; i < 121; i++) {
            query.append(",('X')");
        }
        Properties props = new Properties();
        props.setProperty(PropertyKey.sslMode.getKeyName(), SslMode.DISABLED.name());
        props.setProperty(PropertyKey.allowPublicKeyRetrieval.getKeyName(), "true");
        con1 = getConnectionWithProps(props);
        Statement st = con1.createStatement();
        // (*3)
        assertEquals(122, st.executeUpdate(query.toString()));
        // 32MB - 15Bytes causes an empty packet at the end of the multipacket sequence
        int lengthOfRowForMultiPacket = maxAllowedPacketMinimumForTest - 15;
        // (*4)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES (REPEAT('Y', " + lengthOfRowForMultiPacket + "))");
        // (*5)
        st.executeUpdate("INSERT INTO testBug74998 (data) VALUES ('Z')");
        try {
            // (*1)
            this.rs = st.executeQuery("SELECT id, data FROM testBug74998 ORDER BY id");
        } catch (CJCommunicationsException | CommunicationsException e) {
            assertFalse(e.getCause() instanceof IOException && "Packets received out of order".compareTo(e.getCause().getMessage()) == 0, "Failed to correctly fetch all data from communications layer due to wrong processing of muli-packet number.");
        }
        // safety check
        for (int i = 1; i <= 122; i++) {
            assertTrue(this.rs.next());
            assertEquals(i, this.rs.getInt(1));
            assertEquals("X", this.rs.getString(2));
        }
        assertTrue(this.rs.next());
        assertEquals(123, this.rs.getInt(1));
        assertEquals("YYYYY", this.rs.getString(2).substring(0, 5));
        assertEquals("YYYYY", this.rs.getString(2).substring(lengthOfRowForMultiPacket - 5));
        assertTrue(this.rs.next());
        assertEquals(124, this.rs.getInt(1));
        assertEquals("Z", this.rs.getString(2));
        assertFalse(this.rs.next());
    } finally {
        if (changeMaxAllowedPacket) {
            this.stmt.executeUpdate("SET GLOBAL max_allowed_packet=" + maxAllowedPacketAtServer);
        }
        if (con1 != null) {
            con1.close();
        }
    }
}
Also used : JdbcStatement(com.mysql.cj.jdbc.JdbcStatement) JdbcPreparedStatement(com.mysql.cj.jdbc.JdbcPreparedStatement) PreparedStatement(java.sql.PreparedStatement) Statement(java.sql.Statement) CallableStatement(java.sql.CallableStatement) ServerPreparedStatement(com.mysql.cj.jdbc.ServerPreparedStatement) ClientPreparedStatement(com.mysql.cj.jdbc.ClientPreparedStatement) ReplicationConnection(com.mysql.cj.jdbc.ha.ReplicationConnection) Connection(java.sql.Connection) XAConnection(javax.sql.XAConnection) JdbcConnection(com.mysql.cj.jdbc.JdbcConnection) MysqlConnection(com.mysql.cj.MysqlConnection) IOException(java.io.IOException) Properties(java.util.Properties) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) CommunicationsException(com.mysql.cj.jdbc.exceptions.CommunicationsException) CJCommunicationsException(com.mysql.cj.exceptions.CJCommunicationsException) StatementsTest(testsuite.simple.StatementsTest) Test(org.junit.jupiter.api.Test)

Aggregations

CommunicationsException (com.mysql.cj.jdbc.exceptions.CommunicationsException)10 Test (org.junit.jupiter.api.Test)9 CJCommunicationsException (com.mysql.cj.exceptions.CJCommunicationsException)7 SQLException (java.sql.SQLException)7 MysqlConnection (com.mysql.cj.MysqlConnection)6 JdbcConnection (com.mysql.cj.jdbc.JdbcConnection)6 ServerPreparedStatement (com.mysql.cj.jdbc.ServerPreparedStatement)6 CallableStatement (java.sql.CallableStatement)6 Connection (java.sql.Connection)6 PreparedStatement (java.sql.PreparedStatement)6 Statement (java.sql.Statement)6 Properties (java.util.Properties)6 IOException (java.io.IOException)4 ClientPreparedStatement (com.mysql.cj.jdbc.ClientPreparedStatement)3 JdbcPreparedStatement (com.mysql.cj.jdbc.JdbcPreparedStatement)3 JdbcStatement (com.mysql.cj.jdbc.JdbcStatement)3 ConnectionFeatureNotAvailableException (com.mysql.cj.jdbc.exceptions.ConnectionFeatureNotAvailableException)3 MySQLQueryInterruptedException (com.mysql.cj.jdbc.exceptions.MySQLQueryInterruptedException)3 MySQLStatementCancelledException (com.mysql.cj.jdbc.exceptions.MySQLStatementCancelledException)3 MySQLTimeoutException (com.mysql.cj.jdbc.exceptions.MySQLTimeoutException)3