| 1 |
include/group_replication.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 server1] |
| 6 |
|
| 7 |
############################################################ |
| 8 |
# 1. Verify that the entries corresponding to the |
| 9 |
# instrumented memory are in the setup instruments |
| 10 |
# table and the memory summary tables. |
| 11 |
SELECT * FROM performance_schema.setup_instruments WHERE NAME LIKE 'memory/group_rpl/write_set_encoded'; |
| 12 |
NAME ENABLED TIMED PROPERTIES FLAGS VOLATILITY DOCUMENTATION |
| 13 |
memory/group_rpl/write_set_encoded YES NULL global_statistics 0 Memory used to encode write set before getting broadcasted to group members. |
| 14 |
include/assert.inc ['There should be 1 entry corresponding to the write_set_encoded in the setup_instruments table after starting GR'] |
| 15 |
SELECT EVENT_NAME FROM performance_schema.memory_summary_global_by_event_name WHERE EVENT_NAME LIKE 'memory/group_rpl/write_set_encoded'; |
| 16 |
EVENT_NAME |
| 17 |
memory/group_rpl/write_set_encoded |
| 18 |
include/assert.inc ['There should be 1 entry corresponding to the write_set_encoded in the memory_summary_global_by_event_name table after starting GR'] |
| 19 |
|
| 20 |
############################################################ |
| 21 |
# 2. Verify that the sum of bytes allocated is greater than |
| 22 |
# zero for a transaction and zero after transaction is |
| 23 |
# finished. |
| 24 |
CREATE TABLE t1(c1 INT PRIMARY KEY) ENGINE=innodb; |
| 25 |
SET @@GLOBAL.DEBUG= '+d,group_replication_after_add_write_set'; |
| 26 |
INSERT INTO t1 VALUES(1);; |
| 27 |
[connection server_1] |
| 28 |
SET DEBUG_SYNC= "now WAIT_FOR signal.group_replication_after_add_write_set_reached"; |
| 29 |
include/assert.inc ['The sum bytes allocated must be greater than 0'] |
| 30 |
SET @@GLOBAL.DEBUG= '+d,group_replication_after_before_commit_hook'; |
| 31 |
SET @@GLOBAL.DEBUG= '-d,group_replication_after_add_write_set'; |
| 32 |
SET DEBUG_SYNC= "now SIGNAL signal.group_replication_after_add_write_set_continue"; |
| 33 |
SET DEBUG_SYNC= "now WAIT_FOR signal.group_replication_after_before_commit_hook_reached"; |
| 34 |
include/assert.inc ['The sum of bytes allocated must be zero'] |
| 35 |
SET @@GLOBAL.DEBUG= '-d,group_replication_after_before_commit_hook'; |
| 36 |
SET DEBUG_SYNC= "now SIGNAL signal.group_replication_after_before_commit_hook_continue"; |
| 37 |
[connection server1] |
| 38 |
DROP TABLE t1; |
| 39 |
|
| 40 |
############################################################ |
| 41 |
# 3. Stop GR |
| 42 |
include/stop_group_replication.inc |
| 43 |
|
| 44 |
############################################################## |
| 45 |
# 4. Verify that the entries corresponding to the instrumented |
| 46 |
# write_set_encoded remain in the tables after stopping GR. |
| 47 |
SELECT * FROM performance_schema.setup_instruments WHERE NAME LIKE 'memory/group_rpl/write_set_encoded'; |
| 48 |
NAME ENABLED TIMED PROPERTIES FLAGS VOLATILITY DOCUMENTATION |
| 49 |
memory/group_rpl/write_set_encoded YES NULL global_statistics 0 Memory used to encode write set before getting broadcasted to group members. |
| 50 |
include/assert.inc ['There should be 1 entry corresponding to the write_set_encoded in the setup_instruments table after stopping GR'] |
| 51 |
SELECT EVENT_NAME, CURRENT_NUMBER_OF_BYTES_USED FROM performance_schema.memory_summary_global_by_event_name WHERE EVENT_NAME LIKE 'memory/group_rpl/write_set_encoded'; |
| 52 |
EVENT_NAME CURRENT_NUMBER_OF_BYTES_USED |
| 53 |
memory/group_rpl/write_set_encoded 0 |
| 54 |
include/assert.inc ['There should be 1 entry corresponding to the write_set_encoded in the memory_summary_global_by_event_name table after stopping GR'] |
| 55 |
|
| 56 |
################################################################# |
| 57 |
# 5. Assert that the number of bytes allocated for |
| 58 |
# write_set_encoded event must be 0. |
| 59 |
include/assert.inc ['The sum of bytes allocated must be zero after stopping GR'] |
| 60 |
|
| 61 |
include/group_replication_end.inc |