maria:bb-10.9-mdev-29447-31338

Last commit made on 2023-06-23
Get this branch:
git clone -b bb-10.9-mdev-29447-31338 https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.9-mdev-29447-31338
Repository:
lp:maria

Recent commits

dd316b6... by Yuchen Pei

MDEV-29447 MDEV-26285 MDEV-31338 Refactor spider_db_mbase_util::open_item_func

spider_db_mbase_util::open_item_func() is a monster function.
It is difficult to maintain while it is expected that we need to
modify it when a new SQL function or a new func_type is added.

We split the function into two distinct functions: one handles the
case of str != NULL and the other handles the case of str == NULL.

This refactoring was done in a conservative way because we do not
have comprehensive tests on the function.

It also fixes MDEV-29447 and MDEV-31338 where field items that are
arguments of a func item may be used before created / initialised.

Note this commit is adapted from a patch by Nayuta for MDEV-26285.

e1a631f... by Monty <email address hidden>

Fixed wrong assignment in calculate_block_sizes() for MEM_ROOT

The effect was that that ROOT_FLAG_THREAD_SPECIFIC was cleared and
the memory allocated by memroot would be contributed the the system,
not to the thread.

This exposed a bug in how "show explain for ..." allocated data.
- The thread that did provide the explain allocated data in the
  "show explain" threads mem_root, which is marked as THREAD_SPECIFIC.
- Fixed by allocating the explain data in a temporary explain_mem_root
  which is not THREAD_SPECIFIC.

Other things:
- Added extra checks when using update_malloc_size()
- Do not call update_malloc_size() for memory not registered with
  update_malloc_size(). This avoid some wrong 'memory not freed' reports.
- Added a checking of 'thd->killed' to ensure that
  main.truncate_notembedded.test still works.

Reported by: Yury Chaikou

c4cf5e1... by Monty <email address hidden>

Fixed main.mysqld-help and connect.drop-open-error tests

5b37d58... by Marko Mäkelä

Merge mariadb-10.9.7 into 10.9

223c2c5... by Marko Mäkelä

Merge 10.6 into 10.9

80585c9... by Marko Mäkelä

Merge 10.5 into 10.6

d3eefba... by Marko Mäkelä

MDEV-31355 fixup: Adjust one more test

The test gcol.gcol_purge would reliably hang on 10.6 on a
Microsoft Windows builder without this adjustment.
A similar adjustment was applied in
commit 3e40f9a7f3bbe82d96c8acccbb017deebfa00647
to the tests innodb.dml_purge and innodb.instant_alter_purge.

21031b2... by Marko Mäkelä

Suppress an occasional buffer pool warning

6882eea... by Marko Mäkelä

MDEV-30483 fixup: Declare the test plugin for Debian

c25b496... by Marko Mäkelä

MDEV-31382 SET GLOBAL innodb_undo_log_truncate=ON has no effect on logically empty undo logs

innodb_undo_log_truncate_update(): A callback function. If
SET GLOBAL innodb_undo_log_truncate=ON, invoke
srv_wake_purge_thread_if_not_active().

srv_wake_purge_thread_if_not_active(): If innodb_undo_log_truncate=ON,
always wake up the purge subsystem.

srv_do_purge(): If the history is empty, invoke
trx_purge_truncate_history() in order to free undo log pages.

trx_purge_truncate_history(): If head.trx_no==0, consider the
cached undo logs to be free.

trx_purge(): Remove the parameter "bool truncate" and let the
caller invoke trx_purge_truncate_history() directly.

Reviewed by: Vladislav Lesin