maria:bb-10.5-MDEV-31477

Last commit made on 2023-06-20
Get this branch:
git clone -b bb-10.5-MDEV-31477 https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.5-MDEV-31477
Repository:
lp:maria

Recent commits

9ca52a9... by Rucha Deodhar <email address hidden>

MDEV-31477: Inconsistent handling while fetching values in json

Analysis:
JSON_KEY_VALUE() uses Json_path_extractor::extract() to reach to path and
extract values. One error it only returns true, but no error.
Fix:
report error when there is error in scanning json document.

0b61f4e... by Sergey Petrunia

Fix comment

bd076d4... by THIRUNARAYANAN BALATHANDAYUTHAPANI

MDEV-31442 page_cleaner thread aborts while releasing the tablespace

- InnoDB shouldn't acquire the tablespace when it is being stopped
or closed

f7e9ac0... by Sergey Petrunia

MDEV-31449: Assertion s->table->opt_range_condition_rows <= s->found_records

Fix a typo in make_join_statistics(): when updating statistics for
derived table, set s->table->... not "table->..."

0e2e70c... by Sergey Petrunia

MDEV-31479: Inconsistency between MRR and SQL layer costs can cause poor query plan

(Same as
TODO-3938: best_access_path shows negative costs for mrr=on)

best_access_path() assumes that quick select cost includes
(quick->rows/TIME_FOR_COMPARE) as a cost of checking the attached
part of the WHERE condition.

It calls adjust_quick_cost() to subtract addition from quick's cost.

The problem was that DS-MRR cost formula didn't include this cost.
For very large tables, adjust_quick_cost() would produce a negative
cost which would cause assert in debug build or bad query plan choice
in release builds.

Approved-by: Monty <email address hidden>

841e905... by THIRUNARAYANAN BALATHANDAYUTHAPANI

MDEV-31442 page_cleaner thread aborts while releasing the tablespace

After further I/O on a tablespace has been stopped
(for example due to DROP TABLE or an operation that
rebuilds a table), page cleaner thread tries to
flush the pending writes for the tablespace and
releases the tablespace reference even though it was not
acquired.

fil_space_t::flush(): Don't release the tablespace when it is
being stopped and closed

Thanks to Marko Mäkelä for suggesting this patch.

b307412... by Sergey Petrunia

MDEV-31380 post-fix: fix group_min_max.test with embedded and view-protocol

embedded doesn't have optimizer trace,
view-protocol doesn't work with long column names.

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

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