File: rpl_get_master_version_and_clock.test

package info (click to toggle)
mariadb 1%3A11.8.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, trixie
  • size: 765,428 kB
  • sloc: ansic: 2,382,827; cpp: 1,803,532; asm: 378,315; perl: 63,176; sh: 46,496; pascal: 40,776; java: 39,363; yacc: 20,428; python: 19,506; sql: 17,864; xml: 12,463; ruby: 8,544; makefile: 6,059; cs: 5,855; ada: 1,700; lex: 1,193; javascript: 1,039; objc: 80; tcl: 73; awk: 46; php: 22
file content (52 lines) | stat: -rw-r--r-- 2,069 bytes parent folder | download | duplicates (4)
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
#
# BUG#45214 
# This test verifies if the slave I/O tread tries to reconnect to
# master when it tries to get the values of the UNIX_TIMESTAMP, SERVER_ID,
# COLLATION_SERVER and TIME_ZONE from master under network disconnection.
# The COLLATION_SERVER and TIME_ZONE are got only on master server version 4.
# So they can't be verified by test case here.
# Finish the following tests by calling its common test script:  
# include/rpl_get_master_version_and_clock.test. 

source include/not_valgrind.inc;
source include/have_debug.inc;
source include/have_debug_sync.inc;
source include/master-slave.inc;

#
# The test is not supposed to have any binglog affairs.
# Hence it's enough it to run only with one binlog format
#
source include/have_binlog_format_mixed.inc;

connection slave;

call mtr.add_suppression("Slave I/O: Master command COM_REGISTER_SLAVE failed: .*");
call mtr.add_suppression("Slave I/O: .* failed with error: Lost connection to server at 'reading initial communication packet'");
call mtr.add_suppression("Fatal error: The slave I/O thread stops because
master and slave have equal MariaDB server ids; .*");
call mtr.add_suppression("Slave I/O thread .* register on master");

#Test case 1: Try to get the value of the UNIX_TIMESTAMP from master under network disconnection
SET @saved_dbug = @@GLOBAL.debug_dbug;

# set up two parameters to pass into include/rpl_get_master_version_and_clock
let $dbug_sync_point= 'debug_lock.before_get_UNIX_TIMESTAMP';
let $debug_sync_action= 'now SIGNAL signal.get_unix_timestamp';
source include/rpl_get_master_version_and_clock.test; 

#Test case 2: Try to get the value of the SERVER_ID from master under network disconnection
connection slave;

let $dbug_sync_point= 'debug_lock.before_get_SERVER_ID';
let $debug_sync_action= 'now SIGNAL signal.get_server_id';
source include/rpl_get_master_version_and_clock.test;


# cleanup
SET @@GLOBAL.debug_dbug = @saved_dbug;
# is not really necessary but avoids mtr post-run env check warnings
SET DEBUG_SYNC= 'RESET';

# End of tests
--source include/rpl_end.inc