maria:bb-10.5-sachin

Last commit made on 2021-04-01
Get this branch:
git clone -b bb-10.5-sachin https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.5-sachin
Repository:
lp:maria

Recent commits

0ff367a... by Sachin Setiya

MDEV-22953 main.flush_read_lock failed in buildbot with XAER_NOTA: Unknown XID

Issue:- Since there is no waiting for the actual disconnection of the con_tmp
(which does XA prepare of test1), We can have a issue when test1 is not
prepared and we are calling rollback on test1 , giving XAER_NOTA: Unknown XID
error

Solution:- Wait for the complete disconnection of con_tmp

76d2846... by Krunal Bauskar <email address hidden>

MDEV-24630: MY_RELAX_CPU assembly instruction upgrade/research for
            memory barrier on ARM

As suggested in the said JIRA ticket based on the contribution done by
the community (in an attempt to optimize the spin-loop) the said approach
was evaluated against MariaDB Server 10.5 and found to help improve
throughput in the range of 2-5%.

Note: 10.6 timing graph and model are different as home-brew
mutexes are replaced with pthread mutexes. Said patch has mixed
impact on 10.6 so not recommended for 10.6.

8c2e325... by Marko Mäkelä

MDEV-24302 follow-up: RESET MASTER hangs

As pointed out by Andrei Elkin, the previous fix did not fix one
race condition that may have caused the observed hang.

innodb_log_flush_request(): If we are enqueueing the very first
request at the same time the log write is being completed,
we must ensure that a near-concurrent call to log_flush_notify()
will not result in a missed notification. We guarantee this by
release-acquire operations on log_requests.start and
log_sys.flushed_to_disk_lsn.

log_flush_notify_and_unlock(): Cleanup: Always release the mutex.

log_sys_t::get_flushed_lsn(): Use acquire memory order.

log_sys_t::set_flushed_lsn(): Use release memory order.

log_sys_t::set_lsn(): Use release memory order.

log_sys_t::get_lsn(): Use relaxed memory order by default, and
allow the caller to specify acquire memory order explicitly.
Whenever the log_sys.mutex is being held or when log writes are
prohibited during startup, we can use a relaxed load. Likewise,
in some assertions where reading a stale value of log_sys.lsn
should not matter, we can use a relaxed load.

This will cause some additional instructions to be emitted on
architectures that do not implement Total Store Ordering (TSO),
such as POWER, ARM, and RISC-V Weak Memory Ordering (RVWMO).

0df74a0... by Otto Kekäläinen

Deb: Fix failing Salsa-CI by syncing fixes from downstream to upstream

Fixes jobs:
- mysql-8.0 Sid to mariadb-10.5 upgrade
- mariadb.org-10.5 to mariadb-10.5 upgrade

Downstream source:
https://salsa.debian.org/mariadb-team/mariadb-10.5/-/commit/8db0e530872fea258e87533349fa83568eeed02d

5a4daa9... by Otto Kekäläinen

Deb: Add Breaks/Replaces

Fix the following Breaks/Replaces errors detected by Salsa-CI:

  [ERROR] mariadb-server-10.5 conflicts with mysql-client-core-8.0 files:
    {'/usr/bin/myisam_ftdump', '/usr/share/man/man1/myisam_ftdump.1.gz'}
  [ERROR] mariadb-server-10.5 conflicts with mysql-server-core-8.0 files:
    {'/usr/share/man/man1/mysqlbinlog.1.gz',
     '/usr/share/man/man1/myisamlog.1.gz',
     '/usr/share/man/man1/mysql_tzinfo_to_sql.1.gz',
     '/usr/share/man/man1/perror.1.gz',
     '/usr/share/man/man1/myisampack.1.gz',
     '/usr/bin/mysqld_safe', '/usr/share/man/man1/myisamchk.1.gz',
     '/usr/bin/myisamchk', '/usr/bin/mysql_secure_installation',
     '/usr/bin/mysqld_multi', '/usr/bin/mysql_tzinfo_to_sql',
     '/usr/bin/perror', '/usr/share/man/man1/mysqld_multi.1.gz',
     '/usr/bin/myisampack', '/usr/share/man/man1/mysqld_safe.1.gz',
     '/usr/bin/myisamlog',
     '/usr/share/man/man1/mysql_secure_installation.1.gz',
     '/usr/bin/mysqlbinlog'}
  [ERROR] mariadb-test conflicts with mysql-server-core-8.0 files:
    {'/usr/lib/mysql/plugin/adt_null.so',
     '/usr/lib/mysql/plugin/mypluglib.so'}

Upstreamed from Debian packaging commits:
https://salsa.debian.org/mariadb-team/mariadb-10.5/-/commit/9b6a67b53c2adf1bb5497d8649eb079767419835
https://salsa.debian.org/mariadb-team/mariadb-10.5/-/commit/f6d5545a0241de2cda81c878a157517b83378c04

Also:
- remove excess '<< ${source:Version}' on mysql-client-* and mysql-server-*
- move more packages to Conflicts as it is semantically more correct than
  having those packages in Replaces

ab3777a... by Otto Kekäläinen

Revert "MDEV-23342 MariaDB cannot be installed over MySQL 5.7.30 on Bionic anymore"

This reverts commit 44885273f2cffd3b269fb18b0c369b343d9de512.

Reverting this commit is necessary to fix missing-breaks errors in the
Debian packaging. The original fix was also not entirely necessary as a
fix to the original problem.

Partially also reverts commit e7c7f5c1bbac9a081775a1dc50088ae1e32e2a8d where this
unsorted debian/control file was sorted.

e8b7fce... by Marko Mäkelä

MDEV-24302: RESET MASTER hangs

Starting with MariaDB 10.5, roughly after MDEV-23855 was fixed,
we are observing sporadic hangs during the execution of the
RESET MASTER statement. We are hoping to fix the hangs with these
changes, but due to the rather infrequent occurrence of the hangs
and our inability to reliably reproduce the hangs, we cannot be
sure of this.

What we do know is that innodb_force_recovery=2 (or a larger setting)
will prevent srv_master_callback (the former srv_master_thread) from
running. In that mode, periodic log flushes would never occur and
RESET MASTER could hang indefinitely. That is demonstrated by the new
test case that was developed by Andrei Elkin. We fix this case by
implementing a special case for it.

This also includes some code cleanup and renames of misleadingly
named code. The interface has nothing to do with log checkpoints in
the storage engine; it is only about requesting log writes to be
persistent.

handlerton::commit_checkpoint_request,
commit_checkpoint_notify_ha(): Remove the unused parameter hton.

log_requests.start: Replaces pending_checkpoint_list.
log_requests.end: Replaces pending_checkpoint_list_end.
log_requests.mutex: Replaces pending_checkpoint_mutex.

log_flush_notify_and_unlock(), log_flush_notify(): Replaces
innobase_mysql_log_notify(). The new implementation should be
functionally equivalent to the old one.

innodb_log_flush_request(): Replaces innobase_checkpoint_request().
Implement a fast path for common cases, and reduce the mutex hold time.
POSSIBLE FIX OF THE HANG: We will invoke commit_checkpoint_notify_ha()
for the current request if it is already satisfied, as well as invoke
log_flush_notify_and_unlock() for any satisfied requests.

log_write(): Invoke log_flush_notify() when the write is already durable.
This was missing WITH_PMEM when the log is in persistent memory.

Reviewed by: Vladislav Vaintroub

8e2d69f... by Monty <email address hidden>

Fixed access to undefined memory

alloc_query() is examined the content of it's argument, which was
uninitalized.
Fixed by storing stmt_id in llbuf, according to code comments.

80459bc... by Marko Mäkelä

Merge 10.4 into 10.5

7ae37ff... by Marko Mäkelä

Merge 10.3 into 10.4