diff options
author | Sergei Golubchik <serg@mariadb.org> | 2019-03-11 16:45:38 +0100 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2019-03-12 13:10:49 +0100 |
commit | dda2e940fb035d41852e95a1c2f513ab1534b041 (patch) | |
tree | 1f0a9a90a727be8350cbbec077eb24c2ff2405ff /sql/sql_lex.cc | |
parent | bc8ae50e7c1dd56ceb7fc39e05f87a104d3ce632 (diff) | |
download | mariadb-git-dda2e940fb035d41852e95a1c2f513ab1534b041.tar.gz |
pass the slow logging information in thd->query_plan_flags
This solves the following issues:
* unlike lex->m_sql_cmd and lex->sql_command, thd->query_plan_flags
is not reset in Prepared_statement::execute, it survives
till the log_slow_statement(), so slow logging behaves correctly in --ps
* using thd->query_plan_flags for both slow_log_filter and
log_slow_admin_statements means the definition of "admin" statements
for the slow log is the same no matter how it is filtered out.
Diffstat (limited to 'sql/sql_lex.cc')
-rw-r--r-- | sql/sql_lex.cc | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index 7c330151545..df868d0321f 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -4720,19 +4720,6 @@ bool LEX::is_partition_management() const } -bool Sql_cmd::log_slow_enabled_statement(const THD *thd) const -{ - return global_system_variables.sql_log_slow && thd->variables.sql_log_slow; -} - - -bool Sql_cmd_admin::log_slow_enabled_statement(const THD *thd) const -{ - return opt_log_slow_admin_statements && - Sql_cmd::log_slow_enabled_statement(thd); -} - - #ifdef MYSQL_SERVER uint binlog_unsafe_map[256]; |