Skip to content
  • Marko Mäkelä's avatar
    935ba09d
    Bug#16593427 ROLLBACK OF RECOVERED TRANSACTION CORRUPTS NON-ONLINE ADD INDEX · 935ba09d
    Marko Mäkelä authored
    Resurrect table IX locks for recovered transactions. This fixes a race
    condition between the rollback of a recovered transaction and creating
    a secondary index in a locked operation. This race condition could
    corrupt the secondary index that is being created.
    
    lock_table_ix_resurrect(), trx_resurrect_table_locks(): New functions.
    
    trx_undo_get_prev_rec_from_prev_page(), trx_undo_get_prev_rec(): Add a
    flag for specifying if the page should be X-latched or S-latched.
    
    lock_remove_recovered_trx_record_locks(): Remove also the table lock
    of a recovered transaction.
    
    mtr_memo_release(): Return a Boolean, indicating if the object was removed.
    
    dict_table_open_on_id(): Replace the Boolean parameter try_drop with a
    new enum dict_table_op_t, with a third value
    DICT_TABLE_OP_LOAD_TABLESPACE to silently load a tablespace when it is
    missing. This is needed to suppress a warning in
    trx_resurrect_table_locks() during the innodb.innodb_bug59641 test.
    
    dict_err_ignore_t: Add the flag DICT_ERR_IGNORE_LOAD, to silently load
    the tablespace when it has not been loaded yet, and to skip loading
    the definitions of incomplete secondary indexes.
    
    dict_check_tablespaces_and_store_max_id(): Replace the Boolean
    parameter in_crash_recovery with a new enum dict_check_t, with a third
    value DICT_CHECK_SOME_LOADED to silently skip tablespaces that were
    already loaded by trx_resurrect_table_locks() during crash recovery.
    This is needed to suppress a warning in trx_resurrect_table_locks()
    during the innodb.innodb_bug59641 test.
    
    rb#2283 approved by Jimmy Yang
    935ba09d
    Bug#16593427 ROLLBACK OF RECOVERED TRANSACTION CORRUPTS NON-ONLINE ADD INDEX
    Marko Mäkelä authored
    Resurrect table IX locks for recovered transactions. This fixes a race
    condition between the rollback of a recovered transaction and creating
    a secondary index in a locked operation. This race condition could
    corrupt the secondary index that is being created.
    
    lock_table_ix_resurrect(), trx_resurrect_table_locks(): New functions.
    
    trx_undo_get_prev_rec_from_prev_page(), trx_undo_get_prev_rec(): Add a
    flag for specifying if the page should be X-latched or S-latched.
    
    lock_remove_recovered_trx_record_locks(): Remove also the table lock
    of a recovered transaction.
    
    mtr_memo_release(): Return a Boolean, indicating if the object was removed.
    
    dict_table_open_on_id(): Replace the Boolean parameter try_drop with a
    new enum dict_table_op_t, with a third value
    DICT_TABLE_OP_LOAD_TABLESPACE to silently load a tablespace when it is
    missing. This is needed to suppress a warning in
    trx_resurrect_table_locks() during the innodb.innodb_bug59641 test.
    
    dict_err_ignore_t: Add the flag DICT_ERR_IGNORE_LOAD, to silently load
    the tablespace when it has not been loaded yet, and to skip loading
    the definitions of incomplete secondary indexes.
    
    dict_check_tablespaces_and_store_max_id(): Replace the Boolean
    parameter in_crash_recovery with a new enum dict_check_t, with a third
    value DICT_CHECK_SOME_LOADED to silently skip tablespaces that were
    already loaded by trx_resurrect_table_locks() during crash recovery.
    This is needed to suppress a warning in trx_resurrect_table_locks()
    during the innodb.innodb_bug59641 test.
    
    rb#2283 approved by Jimmy Yang
Loading