Based on the performance testing that was conducted in MDEV-17492,
the InnoDB adaptive hash index could only help performance in specific,
almost-read-only workloads. It could slow down all kinds of workloads
(especially DROP TABLE, TRUNCATE TABLE, ALTER TABLE, or DROP INDEX
operations), and it can become corrupted, causing crashes
and possibly data corruption. Furthermore, the adaptive hash index
consumes space from the InnoDB buffer pool, which could hurt performance
when the working set would almost fit in the buffer pool.
Given all this, it is best to remove innodb_adaptive_hash_index.
For now, we will change the default value of the build option
WITH_INNODB_AHI to OFF and adjust tests.
The test rpl.rpl_failed_drop_tbl_binlog depends on DROP TABLE being
able to be interrupted while it is dropping pages from the
adaptive hash index. It will be skipped from now on by default,
but it will be tested for builds WITH_INNODB_AHI=ON.
MDEV-20525 rocksdb debug compilation fails on Windows due to unresolved my_assert variable
MYSQL_PLUGIN_IMPORT did not work correctly for the Rocksdb helper library
rocksdb_aux_lib, because that library was not compiled with
-DMYSQL_DYNAMIC_PLUGIN.
Fix dbug such that it does not depend on exported data, only on functions
(which do not need MYSQL_PLUGIN_IMPORT decoration)
Use a "getter" function _db_my_assert() instead of DLL-exported variable.
trx_t::is_recovered: Revert most of the changes that were made by the
merge of MDEV-15326 from 10.2. The trx_sys.rw_trx_hash and the recovery
of transactions at startup is quite different in 10.3.
trx_free_at_shutdown(): Avoid excessive mutex protection. Reading fields
that can only be modified by the current thread (owning the transaction)
can be done outside mutex.
trx_t::commit_state(): Restore a tighter assertion.
trx_rollback_recovered(): Clarify why there is no potential race condition
with other transactions.
lock_trx_release_locks(): Merge with trx_t::release_locks(),
and avoid holding lock_sys.mutex unnecessarily long.
rw_trx_hash_t::find(): Remove redundant code, and avoid starving the
committer by checking trx_t::state before trx_t::reference().