Created by Laurynas Biveinis and last modified
Get this branch:
bzr branch lp:~laurynas-biveinis/percona-server/slow-log-fixes-5.1
Only Laurynas Biveinis can upload to this branch. If you are Laurynas Biveinis please log in for upload directions.

Branch merges

Related bugs

Related blueprints

Branch information

Recent revisions

511. By Laurynas Biveinis

Multiple extended slow query log fixes.

Fix bug 887928 (Time in slow query log displayed incorrectly when
slow_query_log_microseconds_timestamp enabled) by using a correct
format specifier for microsecond output and tightening regexps in
percona_slow_query_log_microseconds_timestamp test. Also adjust the
testcase not to use query_exec_time and thus not limit it to debug
builds only.

Fix bug 730173 (InnoDB and query plan information are logged when not
enabled) and bug 1089961 (Slow query log query plan extensions not
tested in MTR) by checking the verbosity flag in more places in
MYSQL_QUERY_LOG::write. Add new testcases percona_log_slow_query_plan
and percona_log_slow_query_plan_qc and remove percona_log_slow_filter
as it's fully subsumed in the new testcases. Adjust mysqldumpslow
script to filter out the optional information correctly. Re-record
percona_bug643149, percona_slow_extended_error_on_quit, and
percona_mysqldumpslow tests.

Fix bug 1091712 (Get rid of thd->write_to_slow_log) by removing it and
moving the rate filtering logic from handle_one_connection() to
log_slow_statement(). At the same time set thd->enable_slow_log to
TRUE instead of opt_log_slow_slave_statements in
Query_log_event::do_apply_event() and init_slave_thread() as the check
at print_slow_log() is sufficient for slave statement filtering.

Fix bug 1088954 (Data type conversion bugs in slow query log output
formatting code) by using %d not %u for last_errno output and
pre-formatting ulonglong values with sprintf.

Fix testcase-only bugs:

Fix bug 909376 (percona_slow_extended_error_on_quit test unstable) by
rewriting the testcase.

Fix bug 1088867 (The effect of log_slow_verbosity is untested in MTR)
by replacing percona_log_slow_verbosity with a new extensive test,
together with include/percona_slow_log_verbosity_grep.inc helper.

Fix bug 1092142 (log_slow_admin_statements untested in MTR) by
replacing the current percona_log_slow_admin_statements non-test with
a new actual testcase.

Fix bug 1089031 (Slow query log XtraDB extensions not tested in MTR)
by adding a new testcase percona_log_slow_innodb. Also, simplify
percona_log_slow_slave_statements-innodb testcase by removing slave
option file, needless master/slave switches, and needless query/result
log disablings, and replace server restart with a slave SQL thread

Fix bug 1096895 (percona_log_slow_slave_statements test needlessly
complicated) by rewriting the testcase to remove needless SQL thread
restarts, very verbose variable settings, slave option file, and other
non-test things.

Fix bug 1096899 (percona_log_slow_sp_statements testcase multiple
issues) by rewriting the testcase to not use query_exec_time session
variable, not limiting it to debug builds only, and adding a test for
the negative case.

Fix bug 1090874 (log_slow_timestamp_every /
slow_query_log_timestamp_always testing issues) by rewriting
percona_log_slow_timestamp_every testcase not to depend on the
subsequent queries getting identical timestamps and not use
query_exec_time session variable, thus not limiting it to debug builds

Fix bug 1096904 (Extended slow query log last_errno value not tested
in MTR) by adding a new testcase percona_slow_extended_log_error.

Attempt to fix bug 1098436 (Unstable test percona_mysqldumpslow) by
slow-logging only relevant statements (i.e. the ones with injected
query execution time) to remove statements with varying execution time
from the output. Set min_examined_row_limit to zero for the
testcase. Additionally adjust include/log_start.inc not to delete the
slow query log file to support logging restarts to the same file.
Remove useless Perl code. Remove useless "FLUSH LOGS" from
include/log_stop.inc. Append .slog to all log files in
include/log_start.inc and provide new include file
include/log_cleanup.inc that removes *.slog from the log directory.
Set log_output to FILE in log_start.inc and restore its old value in

Address bug 1098857 by disabling percona_slow_extended_error_on_quit
and moving out session disconnects out of slow query log in

Adjust percona_long_query_time, percona_use_global_log_slow_control
and percona_use_global_long_query_time test cases to set
min_examined_row_limit to 0.

510. By <email address hidden>

Merge lp:~vlad-lesin/percona-server/5.1-bug1049871-injections-gca

509. By <email address hidden>

Merge lp:~hrvojem/percona-server/rn-5.1.66-14.2

508. By <email address hidden>

Merge lp:~hrvojem/percona-server/bug1057031-5.1

507. By <email address hidden>

Merge lp:~stewart/percona-server/5.1-bug1090596

506. By <email address hidden>

Merge lp:~vlad-lesin/percona-server/5.1-bug1083377-gca

505. By <email address hidden>

Merge lp:~laurynas-biveinis/percona-server/xtradb-multiple-bmp-files-51

504. By <email address hidden>

Merge lp:~laurynas-biveinis/percona-server/bug901060-5.1

503. By <email address hidden>

Merge lp:~akopytov/percona-server/bug830286-5.1

502. By <email address hidden>

Merge lp:~akopytov/percona-server/bug1070856-5.1

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
Stacked on:
This branch contains Public information 
Everyone can see this information.