diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2017-12-06 19:11:12 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2017-12-06 19:34:03 +0200 |
commit | ce07676502b398ca8eacc21e3899f6b0e060c9c9 (patch) | |
tree | 2c709aeefe67335eaa138866b7fb9567f67021dc /mysql-test/include | |
parent | 24c9785a67dda85f8df8a3fde4c4903e09f846e9 (diff) | |
parent | 77fb7ccba41e9a901053ffc4fdc461968f6f616f (diff) | |
download | mariadb-git-ce07676502b398ca8eacc21e3899f6b0e060c9c9.tar.gz |
Merge 10.2 into bb-10.2-ext
Diffstat (limited to 'mysql-test/include')
-rw-r--r-- | mysql-test/include/filter_file.inc | 11 | ||||
-rw-r--r-- | mysql-test/include/show_binlog_events.inc | 8 | ||||
-rw-r--r-- | mysql-test/include/show_events.inc | 7 |
3 files changed, 18 insertions, 8 deletions
diff --git a/mysql-test/include/filter_file.inc b/mysql-test/include/filter_file.inc index 17c7c1985d7..bfe53896710 100644 --- a/mysql-test/include/filter_file.inc +++ b/mysql-test/include/filter_file.inc @@ -53,6 +53,9 @@ # # $rpl_debug # If set, verbose debug info is printed. +# +# $filter_script +# If set, rows matching this regexp will be filtered out --let $include_filename= filter_file.inc --source include/begin_include_file.inc @@ -67,10 +70,12 @@ if ($rpl_debug) --let _FF_PRE_SCRIPT= $pre_script --let _FF_SCRIPT= $script +--let _FF_FILTER_SCRIPT= $filter_script --let _FF_INPUT_FILE= $input_file --let _FF_OUTPUT_FILE= $output_file --let _FF_SELECT_COLUMNS= $select_columns --let _FF_DEBUG= $rpl_debug + if (!$output_file) { --let _FF_OUTPUT_FILE= $input_file @@ -79,6 +84,7 @@ perl; my $pre_script = $ENV{'_FF_PRE_SCRIPT'}; $pre_script =~ s/DOLLAR/\$/g; my $script = $ENV{'_FF_SCRIPT'}; + my $filter_script = $ENV{'_FF_FILTER_SCRIPT'}; $script =~ s/DOLLAR/\$/g; my $input_file = $ENV{'_FF_INPUT_FILE'}; my $output_file = $ENV{'_FF_OUTPUT_FILE'}; @@ -123,7 +129,10 @@ perl; { ' . $script . ' } - $filtered_contents .= $_."\n"; + if (!$filter_script || ! m/$filter_script/) + { + $filtered_contents .= $_."\n"; + } } close FILE or die "Error closing $input_file: $!"; open FILE, "> $output_file" or die "Error opening $output_file: $!"; diff --git a/mysql-test/include/show_binlog_events.inc b/mysql-test/include/show_binlog_events.inc index b2462e0d1b1..57fe1ffe0e3 100644 --- a/mysql-test/include/show_binlog_events.inc +++ b/mysql-test/include/show_binlog_events.inc @@ -7,7 +7,7 @@ # [--let $binlog_file= [<FILENAME> | LAST]] # [--let $binlog_start= <POSITION> ] # [--let $binlog_limit= 1, 3 ] -# [--let $keep_gtid_events= 1] +# [--let $skip_checkpoint_events= 1] # --source include/show_binlog_events.inc # # Parameters: @@ -26,12 +26,6 @@ # Limit for the 'LIMIT' clause of SHOW BINLOG EVENTS, i.e.: # $binlog_limit= 3 -- print three events # $binlog_limit= 4, 3 -- skip four events, print the three next events -# -# $keep_gtid_events -# By default, Gtid_log_event and Previous_gtid_log_event are -# filtered out, so that the output is independent of whether GTIDs -# are enabled or not. If this flag is set, events are kept but -# the actual GTID values are masked out. --let $include_filename= show_binlog_events.inc --source include/begin_include_file.inc diff --git a/mysql-test/include/show_events.inc b/mysql-test/include/show_events.inc index 368cfc9e3a7..9ee01f73999 100644 --- a/mysql-test/include/show_events.inc +++ b/mysql-test/include/show_events.inc @@ -104,8 +104,15 @@ let $script= s{DOLLARmysqltest_vardir}{MYSQLTEST_VARDIR}g; || --let $pre_script= my DOLLARmysqltest_vardir = DOLLARENV{'MYSQLTEST_VARDIR'}; + --delimiter ; +if ($skip_checkpoint_events) +{ + let $filter_script=Binlog_checkpoint; +} + + #--let $select_columns= 1 3 6 --let $input_file= $output_file --source include/filter_file.inc |