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
Sergei Golubchik
find pcre2.h in a non-default location

for macos builder
Rex Johnston
MDEV-39499 Updates to derived-with-keys, window functions determining

..records per key

Enabling derived keys optimization for derived.col = const pushed
conditions.

Estimating records per key in derived key for the optimizer
based on form and/or size of components of a derived table.

Consider a derived table of the form

SELECT ..., ROW_NUMBER ()  OVER (PARTITION BY c1,c2 order by ...)
FROM t1, t2, t3 ...
WHERE ...

If the optimizer generates a key on this derived table because of
a constraint being pushed into it, it currently will not consider key
components of the form  col = const

We lift this constraint and add code to TABLE::add_tmp_key to search
for a window function ROW_NUMBER().  From the partition list c1, c2 we
can in infer an estimate of the number of rows we expect to see for
each key value.  The optimizer can then use this number to determine
a better table join order.
Monty
Added pcre2-8 for embedded server
Jan Lindström
MDEV-39483 : Hang on mariabackup SST

This regression was caused by commit 794b1d0ec5c
Binlog-in-engine: New binlog implementation integrated in InnoDB.
Mariabackup request BACKUP STAGE BLOCK_COMMIT MDL-lock
using m_bs_con connection. Because we have wsrep,
write_galera_info is called using mysql_connection.
Note that m_bs_con and mysql_connection are different
connections. In write_galera_info write_current_binlog_file
is called and FLUSH BINLOG LOGS is executed. In reload_acl_and_cache
MDL_BACKUP_START MDL-lock is requested. Because we already
have conflicting MDL-lock for BLOCK_COMMIT in different THD
it has to wait. This wait ends on timeout and backup fails
causing mariabackup SST to fail and node will not join the cluster.

Fixed by using same connection for write_galera_info as for
BACKUP STAGE BLOCK_COMMIT i.e. m_bs_con.
Daniel Black
MDEV-36453 UBSAN: main.mysqltest - runtime error: null pointer

..passed as argument 2, which is declared to never be null
(dynstr_append_mem).

dynstr_append_mem, uses memcpy to append to the string which in the glibc
library is declared to not take null string as the src. Defensively we
declare dynstr_append_mem to not take a null argument too.

mariadb-test, to prevent it calling dynstr_append_mem with a null
mtr variable value, one that hasn't been initialized, we return an
error if the value is null. The result of this is the $6 in the test
case is never assigned a value and would error.

With this resolved, strchr, if the string isn't found, a null pointer is
returned. UBSAN will complain both about incrementing a pointer beyond
the boundary, and also incrementing if it is null.
Razvan Liviu Varzaru
Test trigger builders

Add section for test trigger builders
rusher
[misc] add maxscale testing to CI
Monty
Fixed failing union test in main.group_by

This failed in buildbot on amd64-ubuntu-2204-debug-ps
Oleksandr Byelkin
Merge branch 'bb-10.11-release' into bb-11.4-release
rusher
Fix handling of length_value for fixed-size temporal types after libmariadb CONC-812 change
Jan Lindström
MDEV-39429 : Galera test failures on 12.3
Mert Baran
MDEV-23987 Make udf_example.c portable and warning-free

Replace the bzero/strmov macro shim with direct memset()/strcpy()
calls and simplify the include block: always include <my_global.h>,
<my_pthread.h>, the standard C headers actually used, and <mysql.h>.
This removes the "bzero" redefinition warning triggered by the
previous STANDARD-vs-non-STANDARD ifdef split.

Fix the result-length computation in lookup() and reverse_lookup():
strcpy() returns the destination pointer, so the original
"strcpy(result, ...) - result" expression always evaluated to 0,
making both functions return empty strings.

Raise initid->max_length to 15 in lookup() and to 255 in
reverse_lookup(), and switch the dotted-quad path to snprintf. In
reverse_lookup()'s hostname copy, clamp the copy length to
initid->max_length - 1 so the NUL terminator fits.

Document avgcost, avg2, is_const and check_const_len in the header
comment block and add their CREATE/DROP FUNCTION examples.
rusher
[misc] Add MaxScale detection via @@maxscale_version variable +  maxscale-tag parameter to CI workflow.
Monty
MDEV-37070  Implement table options to enable/disable features

Added ADAPTIVE_HASH_INDEX=DEFAULT|YES|NO table and index option to InnoDB.
The table and index options only have an effect if InnoDB adaptive hash
index feature is enabled.

- Having the ADAPTIVE_HASH_INDEX TABLE option set to NO will disable
  adaptive hash index for all indexes in the table that do not have
  the index option adaptive_hash_index=yes.
- Having the ADAPTIVE_HASH_INDEX TABLE option set to YES will enable the
  adaptive hash index for all indexes in the table that do not have
  the index option adaptive_hash_index=no.
- Using adaptive_hash_index=default deletes the old setting.
- One can also use OFF/ON as the options. This is to make it work similar
  as other existing options.
- innodb.adaptive_hash_index has been changed from a bool to an enum with
  values OFF, ON and IF_SPECIFIED. If IF_SPECIFIED is used, adaptive
  hash index is only used for tables and indexes that specify
  adaptive_hash_index=on.
- The following new options can be used to further optimize adaptive hash
  index for an index (default is unset/auto for all of them):
  - complete_fields:
    - 0 to the number of columns the key is defined on (max 64)
  - bytes_from_incomplete_field:
    - This is only usable for memcmp()-comparable index fields, such as
      VARBINARY or INT. For example, a 3-byte prefix on an INT will
      return an identical hash value for 0‥255, another one for 256‥511,
      and so on.
    - Range is min 0 max 16383.
  - for_equal_hash_point_to_last_record:
    - Default is unset/auto, NO points to the first record, known as
      left_side in the code; YES points to the last record.
      Example: we have an INT column with the values 1,4,10 and bytes=3,
      will that hash value point to the record 1 or the record 10?
      Note: all values will necessarily have the same hash value
      computed on the big-endian byte prefix 0x800000, for all of the
      values 0x80000001, 0x80000004, 0x8000000a. InnoDB inverts the
      sign bit in order to have memcmp()-compatible comparison.

Example:
CREATE TABLE t1 (a int primary key, b varchar(100), c int,
index (b) adaptive_hash_index=no, index (c))
engine=innodb, adaptive_hash_index=yes;

Notable changes in InnoDB
- btr_search.enabled was changed from a bool to a ulong enum to be
  able to handle options OFF, ON and IF_SPECIFIED. ulong is needed
  to compile with MariaDB enum variables.
- To be able to find all instances where btr_search.enabled was used
  I changed all code to use btr_search.get_enabled() when accessing
  the value and used btr_search.is_enabled(index) to test if AHI is
  enabled for the index.
- btr_search.enable() was changed to always take two parameters,
  resize and value of enabled. This was needed as enabled can now
  have values OFF (0), ON (1), and IF_SPECIFIED (2).
- store all AHI-related options in per-index dict_index_t::ahi
  bit-packed 32-bit atomic field dict_index_t::ahi::enabled_fixed_mask
  - static assertions and debug assertions ensure that all options fit
    into the 32-bit field
  - packing details:
    - enabled, adaptive_hash_index (first 2 bits)
    - fields, complete_fields (7 bits)
    - bytes, bytes_from_incomplete_field (14 bits)
    - left, ~for_equal_hash_point_to_last_record (1 bit)
    - have_fields, fields set flag (1 bit)
    - have_bytes, bytes set flag (1 bit)
    - have_left, left set flag (last 1 bit)
    - 5 bits spare after have_left
  - manipulation of the bit-packed field avoids usage of branches or
    conditional instructions to minimize the performance impact of
    the new options
- in btr_search_update_hash_ref() apply the per-index AHI options
  using bit-masking to override internal heuristic values with user
  preferences
- add innodb.index_ahi_option test:
  - test a combination of per-table and per-index AHI options
  - use a stored procedure which checks if AHI is used during a burst of
    index lookups checking delta in adaptive_hash_searches InnoDB
    monitor variable
  - test that the maximum number of fields per (secondary) index is 64
    (32 PK + 32 secondary key columns)
  - test that crash recovery retains table/index metadata
  - test AHI with partitioned tables
  - verify that changing AHI preferences for table/index is instant DDL
  - boundary checks for complete_fields and bytes_from_incomplete_field
- add innodb.index_ahi_option_debug test:
  - test debug builds with index_ahi_option_debug_check debug variable
    enabled to verify that the proper per-index AHI options are applied
    during index lookups
  - test that "illegal" per-index AHI options are non-destructive and
    just lead to automatic parameter clamping and possibly no AHI usage
  - test toggling global AHI status with concurrent AHI access

Visible user changes:
- select @@global.adaptive_hash_index will now return a string instead
  of 0 or 1.

Other notable changes:
- In sql/create_options.cc:
  - In function set_one_value() avoid reading after the end of the
    current string.

Co-authored-by: Monty <[email protected]>
Co-authored-by: Marko Mäkelä <[email protected]>
Co-authored-by: Alessandro Vetere <[email protected]>
Co-authored-by: Thirunarayanan Balathandayuthapani <[email protected]>
PranavKTiwari
MDEV-38839: Fix assertion in close_thread_tables on CREATE TABLE...SELECT FOR UPDATE with MyISAM temp table in MIXED binlog mode

FOR UPDATE on a MyISAM temp table acquires TL_WRITE due to lack of
row-level locking, causing STMT_WRITES_TEMP_NON_TRANS_TABLE to be set
incorrectly for a read-only access in CREATE TABLE...SELECT FOR UPDATE.
This blocked binlog_truncate_trx_cache() in MIXED mode leaving row
events stranded in the cache and triggering the assertion.

Fix: In the binlog table access flag loop, set
STMT_READS_TEMP_NON_TRANS_TABLE instead of
STMT_WRITES_TEMP_NON_TRANS_TABLE for source temp tables in
CREATE TABLE...SELECT. Add stmt_writes_to_non_trans_temp_table() and
use it in MYSQL_BIN_LOG::write() instead of
stmt_accessed_non_trans_temp_table() to ensure
mark_modified_non_trans_temp_table() is called only for genuine writes.
Yuchen Pei
TODO-5776 [wip] Stubbing
rusher
[misc] update CI
rusher
[misc] add maxscale testing to CI
  • ccpp-linux-amd64-ubsan: build linux-connector_cpp failed -  stdio
Sergei Golubchik
MDEV-32745 followup for 7828fb475b0

* add a test for new --cat_file feature
* fix off-by-one error in --cat_file lines limit
* fix broken INCLUDE_DIRECTORIES in extra/
* fix typos
* remove mtr-specific workaround from the tool, solve it in the test
* remove dead code
* revert --silent-startup, it should not arbitrarily suppress individual
  warnings, it is defined to suppress [Note] and should stick to that.
  The tool doesn't need extra silence anyway.
* fixed memory leak in mariadbd --character_set_server=xxx
* fixed memory leak in mariadb-migration-config-file [client-server] section
Michael Widenius
MDEV-32745 Add a simple MySQL to MariaDB upgrade helper

The tool is named mariadb-migrate-config-file.
The main purpose of the tool is to change MySQL option
files to work both for MySQL and MariaDB.
There are options to do the changes in the options file inline,
or at-end-of-file. One can also remove or comment unknown options.

The list of supported options is generated compile time from
mariadbd --help. All server options, including compiled plugins, are
supported.

The bulk of the code comes from Väinö.
Monty has updated it with a lot of extra options.
Wlad helped with cmake integration

Other things:
- Fixed a memory leak in sql_plugin.cc
- plugin-load will now in case of errors try to load all given plugins
  before aborted
- If silent-startup is used, plugin-load will not give errors for
  plugins it cannot load or warnings about plugin marturity level.
- my_rm_tree() will now delete symlinks, not the actual file, if
  MY_NOSYMLINK flag is used.
- my_stat() will now give data for symlink if MY_NOSYMLINKS is used.
- Added 'number of lines' option to mysqltest --cat_file

@Authors: Väinö Mäkelä <[email protected]>,[email protected]
rusher
[CONCPP-152] Fix handling of length_value for fixed-size temporal types after libmariadb CONC-812 change
Marko Mäkelä
squash! 3618d807034cf6b9ed4531711c2ace07bcebe03a

log_t::write_checkpoint(): Enlarge the last log archive file if needed.

log_write_up_to(): Do call buf_flush_ahead() to ensure checkpoint
progress on log archive files.
Hemant Dangi
MDEV-39006: Galera test failure on galera_3nodes.galera_garbd_backup

Issue:
sst_disable_innodb_writes() promises no writes to persistent files
between Galera donor state and SST release, and most engine subsystems
already honour that (purge, dict_stats, encryption thread count, FTS
optimizer in fts0opt.cc:2844). The page cleaner did not:
buf_flush_page_cleaner()'s set_almost_idle: block ran
buf_dblwr.flush_buffered_writes() and log_checkpoint() unconditionally
on every wake-up. With LSN advanced past last_checkpoint_lsn (via any
prior background mtr - the most common one being a wsrep applier
writeset), log_checkpoint_low() then appended a fresh FILE_CHECKPOINT
record to ib_logfile0 mid-SST, breaking
galera_3nodes.galera_garbd_backup with a --diff_files mismatch.

Solution:
Add a wsrep_sst_disable_writes gate around those two writes, mirroring
the FTS pattern. In non-WSREP builds the flag is a constexpr false and
the check compiles away. This closes the page-cleaner leak; other
writers (wsrep apply paths, in-flight encryption rotation, ib_buffer_pool
dump) are separate concerns and out of scope.

Also assert !recv_no_log_write after log_write_up_to() in
log_checkpoint_low() so debug builds catch any future write path that
slips through.
Sergei Golubchik
MDEV-32745 followup for 7828fb475b0

* add a test for new --cat_file feature
* fix off-by-one error in --cat_file lines limit
* fix broken INCLUDE_DIRECTORIES in extra/
* fix typos
* remove mtr-specific workaround from the tool, solve it in the test
* remove dead code
* fixed memory leak in mariadb-migration-config-file [client-server] section
* fixed memory leak in mariadbd --character_set_server=xxx
  (execution time for main.mariadb-migrate-config-file went down
  from 150s to 2s)
* moved tool header to the tool dir
* avoid tripple-initialization of plugins
* disable tool builds in ASAN builds (because of RocksDB)
Monty
Fix compilation eror because of -Wframe-larger-than= in sql_show.cc

gcc 15.1.15 gives the following error, possible from static struct
initialization:

/my/maria-11.8/sql/sql_show.cc: In function ‘void __static_initialization_and_destruction_0()’:
/my/maria-11.8/sql/sql_show.cc:11356:1: error: the frame size of 62880 bytes is larger than 16384 bytes [-Werror=frame-larger-than=]

Fixed by adding PRAGMA_DISABLE_CHECK_STACK_FRAME to sql_show.cc
Sergei Golubchik
MDEV-32745 followup for 7828fb475b0

* add a test for new --cat_file feature
* fix off-by-one error in --cat_file lines limit
* fix broken INCLUDE_DIRECTORIES in extra/
* fix typos
* remove mtr-specific workaround from the tool, solve it in the test
* remove dead code
* fixed memory leak in mariadbd --character_set_server=xxx
* fixed memory leak in mariadb-migration-config-file [client-server] section
* moved tool header to the tool dir
* avoid tripple-initialization of plugins
rusher
[CI][macOS] Remove orphan libiodbc ls leftover from cpp-1.0 merge

Connector/C++ does not need libiodbc; the cmake invocation no longer
references ODBC paths and brew no longer installs libiodbc. The leftover
'ls -lrt /opt/homebrew/opt/libiodbc/lib' aborts the macOS job under
bash -e because the directory does not exist.
Marko Mäkelä
squash! a5eb56703467f082d7a15c83fe4d14ec66284381

log_t::write_checkpoint(): Enlarge the last log archive file if needed.

log_write_up_to(): Do call buf_flush_ahead() to ensure checkpoint
progress on log archive files.
Sergei Golubchik
MDEV-32745 followup for 7828fb475b0

* add a test for new --cat_file feature
* fix off-by-one error in --cat_file lines limit
* fix broken INCLUDE_DIRECTORIES in extra/
* fix typos
* remove mtr-specific workaround from the tool, solve it in the test
* remove dead code
* fixed memory leak in mariadb-migration-config-file [client-server] section
* fixed memory leak in mariadbd --character_set_server=xxx
  (execution time for main.mariadb-migrate-config-file went down
  from 150s to 2s)
* moved tool header to the tool dir
* avoid tripple-initialization of plugins
Lawrin Novitsky
Fix of UBSAN errors.

In one place copying from nullptr was possible. It could happen if the
streamed text resultset had to be cached(if the connection is requested
for other operation), and NULL value was present.
In couple of places int64_t could be overflown - had to be changed to
uint64 as it is defined plus othe implied changes.
In particular fetching MIN_INT64 value in text protocol could cause
that. Looks like all compilers work fine in this case as there is the
test for this.
rusher
[misc] add maxscale testing to CI
rusher
[misc] add maxscale testing to CI
Sergei Golubchik
MDEV-32745 followup for 7828fb475b0

* add a test for new --cat_file feature
* fix off-by-one error in --cat_file lines limit
* fix broken INCLUDE_DIRECTORIES in extra/
* fix typos
* remove mtr-specific workaround from the tool, solve it in the test
* remove dead code
* fixed memory leak in mariadbd --character_set_server=xxx
* fixed memory leak in mariadb-migration-config-file [client-server] section
* moved tool header to the tool dir
* avoid tripple-initialization of plugins
rusher
[misc] add maxscale testing to CI
Sergei Golubchik
find pcre2.h in a non-default location

for macos builder
Razvan Liviu Varzaru
Trigger CI