• Libing Song's avatar
    Bug#58546 test rpl_packet timeout failure sporadically on PB · 84e4bdbf
    Libing Song authored
                
    rpl_packet got a timeout failure sporadically on PB when stopping
    slave. The real reason of this bug is that STOP SLAVE stopped
    IO thread first and then stopped SQL thread. It was
    possible that IO thread stopped after replicating part of a
    transaction which SQL thread was executing. SQL thread would
    be hung if the transaction could not be rolled back safely.
                
    After this patch, STOP SLAVE will stop SQL thread first and then stop IO
    thread, which guarantees that IO thread will fetch the reset of the
    events of the transaction that SQL thread is executing, so that SQL
    thread can finish the transaction if it cannot be rolled back safely.
                
    Added below auxiliary files to make the test code neater.
    restart_slave_sql.inc
    rpl_connection_master.inc
    rpl_connection_slave.inc
    rpl_connection_slave1.inc
    84e4bdbf
rpl_connection_slave1.inc 68 Bytes