| 1 |
-- source include/not_embedded.inc |
| 2 |
-- source include/have_innodb.inc |
| 3 |
|
| 4 |
# Add to users to the setup_actors table: one enabled, and one disabled |
| 5 |
INSERT INTO performance_schema.setup_actors |
| 6 |
VALUES ('localhost', 'foo', '%', 'YES', 'YES'), |
| 7 |
('localhost', 'bar', '%', 'NO', 'NO'); |
| 8 |
|
| 9 |
# Disable a few instruments |
| 10 |
UPDATE performance_schema.setup_instruments |
| 11 |
SET ENABLED = 'NO' |
| 12 |
WHERE NAME LIKE 'stage/innodb/%' |
| 13 |
OR NAME LIKE 'statement/com/%' |
| 14 |
OR NAME = 'idle'; |
| 15 |
|
| 16 |
# Disable the history_long consumers: |
| 17 |
UPDATE performance_schema.setup_consumers |
| 18 |
SET ENABLED = 'NO' |
| 19 |
WHERE NAME LIKE '%\_history\_long'; |
| 20 |
|
| 21 |
# Disable some of the background threads: |
| 22 |
UPDATE performance_schema.threads SET INSTRUMENTED = 'NO' WHERE NAME LIKE 'thread/innodb/srv\_%'; |
| 23 |
|
| 24 |
# Show limited info (no thread or instrument info) |
| 25 |
CALL sys.ps_setup_show_disabled(FALSE, FALSE); |
| 26 |
|
| 27 |
# Should show instrument data, but not thread info |
| 28 |
CALL sys.ps_setup_show_disabled(TRUE, FALSE); |
| 29 |
|
| 30 |
# Should show thread info, but no instrument data |
| 31 |
CALL sys.ps_setup_show_disabled(FALSE, TRUE); |
| 32 |
|
| 33 |
# Should show all info |
| 34 |
CALL sys.ps_setup_show_disabled(TRUE, TRUE); |
| 35 |
|
| 36 |
# Clean up |
| 37 |
-- source ../include/ps_setup_reset_to_default_cleanup.inc |