| 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 |
CREATE TABLE t1(c1 INT PRIMARY KEY, c2 INT, INDEX(c2)) ENGINE = InnoDB; |
| 8 |
INSERT INTO t1 VALUES |
| 9 |
(1, NULL), |
| 10 |
(2, 2), |
| 11 |
(3, NULL), |
| 12 |
(4, 4), |
| 13 |
(5, NULL), |
| 14 |
(6, 6); |
| 15 |
CREATE TABLE t2(a INT PRIMARY KEY); |
| 16 |
include/sync_slave_sql_with_master.inc |
| 17 |
[connection slave] |
| 18 |
include/stop_slave_sql.inc |
| 19 |
CALL mtr.add_suppression(".*Worker.*failed executing transaction.*at source log .*, end_log_pos.*Deadlock found when trying to get lock.*"); |
| 20 |
CALL mtr.add_suppression(".*Worker.*failed executing transaction.*at source log .*, end_log_pos.*Can not lock user management caches for processing.*"); |
| 21 |
CALL mtr.add_suppression(".*Worker.*failed executing transaction.*at source log .*, end_log_pos.*Replica worker has stopped after at least one previous worker.*"); |
| 22 |
CALL mtr.add_suppression(".*worker thread retried transaction.*time.*in vain, giving up.*"); |
| 23 |
CALL mtr.add_suppression(".*The replica coordinator and worker threads are stopped.*"); |
| 24 |
CALL mtr.add_suppression(".*Replica worker has stopped after at least one previous worker encountered an error when replica-preserve-commit-order was enabled.*"); |
| 25 |
SET GLOBAL replica_parallel_type = LOGICAL_CLOCK; |
| 26 |
SET GLOBAL replica_parallel_workers = 3; |
| 27 |
SET GLOBAL replica_preserve_commit_order = ON; |
| 28 |
SET GLOBAL replica_transaction_retries = REPLICA_TRANSACTION_RETRIES; |
| 29 |
SET GLOBAL innodb_lock_wait_timeout = INNODB_LOCK_WAIT_TIMEOUT; |
| 30 |
include/rpl_connect.inc [creating rpl_slave_connection_2] |
| 31 |
include/rpl_connect.inc [creating rpl_slave_connection_3] |
| 32 |
|
| 33 |
# |
| 34 |
# TC1. `GLOBAL READ_ONLY=ON` issued by client and DDL replicated |
| 35 |
# from source. |
| 36 |
#------------------------------------------------------------------------ |
| 37 |
[connection master] |
| 38 |
INSERT INTO t1 VALUES(10, 10); |
| 39 |
[connection slave] |
| 40 |
[connection master] |
| 41 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 42 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:1"; |
| 43 |
ALTER TABLE t2 ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1; |
| 44 |
SET GTID_NEXT = AUTOMATIC; |
| 45 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:2"; |
| 46 |
INSERT INTO t1 VALUES(11, NULL); |
| 47 |
SET GTID_NEXT = AUTOMATIC; |
| 48 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:3"; |
| 49 |
INSERT INTO t1 VALUES(12, NULL); |
| 50 |
SET GTID_NEXT = AUTOMATIC; |
| 51 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 52 |
[connection slave] |
| 53 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:1"; |
| 54 |
BEGIN; |
| 55 |
[connection rpl_slave_connection_2] |
| 56 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:2"; |
| 57 |
BEGIN; |
| 58 |
[connection rpl_slave_connection_3] |
| 59 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:3"; |
| 60 |
BEGIN; |
| 61 |
[connection slave1] |
| 62 |
include/start_slave_sql.inc |
| 63 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 64 |
include/assert.inc [MTS worker thread count is correct] |
| 65 |
include/assert.inc [Replica preserve commit order is 1] |
| 66 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 67 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 68 |
[connection rpl_slave_connection_2] |
| 69 |
ROLLBACK; |
| 70 |
SET GTID_NEXT = AUTOMATIC; |
| 71 |
include/wait_condition.inc [First worker must wait on commit order] |
| 72 |
[connection rpl_slave_connection_3] |
| 73 |
ROLLBACK; |
| 74 |
SET GTID_NEXT = AUTOMATIC; |
| 75 |
include/wait_condition.inc [Second worker must wait on commit order] |
| 76 |
[connection slave1] |
| 77 |
SET GLOBAL read_only = ON; |
| 78 |
[connection slave] |
| 79 |
include/wait_condition.inc [Client connection must wait for state] |
| 80 |
ROLLBACK; |
| 81 |
SET GTID_NEXT = AUTOMATIC; |
| 82 |
[connection slave1] |
| 83 |
[connection slave] |
| 84 |
include/wait_for_slave_sql_error.inc [errno=1213] |
| 85 |
[connection slave1] |
| 86 |
SET GLOBAL read_only = OFF; |
| 87 |
[connection slave] |
| 88 |
include/start_slave_sql.inc |
| 89 |
[connection master] |
| 90 |
include/sync_slave_sql_with_master.inc |
| 91 |
include/rpl_diff.inc |
| 92 |
[connection master] |
| 93 |
include/sync_slave_sql_with_master.inc |
| 94 |
include/stop_slave_sql.inc |
| 95 |
[connection master] |
| 96 |
INSERT INTO t1 VALUES(13, 13); |
| 97 |
[connection slave] |
| 98 |
[connection master] |
| 99 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 100 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:4"; |
| 101 |
ALTER TABLE t2 ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1; |
| 102 |
SET GTID_NEXT = AUTOMATIC; |
| 103 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:5"; |
| 104 |
INSERT INTO t1 VALUES(14, NULL); |
| 105 |
SET GTID_NEXT = AUTOMATIC; |
| 106 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:6"; |
| 107 |
INSERT INTO t1 VALUES(15, NULL); |
| 108 |
SET GTID_NEXT = AUTOMATIC; |
| 109 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 110 |
[connection slave] |
| 111 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:4"; |
| 112 |
BEGIN; |
| 113 |
[connection rpl_slave_connection_2] |
| 114 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:5"; |
| 115 |
BEGIN; |
| 116 |
[connection rpl_slave_connection_3] |
| 117 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:6"; |
| 118 |
BEGIN; |
| 119 |
[connection slave1] |
| 120 |
include/start_slave_sql.inc |
| 121 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 122 |
include/assert.inc [MTS worker thread count is correct] |
| 123 |
include/assert.inc [Replica preserve commit order is 1] |
| 124 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 125 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 126 |
[connection rpl_slave_connection_2] |
| 127 |
ROLLBACK; |
| 128 |
SET GTID_NEXT = AUTOMATIC; |
| 129 |
include/wait_condition.inc [First worker must wait on commit order] |
| 130 |
[connection slave1] |
| 131 |
SET GLOBAL read_only = ON; |
| 132 |
[connection slave] |
| 133 |
include/wait_condition.inc [Client connection must wait for state] |
| 134 |
ROLLBACK; |
| 135 |
SET GTID_NEXT = AUTOMATIC; |
| 136 |
[connection slave1] |
| 137 |
include/wait_condition.inc [Coordinator must wait for workers to stop] |
| 138 |
[connection rpl_slave_connection_3] |
| 139 |
ROLLBACK; |
| 140 |
SET GTID_NEXT = AUTOMATIC; |
| 141 |
[connection slave] |
| 142 |
include/wait_for_slave_sql_error.inc [errno=3030] |
| 143 |
[connection slave1] |
| 144 |
SET GLOBAL read_only = OFF; |
| 145 |
[connection slave] |
| 146 |
include/start_slave_sql.inc |
| 147 |
[connection master] |
| 148 |
include/sync_slave_sql_with_master.inc |
| 149 |
include/rpl_diff.inc |
| 150 |
[connection master] |
| 151 |
include/sync_slave_sql_with_master.inc |
| 152 |
include/stop_slave_sql.inc |
| 153 |
|
| 154 |
# |
| 155 |
# TC2. `GLOBAL READ_ONLY=ON` issued by client and DML replicated |
| 156 |
# from source. |
| 157 |
#------------------------------------------------------------------------ |
| 158 |
[connection master] |
| 159 |
INSERT INTO t1 VALUES(16, 16); |
| 160 |
[connection slave] |
| 161 |
[connection master] |
| 162 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 163 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:7"; |
| 164 |
INSERT INTO t1 VALUES(17, NULL); |
| 165 |
SET GTID_NEXT = AUTOMATIC; |
| 166 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:8"; |
| 167 |
INSERT INTO t1 VALUES(18, NULL); |
| 168 |
SET GTID_NEXT = AUTOMATIC; |
| 169 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:9"; |
| 170 |
INSERT INTO t1 VALUES(19, NULL); |
| 171 |
SET GTID_NEXT = AUTOMATIC; |
| 172 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 173 |
[connection slave] |
| 174 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:7"; |
| 175 |
BEGIN; |
| 176 |
[connection rpl_slave_connection_2] |
| 177 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:8"; |
| 178 |
BEGIN; |
| 179 |
[connection rpl_slave_connection_3] |
| 180 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:9"; |
| 181 |
BEGIN; |
| 182 |
[connection slave1] |
| 183 |
include/start_slave_sql.inc |
| 184 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 185 |
include/assert.inc [MTS worker thread count is correct] |
| 186 |
include/assert.inc [Replica preserve commit order is 1] |
| 187 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 188 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 189 |
[connection rpl_slave_connection_2] |
| 190 |
ROLLBACK; |
| 191 |
SET GTID_NEXT = AUTOMATIC; |
| 192 |
include/wait_condition.inc [First worker must wait on commit order] |
| 193 |
[connection rpl_slave_connection_3] |
| 194 |
ROLLBACK; |
| 195 |
SET GTID_NEXT = AUTOMATIC; |
| 196 |
include/wait_condition.inc [Second worker must wait on commit order] |
| 197 |
[connection slave1] |
| 198 |
SET GLOBAL read_only = ON; |
| 199 |
[connection slave] |
| 200 |
ROLLBACK; |
| 201 |
SET GTID_NEXT = AUTOMATIC; |
| 202 |
[connection slave1] |
| 203 |
[connection slave] |
| 204 |
include/wait_for_slave_sql_error.inc [errno=1213] |
| 205 |
[connection slave1] |
| 206 |
SET GLOBAL read_only = OFF; |
| 207 |
[connection slave] |
| 208 |
include/start_slave_sql.inc |
| 209 |
[connection master] |
| 210 |
include/sync_slave_sql_with_master.inc |
| 211 |
include/rpl_diff.inc |
| 212 |
[connection master] |
| 213 |
include/sync_slave_sql_with_master.inc |
| 214 |
include/stop_slave_sql.inc |
| 215 |
[connection master] |
| 216 |
INSERT INTO t1 VALUES(20, 20); |
| 217 |
[connection slave] |
| 218 |
[connection master] |
| 219 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 220 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:10"; |
| 221 |
INSERT INTO t1 VALUES(21, NULL); |
| 222 |
SET GTID_NEXT = AUTOMATIC; |
| 223 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:11"; |
| 224 |
INSERT INTO t1 VALUES(22, NULL); |
| 225 |
SET GTID_NEXT = AUTOMATIC; |
| 226 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:12"; |
| 227 |
INSERT INTO t1 VALUES(23, NULL); |
| 228 |
SET GTID_NEXT = AUTOMATIC; |
| 229 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 230 |
[connection slave] |
| 231 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:10"; |
| 232 |
BEGIN; |
| 233 |
[connection rpl_slave_connection_2] |
| 234 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:11"; |
| 235 |
BEGIN; |
| 236 |
[connection rpl_slave_connection_3] |
| 237 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:12"; |
| 238 |
BEGIN; |
| 239 |
[connection slave1] |
| 240 |
include/start_slave_sql.inc |
| 241 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 242 |
include/assert.inc [MTS worker thread count is correct] |
| 243 |
include/assert.inc [Replica preserve commit order is 1] |
| 244 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 245 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 246 |
[connection rpl_slave_connection_2] |
| 247 |
ROLLBACK; |
| 248 |
SET GTID_NEXT = AUTOMATIC; |
| 249 |
include/wait_condition.inc [First worker must wait on commit order] |
| 250 |
[connection slave1] |
| 251 |
SET GLOBAL read_only = ON; |
| 252 |
[connection slave] |
| 253 |
ROLLBACK; |
| 254 |
SET GTID_NEXT = AUTOMATIC; |
| 255 |
[connection slave1] |
| 256 |
include/wait_condition.inc [Coordinator must wait for workers to stop] |
| 257 |
[connection rpl_slave_connection_3] |
| 258 |
ROLLBACK; |
| 259 |
SET GTID_NEXT = AUTOMATIC; |
| 260 |
[connection slave] |
| 261 |
include/wait_for_slave_sql_error.inc [errno=3030] |
| 262 |
[connection slave1] |
| 263 |
SET GLOBAL read_only = OFF; |
| 264 |
[connection slave] |
| 265 |
include/start_slave_sql.inc |
| 266 |
[connection master] |
| 267 |
include/sync_slave_sql_with_master.inc |
| 268 |
include/rpl_diff.inc |
| 269 |
[connection master] |
| 270 |
include/sync_slave_sql_with_master.inc |
| 271 |
include/stop_slave_sql.inc |
| 272 |
|
| 273 |
# |
| 274 |
# TC3. `FLUSH TABLES WITH READ LOCK` issued by client and DDL replicated |
| 275 |
# from source. |
| 276 |
#------------------------------------------------------------------------ |
| 277 |
[connection master] |
| 278 |
INSERT INTO t1 VALUES(24, 24); |
| 279 |
[connection slave] |
| 280 |
[connection master] |
| 281 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 282 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:13"; |
| 283 |
ALTER TABLE t2 ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1; |
| 284 |
SET GTID_NEXT = AUTOMATIC; |
| 285 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:14"; |
| 286 |
INSERT INTO t1 VALUES(25, NULL); |
| 287 |
SET GTID_NEXT = AUTOMATIC; |
| 288 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:15"; |
| 289 |
INSERT INTO t1 VALUES(26, NULL); |
| 290 |
SET GTID_NEXT = AUTOMATIC; |
| 291 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 292 |
[connection slave] |
| 293 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:13"; |
| 294 |
BEGIN; |
| 295 |
[connection rpl_slave_connection_2] |
| 296 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:14"; |
| 297 |
BEGIN; |
| 298 |
[connection rpl_slave_connection_3] |
| 299 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:15"; |
| 300 |
BEGIN; |
| 301 |
[connection slave1] |
| 302 |
include/start_slave_sql.inc |
| 303 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 304 |
include/assert.inc [MTS worker thread count is correct] |
| 305 |
include/assert.inc [Replica preserve commit order is 1] |
| 306 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 307 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 308 |
[connection rpl_slave_connection_2] |
| 309 |
ROLLBACK; |
| 310 |
SET GTID_NEXT = AUTOMATIC; |
| 311 |
include/wait_condition.inc [First worker must wait on commit order] |
| 312 |
[connection rpl_slave_connection_3] |
| 313 |
ROLLBACK; |
| 314 |
SET GTID_NEXT = AUTOMATIC; |
| 315 |
include/wait_condition.inc [Second worker must wait on commit order] |
| 316 |
[connection slave1] |
| 317 |
FLUSH TABLES WITH READ LOCK; |
| 318 |
[connection slave] |
| 319 |
include/wait_condition.inc [Client connection must wait for state] |
| 320 |
ROLLBACK; |
| 321 |
SET GTID_NEXT = AUTOMATIC; |
| 322 |
[connection slave1] |
| 323 |
include/wait_for_slave_param.inc [Slave_SQL_Running_State] |
| 324 |
[connection slave1] |
| 325 |
UNLOCK TABLES; |
| 326 |
[connection slave] |
| 327 |
include/wait_for_slave_sql_error.inc [errno=1213] |
| 328 |
[connection slave1] |
| 329 |
UNLOCK TABLES; |
| 330 |
[connection slave] |
| 331 |
include/start_slave_sql.inc |
| 332 |
[connection master] |
| 333 |
include/sync_slave_sql_with_master.inc |
| 334 |
include/rpl_diff.inc |
| 335 |
[connection master] |
| 336 |
include/sync_slave_sql_with_master.inc |
| 337 |
include/stop_slave_sql.inc |
| 338 |
[connection master] |
| 339 |
INSERT INTO t1 VALUES(27, 27); |
| 340 |
[connection slave] |
| 341 |
[connection master] |
| 342 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 343 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:16"; |
| 344 |
ALTER TABLE t2 ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=1; |
| 345 |
SET GTID_NEXT = AUTOMATIC; |
| 346 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:17"; |
| 347 |
INSERT INTO t1 VALUES(28, NULL); |
| 348 |
SET GTID_NEXT = AUTOMATIC; |
| 349 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:18"; |
| 350 |
INSERT INTO t1 VALUES(29, NULL); |
| 351 |
SET GTID_NEXT = AUTOMATIC; |
| 352 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 353 |
[connection slave] |
| 354 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:16"; |
| 355 |
BEGIN; |
| 356 |
[connection rpl_slave_connection_2] |
| 357 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:17"; |
| 358 |
BEGIN; |
| 359 |
[connection rpl_slave_connection_3] |
| 360 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:18"; |
| 361 |
BEGIN; |
| 362 |
[connection slave1] |
| 363 |
include/start_slave_sql.inc |
| 364 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 365 |
include/assert.inc [MTS worker thread count is correct] |
| 366 |
include/assert.inc [Replica preserve commit order is 1] |
| 367 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 368 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 369 |
[connection rpl_slave_connection_2] |
| 370 |
ROLLBACK; |
| 371 |
SET GTID_NEXT = AUTOMATIC; |
| 372 |
include/wait_condition.inc [First worker must wait on commit order] |
| 373 |
[connection slave1] |
| 374 |
FLUSH TABLES WITH READ LOCK; |
| 375 |
[connection slave] |
| 376 |
include/wait_condition.inc [Client connection must wait for state] |
| 377 |
ROLLBACK; |
| 378 |
SET GTID_NEXT = AUTOMATIC; |
| 379 |
[connection slave1] |
| 380 |
include/wait_for_slave_param.inc [Slave_SQL_Running_State] |
| 381 |
[connection slave1] |
| 382 |
UNLOCK TABLES; |
| 383 |
include/wait_condition.inc [Coordinator must wait for workers to stop] |
| 384 |
[connection rpl_slave_connection_3] |
| 385 |
ROLLBACK; |
| 386 |
SET GTID_NEXT = AUTOMATIC; |
| 387 |
[connection slave] |
| 388 |
include/wait_for_slave_sql_error.inc [errno=3030] |
| 389 |
[connection slave1] |
| 390 |
UNLOCK TABLES; |
| 391 |
[connection slave] |
| 392 |
include/start_slave_sql.inc |
| 393 |
[connection master] |
| 394 |
include/sync_slave_sql_with_master.inc |
| 395 |
include/rpl_diff.inc |
| 396 |
[connection master] |
| 397 |
include/sync_slave_sql_with_master.inc |
| 398 |
include/stop_slave_sql.inc |
| 399 |
|
| 400 |
# |
| 401 |
# TC4. `FLUSH TABLES WITH READ LOCK` issued by client and DML replicated |
| 402 |
# from source. |
| 403 |
#------------------------------------------------------------------------ |
| 404 |
[connection master] |
| 405 |
INSERT INTO t1 VALUES(30, 30); |
| 406 |
[connection slave] |
| 407 |
[connection master] |
| 408 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 409 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:19"; |
| 410 |
INSERT INTO t1 VALUES(31, NULL); |
| 411 |
SET GTID_NEXT = AUTOMATIC; |
| 412 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:20"; |
| 413 |
INSERT INTO t1 VALUES(32, NULL); |
| 414 |
SET GTID_NEXT = AUTOMATIC; |
| 415 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:21"; |
| 416 |
INSERT INTO t1 VALUES(33, NULL); |
| 417 |
SET GTID_NEXT = AUTOMATIC; |
| 418 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 419 |
[connection slave] |
| 420 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:19"; |
| 421 |
BEGIN; |
| 422 |
[connection rpl_slave_connection_2] |
| 423 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:20"; |
| 424 |
BEGIN; |
| 425 |
[connection rpl_slave_connection_3] |
| 426 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:21"; |
| 427 |
BEGIN; |
| 428 |
[connection slave1] |
| 429 |
include/start_slave_sql.inc |
| 430 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 431 |
include/assert.inc [MTS worker thread count is correct] |
| 432 |
include/assert.inc [Replica preserve commit order is 1] |
| 433 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 434 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 435 |
[connection rpl_slave_connection_2] |
| 436 |
ROLLBACK; |
| 437 |
SET GTID_NEXT = AUTOMATIC; |
| 438 |
include/wait_condition.inc [First worker must wait on commit order] |
| 439 |
[connection rpl_slave_connection_3] |
| 440 |
ROLLBACK; |
| 441 |
SET GTID_NEXT = AUTOMATIC; |
| 442 |
include/wait_condition.inc [Second worker must wait on commit order] |
| 443 |
[connection slave1] |
| 444 |
FLUSH TABLES WITH READ LOCK; |
| 445 |
[connection slave] |
| 446 |
include/wait_condition.inc [Client connection must wait for state] |
| 447 |
ROLLBACK; |
| 448 |
SET GTID_NEXT = AUTOMATIC; |
| 449 |
[connection slave1] |
| 450 |
include/wait_for_slave_param.inc [Slave_SQL_Running_State] |
| 451 |
[connection slave1] |
| 452 |
UNLOCK TABLES; |
| 453 |
[connection slave] |
| 454 |
include/wait_for_slave_sql_error.inc [errno=1213] |
| 455 |
[connection slave1] |
| 456 |
UNLOCK TABLES; |
| 457 |
[connection slave] |
| 458 |
include/start_slave_sql.inc |
| 459 |
[connection master] |
| 460 |
include/sync_slave_sql_with_master.inc |
| 461 |
include/rpl_diff.inc |
| 462 |
[connection master] |
| 463 |
include/sync_slave_sql_with_master.inc |
| 464 |
include/stop_slave_sql.inc |
| 465 |
[connection master] |
| 466 |
INSERT INTO t1 VALUES(34, 34); |
| 467 |
[connection slave] |
| 468 |
[connection master] |
| 469 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 470 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:22"; |
| 471 |
INSERT INTO t1 VALUES(35, NULL); |
| 472 |
SET GTID_NEXT = AUTOMATIC; |
| 473 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:23"; |
| 474 |
INSERT INTO t1 VALUES(36, NULL); |
| 475 |
SET GTID_NEXT = AUTOMATIC; |
| 476 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:24"; |
| 477 |
INSERT INTO t1 VALUES(37, NULL); |
| 478 |
SET GTID_NEXT = AUTOMATIC; |
| 479 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 480 |
[connection slave] |
| 481 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:22"; |
| 482 |
BEGIN; |
| 483 |
[connection rpl_slave_connection_2] |
| 484 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:23"; |
| 485 |
BEGIN; |
| 486 |
[connection rpl_slave_connection_3] |
| 487 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:24"; |
| 488 |
BEGIN; |
| 489 |
[connection slave1] |
| 490 |
include/start_slave_sql.inc |
| 491 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 492 |
include/assert.inc [MTS worker thread count is correct] |
| 493 |
include/assert.inc [Replica preserve commit order is 1] |
| 494 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 495 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 496 |
[connection rpl_slave_connection_2] |
| 497 |
ROLLBACK; |
| 498 |
SET GTID_NEXT = AUTOMATIC; |
| 499 |
include/wait_condition.inc [First worker must wait on commit order] |
| 500 |
[connection slave1] |
| 501 |
FLUSH TABLES WITH READ LOCK; |
| 502 |
[connection slave] |
| 503 |
include/wait_condition.inc [Client connection must wait for state] |
| 504 |
ROLLBACK; |
| 505 |
SET GTID_NEXT = AUTOMATIC; |
| 506 |
[connection slave1] |
| 507 |
include/wait_for_slave_param.inc [Slave_SQL_Running_State] |
| 508 |
[connection slave1] |
| 509 |
UNLOCK TABLES; |
| 510 |
include/wait_condition.inc [Coordinator must wait for workers to stop] |
| 511 |
[connection rpl_slave_connection_3] |
| 512 |
ROLLBACK; |
| 513 |
SET GTID_NEXT = AUTOMATIC; |
| 514 |
[connection slave] |
| 515 |
include/wait_for_slave_sql_error.inc [errno=3030] |
| 516 |
[connection slave1] |
| 517 |
UNLOCK TABLES; |
| 518 |
[connection slave] |
| 519 |
include/start_slave_sql.inc |
| 520 |
[connection master] |
| 521 |
include/sync_slave_sql_with_master.inc |
| 522 |
include/rpl_diff.inc |
| 523 |
[connection master] |
| 524 |
include/sync_slave_sql_with_master.inc |
| 525 |
include/stop_slave_sql.inc |
| 526 |
|
| 527 |
# |
| 528 |
# TC5. DML issued by client and `XA PREPARE` replicated from source. |
| 529 |
#------------------------------------------------------------------------ |
| 530 |
[connection master] |
| 531 |
INSERT INTO t1 VALUES(41, 41); |
| 532 |
[connection slave] |
| 533 |
[connection master] |
| 534 |
# Adding debug point 'set_commit_parent_100' to @@GLOBAL.debug |
| 535 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:25"; |
| 536 |
XA START 'xa1'; INSERT INTO t1 VALUES(42, NULL); XA END 'xa1'; XA PREPARE 'xa1'; |
| 537 |
SET GTID_NEXT = AUTOMATIC; |
| 538 |
# Removing debug point 'set_commit_parent_100' from @@GLOBAL.debug |
| 539 |
[connection slave] |
| 540 |
SET GTID_NEXT = "aaaaaaaa-1111-bbbb-2222-cccccccccccc:25"; |
| 541 |
BEGIN; |
| 542 |
[connection slave1] |
| 543 |
include/start_slave_sql.inc |
| 544 |
include/assert.inc [Replica parallel type is LOGICAL_CLOCK] |
| 545 |
include/assert.inc [MTS worker thread count is correct] |
| 546 |
include/assert.inc [Replica preserve commit order is 1] |
| 547 |
include/assert.inc [Replica transaction retries has correct configured value] |
| 548 |
include/assert.inc [InnoDB lock wait timeout has correct configured value] |
| 549 |
[connection slave1] |
| 550 |
BEGIN; INSERT INTO t1 VALUES(42, NULL); |
| 551 |
[connection slave] |
| 552 |
include/wait_condition.inc [Client connection must wait for state] |
| 553 |
ROLLBACK; |
| 554 |
SET GTID_NEXT = AUTOMATIC; |
| 555 |
[connection slave1] |
| 556 |
[connection slave] |
| 557 |
include/wait_for_slave_sql_error.inc [errno=1205] |
| 558 |
[connection slave1] |
| 559 |
ROLLBACK; |
| 560 |
[connection master] |
| 561 |
XA COMMIT 'xa1'; |
| 562 |
[connection slave] |
| 563 |
include/start_slave_sql.inc |
| 564 |
[connection master] |
| 565 |
include/sync_slave_sql_with_master.inc |
| 566 |
include/rpl_diff.inc |
| 567 |
[connection master] |
| 568 |
include/sync_slave_sql_with_master.inc |
| 569 |
include/stop_slave_sql.inc |
| 570 |
include/start_slave_sql.inc |
| 571 |
[connection master] |
| 572 |
DROP TABLE t1; |
| 573 |
DROP TABLE t2; |
| 574 |
include/rpl_end.inc |
| 575 |
[connection slave] |
| 576 |
SET GLOBAL replica_parallel_type = 'SAVED_REPLICA_PARALLEL_TYPE'; |
| 577 |
SET GLOBAL replica_parallel_workers = SAVED_REPLICA_PARALLEL_WORKERS; |
| 578 |
SET GLOBAL replica_preserve_commit_order = SAVED_REPLICA_PRESERVE_COMMIT_ORDER; |
| 579 |
SET GLOBAL replica_transaction_retries = SAVED_REPLICA_TRANSACTION_RETRIES; |
| 580 |
SET GLOBAL innodb_lock_wait_timeout = SAVED_INNODB_LOCK_WAIT_TIMEOUT; |
| 581 |
SET GLOBAL read_only = SAVED_READ_ONLY; |