summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* MDEV-21962 Allocate buf_pool staticallyMarko Mäkelä2020-03-1829-2168/+1873
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Thanks to MDEV-15058, there is only one InnoDB buffer pool. Allocating buf_pool statically removes one level of pointer indirection and makes code more readable, and removes the awkward initialization of some buf_pool members. While doing this, we will also declare some buf_pool_t data members private and replace some functions with member functions. This is mostly affecting buffer pool resizing. This is not aiming to be a complete rewrite of buf_pool_t to a proper class. Most of the buffer pool interface, such as buf_page_get_gen(), will remain in the C programming style for now. buf_pool_t::withdrawing: Replaces buf_pool_withdrawing. buf_pool_t::withdraw_clock_: Replaces buf_withdraw_clock. buf_pool_t::create(): Repalces buf_pool_init(). buf_pool_t::close(): Replaces buf_pool_free(). buf_bool_t::will_be_withdrawn(): Replaces buf_block_will_be_withdrawn(), buf_frame_will_be_withdrawn(). buf_pool_t::clear_hash_index(): Replaces buf_pool_clear_hash_index(). buf_pool_t::get_n_pages(): Replaces buf_pool_get_n_pages(). buf_pool_t::validate(): Replaces buf_validate(). buf_pool_t::print(): Replaces buf_print(). buf_pool_t::block_from_ahi(): Replaces buf_block_from_ahi(). buf_pool_t::is_block_field(): Replaces buf_pointer_is_block_field(). buf_pool_t::is_block_mutex(): Replaces buf_pool_is_block_mutex(). buf_pool_t::is_block_lock(): Replaces buf_pool_is_block_lock(). buf_pool_t::is_obsolete(): Replaces buf_pool_is_obsolete(). buf_pool_t::io_buf: Make default-constructible. buf_pool_t::io_buf::create(): Delayed 'constructor' buf_pool_t::io_buf::close(): Early 'destructor' HazardPointer: Make default-constructible. Define all member functions inline, also for derived classes.
* MDEV-21975 Add BINLOG REPLAY privilege and bind new privileges to ↵Alexander Barkov2020-03-1831-65/+645
| | | | gtid_seq_no, preudo_thread_id, server_id, gtid_domain_id
* MDEV-21966: Fix clang -Winconsistent-missing-overrideMarko Mäkelä2020-03-181-7/+7
|
* MDEV-21973 Bind REPLICATION {MASTER|SLAVE} ADMIN to gtid_* GLOBAL-only ↵Alexander Barkov2020-03-1815-4/+423
| | | | system variables
* merge 10.4 to 10.5Monty2020-03-1873-481/+730
|\
| * Fixed that caused failure in --ps binlog_encryption.rpl_gtid_basicMonty2020-03-172-3/+7
| | | | | | | | | | Problem was that replace_dynstr_append_mem() assumed strings are null terminated which is not always the case.
| * MDEV-21932 A fast plan with ROR index-merge is ignored whenbb-10.4-monty3Igor Babaev2020-03-173-0/+95
| | | | | | | | | | | | | | | | | | 'index_merge_sort_union=off' When index_merge_sort_union is set to 'off' and index_merge_union is set to 'on' then any evaluated index merge scan must consist only of ROR scans. The cheapest out of such index merges must be chosen. This index merge might not be the cheapest index merge.
| * Removed double records_in_range calls from multi_range_read_info_constMonty2020-03-1768-483/+634
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This was to remove a performance regression between 10.3 and 10.4 In 10.5 we will have a better implementation of records_in_range that will enable us to get more statistics. This change was not done in 10.4 because the 10.5 will be part of a larger change that is not suitable for the GA 10.4 version Other things: - Changed default handler block_size to 8192 to fix things statistics for engines that doesn't set the block size. - Fixed a bug in spider when using multiple part const ranges (Patch from Kentoku)
| * MDEV-18439 Windows builds should have core_file=1 by defaultVladislav Vaintroub2020-03-171-1/+1
| | | | | | | | | | | | | | | | It did not work, eventhough the default for Windows was changed to 1 for the corresponding system variable. This be because test_flags was zeroed mysql_init_variables. The patch fixes this glitch.
* | MDEV-21972 Bind REPLICATION MASTER ADMIN to master_verify_checksumAlexander Barkov2020-03-184-1/+61
| |
* | MDEV-21971 Bind BINLOG ADMIN to binlog_annotate_row_events and ↵Alexander Barkov2020-03-187-2/+165
| | | | | | | | binlog_row_image global and session variables
* | MDEV-21969 Bind REPLICATION SLAVE ADMIN to relay_log_*, sync_master_info, ↵Alexander Barkov2020-03-1812-5/+301
| | | | | | | | sync_relay_log, sync_relay_log_info
* | MDEV-21967 Bind REPLICATION {MASTER|SLAVE} ADMIN to rpl_semi_sync_* variablesAlexander Barkov2020-03-1820-9/+546
| |
* | MDEV-21966 Bind REPLICATION SLAVE ADMIN to a number of global system variablesAlexander Barkov2020-03-1851-27/+1392
| |
* | MDEV-21963 Bind BINLOG ADMIN to a number of global system variablesAlexander Barkov2020-03-1731-14/+910
| |
* | MDEV-21961 Bind CONNECTION ADMIN to a number of global system variablesAlexander Barkov2020-03-1730-21/+1531
| |
* | MDEV-21960 Bind READ_ONLY ADMIN to @@read_onlyAlexander Barkov2020-03-176-2/+115
| |
* | MDEV-21957 Bind BINLOG ADMIN to @@binlog_format, @@binlog_direct_.., ↵Alexander Barkov2020-03-1714-19/+347
| | | | | | | | @@sql_log_bin
* | Merge 10.4 into 10.5Marko Mäkelä2020-03-1717-96/+220
|\ \ | |/
| * MDEV-16188: Fix clang 10 -Wimplicit-int-float-conversionMarko Mäkelä2020-03-161-1/+2
| | | | | | | | | | | | mi_records_in_range(): Because HA_POS_ERROR cannot be accurately represented in double (it will be off by one), add an explicit cast to silence the warning.
| * MDEV-5313: Fix GCC 10 -Wenum-conversionMarko Mäkelä2020-03-161-1/+9
| |
| * Merge 10.3 into 10.4Marko Mäkelä2020-03-1620-98/+430
| |\
| | * MDEV-13134/MDEV-21855: Add a test caseMarko Mäkelä2020-03-162-0/+147
| | |
| | * Merge 10.2 into 10.3Marko Mäkelä2020-03-1318-104/+283
| | |\
| | | * Fix GCC 10.0 -Wstringop-overflowMarko Mäkelä2020-03-131-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | myrg_open(): Reduce the scope of the variable 'end' and simplify the code. For some reason, I got no warning for this code in the 10.2 branch, only 10.3 or later. The ENGINE=MERGE is covered by the tests main.merge, main.merge_debug, and main.merge-big.
| | | * MDEV-10047: table-based master info repositorySujatha2020-03-133-1/+220
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: ======= When we upgrade from "mysql" to "mariadb" if slave is using repositories as tables their data is completely ignored and no warning is issued in error log. Fix: === "mysql_upgrade" test should check for the presence of data in "mysql.slave_master_info" and "mysql.slave_relay_log_info" tables. When tables have some data the upgrade script should report a warning which hints users that the data in repository tables will be ignored.
| | | * Fix clang 10 warningsMarko Mäkelä2020-03-132-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | _ma_fetch_keypage(): Correct an assertion that used to always hold. Thanks to clang -Wint-in-bool-context for flagging this. double_to_datetime_with_warn(): Suppress -Wimplicit-int-float-conversion by adding a cast. LONGLONG_MAX converted to double will actually be LONGLONG_MAX+1.
| | | * MDEV-21933 INFORMATION_SCHEMA.INNODB_SYS_TABLESPACES accesses SYS_DATAFILESMarko Mäkelä2020-03-133-28/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All tablespace metadata is buffered in fil_system. There is a LRU mechanism, but that only controls the opening and closing of fil_node_t::handle. It is much more efficient and less error-prone to access data file names by looking up the fil_space_t object rather than by essentially joining each row with an access to SYS_DATAFILES via the InnoDB internal SQL parser. dict_get_first_path(): Declare static. The function may only be needed when loading or updating the data dictionary. Also, change a condition in order to avoid a bogus GCC 10 -Wstringop-overflow warning for mem_strdupl() about len==ULINT_UNDEFINED. i_s_sys_tablespaces_fill_table(): Do not access other InnoDB internal dictionary tables than SYS_TABLESPACES.
| | | * Fix GCC 10 -Wclass-memaccessMarko Mäkelä2020-03-131-1/+1
| | | |
| | | * Fix GCC 10 -Wstringop-truncationMarko Mäkelä2020-03-131-0/+2
| | | |
| | | * Update libmariadbMarko Mäkelä2020-03-131-0/+0
| | | | | | | | | | | | | | | | This fixes GCC 10.0.1 -Wstringop-truncation and some typos.
| | | * Merge 10.1 into 10.2Marko Mäkelä2020-03-138-92/+53
| | | |\
| | | | * Merge 5.5 into 10.1Marko Mäkelä2020-03-131-7/+7
| | | | |\
| | | | | * Cleanup: clang-10 -Wmisleading-indentationMarko Mäkelä2020-03-111-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also, remove some trailing white space and add missing static qualifier to free_annotate_event().
| | | | * | MDEV-21918 improve page_zip_verify_checksum()Eugene Kosov2020-03-112-44/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | actually, page_zip_verify_checksum() generally allows all-zeroes checksums because our CRC32 checksum is something like crc_1 ^ crc_2 ^ crc_3 Also, all zeroes page is considered correct. As a side effect fix nasty reinterpret_cast<> UB Also, since c0f47a4a5842 innodb_checksum_algorithm=full_crc32 exists which computes CRC32 in one go (without bitwise arithmetic)
| | | | * | fix typedef-related warning and cleanup using namespace stdEugene Kosov2020-03-116-11/+9
| | | | | |
| | | | * | Fix compile warning:Sergei Petrunia2020-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It was: implicit conversion from 'ha_rows' (aka 'unsigned long long') to 'double' changes value from 18446744073709551615 to 18446744073709551616 Follow what JOIN::get_examined_rows() does for similar code.
| | | * | | InnoDB: improve error message for checksum mismatchEugene Kosov2020-03-121-1/+2
| | | | | |
| | | * | | Add galera debug sync to galera_slave_replay test.Jan Lindström2020-03-111-1/+2
| | | | | |
| | * | | | Add galera debug sync to galera_slave_replay test.Jan Lindström2020-03-121-1/+2
| | | | | |
| | * | | | Fixed wrong assert (found by clang)Monty2020-03-111-1/+1
| | | | | |
| * | | | | MDEV-21599 plugins.server_audit fails sporadically in buildbotSergei Golubchik2020-03-141-0/+3
| | | | | |
* | | | | | perfschema: remove unused variablesMarko Mäkelä2020-03-171-6/+3
| | | | | |
* | | | | | Fix the build on big-endian systemsMarko Mäkelä2020-03-171-15/+17
|\ \ \ \ \ \
| * | | | | | Fix compile on all big endian related to innodb:ut_crc32_swap_byteorderDaniel Black2020-03-171-15/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move function ut_crc32_swap_byteorder to a non-x86 #ifdef area. As its only used in BIGENDIAN, use #ifdefs around ut_crc32_swap_byteorder. Travis CI and Debian both include s390x in builds/test, which is big endian. Fixes commit: 1312b4ebb652
* | | | | | | MDEV-21956 Add class Sys_var_charptr_fscsAlexander Barkov2020-03-174-141/+130
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Simplifying definitions on Sys_var_charptr*: - Removing sys_var::is_os_charset - Adding a new class Sys_var_charptr_fscs, to handle system variables with character_set_filesystem.
* | | | | | | Cleanup: Remove an unused variableMarko Mäkelä2020-03-161-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | log_write_buf(): Remove the unused variable write_header. The dependent code was removed in commit 0c2365c4e3c89c3b284315e19a7d95221b524868. That was dead or unnecessary code at least ever since commit 9ef2d29ff44de2013c95666a011b993e5c2e5674 removed the support for innodb_log_files_in_group>1.
* | | | | | | MDEV-21949 key rotation for innodb_encrypt_log is not working in 10.5Eugene Kosov2020-03-162-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | log_t::has_encryption_key_rotation(): checks whether key rotation is supported. In a subsequent redo log format version, this key rotation may be broken again.
* | | | | | | cleanup redo logEugene Kosov2020-03-163-46/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Write log header just ones when file is created, instead of writing to it on every log file wrap around. log_t::file::write_header_durable(): this one writes to log header log_write_buf(): this one stops writing to log header
* | | | | | | cleanup redo logEugene Kosov2020-03-161-20/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | move statistics modification into one place