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
even more
Elena Stepanova
Test commit
Elena Stepanova
Test commit
Nikita Malyavin
Refactor REPLACE
Sergei Golubchik
and more
Dave Gosselin
MDEV-32397 join_read_first, keyread SEGV crash

Queries having the following form may cause a crash
  SELECT t1.a FROM ( SELECT a AS a1 FROM t1 ) dt
  JOIN t1 ON a1 LIKE EXISTS ( SELECT a + RAND () FROM t1 UNION SELECT a FROM t1);
because the table t1 has some cleanup operations performed prematurely
during the subselect, before the outer query has finished with the table.

In this particular case, the presence of RAND() makes the subquery
uncacheable, necessitating the need to execute the subquery multiple
times during join record evaluation.  Each time the subquery runs, it
creates its own JOIN structure which has references to the table t1.
When the subquery completes, JOIN::cleanup and functions called by it
result in ha_end_keyread() being called on table t1.  However, we are
not done with table t1 because the upper level `select t1.a from...`
query requires table t1 to be open.  To solve this, we make the executor
aware of when we're in subqueries like this and delay when we call
ha_end_keyread() until the end of the parent query.
Nikita Malyavin
MDEV-30046 Refactor and fix idempotent replication

Idempotent write_row works same as REPLACE: if there is a duplicating
record in the table, then it will be deleted and re-inserted, with the
same update optimization.

The code in Rows:log_event::write_row was basically copy-pasted from
write_record.

What's done:
REPLACE operation was unified across replication and sql. It is now
representred as two methods: locate and replace.

* locate_dup_record: find the conflicting record and save in in record[1].
  locating through dup_ref is used whenever possible. Locating by the key
  is now done though lookup_handler, if it exists. The reason is that
  duplicate error could be on the normal key, but RND could be inited.
* TABLE::replace_row: delete or update the conflicting row. It does not
  re-insert allowing to continue to general retry-loop of insertion.
  The result is described by replace_execution_result structure,
  containing the type of execution path chosen and a kind of error,
  allowing to treat it differently.
* Unify replace initialization step across implementations:
  add prepare_for_replace and finalize_replace

Drawbacks:
alloca is removed in favor of simple allocation. Anyway using alloca makes it
harder to catch stack overflows related to maximally long
fields. A simple stack allocation of MAX_KEY could be used, but better not
to abuse the stack.
Now there is a memory leak with the statement duration. It'll be fixed a
bit later, in the next refactoring.
Daniele Sciascia
MDEV-33216 stack-use-after-return in Wsrep_schema_impl::open_table()

Fix a case of stack-use-after-return reported by ASAN in
Wsrep_schema_impl::open_table(). This function has a stack allocated
TABLE_LIST object and return TABLE_LIST::table to the caller.
Changed the function to take a TABLE_LIST pointer as argument.

Signed-off-by: Julius Goryavsky <[email protected]>
Elena Stepanova
Test commit
Nikita Malyavin
MDEV-30046 wrong row targeted with "insert ... on duplicate" and "replace"

When HA_DUPLICATE_POS is not supported, the row to replace was navigated by
ha_index_read_idx_map, which uses only hash to navigate.

Suchwise, given a hash collision it may choose an incorrect row.

handler::position would be correct and very convenient to use here.
The code is updated to set dup_ref by a handler independently of engine
capabilities, when extra lookup is made (for long unique or something else,
for example WITHOUT OVERLAPS)

REPLACE works correctly with this regard, however there are other cases yet
uncovered: LOAD DATA and replication with IDEMPOTENT mode. They will be
fixed by a follow-up, after refactoring.
Elena Stepanova
Test commit
Monty
Fixed memory leaks in embedded server and mysqltest

This commit fixes the following issues:
- memory leak checking enabled for mysqltest. This cover all cases except
  calls to 'die()' that only happens in case of internal failures in
  mysqltest. die() is not called anymore in the result files differs.
- One can now run mtr --embedded without failures (this crashed or hang
  before)
- cleanup_and_exit() has a new parameter that indicates that it is called
  from die(), in which case we should not do memory leak checks. We now
  always call cleanup_and_exit() instead of exit() to be able to free up
  memory and discover memory leaks.
- Lots of new assert to catch error conditions
- More DBUG statements.
- Fixed that all results are freed in mysqltest (Fixed a memory leak in
  mysqltest when using prepared statements).
- Fixed race condition in do_stmt_close() that caused embedded server
  to not free memory. (Memory leak in mysqltest with embedded server).
- Fixed two memory leaks in embedded server when using prepared statements.
  These memory leaks caused timeout hangs in mtr when server was compiled
  with safemalloc. This issue was not noticed (except as timeouts) as
  memory report checking was done but output of it was disabled.
Sergei Golubchik
and more
Nikita Malyavin
Refactor REPLACE
Sergei Golubchik
innodb.innodb_defrag_stats wait for the correct value

failed on amd64-centos-stream8
Sergei Golubchik
and more
Sergei Golubchik
perfschema.misc debugging
Sergei Golubchik
more debugging
Sergei Golubchik
and more
Nikita Malyavin
Refactor REPLACE
Sergei Golubchik
rpl.rpl_domain_id_filter_master_crash failed on msan builder

it seems that the test can get IO thread running or not,
there's a comment about it. Thus stop_slave_io.inc is told
to ignore errors.

Make stop_slave_io.inc also disable warnings in this case,
in particular "1255 Slave already has been stopped"
Elena Stepanova
Test commit
Sergei Golubchik
innodb.monitor test: wait for the correct value

on a busy system it might take time for buffer_page_written_index_leaf
to reach the correct value. Wait for it.

also, tag identical statements to be different in the result file.
Elena Stepanova
Test commit
Elena Stepanova
Test commit
Nikita Malyavin
Refactor REPLACE
Sergei Golubchik
MDEV-22955 innodb.innodb-alter fails in buildbot with extra warning

add 10.5-specific global suppression.
the extra warning is gone in 10.6
Vlad Lesin
MDEV-33757 Get rid of TrxUndoRsegs code

TrxUndoRsegs is wrapper for vector of trx_rseg_t*. It has two
constructors, both initialize the vector with only one element. And they
are used to push transactions rseg(the singular) to purge queue. There is
no function to add elements to the vector. The default constructor is used
only for declaration of NullElement.

The TrxUndoRsegs was introduced in WL#6915 in MySQL 5.7 and. MySQL 5.7
would unnecessarily let the purge of history parse the
temporary undo records, and then look up the table (via a global hash
table), and only at the point of processing the parsed undo log record
determine that the table is a temporary table and the undo record must be
thrown away.

In MariaDB 10.2 we have two disjoint sets of rollback segments (128 for
persistent, 128 for temporary), and purge does not even see the temporary
tables. The only reason why temporary tables are visible to other threads
is a SQL layer bug (MDEV-17805).

purge_sys_t::choose_next_log(): merge the relevant part
of TrxUndoRsegsIterator::set_next() to the start of
purge_sys_t::choose_next_log().

purge_sys_t::rseg_get_next_history_log(): add a tail call of
purge_sys_t::choose_next_log() and adjust the callers, to simplify the
control flow further.

purge_sys.pq_mutex and purge_sys.purge_queue: make it private by adding
some simple accessor function.

trx_purge_cleanse_purge_queue(): make it a member of purge_sys_t to have
have access to private purge_sys.pq_mutex and purge_sys.purge_queue,
simplify the code with using simple array copy and clearing purge queue
instead of poping each purge queue element.

Thanks Marko Mäkelä for historical overview of TrxUndoRsegs development.

Reviewed by: Marko Mäkelä
Sergei Golubchik
mtr: increase timeouts under ASAN/UBSAN/MSAN

not only under valgrind
Sergei Golubchik
even more
Sergei Golubchik
mtr: increase timeouts under ASAN/UBSAN/MSAN

not only under valgrind
Sergei Golubchik
and more
Elena Stepanova
Test commit
Julius Goryavsky
MDEV-33677 : Port Performance Schema for Galera from ES

Added performance schema tables for Galera.
This is a port of the code from ES 10.6

Refs:
MENT-346  commit 86c06851
MENT-346  commit 10d0fcaf
MENT-1333 commit 2005adc3
MENT-347  commit aaca43b4
MENT-1370 commit 1f460e6b
  • kvm-rpm-centos74-amd64: make rpms failed -  stdiokernel
Sergei Golubchik
more debugging
Sergei Golubchik
perfschema.misc debugging
Sergei Golubchik
perfschema is disabled until it's enabled

as it was thinking it was enabled even if initialize_performance_schema
wasn't called at all
Brandon Nesterenko
MDEV-33672: Gtid_log_event Construction from File Should Ensure Event Length When Using Extra Flags

A GTID event can have variable length, with contributing factors
such as the variable length from the flags2 and optional extra flags
fields. These fields are bitmaps, where each set bit indicates an
additional value that should be appended to the event, e.g.
multi-engine transactions append a number to indicate the number of
additional engines a transaction uses. However, if a flags bit is
set, and no additional fields are appended to the event, MDEV-33672
reports that the server can still try to read from memory as if it
did exist. Note, however, in debug builds, this condition is
asserted for FL_EXTRA_MULTI_ENGINE.

This patch fixes this to check that the length of the event is
aligned with the expectation set by the flags for FL_PREPARED_XA,
FL_COMPLETED_XA, and FL_EXTRA_MULTI_ENGINE.

Reviewed By:
============
Kristian Nielsen <[email protected]>
Monty
Fixed memory leaks in embedded server and mysqltest

This commit fixes the following issues:
- memory leak checking enabled for mysqltest. This cover all cases except
  calls to 'die()' that only happens in case of internal failures in
  mysqltest. die() is not called anymore in the result files differs.
- One can now run mtr --embedded without failures (this crashed or hang
  before)
- cleanup_and_exit() has a new parameter that indicates that it is called
  from die(), in which case we should not do memory leak checks. We now
  always call cleanup_and_exit() instead of exit() to be able to free up
  memory and discover memory leaks.
- Lots of new assert to catch error conditions
- More DBUG statements.
- Fixed that all results are freed in mysqltest (Fixed a memory leak in
  mysqltest when using prepared statements).
- Fixed race condition in do_stmt_close() that caused embedded server
  to not free memory. (Memory leak in mysqltest with embedded server).
- Fixed two memory leaks in embedded server when using prepared statements.
  These memory leaks caused timeout hangs in mtr when server was compiled
  with safemalloc. This issue was not noticed (except as timeouts) as
  memory report checking was done but output of it was disabled.
Elena Stepanova
Test commit