File: rpl_dump_thread_reconnect_message.test

package info (click to toggle)
mysql-8.0 8.0.43-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,273,924 kB
  • sloc: cpp: 4,684,605; ansic: 412,450; pascal: 108,398; java: 83,641; perl: 30,221; cs: 27,067; sql: 26,594; sh: 24,181; python: 21,816; yacc: 17,169; php: 11,522; xml: 7,388; javascript: 7,076; makefile: 2,194; lex: 1,075; awk: 670; asm: 520; objc: 183; ruby: 97; lisp: 86
file content (56 lines) | stat: -rw-r--r-- 2,319 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# ==== Purpose ====
# Verify that a clear and meaningful message is logged on the source when
# restarting the IO thread.
#
# ==== Requirements ====
# A clear and meaningful message must be logged in the source log file during
# the IO thread restart.
#
# ==== Implementation ====
#  1. Set up initial source-replica configuration
#  2. Start IO thread on replica which will start a dump thread on source
#  3. Restart the IO thread (Source should kill existing dump thread before
#     starting a new dump thread)
#  4. Verify that no message appears stating 'killed the zombie thread'
#  5. Verify that a message stating 'killed the old dump thread' is present
#  6. Cleanup
#
# ==== References ====
# Bug#25330090 SLIGHTLY CONFUSING 'NOTE' REPORTED IN MASTER SERVER'S LOG WHEN
# SLAVE RECONNECTS

--source include/have_binlog_format_row.inc

--echo # 1. Set up initial source-replica configuration
--let rpl_skip_start_slave= 1
--source include/master-slave.inc

--source include/rpl_connection_slave.inc

--echo # 2. Start IO thread on replica which will start a dump thread on source
--source include/start_slave_io.inc

--echo # 3. Restart the IO thread (Source should kill existing dump thread
--echo #    before starting a new dump thread)
--source include/stop_slave_io.inc
--source include/start_slave_io.inc

--echo # 4. Verify that no message appears stating 'killed the zombie thread'
--let $assert_file=$MYSQLTEST_VARDIR/log/mysqld.1.err
--let $assert_count_condition= <=0
--let $assert_select= While initializing dump thread for replica with UUID.*, found a zombie dump thread with the same UUID.*
--let $assert_text= No zombie thread kill message on the source
--source include/assert_grep.inc

--echo # 5. Verify that a message stating 'killed the old dump thread' is present
--let $assert_file=$MYSQLTEST_VARDIR/log/mysqld.1.err
--let $assert_count_condition= >=1
--let $assert_select= Upon reconnection with the replica, while initializing the dump thread for.*, an existing dump thread with the same.* was detected.*
--let $assert_text= Found dump thread kill message on the source
--source include/assert_grep.inc

--echo # 6. Cleanup
--source include/rpl_connection_slave.inc
# We do not care about SQL thread for this test scenario
--let $rpl_only_running_threads= 1
--source include/rpl_end.inc