Debian Codegraph @

mysql-test/suite/rpl_nogtid/r/rpl_no_gtid_split_statements.result

raw
1 include/master-slave.inc
2 Warnings:
3 Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
4 Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
5 [connection master]
6 CALL mtr.add_suppression('Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT.');
7 CALL mtr.add_suppression("Error dropping database");
8 CALL mtr.add_suppression("Can't drop database '.*'; database doesn't exist");
9 CALL mtr.add_suppression("Replica SQL for channel '': ... The replica coordinator and worker threads are stopped, possibly leaving data in inconsistent state. .* Error_code: 1756");
10 ==== Case 1: CALL is split on master ====
11 ---- Initialize ----
12 CREATE TABLE t (a INT);
13 CREATE PROCEDURE proc ()
14 BEGIN
15 INSERT INTO t VALUES (1);
16 INSERT INTO t VALUES (2);
17 END|
18 ---- GTID_NEXT=AUTOMATIC ----
19 include/gtid_step_reset.inc
20 CALL proc();
21 include/gtid_step_assert.inc [count=2, only_count=0]
22 include/assert.inc [Both rows were inserted]
23 DELETE FROM t;
24 ---- GTID_NEXT=non-automatic ----
25 include/gtid_step_reset.inc
26 SET GTID_NEXT = '#';
27 CALL proc();
28 SET GTID_NEXT= 'AUTOMATIC';
29 include/gtid_step_assert.inc [count=1, only_count=0]
30 include/assert.inc [One row inserted if GTID_MODE=ON, two if GTID_MODE=OFF]
31 DROP TABLE t;
32 DROP PROCEDURE proc;
33 ==== Case 2A: DROP TABLE is split on master ====
34 ---- Initialize ----
35 CREATE PROCEDURE create_tables()
36 BEGIN
37 CREATE TABLE base (a INT) ENGINE = InnoDB;
38 CREATE TEMPORARY TABLE temp_t (a INT) ENGINE = InnoDB;
39 CREATE TEMPORARY TABLE temp_n (a INT) ENGINE = MyISAM;
40 END|
41 CREATE PROCEDURE drop_tables()
42 BEGIN
43 DROP TABLE IF EXISTS base;
44 DROP TABLE IF EXISTS temp_t;
45 DROP TABLE IF EXISTS temp_n;
46 END|
47 include/rpl_sync.inc
48 ---- GTID_MODE=AUTOMATIC ----
49 CALL create_tables();
50 include/gtid_step_reset.inc
51 DROP TABLE base, temp_t;
52 include/gtid_step_assert.inc [count=2, only_count=0]
53 include/assert_binlog_events.inc
54 DROP TABLE temp_n;
55 include/rpl_sync.inc
56 include/rpl_reset.inc
57 CALL create_tables();
58 include/gtid_step_reset.inc
59 DROP TABLE base, temp_n;
60 include/gtid_step_assert.inc [count=2, only_count=0]
61 include/assert_binlog_events.inc
62 DROP TABLE temp_t;
63 include/rpl_sync.inc
64 include/rpl_reset.inc
65 CALL create_tables();
66 include/gtid_step_reset.inc
67 DROP TABLE temp_t, temp_n;
68 include/gtid_step_assert.inc [count=2, only_count=0]
69 include/assert_binlog_events.inc
70 DROP TABLE base;
71 include/rpl_sync.inc
72 include/rpl_reset.inc
73 CALL create_tables();
74 include/gtid_step_reset.inc
75 DROP TABLE base, temp_t, temp_n;
76 include/gtid_step_assert.inc [count=3, only_count=0]
77 include/assert_binlog_events.inc
78 include/rpl_sync.inc
79 include/rpl_reset.inc
80 ---- GTID_MODE=non-automatic ----
81 CALL create_tables();
82 include/gtid_step_reset.inc
83 SET GTID_NEXT = '#';
84 DROP TABLE base, temp_t;
85 SET GTID_NEXT = 'AUTOMATIC';
86 include/gtid_step_assert.inc [count=2, only_count=0]
87 include/assert_binlog_events.inc
88 DROP TABLE temp_n;
89 include/rpl_sync.inc
90 include/rpl_reset.inc
91 CALL create_tables();
92 include/gtid_step_reset.inc
93 SET GTID_NEXT = '#';
94 DROP TABLE base, temp_n;
95 SET GTID_NEXT = 'AUTOMATIC';
96 include/gtid_step_assert.inc [count=2, only_count=0]
97 include/assert_binlog_events.inc
98 DROP TABLE temp_t;
99 include/rpl_sync.inc
100 include/rpl_reset.inc
101 CALL create_tables();
102 include/gtid_step_reset.inc
103 SET GTID_NEXT = '#';
104 DROP TABLE temp_t, temp_n;
105 SET GTID_NEXT = 'AUTOMATIC';
106 include/gtid_step_assert.inc [count=2, only_count=0]
107 include/assert_binlog_events.inc
108 DROP TABLE base;
109 include/rpl_sync.inc
110 include/rpl_reset.inc
111 CALL create_tables();
112 include/gtid_step_reset.inc
113 SET GTID_NEXT = '#';
114 DROP TABLE base, temp_t, temp_n;
115 SET GTID_NEXT = 'AUTOMATIC';
116 include/gtid_step_assert.inc [count=3, only_count=0]
117 include/assert_binlog_events.inc
118 include/rpl_sync.inc
119 include/rpl_reset.inc
120 ==== Case 2B: DROP TABLE is split on slave ====
121 ---- Initialize ----
122 CREATE TABLE dummy (a INT);
123 DROP PROCEDURE create_tables;
124 CREATE FUNCTION create_tables_func() RETURNS INT
125 BEGIN
126 IF @@GLOBAL.SERVER_ID = 2 THEN
127 CREATE TEMPORARY TABLE temp_t (a INT) ENGINE = InnoDB;
128 CREATE TEMPORARY TABLE temp_n (a INT) ENGINE = MyISAM;
129 END IF;
130 RETURN 0;
131 END|
132 CREATE PROCEDURE create_tables()
133 BEGIN
134 CREATE TABLE base (a INT);
135 SET @@SESSION.SQL_LOG_BIN = 0;
136 CREATE TABLE temp_t (a INT);
137 CREATE TABLE temp_n (a INT);
138 SET @@SESSION.SQL_LOG_BIN = 1;
139 INSERT INTO dummy VALUES (create_tables_func());
140 END|
141 include/rpl_sync.inc
142 ---- GTID_MODE=AUTOMATIC ----
143 CALL create_tables();
144 Warnings:
145 Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system variable that may have a different value on the replica.
146 include/gtid_step_reset.inc
147 DROP TABLE base, temp_t;
148 include/gtid_step_assert.inc [count=1, only_count=0]
149 include/assert_binlog_events.inc
150 DROP TABLE temp_n;
151 include/rpl_sync.inc
152 include/rpl_reset.inc
153 CALL create_tables();
154 Warnings:
155 Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system variable that may have a different value on the replica.
156 include/gtid_step_reset.inc
157 DROP TABLE base, temp_n;
158 include/gtid_step_assert.inc [count=1, only_count=0]
159 include/assert_binlog_events.inc
160 DROP TABLE temp_t;
161 include/rpl_sync.inc
162 include/rpl_reset.inc
163 CALL create_tables();
164 Warnings:
165 Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system variable that may have a different value on the replica.
166 include/gtid_step_reset.inc
167 DROP TABLE temp_t, temp_n;
168 include/gtid_step_assert.inc [count=1, only_count=0]
169 include/assert_binlog_events.inc
170 DROP TABLE base;
171 include/rpl_sync.inc
172 include/rpl_reset.inc
173 CALL create_tables();
174 Warnings:
175 Note 1592 Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statement is unsafe because it uses a system variable that may have a different value on the replica.
176 include/gtid_step_reset.inc
177 DROP TABLE base, temp_t, temp_n;
178 include/gtid_step_assert.inc [count=1, only_count=0]
179 include/assert_binlog_events.inc
180 include/rpl_sync.inc
181 include/rpl_reset.inc
182 ---- Clean up ----
183 DROP FUNCTION create_tables_func;
184 DROP PROCEDURE create_tables;
185 DROP PROCEDURE drop_tables;
186 DROP TABLE dummy;
187 ==== Case 2C: DROP TABLES for base tables in engines with and without atomic DDL support ====
188 CREATE TABLE base_1_n (a INT) ENGINE = MyISAM;
189 CREATE TABLE base_2_n (a INT) ENGINE = MyISAM;
190 CREATE TABLE base_3_a (a INT) ENGINE = InnoDB;
191 CREATE TABLE base_4_a (a INT) ENGINE = InnoDB;
192 include/rpl_sync.inc
193 ---- GTID_MODE=AUTOMATIC ----
194 include/gtid_step_reset.inc
195 DROP TABLES base_1_n, base_2_n, base_3_a, base_4_a;
196 # In AUTOMATIC mode the above statement should be split into three:
197 # two statements for each of MyISAM tables and single statement
198 # dropping both of InnoDB tables.
199 include/gtid_step_assert.inc [count=3, only_count=0]
200 CREATE TABLE base_1_n (a INT) ENGINE = MyISAM;
201 CREATE TABLE base_2_n (a INT) ENGINE = MyISAM;
202 CREATE TABLE base_3_a (a INT) ENGINE = InnoDB;
203 CREATE TABLE base_4_a (a INT) ENGINE = InnoDB;
204 include/rpl_sync.inc
205 ---- GTID_NEXT=non-automatic ----
206 include/gtid_step_reset.inc
207 SET GTID_NEXT = '#';
208 DROP TABLES base_1_n, base_2_n, base_3_a, base_4_a;
209 SET GTID_NEXT= 'AUTOMATIC';
210 # Without GTID assigned the above statement should be split into
211 # three as in AUTOMATIC mode.
212 include/gtid_step_assert.inc [count=3, only_count=0]
213 include/rpl_sync.inc
214 ==== Case 2D: Failing DROP TABLES for base tables with and without atomic DDL support ====
215 See rpl_split_statements_debug.test
216 ==== Case 3: DROP DATABASE ====
217 See rpl_split_statements_debug.test
218 ==== Case 4: CREATE TABLE ... SELECT ====
219 See rpl_gtid_create_select.test
220 include/rpl_end.inc