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
Daniel Black
MDEV-39813 ST_GeomFromGeoJSON does not control recursion depth

Geometry::create_from_json reset the killedptr and the stack
depth (stack_p) every time json_scan_start was called. We save/
restore these values so that the ST_GeomFrom_GeoJSON can be killed
and incur timeout, and also so that its depth measurement is kept.

Test case an bug report thanks to byteoverride.
Thirunarayanan Balathandayuthapani
MDEV-39092  Aria backup ignores aria_log_dir_path

BACKUP SERVER scanned maria_data_root (= aria_log_dir_path) for both
table files and logs, so when aria_log_dir_path differed from the
datadir the Aria tables were missed. Scan the server datadir for
.MAD or .MAI files and aria_log_dir_path only for the logs/control file.
Daniel Black
Merge 10.6 into 10.11
PranavKTiwari
Added logic
Raghunandan Bhat
MDEV-40176: UBSAN: runtime error: applying non-zero offset at `strings/ctype-mb.c:261`
Daniel Black
MDEV-39276: Assertion `0` failed in json_find_path

This was resolved with MDEV-35548, however we add
two additional test cases.
Thirunarayanan Balathandayuthapani
MDEV-39061 mariadb-backup compatible wrapper for BACKUP SERVER

This adds a shell script that lets users keep using their existing
mariadb-backup commands while the real work is done by the new
server-side BACKUP SERVER command. The goal is "drop-in": users should
not have to change their backup scripts.

scripts/mariabackup/mariabackup.sh (plain POSIX sh) understands the usual
mariadb-backup modes and translates each one. A companion helper,
scripts/mariabackup/mbstream.sh, lets streamed backups be unpacked by
pipelines that expect the mbstream CLI. Both are documented in
scripts/mariabackup/README.md.

--backup
========
Connects with the mariadb client and runs "BACKUP SERVER TO '<dir>'".
Connection options (--user, --host, --port, --socket, --defaults-file,
ssl, ...) are passed through to the client; --parallel=N becomes the
"<N> CONCURRENT" clause.
After the backup it writes backup-prepare.cnf into the backup
directory, recording what --prepare needs later: where
mariadbd lives, the InnoDB parameters (page size, data file path,
undo tablespaces, checksum algorithm, log file size), and if
the server is encrypted then how to reload the encryption key
plugin (the file_key_management variables),
so an encrypted backup can be prepared without extra input.

--backup --stream
=================
Runs "BACKUP SERVER WITH [N CONCURRENT] '<command>'": the server feeds
each stream's tar to <command>, the wrapper collects the parts, writes
them to stdout, then appends backup-prepare.cnf as a final tar. The
output is several tar archives concatenated, so extract it with
"tar --ignore-zeros".
Two properties follow from how BACKUP SERVER streams,
both differing from mariadb-backup:
- local: the stream command runs inside the server, so the wrapper
  must share its filesystem;
- tar only: any --stream=<format> (including xbstream) yields tar.
--target-dir is optional in stream mode (scratch for the per-stream
parts; a mktemp dir is used otherwise).

mbstream.sh maps the mbstream CLI onto tar. Extraction uses
"tar --ignore-zeros" to unpack all the concatenated archives. So
existing "mbstream -x"/"-c" pipelines keep working on the wrapper's
stream. mbstream-only flags (-p/--parallel, ...)
are accepted and ignored.

--prepare
=========
Starts "mariadbd --bootstrap" on the backup directory using
backup-prepare.cnf as its defaults file, replays the archived redo
log between the start and target LSN read from backup.cnf,
then builds a fresh ib_logfile0 so a normal server can start
on the directory. mariadbd is taken from the path recorded in
backup-prepare.cnf if that binary exists, otherwise from PATH.
User --defaults-file/-extra-file and encryption options are
layered onto the bootstrap.

--copy-back / --move-back
=========================
Copy or move a prepared backup into the datadir. The datadir
is created if missing, a non-empty datadir is refused unless
--force-non-empty-directories is given, and a chown
reminder is printed.

If --aria-log-dir-path is given, the Aria logs (aria_log_control,
aria_log.*) are relocated into that directory.

Packaging
=========
The wrapper is not installed by default and never replaces the
real mariadb-backup / mbstream binaries.
1. cmake -DWITH_MARIABACKUP_WRAPPER=ON (default OFF) controls it.
2. When ON, the scripts install as /usr/bin/mariadb-backup-server
and /usr/bin/mbstream-server, tagged COMPONENT Backup so they
ship in the mariadb-backup package.
3. RPM: nothing extra to do. the component handles it.
4. DEB: not wired. debian/rules uses --fail-missing and does not
enable the option, so the -server binaries are not listed.
To ship via DEB, make a paired change: add
-DWITH_MARIABACKUP_WRAPPER=ON in debian/rules and list both
usr/bin/mariadb-backup-server and
usr/bin/mbstream-server in debian/mariadb-backup.install together.
5. The real mariadb-backup/mbstream binaries and the
mariabackup symlink are left untouched; opt in via an alias or a
symlink early in PATH.

Limitations (not supported yet)
===============================
1) Incremental backup & prepare (--incremental-basedir,
  --incremental-dir, --apply-log-only)
2) --rollback-xa
3) Partial backup (--databases, --tables, --tables-file)
4) Output compression and encryption (--compress, --encrypt)
5) --export is accepted but only warns and runs a plain recovery
6) --extra-lsndir is ignored
7) Windows: POSIX sh only, not installed on Windows

Behaviour differences from native mariadb-backup
================================================
- The wrapper needs the mariadb client on PATH for
--backup, and mariadbd on PATH (or recorded in backup-prepare.cnf)
for --prepare
- BACKUP SERVER refuses an already-existing target directory
- BACKUP SERVER does copy the data file as raw pages without
checksum validation, so a corrupted table is not detected
at backup time
- --prepare only works on a wrapper-made backup. It
needs backup-prepare.cnf)
- --stream is tar, not xbstream, and local-only

Tests
=====
include/have_mariabackup_wrapper.inc redirects $XTRABACKUP to
mariabackup.sh and $XBSTREAM to mbstream.sh, skipping when a
wrapper or the mariadb client is unavailable.
include/have_mariabackup_combination.inc runs a test under both the
[CLIENT] mariadb-backup binary and the [SERVER] wrapper.
Daniel Black
MDEV-39691 wsrep.cnf contains deprecated wsrep_causal_reads

wsrep_causal_reads was deprecated in 10.1.3 and removed in 11.3.1.
Put in place the equivalent (and default) wsrep_sync_wait=0.

Amend a few early comments to show MariaDB as our product.
Marko Mäkelä
Merge 13.0 into main
Marko Mäkelä
Merge 12.3 into 13.0
Oleg Smirnov
MDEV-32326 Recursive CTE reference in a scalar subquery must be rejected

A recursive reference to a WITH RECURSIVE table that is reachable only
through a scalar subquery (in particular through a WITH clause nested
inside such a subquery) was not recognized as a subquery reference. As a
result the recursive CTE was wrongly accepted as standard-compliant instead
of being rejected with ER_NOT_STANDARD_COMPLIANT_RECURSIVE, and execution
later dereferenced an uninitialized join_tab for that reference in
st_select_lex_unit::exec_recursive(), crashing the server.

The cause was in With_element::check_dependencies_in_unit(). The flag
marking that we are inside a subquery (in_subq) was updated only after the
unit's own WITH clause had already been analyzed. Hence dependencies
discovered while descending into a WITH clause attached to a scalar
subquery were recorded in top_level_dep_map instead of sq_dep_map, so
contains_sq_with_recursive_reference() failed to report the violation.

The fix: set in_subq from unit->item before processing the unit's WITH
clause, so that dependencies found in nested WITH clauses of a scalar
subquery are correctly attributed to the subquery context.

The expected error for the MDEV-32299 cases in cte_recursive.test changes
accordingly from ER_BAD_FIELD_ERROR to ER_NOT_STANDARD_COMPLIANT_RECURSIVE:
the query is now rejected at dependency analysis for its non-compliant
recursive reference rather than failing later during name resolution. The
test still verifies that no crash occurs.
Daniel Black
MDEV-39541 mem_pressure::~mem_pressure() causes a crash on bootstrap

Fill in the anomaly shutdown paths of InnoDB to include call to
buf_mem_pressure_shutdown now that MDEV-39585 provides some
proper calls shutdown InnoDB and other plugins during the shutdown
under --bootstrap.

Alternate: destructor attribute on buf_mem_pressure_shutdown would
acheive the same thing and given Linux compilers are capabile of
this. This is possible as mem_pressure is currently implemented
in Linux only.
Daniel Black
MDEV-39585 mariadb bootstrap fails to perform plugin deinitalization

mariadbd under --bootstrap failed to preform plugin deinitialization.

The sleep(2);exit is removed and replaced to a goto termination label
to perform the same shutdown procedure of the server after all the
connection closing.

To prevent a compile error about char *user being uninitialized
this sql_print_information(ER_DEFAULT(ER_NORMAL_SHUTDOWN)) is moved to
its own block. The memory free did need to occur in the bootstrap mode
too to avoid memory leak errors.

wait_for_signal_thread_to_end(), was previously in close_connections()
however its required too for --bootstrap.
Daniel Black
MDEV-39585: Support SHUTDOWN command on Windows in bootstrap

Don't perform mysqld_win_initiate_shutdown under --bootstrap when
triggered by SHUTDOWN. With this we don't perform any service
interactions.

Then the shutdown can proceeded without then hard process termination
in mysqld_win_initiate_shutdown. This previously occurred because the
handle_connections_win() was never called in --bootstrap and therefore
startup_complete() was false.

Thanks Vladislav Vaintroub for investigation and providing
implementation guidance.
Raghunandan Bhat
MDEV-38971: ASAN/UBSAN errors, assertion `is_valid_value_slow()` failure upon combination temporal functions and `ZERO_DATE_TIME_CAST`

Problem:
  The following functions-
  - `Item_func_last_day::get_date`
  - `Item_date_typecast::get_date`
  - `Item_datetime_typecast::get_date` forwarded the TIME_INTERVAL_DAY /
  TIME_INTERVAL_hhmmssff flags, set by an enclosing EXTRACT, into the
  DATE/DATETIME conversion of their argument.This made, for ex:
  LAST_DAY(200012010000) and CAST(200012010000 AS DATETIME) parse number
  as TIME interval instead of a DATETIME. Under ZERO_DATE_TIME_CAST
  that hour became an out-of-range month, overflowing days_in_month in
  `check_date` and invalidating the Datetime.

Fix:
  A DATE / DATETIME can never be an interval, so suppress the
  TIME_INTERVAL_hhmmssff / TIME_INTERVAL_DAY flags when `LAST_DAY` and
  `CAST` converts its argument. Also add a debug assert in `check_date`
  to catch any future caller that violates its "month is assumed valid"
  contract.
Vladislav Vaintroub
MDEV-25817 proxy protocol: successful login does not reset connect errors

With proxy protocol thd_set_peer_addr() runs twice (proxy host, then the
real client from the proxy header). Connect errors are accounted against
the real client, but check_connection() incorrectly uses condition on the
proxy host's count, rather than real client's address.

Fix: reset both the proxy host, and real client's connect errors on
successful connection.

Added tests for incomplete handshake, and reset behavior,
under proxy protocol, for both real client errors, and proxy host errors.
Daniel Black
MDEV-39585: Support SHUTDOWN command on Windows in bootstrap

Don't perform mysqld_win_initiate_shutdown under --bootstrap when
triggered by SHUTDOWN. With this we don't perform any service
interactions.

Then the shutdown can proceeded without then hard process termination
in mysqld_win_initiate_shutdown. This previously occurred because the
handle_connections_win() was never called in --bootstrap and therefore
startup_complete() was false.

Thanks Vladislav Vaintroub for investigation and providing
implementation guidance.
Sergei Golubchik
fix plugins.feedback_os_release failure on sles-1600

just the comment at the beginning of its /etc/os-release
is already more than 256 bytes
Raghunandan Bhat
MDEV-39450: Memory corruption: overlapping memory ranges in `Field_longstr::compress` on UPDATE of compressed column

Problem:
  Values shorter than `column_compression_threshold` (default 100) are
  stored uncompressed. Reading such a column returns a pointer into that
  buffer rather than a copy.

  When the new value is a substring of the column that aliases this
  buffer at a non-zero offset, e.g. `RIGHT(c,n)` or `SUBSTRING(c,n)`,
  the source and destination overlap, and the `memcpy()` in the "store
  uncompressed" path copies overlapping regions, which is undefined
  behaviour.

Fix:
  Replace `memcpy` with `memmove` to avoid copying between overlapping
  memory regions.
Daniel Black
MDEV-39585 mariadb bootstrap fails to perform plugin deinitalization

mariadbd under --bootstrap failed to preform plugin deinitialization.

The sleep(2);exit is removed and replaced to a goto termination label
to perform the same shutdown procedure of the server after all the
connection closing.

To prevent a compile error about char *user being uninitialized
this sql_print_information(ER_DEFAULT(ER_NORMAL_SHUTDOWN)) is moved to
its own block. The memory free did need to occur in the bootstrap mode
too to avoid memory leak errors.

wait_for_signal_thread_to_end(), was previously in close_connections()
however its required too for --bootstrap.
Vladislav Vaintroub
MDEV-25817 proxy protocol: successful login does not reset connect errors

With proxy protocol thd_set_peer_addr() runs twice (proxy host, then the
real client from the proxy header). Connect errors are accounted against
the real client, but check_connection() incorrectly uses condition on the
proxy host's count, rather than real client's address.

Fix: reset both the proxy host, and real client's connect errors on
successful connection.

Added tests for incomplete handshake, and reset behavior,
under proxy protocol, for both real client errors, and proxy host errors.
Vladislav Vaintroub
MDEV-38369 improve heap allocation performance on Windows with segmentHeap

Use modern segmentHeap heap manager on Windows.

The problem it is solving is severily reduced scalability on concurrent
OLTP benchmarks, due to inherent scalability problems in default NT Heap
implementation.

The benchmarks (see the corresponding ticket) show improvements across
the board, with about 5-10% on low concurrency up to several orders of
magnitude on high concurrency.

Also addressed Gemini and Copilot concerns about correct namespace in
the app manifest XML file - make it the same as in Microsoft examples.
Marko Mäkelä
MDEV-14992 BACKUP SERVER

The following SQL statements will be introduced:

BACKUP SERVER TO '/path/to/directory' [ 1 CONCURRENT ];
BACKUP SERVER WITH [ 1 CONCURRENT ] 'command';

In place of the 1, any positive number of threads may be specified.
For the first variant, '/path/to' must exist and '/path/to/directory'
must not exist; that is where the backup will be written to.

For the second variant, 'command' must be the name of a script or
command that will be executed in a child process. The standard input
of that command will be in a format that is compatible with
GNU tar --format=oldgnu (and also BSD tar variants that are also part of
Microsoft Windows and Apple macOS). The command is expected to optionally
compress and encrypt the stream and redirect it to a file on a local or
a remote server. The BACKUP SERVER WITH will append an additional argument,
a positive base-ten number in ASCII, starting with 1, to identify the
current thread. In this way, each concurrent stream can write a separate
file.

The backup or the first stream will contain a file backup.cnf, which
includes parameters needed for restoring the backup. Currently,
these are innodb_log_recovery_start and innodb_log_recovery_target.
If innodb_log_recovery_target>0, InnoDB will be in read-only mode,
not allowing any writes to persistent files other than via the log
application.

To restore a streaming backup made with BACKUP SERVER WITH, an empty
directory needs to be created and all streams be extracted there using
the standard tar utility of the operating system, optionally after
undoing any encryption or compression that had been added by the
backup command. Then, the backup is prepared or MariaDB server started
up on the extracted directory, similar to as if the BACKUP SERVER TO
statement had been used.

Note: The parameter innodb_log_recovery_start in backup.cnf is
STRICTLY NECESSARY TO AVOID CORRUPTION! By default, InnoDB crash recovery
starts from the latest available log checkpoint. However, for restoring
a backup, recovery must start from the checkpoint that was the latest
when the backup was started. Starting recovery from a possible later
checkpoint will result in a corrupted database!

The following will be implemented separately:

MDEV-39061 mariadb-backup compatible wrapper script for BACKUP SERVER
MDEV-40163 Partial backup and restore
MDEV-39091 Back up ENGINE=RocksDB
MDEV-39092 Less blocking backup of ENGINE=Aria

The implementation introduces a basic driver Sql_cmd_backup,
storage engine interfaces, and basic copying of the storage engines
InnoDB, Aria, MyISAM, MERGE (MyISAM), Archive, CSV.

backup_target: A structured data type to represent a target directory.
On Microsoft Windows, we must use directory paths because there is
no variant of CopyFileEx() that would work on file handles.

backup_sink: Wraps a per-thread output stream as well as storage engine
specific context.

handlerton::backup_start(), handlerton::backup_end(): Invoked at the
start or end of a backup phase, in the thread that executes a
BACKUP SERVER statement.

handlerton::backup_step(): A backup step that can be invoked from
multiple threads concurrently, between the execution of the corresponding
handlerton::backup_start() and handlerton::backup_end() of the same
phase.

copy_entire_file(): A file copying service for POSIX systems.

copy_file(): A partial or sparse file-copying service for all systems.

backup_stream_append(): Equivalent to copy_file(), but appending to
a stream. On Linux, this uses sendfile(2), which assumes that the
source data will not be changed before the data has been consumed
from the pipe.

backup_stream_append_async(): A variant of backup_stream_append()
where the source file region is guaranteed to be immutable after the
call returns. We must not use Linux sendfile(2) for copying data files
that may be modified in place, because it could introduce a race
condition between a page write that runs concurrently with a child process
that is reading the data from the pipe.

InnoDB_backup::context: Backup context, attached to backup_sink
so that context can continue to exist between the time a
BACKUP SERVER releases all locks and another BACKUP SERVER starts
executing, with innodb_backup pointing to the new backup, while
the old backup is still being finished.

fil_space_t::write_or_backup: Keep track of in-flight page writes and
pending backup operation. We must not allow them concurrently, because
that could lead into torn pages in the backup.

fil_space_t::backup_end: The first page number that is not being backed up
(by default 0, to indicate that no backup is in progress).

fil_space_t::BACKUP_BATCH_SIZE: The number of preceding pages that will be
covered by fil_space_t::backup_end. This is the unit of "page range locking"
during InnoDB backup.

log_sys.backup: Whether BACKUP SERVER is in progress. The purpose of this
is to make BACKUP SERVER prevent the concurrent execution of
SET GLOBAL innodb_log_archive=OFF or SET GLOBAL innodb_log_file_size
when innodb_log_archive=OFF.

log_sys.archived_checkpoint: Keep track of the earliest available
checkpoint, corresponding to log_sys.archived_lsn. This reflects
SET GLOBAL innodb_log_recovery_start (which is settable now), for
incremental backup.

buf_flush_list_space(): Check for concurrent backup before writing each
page. This is inefficient, but this function may be invoked from multiple
threads concurrently, and it cannot be changed easily, especially for
fil_crypt_thread().

fil_system.have_all_spaces: Whether all tablespace metadata is guaranteed
to be known. To speed up startup, InnoDB does not normally open
all tablespace files.
Daniel Black
MDEV-39541 mem_pressure::~mem_pressure() causes a crash on bootstrap

Fill in the anomaly shutdown paths of InnoDB to include call to
buf_mem_pressure_shutdown now that MDEV-39585 provides some
proper calls shutdown InnoDB and other plugins during the shutdown
under --bootstrap.

Alternate: destructor attribute on buf_mem_pressure_shutdown would
acheive the same thing and given Linux compilers are capabile of
this. This is possible as mem_pressure is currently implemented
in Linux onny.
Abdelrahman Hedia
MDEV-24931: Fix Bitmap<64>::is_prefix assertion with >64-column NATURAL JOIN on derived table

When a NATURAL JOIN operates on a derived table (or view with
derived_merge=off) having more than 64 columns, the optimizer's
generate_derived_keys_for_table() would:

1) Overflow a 32-bit shift: (key_part_map)(1 << parts) when parts >= 32
2) Create a derived key with more parts than Bitmap<64>/key_part_map can hold
3) Crash on DBUG_ASSERT(prefix_size <= width) in Bitmap<64>::is_prefix(65)

Fix: cap the number of hash-join KEYUSE entries for a materialized derived
table at the handler's max_key_parts(). Excess columns are excluded from the
key, so generate_derived_keys_for_table() never builds a key with more parts
than key_part_map (64 bits) or Bitmap<64> can represent. Also fix the shift
to cast before shifting: (key_part_map) 1 << parts.
Marko Mäkelä
Merge 11.4 into 11.8
Yuchen Pei
MDEV-40103 Initialise thd->net in spider_create_sys_thd

This fixes an msan uninitialized bug
Daniel Black
MDEV-39829/MDEV-33532 s3.debug test failure

MDEV-39516 corrected the interface with curl particularly around
passing options.

After this the s3.debug actually enabled curl debugging like is
was meant to. With this enabled, there are addition s3_test_ pattens
in the result file, from the error log where curl correctly provide
debug message.

ps-protocol test also failed under MDEV-33532 where a differnet
number of entries was recored.

Correct variations by using the $database/$table rather than just the
s3_test_ pattern.

As the purpose of this test is to check if s3_debug is dynamic, the
second part of the test searches for a previously, under s3_debug=1,
table t2 interaction, where the results should be NOT_FOUND.

Remove count from the result file to allow for different curl versions
and the possibiliy of being run under ps-protocol.
forkfun
MDEV-35630 Wrong ER_FK_COLUMN_CANNOT_CHANGE with a STORED column before the FK column

prepare_inplace_alter_table() maps a field position to an InnoDB
cols[] position by skipping columns absent from that array. It used
Field::vcol_info, which is also set for STORED generated columns, so
such a column shifted the mapping by one and the FK-membership check
examined the wrong column, raising a false ER_FK_COLUMN_CANNOT_CHANGE.

Skip only truly virtual columns: use !stored_in_db() instead of
vcol_info.
Marko Mäkelä
Merge 10.11 into 11.4
Marko Mäkelä
Merge 11.8 into 12.3
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.
Thirunarayanan Balathandayuthapani
MDEV-39706  Assertion `!thd || !coordinator_thd' failed

Problem:
========
  - This assert was introduced in commit
0152c617e80ccf3f33d3ea4b50c17d5f588613b1 (MDEV-39261), which sets
coordinator_thd in clone_oldest_view() and resets it to nullptr in
batch_cleanup() at the end of the batch.
When innodb_trx_purge_view_update_only_debug is enabled, InnoDB fail
to reset coordinator_thd. As a result, InnoDB fails with assert in
next batch

Solution:
========
trx_purge(): Reset coordinator_thd to nullptr when
innodb_trx_purge_view_update_only_debug is enabled.
Daniel Black
MDEV-37615: Clang based static analysis false postive reports on UNINIT_VAR

Clang upstream bug https://github.com/llvm/llvm-project/issues/173210
shows that a "int x=x" construct will in the intermediate representation
have code to read from x. With this generated sanitizer=undefined and
static analyzers will all see the uninitialized read and write.

Because clang has a stronger implementation of following paths to
uninitialized variables, "#define UNINIT_VAR(x) x" is the which
is what our release binaries use is the ideal path for this compiler.

Clang based compilers with error during compilation if any
uninitialized behaviour is detected at compile time because of
0c80ddb519bd06efbd7ccf2a2487b2503cd16db5.

Corrects MDEV-36542 - 6fd57f478f585249bdca242b1576ac0a7bd7aacf.
Daniel Black
spelling correction: support-files/wsrep.cnf.sh

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Rucha Deodhar
MDEV-32726: Fix failing test for freebsd for json

(10.6 backport)

Json test about max statement time fails with freebsd because on some
architectures the test might execute faster and the statement may not fail.

To simulate failure regardless of architecture, introduce a wait of seconds
longer than the max_statement_time.
Daniel Black
MDEV-28404 JSON functions don't respect KILL QUERY

Or max_statement_time limit or MAX_DEPTH.

Correct interuptability and depth checking of:
* JSON_CONTAINS
* JSON_CONTAINS_PATH
* JSON_EXISTS
* JSON_EXTRACT
* JSON_KEYS
* ST_GeomFromGeoJSON

Populate in the json library the killed as a specific
error message. As the json library has a killed_ptr
is approprate it handles it.

As json_report_error now processes the killed there's
no need of thd->check_killed().

Verified that the path after every json_scan_next, the
location of checking the killed_ptr, reports errors
correctly.
Thirunarayanan Balathandayuthapani
MDEV-14992 Backup CSV, ARCHIVE and MERGE engine table files

- Extend the data file extensions copied by ma_backup to cover the CSV
(CSV/CSM), ARCHIVE (ARM/ARZ) and MERGE (MRG) engines in addition to
Aria and MyISAM. Update the log_tables mariabackup test to handle
the NEW combination.
Daniel Black
MDEV-30518: JSON functions cannot be killed on big-endian (backport)

Backport to 10.6 without JSON_OVERLAPS

The json_engine killed_ptr was of type uchar however the enum
in the server is dependant on the architecture. On big-endian
architectures like IBM Z, retreiving a uchar* retreived the
unmodifed part of the THD->kill enum location and was always 0.

As C++11 allows enums to inherit a type, used uint32_t as the base
class of killed_state type in the server and used uint32_t in the
json library.

reload_acl_and_cache required an expression change to avoid
the compile error:
sql/sql_reload.cc:472:24: error: enumerated and non-enumerated
type in conditional expression [-Werror=enum-conversion]
  472 |  return result || (thd ? thd->killed : 0);

Added the kill_ptr assignment the following functions can be
killed:
* Item_func_json_depth::val_int
* Item_func_json_type::val_str
* Item_func_json_length::val_int

Item_func_json_array_append::val_str, check_killed() only applied
to json_error: label and not return_null.

Item_func_json_format::val_str(), corresponding to the SQL,
json_compact, json_detailed, json_loose - add debug instrumentation
for the func_json_notembedded test.

MDEV-26726 (fcd345de485f) added a json_pause_execution sync point
however the test case used debug_max_statement_time, which doesn't
exist. Fix the sync point name in the test.
Ian Gilfillan
MDBF-1180: Fix errors in CONTRIBUTING.md