Home - Waterfall Grid T-Grid Console Builders Recent Builds Buildslaves Changesources - JSON API - About

Console View


Categories: connectors experimental galera main
Legend:   Passed Failed Warnings Failed Again Running Exception Offline No data

connectors experimental galera main
Kristian Nielsen
Merge 11.8 to 12.3

Signed-off-by: Kristian Nielsen <[email protected]>
Raghunandan Bhat
MDEV-39559: Assertion `b` failed in `my_strnncoll_xxxx_nopad_ci`

Problem:
  When verifying a `UNIQUE` constraint over an empty BLOB/TEXT column,
  `Field_blob::cmp(a_ptr, b_ptr)` extracts a NULL data pointer (with
  length 0) from the record slot and forwards it to the charset-level
  comparison, which asserts non-NULL pointers (added in MDEV-35717).

  A zero-length blob is allowed to have a NULL data pointer in its
  record slot; `Field_blob::val_decimal()` already treats (NULL, 0) as
  an empty value. The comparison paths missed that substitution.

Fix:
  - In `Field_blob::cmp(a_ptr, b_ptr)`and
    `Field_blob::key_cmp(key_ptr, max_key_length)`, substitute "" for a
    NULL data pointer before delegating to the comparison.
  - Add a debug assert in each of the above functions to document the
    invariant that a NULL pointer is only valid alongside zero length
    and (NULL, length>0) is invalid.
drrtuy
chore: update DuckDB docs and info.
Kristian Nielsen
Post-merge fix

Signed-off-by: Kristian Nielsen <[email protected]>
Rucha Deodhar
MDEV-38862: Fix double comma in user lists causing incorrect filtering

Analysis:
Configuring server_audit_incl_users or server_audit_excl_users with
double commas, edge commas, or spaces (e.g., 'user1,,user2') causes
getkey_user() to pass a 0-length token to coll_insert(). This inserts
an empty string ("") into the user tree collection, corrupting the
lookup logic and forcing the plugin to fail open and log all users.
Fix:
Added a check for `cmp_length == 0` to skip inserting empty or
whitespace-only tokens and fixed pointer arithmetic to safely skip
boundary commas.
Jan Lindström
MDEV-38870 : Galera test failure on galera.MDEV-38201

Test changes only. Moved wait condition where node should
disconnect from cluster because it has become inconsistent.
After that next FLUSH HOST based on timing could return
not supported or timeout.
Daniel Black
MDEV-39881 mroonga set, but not used variables: grn_ii_buffer_check

crid unused, so removed.
Brandon Nesterenko
MDEV-38144: Update test results to show bug regression

The c_unsigned INT UNSIGNED would continue to show as unsigned without
the fix because the YEAR is also considered unsigned. Fixed the test to
use a signed INT after YEAR so the bug would show as the INT field
consuming the (unconsumed-by-year) UNSIGNED INT bit.

Also fixed bad spacing.
Kristian Nielsen
Merge branch '11.8' into 12.3
Pekka Lampio
MDEV-38386 Fix incomplete cleanup in Galera MTR tests failing under --repeat

A number of Galera MTR tests pass on the first run but fail on a second
--repeat iteration, because server, cluster or filesystem state leaks
across runs and the test does not restore a clean starting state.

Fix the cleanup (or force a fresh cluster) in the affected tests. Each
fix was verified with --repeat=2 --force.

1. Stale async-slave GTID position (11 tests)

  RESET SLAVE [ALL] does not clear gtid_slave_pos. As the master does
  RESET MASTER in cleanup, on the next run the slave considers the
  events already applied and skips them, so the replicated tables never
  appear. Clear the position with SET GLOBAL gtid_slave_pos = "".

2. Leftover binlog GTID state from trailing cleanup (1 test)

  Trailing DROP TABLE / mtr.add_suppression statements ran after the
  .inc's reset master and re-populated node_2's binlog. gtid_binlog_state
  keeps the latest seqno per (domain, server_id) pair, so a stray
  0-2-<n> survived into the next run and broke the state comparison.
  Reorder the cleanup and reset node_2's binlog last.

3. Cluster-global, one-time or time-window state (11 tests)

  The wsrep GTID domain seqno is cluster-global and is not reset by
  reset master (nor by a mid-test SST rejoin); error-log contents,
  warning-flood suppression timers and one-time bootstrap behaviour are
  likewise not restored by in-test cleanup. Force a fresh cluster with
  include/force_restart.inc.

4. Leftover filesystem artifacts (1 test)

  mariabackup refuses to back up into a non-empty target directory, so
  the leftover target dirs from the previous run made the backup fail
  silently and the expected log messages never appeared. Remove the
  target directories in cleanup.
Dave Gosselin
MDEV-39207:  mark test as not_embedded

Test fails on embedded CI because original not_embedded flag was not preserved
Daniel Black
MDEV-39881 mroonga set, but not used variables: command_schema

too big of stack. Supress for now.

groonga/lib/proc/proc_schema.c:1209:1: error: stack frame size (77688) exceeds limit (49152) in 'command_schema' [-Werror,-Wframe-larger-than]
1209 | command_schema(grn_ctx *ctx, int nargs, grn_obj **args, grn_user_data *user_data)
      | ^
1 error generated.
Daniel Black
MDEV-31209 Queries with window functions do not obey KILL / max_statement_time

Window functions run in a loop in
Frame_cursor::compute_values_for_current_row which can include a large
number of rows.

Adjust this function to check for the current thd being killed by only
every 256 rows, so as not to destroy any CPU pipelining or similar.
Daniel Black
MDEV-39881 mroonga set, but not used variables: grn_ii_buffer_check

size set not used. Remove size.
Andreas Schwab
MDEV-39925: Fix error reporting in create_libaio

The io_setup function in libaio returns a negated errno value on error,
but strerror expects a normal errno value.
Daniel Black
MDEV-39881 mroonga set, but not used variables: grn_ts_expr_bridge_node_filter

tmp used, so removed.
Sergei Golubchik
MDEV-40058 cached_sha2_password crashes on zero-length password

valid encrypted password cannot have zero length and must end with '\0'
Fariha Shaikh
MDEV-39928 Fix GitLab CI centos9 job failure

The centos9 job uses yum-builddep -y mariadb-server to install build
dependencies, but the mariadb-server source package has been removed
from CentOS Stream 9 repositories. Replace with explicit installation of
the required build dependencies.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services, Inc.
Yuchen Pei
[fixup] Move tests requiring an example plugin from sys_vars.session_track_system_variables_basic to a separate test

A follow up to 1f56d9c3feeeca82661cbe57cb628207c8b186f8. This restores
test coverage when the example plugin is not built.
Dave Gosselin
MDEV-39952:  Skip tests that need mariabackup

Skips tests that require mariabackup if mariabackup was not
built (WITH_MARIABACKUP=OFF).

Backport of the same MTR change from 12.3 but applied to
additional tests.
Dave Gosselin
MDEV-38669:  ASAN fail in Item_func_collect::add during ST_COLLECT

st_collect read past the end of its input because it assumed
that the input was a valid geometry.  Check that the length of the
input is at least long enough to possibly contain a valid geometry.
Eric
MDEV-38144: update Optional_metadata_fields to use MariaDB types

Currently Optional_metadata_fields has many members that use classes
from the C++ standard library, most notably the use of std::vector and
std::string. This is inconsistent with the coding standards, as MariaDB
defines its own types for arrays/lists/strings. This patch updates
these variables to use existing MariaDB types.

Additionally, the structure of the fields is changed. Instead of having
a separate list to track each metadata field; the structure now exists
at the column level (Column_metadata), and it has individual member
variables to describe its metadata. This allows for more
straightforward memory management, as everything will now be allocated
at once.

There is also a bug fix in this patch. Prior to this refactor, YEAR
columns would not consume their "unsigned" bit flag, resulting in
numeric columns after a YEAR type to have incorrect signage. This is
now fixed.

Reviewed-by: Brandon Nesterenko <[email protected]>
Dave Gosselin
MDEV-38158:  Incorrect query result

When setup_copy_fields() needs to copy a non-aggregate function value,
it doesn't construct an Item_copy directly.  Instead, it calls
Type_handler::create_item_copy, which is a kind of factory.  The base
Type_handler::create_item_copy returns Item_copy_string.  Some type
handlers override it, like timestamp and fixed binary.  However, the
numeric type handlers (e.g., float, double, int, decimal) did not, so
they fell through to that base and got Item_copy_string.

A SELECT that aggregates will copy each non aggregate function value
into a temporary table through an Item_copy object, whose concrete
type is chosen by the create_item_copy method on the value's type
handler.  For numeric types that method returned Item_copy_string,
which stores the value as text.  A FLOAT keeps only FLT_DIG
significant digits as text, too few to reproduce its 24 bit mantissa,
so the copied value differed from the original.  With one row per
group, CAST(c1 AS FLOAT) - MIN(CAST(c1 AS FLOAT)) returned a large
number instead of zero.

Add Item_copy_real with Item_copy_float and Item_copy_double variants
that keep the value as a double, the same way Item_cache_real does, and
let the float and double type handlers create them.  This mirrors the
existing copy items for timestamp and fixed binary types.
Daniel Black
MDEV-39881 mroonga set, but not used variables: expr.c

grn_expr_unpack - used offset - add attribute unused
as to not to change macro used elsewhere.

grn_expr_exec: unused ln1/la1 - remove

grn_table_select_index_not_equal: weight unused - remove
Fariha Shaikh
MDEV-39931 Fix main.socket_conflict failure when running as root

The test directly executes $MYSQLD via --exec, bypassing MTR's automatic
--user=root injection. In GitLab CI containers where tests run as root,
mariadbd refuses to start and the test fails.

Skip the test when running as root, matching the existing approach used
by the related main.bad_startup_options test.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services, Inc.
Daniel Black
MDEV-39881 mroonga set, but not used variables: func_snippet

rc set  but not used

Handle snippet errors based on rc value.
Daniel Black
MDEV-39881 mroonga set, but not used variables: grn_time_to_tm

usec unused as it couldn't be used by grn_time_t_to_tm.
Thirunarayanan Balathandayuthapani
MDEV-39963  InnoDB system tablespace autoshrink fails when the tail  extent is an empty XDES_FREE_FRAG extent

Problem:
========
- The InnoDB system tablespace fails to autoshrink even when it is
almost entirely free. Defragmentation reports success but no
space is reclaimed, and the log shows the high-water mark pinned
at the end of the file.

fsp_traverse_extents(): when locating the last used extent,
descends from the end of the tablespace and treats an extent
as reclaimable only when it is XDES_FREE, or the descriptor-page
extent (XDES_FREE_FRAG with two used pages).
Every other XDES_FREE_FRAG extent stops the scan.

An XDES_FREE_FRAG extent with zero used pages can legitimately
exist on disk in tablespaces written by server versions between
commit 0b47c126e31 (MDEV-13542) and commit 7737f15f874 (MDEV-31333).
In that window fsp_free_page() evaluated xdes_get_n_used()
before clearing the freed page's XDES_FREE_BIT, so freeing the
last used page of a fragment extent left the empty extent on the
FSP_FREE_FRAG list instead of moving it to FSP_FREE.
7737f15f874 restored the correct ordering, but pre-existing
data files may still carry such extents.

Such an empty extent is logically identical to XDES_FREE, but
fsp_traverse_extents() mistook it for a used extent, pinned
last_used_extent at end-of-file, and the shrink reclaimed nothing.

Solution:
========
fsp_traverse_extents(): Treat an XDES_FREE_FRAG extent with no used
pages (n_used == 0) the same as XDES_FREE
Kristian Nielsen
Merge 10.11 to 11.4

Signed-off-by: Kristian Nielsen <[email protected]>
Daniel Black
MDEV-39881 mroonga set, but not used variables: yy_reduce

attribute unused for those in macros.
drrtuy
chore: TPC-H automation and packaging section update in README.
Thirunarayanan Balathandayuthapani
MDEV-39963  InnoDB system tablespace autoshrink fails when the tail  extent is an empty XDES_FREE_FRAG extent

Problem:
========
- The InnoDB system tablespace fails to autoshrink even when it is
almost entirely free. Defragmentation reports success but no
space is reclaimed, and the log shows the high-water mark pinned
at the end of the file.

fsp_traverse_extents(): when locating the last used extent,
descends from the end of the tablespace and treats an extent
as reclaimable only when it is XDES_FREE, or the descriptor-page
extent (XDES_FREE_FRAG with two used pages).
Every other XDES_FREE_FRAG extent stops the scan.

An XDES_FREE_FRAG extent with zero used pages can legitimately
exist on disk in tablespaces written by server versions between
commit 0b47c126e31 (MDEV-13542) and commit 7737f15f874 (MDEV-31333).
In that window fsp_free_page() evaluated xdes_get_n_used()
before clearing the freed page's XDES_FREE_BIT, so freeing the
last used page of a fragment extent left the empty extent on the
FSP_FREE_FRAG list instead of moving it to FSP_FREE.
7737f15f874 restored the correct ordering, but pre-existing
data files may still carry such extents.

Such an empty extent is logically identical to XDES_FREE, but
fsp_traverse_extents() mistook it for a used extent, pinned
last_used_extent at end-of-file, and the shrink reclaimed nothing.

Solution:
========
fsp_traverse_extents(): Treat an XDES_FREE_FRAG extent with no used
pages (n_used == 0) the same as XDES_FREE
Dave Gosselin
MDEV-39005: Assertion failure on hint-forced Split-Materialized plan

Using a hint to force splitting can force the optimizer to choose a
split plan that would otherwise be considered invalid.
SPLIT_MATERIALIZED(DT) forces splitting, the optimizer must still
respect the invariants checked by apply_selectivity_for_table() for
what would otherwise be a splitting that would never be chosen
naturally.

In the attached test case, a derived table DT performs GROUP BY/HAVING
and is then joined to t2. With the hint forcing a split, the splitting
code can compute a `records` estimate that makes the effective
selectivity (`sel`) exceed the bound assumed in
apply_selectivity_for_table() (specifically the
`use_cond_selectivity > 1` assertion path), i.e. it can exceed:

  s->table->opt_range_condition_rows / table_records

To fix this, when a split is hint-forced, clamp `records` to the
unsplit derived cardinality (`spl_opt_info->unsplit_card`). This
effectively bounds `records` to:

  min(unsplit_card, unsplit_card * split_sel)

and prevents `sel` from exceeding the range-condition-rows ratio in
the assertion.
Dave Gosselin
MDEV-36059: 2nd PS exec crash w/nested VIEWs

A prepared statement runs preparation again on every execution, and
preparation merges any VIEWs named in the statement.  A VIEW that
appears only inside a subquery is meant to be skipped by the merge for
insert pass during mysql_handle_derived, since it is not the target of
the DELETE.

The first execution prepares with the subquery still nested, so the
view is correctly skipped, and the DELETE succeeds.  Optimization then
converts the IN subquery into a semi-join and adds its tables into the
first SELECT_LEX's table list (reassigning them to that SELECT_LEX).
This conversion is meant to persist for later executions.

Then the PS's second execution prepares against the already flattened
VIEW.  mysql_handle_derived now finds the subquery's VIEW among the
first SELECT_LEX's tables and tries to merge it.  mysql_handle_derived
already had some existing skip logic to recognize a VIEW, but the
semijoin conversion has already merged the VIEW into the first
SELECT_LEX, so the skip doesn't correctly apply.  So a nested VIEW is
merged for insert with no table, causing a crash on the NULL table
pointer.

Solution is to skip a table during mysql_handle_derived when it is the
inner side of a semijoin, recognized by its embedding semijoin nest.
Kristian Nielsen
Merge 11.4 to 11.8

Signed-off-by: Kristian Nielsen <[email protected]>
Kristian Nielsen
Fix inconsistent terminology

Signed-off-by: Kristian Nielsen <[email protected]>
Marko Mäkelä
MDEV-39971: generate_option_list may invoke pclose(nullptr)

call_mariadbd(): Remove the redundant and potentially harmful call
of my_pclose(f) when my_popen() failed. At least in some versions
of GNU libc the function pclose(3) is declared with
__attribute__((nonnull)).

Fixes up commit 7828fb475b00d4211ba8ce1ec6e9a1b06e0fc39b (MDEV-32745)
PranavKTiwari
MDEV-22943: Assertion 'marked_for_read()' failed in Field_varstring::val_str on CHECKSUM TABLE

use_all_stored_columns() cleared read_set bits for all generated
columns, including persistent generated columns.

This caused stored generated columns to be accessed without being
marked for read, leading to a marked_for_read() assertion during
CHECKSUM TABLE EXTENDED.

Only exclude non-stored virtual generated columns from read_set.