- 07 Dec, 2017 6 commits
-
-
Jan Lindström authored
-
Jan Lindström authored
MDEV-14401: Stored procedure that declares a handler that catches ER_LOCK_DEADLOCK error causes thd->is_error() assertion This was missing bug fix from MySQL wsrep i.e. Galera. Problem was that if stored procedure declares a handler that catches deadlock error, then the error may have been cleared in method sp_rcontext::handle_sql_condition(). Use wsrep_conflict_state correctly to determine is the error already sent to client. Add test case for both this bug and MDEV-12837: WSREP: BF lock wait long. Test requires both fixes to pass.
-
Jan Lindström authored
Problem was a merge error from MySQL wsrep i.e. Galera. wsrep_on_check New check function. Galera can't be enabled if innodb-lock-schedule-algorithm=VATS. innobase_kill_query In Galera async kill we could own lock mutex. innobase_init If Variance-Aware-Transaction-Sheduling Algorithm (VATS) is used on Galera we fall back to First-Come-First-Served (FCFS) with notice to user. Changed innodb-lock-schedule-algorithm as read-only parameter as it was designed to be. lock_reset_lock_and_trx_wait Use ib::hex() to print out transaction ID. lock_rec_other_has_expl_req, lock_rec_other_has_conflicting, RecLock::add_to_waitq lock_rec_lock_slow lock_table_other_has_incompatible lock_rec_insert_check_and_lock lock_prdt_other_has_conflicting Change pointer to conflicting lock to normal pointer as this pointer contents could be changed later. RecLock::create Conclicting lock pointer is moved to last parameter with default value NULL. This conflicting transaction could be selected as victim in Galera if requesting transaction is BF (brute force) transaction. In this case contents of conflicting lock pointer will be changed. Use ib::hex() to print transaction ids.
-
Monty authored
Increase the number of status variabels that can be handled
-
Marko Mäkelä authored
-
Marko Mäkelä authored
dict_stats_process_entry_from_defrag_pool(): Release the mutex
-
- 06 Dec, 2017 9 commits
-
-
Marko Mäkelä authored
Follow-up fix to MDEV-13201 Assertion `srv_undo_sources || ...` failed on shutdown during DDL operation Introduce the debug flag trx_t::persistent_stats to suppress the assertion for the updates of persistent statistics during fast shutdown. dict_stats_exec_sql(): Do execute the statement even though shutdown has been initiated.
-
Marko Mäkelä authored
dict_stats_exec_sql(): Expect the caller to always provide a transaction. Remove some redundant assertions. The caller must hold dict_sys->mutex, but holding dict_operation_lock is only necessary for accessing data dictionary tables, which we are not accessing. dict_stats_save_index_stat(): Acquire dict_sys->mutex for invoking dict_stats_exec_sql(). dict_stats_save(), dict_stats_update_for_index(), dict_stats_update(), dict_stats_drop_index(), dict_stats_delete_from_table_stats(), dict_stats_delete_from_index_stats(), dict_stats_drop_table(), dict_stats_rename_in_table_stats(), dict_stats_rename_in_index_stats(), dict_stats_rename_table(): Use a single caller-provided transaction that is started and committed or rolled back by the caller. dict_stats_process_entry_from_recalc_pool(): Let the caller provide a transaction object. ha_innobase::open(): Pass a transaction to dict_stats_init(). ha_innobase::create(), ha_innobase::discard_or_import_tablespace(): Pass a transaction to dict_stats_update(). ha_innobase::rename_table(): Pass a transaction to dict_stats_rename_table(). We do not use the same transaction as the one that updated the data dictionary tables, because we already released the dict_operation_lock. (FIXME: there is a race condition; a lock wait on SYS_* tables could occur in another DDL transaction until the data dictionary transaction is committed.) ha_innobase::info_low(): Pass a transaction to dict_stats_update() when calculating persistent statistics. alter_stats_norebuild(), alter_stats_rebuild(): Update the persistent statistics as well. In this way, a single transaction will be used for updating the statistics of a whole table, even for partitioned tables. ha_innobase::commit_inplace_alter_table(): Drop statistics for all partitions when adding or dropping virtual columns, so that the statistics will be recalculated on the next handler::open(). This is a refactored version of Oracle Bug#22469660 fix. RecLock::add_to_waitq(), lock_table_enqueue_waiting(): Do not allow a lock wait to occur for updating statistics in a data dictionary transaction, such as DROP TABLE. Instead, return the previously unused error code DB_QUE_THR_SUSPENDED. row_merge_lock_table(), row_mysql_lock_table(): Remove dead code for handling DB_QUE_THR_SUSPENDED. row_drop_table_for_mysql(), row_truncate_table_for_mysql(): Drop the statistics as part of the data dictionary transaction. After TRUNCATE TABLE, the statistics will be recalculated on subsequent ha_innobase::open(), similar to how the logic after the above-mentioned Oracle Bug#22469660 fix in ha_innobase::commit_inplace_alter_table() works. btr_defragment_thread(): Use a single transaction object for updating defragmentation statistics. dict_stats_save_defrag_stats(), dict_stats_save_defrag_stats(), dict_stats_process_entry_from_defrag_pool(), dict_defrag_process_entries_from_defrag_pool(), dict_stats_save_defrag_summary(), dict_stats_save_defrag_stats(): Add a parameter for the transaction. dict_stats_empty_table(): Make public. This will be called by row_truncate_table_for_mysql() after dropping persistent statistics, to clear the memory-based statistics as well.
-
Sergei Petrunia authored
Part #2: Don't use the new code for the clustered PK, it is handled in the special way right above.
-
Sergei Petrunia authored
TABLE_SHARE::init_from_binary_frm_image() calls handler_file->index_flags() before it has set TABLE_SHARE::primary_key (it is 0 while it should be MAX_KEY in my example). This causes MyRocks to report wrong index flags (it thinks it's a PK while it is not), which causes invalid query plans later on. Do the only thing that seems feasible: adjust field->part_of key to have correct value in ha_rocksdb::open.
-
Sergei Petrunia authored
Part#1: Set field->part_of_key correctly for PK fields.
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
-
- 05 Dec, 2017 3 commits
-
-
Marko Mäkelä authored
-
Marko Mäkelä authored
MDEV-14587 dict_stats_process_entry_from_defrag_pool() fails to call dict_table_close() when index==NULL dict_stats_process_entry_from_defrag_pool(): Simplify the logic, and always call dict_table_close() when dict_table_open() returned a non-NULL handle.
-
Marko Mäkelä authored
MDEV-13670/MDEV-14550 Error log flood : "InnoDB: page_cleaner: 1000ms intended loop took N ms. The settings might not be optimal." Silence the error log output that was introduced in MySQL 5.7 (MariaDB 10.2.2) if log_warnings=2 or less. We should still figure out what these messages really indicate and how to solve the problems. pc_sleep_if_needed(): Add a parameter for the current time, so that there will be fewer successive calls to ut_time_ms() with no I/O between them. buf_flush_page_cleaner_coordinator(): Exit the first loop whenever shutdown has been requested. At the start of the loop, call ut_time_ms() only once. Do not display the message if log_warnings=2 or less.
-
- 04 Dec, 2017 2 commits
-
-
Marko Mäkelä authored
The function dict_stats_update_if_needed() replaced row_update_statistics_if_needed(). Adjust the comments accordingly.
-
Marko Mäkelä authored
-
- 03 Dec, 2017 2 commits
-
-
Monty authored
Problem was that Binlog_checkpoint can happen at random times. Fixed by not write binlog_checkpoint for the rpl_log test. Other things: - Removed not used variable "$keep_gtid_events" - Added option for show_binlog_events to skip binlog_checkpoint
-
Monty authored
Originally only symbols withing [] where resolved. Now we resolve symbols also withing (+...) To make it easier to see where the resolved symbol comes from, we resolve the symbol 'in place' instead of just printing the resolved symbol alone.
-
- 01 Dec, 2017 2 commits
-
-
Marko Mäkelä authored
-
Marko Mäkelä authored
srv_purge_wakeup(): If thd_destructor_proxy has initiated the first step of shutdown, ensure that all purge threads terminate. logs_empty_and_mark_files_at_shutdown(): Add a debug assertion. (The purge threads should have been shut down already before this step.)
-
- 30 Nov, 2017 1 commit
-
-
Vladislav Vaintroub authored
(possibly intermittent) checksum mismatch.
-
- 29 Nov, 2017 3 commits
-
-
Vladislav Vaintroub authored
-
Vladislav Vaintroub authored
is detected. The checksum mismatch can be due to partial write, thus retry the read
-
Vicențiu Ciorbaru authored
Window is a reserved keyword according to SQL Standard 2016. However, we can make the grammar slightly flexible by allowing WINDOW keyword everywhere except table aliases. Change yacc grammar to separate between all keywords and table_alias keywords.
-
- 28 Nov, 2017 3 commits
-
-
Daniel Bartholomew authored
-
Marko Mäkelä authored
-
Vladislav Vaintroub authored
- get rid of casts between int and HANDLE. - store file descriptor in TP_connection_generic to get rid of multiple mysql_socket_getfd(c->thd->net.vio->mysql_socket)) Also support named pipes (no reason not to support, since it is easy)
-
- 27 Nov, 2017 1 commit
-
-
Elena Stepanova authored
-
- 24 Nov, 2017 8 commits
-
-
Vladislav Vaintroub authored
-
Sergey Vojtovich authored
mariabackup fails to builds with PFS disabled. The reason was missing include, which was included by PFS otherwise.
-
Vladislav Vaintroub authored
# Conflicts: # storage/innobase/include/os0file.h
-
Vladislav Vaintroub authored
-
Marko Mäkelä authored
-
Marko Mäkelä authored
When Mariabackup is invoked on an instance that uses a multi-file InnoDB system tablespace, it may fail to other files of the system tablespace than the first one. This was revealed by the MDEV-14447 test case. The offending code is assuming that the first page of each data file is page 0. But, in multi-file system tablespaces that is not the case. xb_fil_cur_open(): Instead of re-reading the first page of the file, rely on the fil_space_t metadata that already exists in memory. xb_get_space_flags(): Remove.
-
Vladislav Vaintroub authored
-
Vladislav Vaintroub authored
Update C/C to include fix for this bug.
-