From: Christopher Powers Date: August 3 2011 5:50pm Subject: bzr push into mysql-trunk branch (chris.powers:3343 to 3344) WL#4896 List-Archive: http://lists.mysql.com/commits/140532 Message-Id: <201108031750.p73HokPP017232@acsmt356.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit 3344 Christopher Powers 2011-08-03 WL#4896 "Performance Schema Net IO" Added dml_handler.test to verify that the Performance Schema does not support HANDLER statements. added: mysql-test/suite/perfschema/r/dml_handler.result mysql-test/suite/perfschema/t/dml_handler.test 3343 Christopher Powers 2011-08-03 WL#4896 "Performance Schema Net IO" - Updated perfschema.schema.test to include socket tables modified: mysql-test/suite/perfschema/include/schema.inc mysql-test/suite/perfschema/r/schema.result mysql-test/suite/perfschema/t/disabled.def mysql-test/t/disabled.def === added file 'mysql-test/suite/perfschema/r/dml_handler.result' --- a/mysql-test/suite/perfschema/r/dml_handler.result 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/perfschema/r/dml_handler.result 2011-08-03 17:49:55 +0000 @@ -0,0 +1,119 @@ + +# Create a temporary table of performance schema table names + +CREATE TEMPORARY TABLE table_list (id INT AUTO_INCREMENT, PRIMARY KEY (id)) AS +SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES +WHERE TABLE_SCHEMA='performance_schema'; +SELECT COUNT(*) FROM table_list INTO @table_count; + +# For each table in the performance schema, attempt HANDLER...OPEN, +# which should fail with an error 1031, ER_ILLEGAL_HA. + +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=36; +HANDLER performance_schema.threads OPEN; +ERROR HY000: Table storage engine for 'threads' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=35; +HANDLER performance_schema.table_lock_waits_summary_by_table OPEN; +ERROR HY000: Table storage engine for 'table_lock_waits_summary_by_table' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=34; +HANDLER performance_schema.table_io_waits_summary_by_table OPEN; +ERROR HY000: Table storage engine for 'table_io_waits_summary_by_table' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=33; +HANDLER performance_schema.table_io_waits_summary_by_index_usage OPEN; +ERROR HY000: Table storage engine for 'table_io_waits_summary_by_index_usage' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=32; +HANDLER performance_schema.socket_summary_by_instance OPEN; +ERROR HY000: Table storage engine for 'socket_summary_by_instance' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=31; +HANDLER performance_schema.socket_summary_by_event_name OPEN; +ERROR HY000: Table storage engine for 'socket_summary_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=30; +HANDLER performance_schema.socket_instances OPEN; +ERROR HY000: Table storage engine for 'socket_instances' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=29; +HANDLER performance_schema.setup_timers OPEN; +ERROR HY000: Table storage engine for 'setup_timers' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=28; +HANDLER performance_schema.setup_objects OPEN; +ERROR HY000: Table storage engine for 'setup_objects' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=27; +HANDLER performance_schema.setup_instruments OPEN; +ERROR HY000: Table storage engine for 'setup_instruments' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=26; +HANDLER performance_schema.setup_consumers OPEN; +ERROR HY000: Table storage engine for 'setup_consumers' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=25; +HANDLER performance_schema.setup_actors OPEN; +ERROR HY000: Table storage engine for 'setup_actors' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=24; +HANDLER performance_schema.rwlock_instances OPEN; +ERROR HY000: Table storage engine for 'rwlock_instances' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=23; +HANDLER performance_schema.performance_timers OPEN; +ERROR HY000: Table storage engine for 'performance_timers' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=22; +HANDLER performance_schema.objects_summary_global_by_type OPEN; +ERROR HY000: Table storage engine for 'objects_summary_global_by_type' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=21; +HANDLER performance_schema.mutex_instances OPEN; +ERROR HY000: Table storage engine for 'mutex_instances' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=20; +HANDLER performance_schema.file_summary_by_instance OPEN; +ERROR HY000: Table storage engine for 'file_summary_by_instance' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=19; +HANDLER performance_schema.file_summary_by_event_name OPEN; +ERROR HY000: Table storage engine for 'file_summary_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=18; +HANDLER performance_schema.file_instances OPEN; +ERROR HY000: Table storage engine for 'file_instances' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=17; +HANDLER performance_schema.events_waits_summary_global_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_waits_summary_global_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=16; +HANDLER performance_schema.events_waits_summary_by_thread_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_waits_summary_by_thread_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=15; +HANDLER performance_schema.events_waits_summary_by_instance OPEN; +ERROR HY000: Table storage engine for 'events_waits_summary_by_instance' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=14; +HANDLER performance_schema.events_waits_history_long OPEN; +ERROR HY000: Table storage engine for 'events_waits_history_long' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=13; +HANDLER performance_schema.events_waits_history OPEN; +ERROR HY000: Table storage engine for 'events_waits_history' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=12; +HANDLER performance_schema.events_waits_current OPEN; +ERROR HY000: Table storage engine for 'events_waits_current' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=11; +HANDLER performance_schema.events_statements_summary_global_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_statements_summary_global_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=10; +HANDLER performance_schema.events_statements_summary_by_thread_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_statements_summary_by_thread_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=9; +HANDLER performance_schema.events_statements_history_long OPEN; +ERROR HY000: Table storage engine for 'events_statements_history_long' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=8; +HANDLER performance_schema.events_statements_history OPEN; +ERROR HY000: Table storage engine for 'events_statements_history' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=7; +HANDLER performance_schema.events_statements_current OPEN; +ERROR HY000: Table storage engine for 'events_statements_current' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=6; +HANDLER performance_schema.events_stages_summary_global_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_stages_summary_global_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=5; +HANDLER performance_schema.events_stages_summary_by_thread_by_event_name OPEN; +ERROR HY000: Table storage engine for 'events_stages_summary_by_thread_by_event_name' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=4; +HANDLER performance_schema.events_stages_history_long OPEN; +ERROR HY000: Table storage engine for 'events_stages_history_long' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=3; +HANDLER performance_schema.events_stages_history OPEN; +ERROR HY000: Table storage engine for 'events_stages_history' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=2; +HANDLER performance_schema.events_stages_current OPEN; +ERROR HY000: Table storage engine for 'events_stages_current' doesn't have this option +SELECT TABLE_NAME INTO @table_name FROM table_list WHERE id=1; +HANDLER performance_schema.cond_instances OPEN; +ERROR HY000: Table storage engine for 'cond_instances' doesn't have this option === added file 'mysql-test/suite/perfschema/t/dml_handler.test' --- a/mysql-test/suite/perfschema/t/dml_handler.test 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/perfschema/t/dml_handler.test 2011-08-03 17:49:55 +0000 @@ -0,0 +1,55 @@ +# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; version 2 of the License. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software Foundation, +# 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA + +# Tests for PERFORMANCE_SCHEMA + +--source include/not_embedded.inc +--source include/have_perfschema.inc + +#============================================================================== +# This test verifies that the peformance schema storage engine does not support +# HANDLER operations. +# +# Get the list of tables from information_schema.tables, store the table names +# in a temporary table. For each table in the list, attempt a HANDLER ... OPEN, +# which should return error 1031, "Table storage engine for '