MDEV-24167 fixup: srw_lock_debug for SUX_LOCK_GENERIC
srw_lock_debug::have_rd(), srw_lock_debug::have_wr():
For SUX_LOCK_GENERIC (no futex based synchronization primitives),
we cannot check if the underlying srw_lock is held by us.
Thanks to Dmitry Shulga for pointing out this build failure.
MDEV-30655 IMPORT TABLESPACE fails with column count or index count mismatch
Problem:
========
Currently import operation fails with schema mismatch when
cfg file has hidden fts document id and hidden fts document index.
Fix:
====
To fix this issue, simply add the fts doc id column,
indexes in table definition and try to import the table.
In case of success:
1) update the fts document id in sys columns.
2) update the number of columns in sys tables.
3) insert the new fts index entry in sys indexes table
and sys fields.
4) Reload the table with new table definition
MDEV-32898 Phantom rows caused by updates of PRIMARY KEY
Locking reads inside InnoDB traditionally always were using
the READ COMMITTED isolation level. We will introduce a new
session variable to enable a stricter check:
SET innodb_strict_isolation = ON;
In this mode, if an attempt to acquire a lock on a record that
does not exist in the current read view is made, an error
DB_RECORD_CHANGED (HA_ERR_RECORD_CHANGED, ER_CHECKREAD) will
be raised. This error will be treated in the same way as a deadlock:
the transaction will be rolled back.
lock_clust_rec_read_check_and_lock(): If the current transaction has
a read view where the record is not visible and innodb_strict_isolation=ON,
fail before trying to acquire the lock.
MDEV-33464 Crash when innodb_max_undo_log_size is set to innodb_page_size*4294967296
purge_sys_t::truncating_tablespace(): Clamp the
innodb_max_undo_log_size to the maximum number of pages
before converting the result into a 32-bit unsigned integer.
This fixes up commit f8c88d905b44bffe161158309e9acc25ad3691aa (MDEV-33213).
In later major versions, we would use 32-bit unsigned integer here
due to commit ca501ffb04246dcaa1f1d433d916d8436e30602e
and the code would crash also on 64-bit processors.