maria:bb-10.4-MDEV-33138-galera

Last commit made on 2024-01-26
Get this branch:
git clone -b bb-10.4-MDEV-33138-galera https://git.launchpad.net/maria

Branch merges

Branch information

Name:
bb-10.4-MDEV-33138-galera
Repository:
lp:maria

Recent commits

a3707a7... by =?utf-8?q?Jan_Lindstr=C3=B6m?= <email address hidden>

MDEV-33138 : Galera test case MW-336 unstable

Add more inserts before wsrep_slave_threads is set to 1 and
add wait_condition to wait all of them are replicated before
wait_condition about number of wsrep_slave_threads.

Signed-off-by: Julius Goryavsky <email address hidden>

7cbaaf1... by =?utf-8?q?Jan_Lindstr=C3=B6m?= <email address hidden>

MDEV-32635: galera_shutdown_nonprim: mysql_shutdown failed

Add wait_condition after cluster membership change

Signed-off-by: Julius Goryavsky <email address hidden>

75df2b0... by Daniele Sciascia <email address hidden>

Re-enable MTR test galera_sr.GCF-1060

Test seems to pass reliably now.

Signed-off-by: Julius Goryavsky <email address hidden>

fa7501f... by sjaakola <email address hidden>

MDEV-30456 ALTER TABLE algorithm clause not replicated

Fixing the regression happening with galera.galera_toi_ddl_nonconflicting
The problem, surfaced by the test, was due to multi-statement used in the test.
The test issues two queries, as multi-statement:

--send ALTER TABLE t1 ADD COLUMN f3 INTEGER; INSERT INTO t1 (f1, f2) VALUES (DEFAULT, 123);

With this, the session's THD structure has in query_string member
the full multi-statement, and this was used as base query in
TOI replication rewriting.

The fix is to pass actual length of the ALTER statement part for
TOI replication.

Signed-off-by: Julius Goryavsky <email address hidden>

3dd5662... by Julius Goryavsky <email address hidden>

MDEV-30456: post-review changes

89bc7be... by sjaakola <email address hidden>

MDEV-30456 ALTER TABLE algorithm clause not replicated

If user has specified the desired alter algorithm by using session
variable alter_algorithm, and not specifying the algorithm in the
ALTER SQL statement, then the ALTER will be processed in sending node
according the algorithm chosen by the alter_algorithm variable.
But in receiving nodes, appliers cannot see this session variable,
and will use the default algorithm when executing the ALTER.

The fix in this commit, will check if user has set alter_algorithm
variable and has not specified the algorithm clause in the ALTER
statement, and in such case will rewrite the original ALTER statement
appended by the algorithm clause. This rewritten ALTER statement will
be used in replication.

The commit has also new mtr test: galera.galera_alter_table_algorithm
which verifies that ALTER query rewrite happens when needed

Signed-off-by: Julius Goryavsky <email address hidden>

1070575... by Yuchen Pei <email address hidden>

MDEV-33191 spider: fix dbton_id when iterating over links

There are two array fields in spider_share with similar names:

share->use_sql_dbton_ids that maps from i to the i-th dbton used by
share. Thus it should be used only when i iterates over all distinct
dbtons used by share.

share->sql_dbton_ids that maps from i to the dbton used by the i-th
link of the share. Thus it should be used only when i iterates over
all links of a share.

We correct instances where share->sql_dbton_ids should be used instead
of share->use_sql_dbton_ids.

f738cc9... by Alexander Barkov

MDEV-29095 REGEXP_REPLACE treats empty strings different than REPLACE in ORACLE mode

Turning REGEXP_REPLACE into two schema-qualified functions:
- mariadb_schema.regexp_replace()
- oracle_schema.regexp_replace()

Fixing oracle_schema.regexp_replace(subj,pattern,replacement) to treat
NULL in "replacement" as an empty string.

Adding new classes implementing oracle_schema.regexp_replace():
- Item_func_regexp_replace_oracle
- Create_func_regexp_replace_oracle

Adding helper methods:
- String *Item::val_str_null_to_empty(String *to)
- String *Item::val_str_null_to_empty(String *to, bool null_to_empty)

and reusing these methods in both Item_func_replace and
Item_func_regexp_replace.

3699a7e... by Daniel Black

macos: Fix CMAKE_OSX_ARCHITECTURES when not set

When CMAKE_OSX_ARCHITECTURES isn't set we end up with
"Packaging as: mariadb-10.4.33-osx10.19-x86_64" on arm64 builders.

Instead of implying 64bit is x86, use CMAKE_SYSTEM_PROCESSOR to form
the filename.

7c2f082... by Vicențiu Ciorbaru

Improve READLINE_V5 detection

More in depth check to cover all used readline functions.