diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2017-03-09 15:58:33 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2017-03-09 15:58:33 +0200 |
commit | 15bdfeeba82134ed09ee3424db804fad1b613d8c (patch) | |
tree | 94fde9fcba31fa69848fbf115f14a30834bf1c4d /storage/innobase/include/trx0sys.ic | |
parent | 24cbc8dae3f94214a752c757fb82fc80faa1d864 (diff) | |
download | mariadb-git-15bdfeeba82134ed09ee3424db804fad1b613d8c.tar.gz |
Remove trx_sys_t::pending_purge_rseg_array.
In MySQL 5.7, there is some redundant code for supposedly handling
an upgrade from an earlier version of InnoDB.
An upgrade of InnoDB between major versions should include a
slow shutdown (innodb_fast_shutdown=0) of the previous version.
A comment in trx_lists_init_at_db_start() confused clean shutdown
and slow shutdown. A clean shutdown does not necessarily guarantee
that there are no active transactions. A slow shutdown guarantees
that.
Because there was no code to handle rollback of recovered transactions
that happened to use the rollback segment slots that MySQL 5.7.2
repurposed for temporary undo logs, the upgrade is not working in all
cases, and we may as well remove the code to handle purging.
trx_sys_t::pending_purge_rseg_array: Remove.
trx_undo_get_undo_rec_low(): Define as static. Remove the parameter
is_redo_rseg.
trx_undo_get_undo_rec(), trx_rseg_get_on_id(): Remove the parameter
is_redo_rseg.
trx_rseg_mem_free(): Remove the second parameter.
trx_sys_get_nth_rseg(): Replace with trx_rseg_get_on_id().
trx_rseg_schedule_pending_purge(): Remove.
Diffstat (limited to 'storage/innobase/include/trx0sys.ic')
-rw-r--r-- | storage/innobase/include/trx0sys.ic | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/storage/innobase/include/trx0sys.ic b/storage/innobase/include/trx0sys.ic index b07f487984c..f03535c53b3 100644 --- a/storage/innobase/include/trx0sys.ic +++ b/storage/innobase/include/trx0sys.ic @@ -62,31 +62,6 @@ trx_sys_hdr_page( && page_id.page_no() == TRX_SYS_PAGE_NO); } -/***************************************************************//** -Gets the pointer in the nth slot of the rseg array. -@return pointer to rseg object, NULL if slot not in use */ -UNIV_INLINE -trx_rseg_t* -trx_sys_get_nth_rseg( -/*=================*/ - trx_sys_t* sys, /*!< in: trx system */ - ulint n, /*!< in: index of slot */ - bool is_redo_rseg) /*!< in: true if redo rseg. */ -{ - ut_ad(n < TRX_SYS_N_RSEGS); - - /* If redo rseg is being requested and id falls in range of - non-redo rseg that is from slot-1....slot-srv_tmp_undo_logs then - server is being upgraded from pre-5.7.2. In such case return - rseg from pending_purge_rseg_array array. */ - if (is_redo_rseg && trx_sys_is_noredo_rseg_slot(n)) { - ut_ad(trx_sys->pending_purge_rseg_array[n] != NULL); - return(trx_sys->pending_purge_rseg_array[n]); - } - - return(sys->rseg_array[n]); -} - /**********************************************************************//** Gets a pointer to the transaction system header and x-latches its page. @return pointer to system header, page x-latched. */ |