maria:bb-11.0-mdev31223

Last commit made on 2023-05-09
Get this branch:
git clone -b bb-11.0-mdev31223 https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-11.0-mdev31223
Repository:
lp:maria

Recent commits

368dd22... by Sergey Petrunia

MDEV-31223: UBSan error: sql_select.h:969:7: runtime error: load of value...

In Loose_scan_opt::save_to_position, initialize
POSITION::firstmatch_with_join_buf.

b3edbf2... by Sergey Petrunia

MDEV-31022: SIGSEGV in maria_create from create_internal_tmp_table

The code in create_internal_tmp_table() didn't take into account that
now temporary (derived) tables may have multiple indexes:

- one index due to duplicate removal
   = In this example created by conversion of big-IN(...) into subquery
   = this index might be converted into a "unique constraint" if the key
     length is too large.
- one index added by derived_with_keys optimization.

Make create_internal_tmp_table() handle multiple indexes.

Before this patch, use of a unique constraint was indicated in
TABLE_SHARE::uniques. This was ok as unique constraint was the only index
in the table. Now it's no longer the case so TABLE_SHARE::uniques is removed
and replaced with an in-memory-only flag HA_UNIQUE_HASH.

This patch is based on Monty's patch.
Co-Author: Monty <email address hidden>

63df43a... by Monty <email address hidden>

Removed temporary test file that should not have been pushed

78f684e... by Monty <email address hidden>

Moved events tests from main to suite/events

This makes it easier to run test on just events.

ec820a3... by Monty <email address hidden>

Moved merge tests from main to suite/merge

This makes it easier to run test on just the MRG_MYISAM engine.

Other things:
- Renamed merge-big.test to flush_corruption.test as it does not
  have anything to do with merge tables.

0099c2f... by Monty <email address hidden>

MDEV-30786 SIGFPE in cost_group_min_max on EXP

The problem was that for merge tables without any underlaying tables the
block size was 0, which the code could not handle.

Fixed by ensuring that MERGE tables never have a block size of 0.
Fixed also a wrong assumption of number of seeks needed to scan
merge tables.

3bdc554... by Monty <email address hidden>

MDEV-30812: Improve output cardinality estimates for hash join

Introduces @@optimizer_switch flag: hash_join_cardinality

When this option is on, use EITS statistics to produce tighter bounds
for hash join output cardinality.

This patch is an extension / replacement to a similar patch in 10.6

New features:
- optimizer_switch hash_join_cardinality is on by default
- records_out is set to fanout when HASH is used
- Fixed bug in is_eits_usable: The function did not work with views

8d26537... by Marko Mäkelä

MDEV-30895 Assertion btr_cur->rtr_info->thr... in rtr_ins_enlarge_mbr()

rtr_ins_enlarge_mbr(): Relax the assertion that was added in
commit f27e9c894779a4c7ebe6446ba9aa408f1771c114
to cover also table-rebuilding DDL. We only need
btr_cur->rtr_info->thr for acquiring R-tree locks,
and the thread that is executing a DDL operation has exclusive
access to the being-built index or the copy of the being-rebuilt table.

6abafdb... by Yuchen Pei

MDEV-29676 Add query to set lock wait timeout when getting sts crd

Set the lock wait timeout to 1 beforehand, and reset it afterwards, to
avoid lock conflict caused by opening the same table twice in case of
self-reference.

779307d... by Yuchen Pei

MDEV-29676 Some changes in behaviour w.r.t. spider sts crd

- assign spider->share early when !new_share
- remove locking before spider_share_init_{sts,crd}