1. 24 Mar, 2020 20 commits
    • Michael Widenius's avatar
    • Monty's avatar
      Fixed typo in aria_s3_copy · 44790f58
      Monty authored
      44790f58
    • Monty's avatar
      3775e7cc
    • Monty's avatar
      Speed up writing to encrypted binlogs · 120b73a0
      Monty authored
      MDEV-21604
      
      Added "virtual" low level write function encrypt_or_write that is set
      to point to either normal or encrypted write functions.
      
      This patch also fixes a possible memory leak if writing to binary log fails.
      120b73a0
    • Monty's avatar
      Clean up and speed up interfaces for binary row logging · 91ab42a8
      Monty authored
      MDEV-21605 Clean up and speed up interfaces for binary row logging
      MDEV-21617 Bug fix for previous version of this code
      
      The intention is to have as few 'if' as possible in ha_write() and
      related functions. This is done by pre-calculating once per statement the
      row_logging state for all tables.
      
      Benefits are simpler and faster code both when binary logging is disabled
      and when it's enabled.
      
      Changes:
      - Added handler->row_logging to make it easy to check it table should be
        row logged. This also made it easier to disabling row logging for system,
        internal and temporary tables.
      - The tables row_logging capabilities are checked once per "statements
        that updates tables" in THD::binlog_prepare_for_row_logging() which
        is called when needed from THD::decide_logging_format().
      - Removed most usage of tmp_disable_binlog(), reenable_binlog() and
        temporary saving and setting of thd->variables.option_bits.
      - Moved checks that can't change during a statement from
        check_table_binlog_row_based() to check_table_binlog_row_based_internal()
      - Removed flag row_already_logged (used by sequence engine)
      - Moved binlog_log_row() to a handler::
      - Moved write_locked_table_maps() to THD::binlog_write_table_maps() as
        most other related binlog functions are in THD.
      - Removed binlog_write_table_map() and binlog_log_row_internal() as
        they are now obsolete as 'has_transactions()' is pre-calculated in
        prepare_for_row_logging().
      - Remove 'is_transactional' argument from binlog_write_table_map() as this
        can now be read from handler.
      - Changed order of 'if's in handler::external_lock() and wsrep_mysqld.h
        to first evaluate fast and likely cases before more complex ones.
      - Added error checking in ha_write_row() and related functions if
        binlog_log_row() failed.
      - Don't clear check_table_binlog_row_based_result in
        clear_cached_table_binlog_row_based_flag() as it's not needed.
      - THD::clear_binlog_table_maps() has been replaced with
        THD::reset_binlog_for_next_statement()
      - Added 'MYSQL_OPEN_IGNORE_LOGGING_FORMAT' flag to open_and_lock_tables()
        to avoid calculating of binary log format for internal opens. This flag
        is also used to avoid reading statistics tables for internal tables.
      - Added OPTION_BINLOG_LOG_OFF as a simple way to turn of binlog temporary
        for create (instead of using THD::sql_log_bin_off.
      - Removed flag THD::sql_log_bin_off (not needed anymore)
      - Speed up THD::decide_logging_format() by remembering if blackhole engine
        is used and avoid a loop over all tables if it's not used
        (the common case).
      - THD::decide_logging_format() is not called anymore if no tables are used
        for the statement. This will speed up pure stored procedure code with
        about 5%+ according to some simple tests.
      - We now get annotated events on slave if a CREATE ... SELECT statement
        is transformed on the slave from statement to row logging.
      - In the original code, the master could come into a state where row
        logging is enforced for all future events if statement could be used.
        This is now partly fixed.
      
      Other changes:
      - Ensure that all tables used by a statement has query_id set.
      - Had to restore the row_logging flag for not used tables in
        THD::binlog_write_table_maps (not normal scenario)
      - Removed injector::transaction::use_table(server_id_type sid, table tbl)
        as it's not used.
      - Cleaned up set_slave_thread_options()
      - Some more DBUG_ENTER/DBUG_RETURN, code comments and minor indentation
        changes.
      - Ensure we only call THD::decide_logging_format_low() once in
        mysql_insert() (inefficiency).
      - Don't annotate INSERT DELAYED
      - Removed zeroing pos_in_table_list in THD::open_temporary_table() as it's
        already 0
      91ab42a8
    • Monty's avatar
      Fixed valgrind warning · f51df1dc
      Monty authored
      f51df1dc
    • Monty's avatar
      Improve update handler (long unique keys on blobs) · 4ef43755
      Monty authored
      MDEV-21606 Improve update handler (long unique keys on blobs)
      MDEV-21470 MyISAM and Aria start_bulk_insert doesn't work with long unique
      MDEV-21606 Bug fix for previous version of this code
      MDEV-21819 2 Assertion `inited == NONE || update_handler != this'
      
      - Move update_handler from TABLE to handler
      - Move out initialization of update handler from ha_write_row() to
        prepare_for_insert()
      - Fixed that INSERT DELAYED works with update handler
      - Give an error if using long unique with an autoincrement column
      - Added handler function to check if table has long unique hash indexes
      - Disable write cache in MyISAM and Aria when using update_handler as
        if cache is used, the row will not be inserted until end of statement
        and update_handler would not find conflicting rows.
      - Removed not used handler argument from
        check_duplicate_long_entries_update()
      - Syntax cleanups
        - Indentation fixes
        - Don't use single character indentifiers for arguments
      4ef43755
    • Monty's avatar
      Cleanups & indentation changes · 736998cb
      Monty authored
      - Only indentation changes in sql_rename.cc
      - Ignore some WSREP error messages when there isn't a internet connection
      - Force restart of stat_tables_part.test to make result stable
      - Fixed compiler warnings in CONNECT
      736998cb
    • Monty's avatar
      Added support for replication for S3 · 6a9e24d0
      Monty authored
      MDEV-19964 S3 replication support
      
      Added new configure options:
      s3_slave_ignore_updates
      "If the slave has shares same S3 storage as the master"
      
      s3_replicate_alter_as_create_select
      "When converting S3 table to local table, log all rows in binary log"
      
      This allows on to configure slaves to have the S3 storage shared or
      independent from the master.
      
      Other thing:
      Added new session variable '@@sql_if_exists' to force IF_EXIST to DDL's.
      6a9e24d0
    • Monty's avatar
      Ignore mariadb-config.1 · e5de1e26
      Monty authored
      e5de1e26
    • Sergey Vojtovich's avatar
      handler::rebind() · da82e759
      Sergey Vojtovich authored
      - rename PFS specific rebind_psi() to generic rebind()
      - call rebind independently of PFS compilation status
      - allow rebind() return an error
      da82e759
    • Monty's avatar
      Added IF EXISTS to RENAME TABLE and ALTER TABLE · bff79492
      Monty authored
      bff79492
    • Marko Mäkelä's avatar
      Merge 10.4 into 10.5 · 5f5c63e0
      Marko Mäkelä authored
      5f5c63e0
    • mkaruza's avatar
      MDEV-21988: Assertion failure mysqld: bool trans_commit_stmt(THD*): Assertion... · a940151e
      mkaruza authored
      MDEV-21988: Assertion failure mysqld: bool trans_commit_stmt(THD*): Assertion `thd->in_active_multi_stmt_transaction() || thd->m_transaction_psi == __null' failed. (#1476)
      
      Set temporary `SERVER_STATUS_IN_TRANS` so assert is not triggered in `trans_commit_stmt`.
      a940151e
    • Marko Mäkelä's avatar
      Fix clang -Wsometimes-uninitialized · efc97eff
      Marko Mäkelä authored
      efc97eff
    • Marko Mäkelä's avatar
      MDEV-22020: Fix spider/bugfix.return_found_rows_update · 8b647d69
      Marko Mäkelä authored
      The test failed to specify default-character-set when
      invoking the client. The compile-time default parameters of the
      client could be overridden by configuration files in /etc/mysql.
      Let us explicitly specify --default-character-set.
      8b647d69
    • Sergei Golubchik's avatar
    • Rasmus Johansson's avatar
      MDEV-22009 mysqlhotcopy tool and wsrep scripts not found · 79b89017
      Rasmus Johansson authored
      main.mysqlhotcopy_myisam cannot find mysqlhotcopy tool
      
      wsrep scripts are not executable in CMAKE_CURRENT_BINARY_DIR
      79b89017
    • Sergei Golubchik's avatar
      MDEV-22003 mysql_config disappeared from 10.5 (e.g. binary tarball or source build) · e4afd3c3
      Sergei Golubchik authored
      * generate and install mysql_config
      * symlink mariadb_config (from C/C) to mariadb-config
      
      also:
      * .gitignore generated mariadb-config.1
      * remove obsolete compiler flag from C/C
      e4afd3c3
    • Sergei Golubchik's avatar
      Revert "MDEV-21303 Make executables MariaDB named" · 73edb6ff
      Sergei Golubchik authored
      This reverts commit 5d1b8f41.
      
      because since 306e439c manpages use troff aliases
      instead of symlinks, so they should not be symlinked.
      73edb6ff
  2. 23 Mar, 2020 14 commits
  3. 21 Mar, 2020 6 commits