maria:bb-10.4-MDEV-21007

Last commit made on 2022-12-14
Get this branch:
git clone -b bb-10.4-MDEV-21007 https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.4-MDEV-21007
Repository:
lp:maria

Recent commits

c758eda... by Yuchen Pei

MDEV-21007 Do not assert auto_increment_value unless all parts open

Commit 6dce6aecebe6ef78a14cb5c5c5daa8a355551e40 breaks out of a loop
in ha_partition::info when some partitions aren't opened, in which
case auto_increment_value assertion will fail. This commit patches
that hole.

Signed-off-by: Yuchen Pei <email address hidden>
Reviewed-by: Alexey Botchkov <email address hidden>

87eccd7... by Sergey Petrunia

MDEV-30218: Incorrect optimization for rowid_filtering

(Patch from Monty, slightly amended)

Fix rowid filtering optimization in best_access_path():

== Ref access + rowid filtering ==
The cost computations compare #records and index-only scan cost
(keyread_tmp) to find out the per-record advantage one will get if
they skip reading full table record.

The computations produce wrong result when:

- the #records are "clipped down" with s->worst_seeks or
  thd->variables.max_seeks_for_key. keyread_tmp is not clipped
  this way so the numbers are not comparable.

- access_factor is negative. This means index_only read is
  cheaper than non-index-only read.

This patch makes the optimizer not to consider Rowid Filtering in
such cases.
The decision is logged in the Optimizer Trace using
"rowid_filter_skipped" name.

== Range access + rowid filtering ==
when considering to use Rowid Filter with range access, do multiply
keyread_tmp by record_count. That way, it is comparable with the
range access's estimate, which is multiplied by record_count.

fdf43b5... by Marko Mäkelä

Merge 10.3 into 10.4

382e85f... by Daniel Black

MDEV-30065: mariadb-install-db allow for --enforce-storage-engine=InnoDB

Hide the errors related to missing innodb stats tables in bootstrap mode
on the assumption that because we are in bootstrap mode they are going
to be created.

c1cc6e8... by Daniel Black

Correct DBUG_ENTER for Pushdown_derived::execute

a491400... by Julius Goryavsky <email address hidden>

MDEV-29814: galera_var_notify_ssl_ipv6 causes testing system to hang

This commit fixes the test system hanging due to
the galera_var_notify_ssl_ipv6 test and also brings
the wsrep_notify[_ssl].sh files in line with each other
between the user template and the mtr suite.

Quotes are also added here to avoid problems if the
user specifies the value of one of the variables at the
beginning of the file containing shell-specific characters,
for example, if the password or username specified in the
PSWD and USER variables will contain the "$" character.

Also fixed an issue with automatic --ssl-verify-server-cert
option substitution when the corresponding value is set
by the user to "1" or "on".

Also fixed some tests here to avoid joining one of the nodes
to another cluster when the nodes are restarted from the mtr
side, which can lead to random failures when testing with
buildbot.

8f30973... by Julius Goryavsky <email address hidden>

MDEV-29814: galera_var_notify_ssl_ipv6 causes testing system to hang

This commit fixes the test system hanging due to
the galera_var_notify_ssl_ipv6 test and also brings
the wsrep_notify[_ssl].sh files in line with each other
between the user template and the mtr suite.

Quotes are also added here to avoid problems if the
user specifies the value of one of the variables at the
beginning of the file containing shell-specific characters,
for example, if the password or username specified in the
PSWD and USER variables will contain the "$" character.

Also fixed an issue with automatic --ssl-verify-server-cert
option substitution when the corresponding value is set
by the user to "1" or "on".

Also fixed some tests here to avoid joining one of the nodes
to another cluster when the nodes are restarted from the mtr
side, which can lead to random failures when testing with
buildbot.

782b2a7... by Marko Mäkelä

MDEV-29144 ER_TABLE_SCHEMA_MISMATCH or crash on DISCARD/IMPORT

mysql_discard_or_import_tablespace(): On successful
ALTER TABLE...DISCARD TABLESPACE, evict the table handle from the
table definition cache, so that ha_innobase::close() will be invoked,
like InnoDB expects to be the case. This will avoid an assertion failure
ut_a(table->get_ref_count() == 0) during IMPORT TABLESPACE.

ha_innobase::open(): Do not issue any ER_TABLESPACE_DISCARDED warning.
Member functions for DML will do that.

ha_innobase::truncate(), ha_innobase::check_if_supported_inplace_alter():
Issue ER_TABLESPACE_DISCARDED warnings, to compensate for the removal of
the warning in ha_innobase::open().

row_quiesce_write_indexes(): Only write information about committed
indexes. The ALTER TABLE t NOWAIT ADD INDEX(c) in the nondeterministic
test case will most of the time fail due to a metadata lock (MDL) timeout
and leave behind an uncommitted index.

Reviewed by: Sergei Golubchik

8f3631d... by Daniel Black

MDEV-30150 ST_GeomFromGeoJSON, 'geometry' before 'type: feature' error

The geometry type requires Type:"Feature" but the feature need
not be first in the JSON structure.

Adjust code to return an error if geometry isn't a JSON object,
but continue parsing searching for Type: "Feature" to trigger
the geometry parsing.

Thanks Derick Magnusen for the bug report.

d360fa6... by Vladislav Vaintroub

MDEV-30162 Fix occasional "Permission denied" on Windows caused by buggy 3rd party

Add retry logic for CreateFile, DeleteFile, or MoveFile
when GetLastError() is ERROR_SHARING_VIOLATION.