List:Commits« Previous MessageNext Message »
From:Marc Alff Date:December 8 2010 5:11am
Subject:bzr push into mysql-5.5-bugteam branch (marc.alff:3176 to 3177) Bug#58798
View as plain text  
 3177 Marc Alff	2010-12-07
      Bug#58798 SHOW ENGINE PERFORMANCE_SCHEMA STATUS: incorrect table lettercase
      
      Before this fix, the output of SHOW ENGINE PERFORMANCE_SCHEMA STATUS
      used uppercase to name performance schema tables.
      
      This is inconsistent since performance schema tables have been renamed to lowercase.
      
      Also, an old table 'PROCESSLIST' was still visible, 
      even after this table got renamed to 'threads'.
      
      This fix:
      - correctly uses lowercases in the output, to match the current naming.
      - replaced 'PROCESSLIST' with 'threads'.
      
      Tested the output of SHOW ENGINE PERFORMANCE_SCHEMA STATUS manually.
      No automated test cases can be written for this, 
      since the output is too platform dependent (sizes).

    modified:
      storage/perfschema/pfs_engine_table.cc
 3176 Ramil Kalimullin	2010-12-07
      Fix for bug #58669: read_only not enforced on 5.5.x
      merged from mysql-5.5.8-release tree,
      revision: ramil@stripped

    added:
      mysql-test/r/bug58669.result
      mysql-test/t/bug58669-master.opt
      mysql-test/t/bug58669.test
    modified:
      sql/mysqld.cc
      sql/mysqld.h
      sql/sys_vars.cc
=== modified file 'storage/perfschema/pfs_engine_table.cc'
--- a/storage/perfschema/pfs_engine_table.cc	2010-12-01 12:06:41 +0000
+++ b/storage/perfschema/pfs_engine_table.cc	2010-12-07 20:00:33 +0000
@@ -519,9 +519,9 @@ bool pfs_show_status(handlerton *hton, T
   /*
     Note about naming conventions:
     - Internal buffers exposed as a table in the performance schema are named
-    after the table, as in 'EVENTS_WAITS_CURRENT'
+    after the table, as in 'events_waits_current'
     - Internal buffers not exposed by a table are named with parenthesis,
-    as in '(PFS_MUTEX_CLASS)'.
+    as in '(pfs_mutex_class)'.
   */
   if (stat != HA_ENGINE_STATUS)
     DBUG_RETURN(false);
@@ -532,219 +532,219 @@ bool pfs_show_status(handlerton *hton, T
   {
     switch (i){
     case 0:
-      name= "EVENTS_WAITS_CURRENT.ROW_SIZE";
+      name= "events_waits_current.row_size";
       size= sizeof(PFS_wait_locker);
       break;
     case 1:
-      name= "EVENTS_WAITS_CURRENT.ROW_COUNT";
+      name= "events_waits_current.row_count";
       size= LOCKER_STACK_SIZE * thread_max;
       break;
     case 2:
-      name= "EVENTS_WAITS_HISTORY.ROW_SIZE";
+      name= "events_waits_history.row_size";
       size= sizeof(PFS_events_waits);
       break;
     case 3:
-      name= "EVENTS_WAITS_HISTORY.ROW_COUNT";
+      name= "events_waits_history.row_count";
       size= events_waits_history_per_thread * thread_max;
       break;
     case 4:
-      name= "EVENTS_WAITS_HISTORY.MEMORY";
+      name= "events_waits_history.memory";
       size= events_waits_history_per_thread * thread_max
         * sizeof(PFS_events_waits);
       total_memory+= size;
       break;
     case 5:
-      name= "EVENTS_WAITS_HISTORY_LONG.ROW_SIZE";
+      name= "events_waits_history_long.row_size";
       size= sizeof(PFS_events_waits);
       break;
     case 6:
-      name= "EVENTS_WAITS_HISTORY_LONG.ROW_COUNT";
+      name= "events_waits_history_long.row_count";
       size= events_waits_history_long_size;
       break;
     case 7:
-      name= "EVENTS_WAITS_HISTORY_LONG.MEMORY";
+      name= "events_waits_history_long.memory";
       size= events_waits_history_long_size * sizeof(PFS_events_waits);
       total_memory+= size;
       break;
     case 8:
-      name= "(PFS_MUTEX_CLASS).ROW_SIZE";
+      name= "(pfs_mutex_class).row_size";
       size= sizeof(PFS_mutex_class);
       break;
     case 9:
-      name= "(PFS_MUTEX_CLASS).ROW_COUNT";
+      name= "(pfs_mutex_class).row_count";
       size= mutex_class_max;
       break;
     case 10:
-      name= "(PFS_MUTEX_CLASS).MEMORY";
+      name= "(pfs_mutex_class).memory";
       size= mutex_class_max * sizeof(PFS_mutex_class);
       total_memory+= size;
       break;
     case 11:
-      name= "(PFS_RWLOCK_CLASS).ROW_SIZE";
+      name= "(pfs_rwlock_class).row_size";
       size= sizeof(PFS_rwlock_class);
       break;
     case 12:
-      name= "(PFS_RWLOCK_CLASS).ROW_COUNT";
+      name= "(pfs_rwlock_class).row_count";
       size= rwlock_class_max;
       break;
     case 13:
-      name= "(PFS_RWLOCK_CLASS).MEMORY";
+      name= "(pfs_rwlock_class).memory";
       size= rwlock_class_max * sizeof(PFS_rwlock_class);
       total_memory+= size;
       break;
     case 14:
-      name= "(PFS_COND_CLASS).ROW_SIZE";
+      name= "(pfs_cond_class).row_size";
       size= sizeof(PFS_cond_class);
       break;
     case 15:
-      name= "(PFS_COND_CLASS).ROW_COUNT";
+      name= "(pfs_cond_class).row_count";
       size= cond_class_max;
       break;
     case 16:
-      name= "(PFS_COND_CLASS).MEMORY";
+      name= "(pfs_cond_class).memory";
       size= cond_class_max * sizeof(PFS_cond_class);
       total_memory+= size;
       break;
     case 17:
-      name= "(PFS_THREAD_CLASS).ROW_SIZE";
+      name= "(pfs_thread_class).row_size";
       size= sizeof(PFS_thread_class);
       break;
     case 18:
-      name= "(PFS_THREAD_CLASS).ROW_COUNT";
+      name= "(pfs_thread_class).row_count";
       size= thread_class_max;
       break;
     case 19:
-      name= "(PFS_THREAD_CLASS).MEMORY";
+      name= "(pfs_thread_class).memory";
       size= thread_class_max * sizeof(PFS_thread_class);
       total_memory+= size;
       break;
     case 20:
-      name= "(PFS_FILE_CLASS).ROW_SIZE";
+      name= "(pfs_file_class).row_size";
       size= sizeof(PFS_file_class);
       break;
     case 21:
-      name= "(PFS_FILE_CLASS).ROW_COUNT";
+      name= "(pfs_file_class).row_count";
       size= file_class_max;
       break;
     case 22:
-      name= "(PFS_FILE_CLASS).MEMORY";
+      name= "(pfs_file_class).memory";
       size= file_class_max * sizeof(PFS_file_class);
       total_memory+= size;
       break;
     case 23:
-      name= "MUTEX_INSTANCES.ROW_SIZE";
+      name= "mutex_instances.row_size";
       size= sizeof(PFS_mutex);
       break;
     case 24:
-      name= "MUTEX_INSTANCES.ROW_COUNT";
+      name= "mutex_instances.row_count";
       size= mutex_max;
       break;
     case 25:
-      name= "MUTEX_INSTANCES.MEMORY";
+      name= "mutex_instances.memory";
       size= mutex_max * sizeof(PFS_mutex);
       total_memory+= size;
       break;
     case 26:
-      name= "RWLOCK_INSTANCES.ROW_SIZE";
+      name= "rwlock_instances.row_size";
       size= sizeof(PFS_rwlock);
       break;
     case 27:
-      name= "RWLOCK_INSTANCES.ROW_COUNT";
+      name= "rwlock_instances.row_count";
       size= rwlock_max;
       break;
     case 28:
-      name= "RWLOCK_INSTANCES.MEMORY";
+      name= "rwlock_instances.memory";
       size= rwlock_max * sizeof(PFS_rwlock);
       total_memory+= size;
       break;
     case 29:
-      name= "COND_INSTANCES.ROW_SIZE";
+      name= "cond_instances.row_size";
       size= sizeof(PFS_cond);
       break;
     case 30:
-      name= "COND_INSTANCES.ROW_COUNT";
+      name= "cond_instances.row_count";
       size= cond_max;
       break;
     case 31:
-      name= "COND_INSTANCES.MEMORY";
+      name= "cond_instances.memory";
       size= cond_max * sizeof(PFS_cond);
       total_memory+= size;
       break;
     case 32:
-      name= "PROCESSLIST.ROW_SIZE";
+      name= "threads.row_size";
       size= sizeof(PFS_thread);
       break;
     case 33:
-      name= "PROCESSLIST.ROW_COUNT";
+      name= "threads.row_count";
       size= thread_max;
       break;
     case 34:
-      name= "PROCESSLIST.MEMORY";
+      name= "threads.memory";
       size= thread_max * sizeof(PFS_thread);
       total_memory+= size;
       break;
     case 35:
-      name= "FILE_INSTANCES.ROW_SIZE";
+      name= "file_instances.row_size";
       size= sizeof(PFS_file);
       break;
     case 36:
-      name= "FILE_INSTANCES.ROW_COUNT";
+      name= "file_instances.row_count";
       size= file_max;
       break;
     case 37:
-      name= "FILE_INSTANCES.MEMORY";
+      name= "file_instances.memory";
       size= file_max * sizeof(PFS_file);
       total_memory+= size;
       break;
     case 38:
-      name= "(PFS_FILE_HANDLE).ROW_SIZE";
+      name= "(pfs_file_handle).row_size";
       size= sizeof(PFS_file*);
       break;
     case 39:
-      name= "(PFS_FILE_HANDLE).ROW_COUNT";
+      name= "(pfs_file_handle).row_count";
       size= file_handle_max;
       break;
     case 40:
-      name= "(PFS_FILE_HANDLE).MEMORY";
+      name= "(pfs_file_handle).memory";
       size= file_handle_max * sizeof(PFS_file*);
       total_memory+= size;
       break;
     case 41:
-      name= "EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME.ROW_SIZE";
+      name= "events_waits_summary_by_thread_by_event_name.row_size";
       size= sizeof(PFS_single_stat_chain);
       break;
     case 42:
-      name= "EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME.ROW_COUNT";
+      name= "events_waits_summary_by_thread_by_event_name.row_count";
       size= thread_max * instr_class_per_thread;
       break;
     case 43:
-      name= "EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME.MEMORY";
+      name= "events_waits_summary_by_thread_by_event_name.memory";
       size= thread_max * instr_class_per_thread * sizeof(PFS_single_stat_chain);
       total_memory+= size;
       break;
     case 44:
-      name= "(PFS_TABLE_SHARE).ROW_SIZE";
+      name= "(pfs_table_share).row_size";
       size= sizeof(PFS_table_share);
       break;
     case 45:
-      name= "(PFS_TABLE_SHARE).ROW_COUNT";
+      name= "(pfs_table_share).row_count";
       size= table_share_max;
       break;
     case 46:
-      name= "(PFS_TABLE_SHARE).MEMORY";
+      name= "(pfs_table_share).memory";
       size= table_share_max * sizeof(PFS_table_share);
       total_memory+= size;
       break;
     case 47:
-      name= "(PFS_TABLE).ROW_SIZE";
+      name= "(pfs_table).row_size";
       size= sizeof(PFS_table);
       break;
     case 48:
-      name= "(PFS_TABLE).ROW_COUNT";
+      name= "(pfs_table).row_count";
       size= table_max;
       break;
     case 49:
-      name= "(PFS_TABLE).MEMORY";
+      name= "(pfs_table).memory";
       size= table_max * sizeof(PFS_table);
       total_memory+= size;
       break;
@@ -753,7 +753,7 @@ bool pfs_show_status(handlerton *hton, T
       for aggregation in total_memory.
     */
     case 50:
-      name= "PERFORMANCE_SCHEMA.MEMORY";
+      name= "performance_schema.memory";
       size= total_memory;
       /* This will fail if something is not advertised here */
       DBUG_ASSERT(size == pfs_allocated_memory);

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.5-bugteam branch (marc.alff:3176 to 3177) Bug#58798Marc Alff8 Dec