Merge lp:~stewart/percona-server/bug896439 into lp:percona-server/5.1

Proposed by Stewart Smith
Status: Merged
Approved by: Alexey Kopytov
Approved revision: no longer in the source branch.
Merged at revision: 454
Proposed branch: lp:~stewart/percona-server/bug896439
Merge into: lp:percona-server/5.1
Diff against target: 616 lines (+140/-230)
11 files modified
Percona-Server/mysql-test/r/information_schema.result (+7/-11)
Percona-Server/mysql-test/r/information_schema_db.result (+1/-2)
Percona-Server/mysql-test/r/mysqlshow.result (+2/-4)
Percona-Server/mysql-test/suite/innodb_plugin/r/percona_skip_innodb_i_s.result (+93/-0)
Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s-master.opt (+1/-0)
Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s.test (+21/-0)
Percona-Server/storage/innodb_plugin/Makefile.am (+0/-1)
Percona-Server/storage/innodb_plugin/handler/ha_innodb.cc (+1/-2)
Percona-Server/storage/innodb_plugin/handler/i_s.cc (+14/-158)
Percona-Server/storage/innodb_plugin/handler/i_s.h (+0/-1)
Percona-Server/storage/innodb_plugin/handler/innodb_patch_info.h (+0/-51)
To merge this branch: bzr merge lp:~stewart/percona-server/bug896439
Reviewer Review Type Date Requested Status
Alexey Kopytov (community) Approve
Review via email: mp+110465@code.launchpad.net

Description of the change

fix crashes with selecting Innodb/xtradb I_S tables with skip-innodb.

There was a simple macro to do it and we missed it :(

To post a comment you must log in.
Revision history for this message
Alexey Kopytov (akopytov) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Percona-Server/mysql-test/r/information_schema.result'
2--- Percona-Server/mysql-test/r/information_schema.result 2011-11-24 02:00:56 +0000
3+++ Percona-Server/mysql-test/r/information_schema.result 2012-06-15 06:06:23 +0000
4@@ -83,7 +83,7 @@
5 INNODB_RSEG
6 INNODB_LOCKS
7 INNODB_BUFFER_POOL_PAGES
8-XTRADB_ENHANCEMENTS
9+INNODB_TABLE_STATS
10 INNODB_TRX
11 XTRADB_ADMIN_COMMAND
12 INNODB_LOCK_WAITS
13@@ -96,7 +96,6 @@
14 INNODB_SYS_INDEXES
15 INNODB_BUFFER_POOL_PAGES_BLOB
16 INNODB_CMPMEM_RESET
17-INNODB_TABLE_STATS
18 columns_priv
19 db
20 event
21@@ -901,14 +900,14 @@
22 TEMPORARY_TABLES TABLE_NAME select
23 TABLE_STATISTICS TABLE_NAME select
24 VIEWS TABLE_NAME select
25+INNODB_TABLE_STATS table_name select
26 INNODB_INDEX_STATS table_name select
27-INNODB_TABLE_STATS table_name select
28 delete from mysql.user where user='mysqltest_4';
29 delete from mysql.db where user='mysqltest_4';
30 flush privileges;
31 SELECT table_schema, count(*) FROM information_schema.TABLES WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test', 'mysqltest') AND table_name<>'ndb_binlog_index' AND table_name<>'ndb_apply_status' GROUP BY TABLE_SCHEMA;
32 table_schema count(*)
33-information_schema 54
34+information_schema 53
35 mysql 22
36 create table t1 (i int, j int);
37 create trigger trg1 before insert on t1 for each row
38@@ -1335,7 +1334,7 @@
39 INNODB_RSEG rseg_id
40 INNODB_LOCKS lock_id
41 INNODB_BUFFER_POOL_PAGES page_type
42-XTRADB_ENHANCEMENTS name
43+INNODB_TABLE_STATS table_schema
44 INNODB_TRX trx_id
45 XTRADB_ADMIN_COMMAND result_message
46 INNODB_LOCK_WAITS requesting_trx_id
47@@ -1348,7 +1347,6 @@
48 INNODB_SYS_INDEXES TABLE_ID
49 INNODB_BUFFER_POOL_PAGES_BLOB space_id
50 INNODB_CMPMEM_RESET page_size
51-INNODB_TABLE_STATS table_schema
52 SELECT t.table_name, c1.column_name
53 FROM information_schema.tables t
54 INNER JOIN
55@@ -1404,7 +1402,7 @@
56 INNODB_RSEG rseg_id
57 INNODB_LOCKS lock_id
58 INNODB_BUFFER_POOL_PAGES page_type
59-XTRADB_ENHANCEMENTS name
60+INNODB_TABLE_STATS table_schema
61 INNODB_TRX trx_id
62 XTRADB_ADMIN_COMMAND result_message
63 INNODB_LOCK_WAITS requesting_trx_id
64@@ -1417,15 +1415,14 @@
65 INNODB_SYS_INDEXES TABLE_ID
66 INNODB_BUFFER_POOL_PAGES_BLOB space_id
67 INNODB_CMPMEM_RESET page_size
68-INNODB_TABLE_STATS table_schema
69 SELECT MAX(table_name) FROM information_schema.tables WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test');
70 MAX(table_name)
71-XTRADB_ENHANCEMENTS
72+XTRADB_ADMIN_COMMAND
73 SELECT table_name from information_schema.tables
74 WHERE table_name=(SELECT MAX(table_name)
75 FROM information_schema.tables WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test'));
76 table_name
77-XTRADB_ENHANCEMENTS
78+XTRADB_ADMIN_COMMAND
79 DROP TABLE IF EXISTS bug23037;
80 DROP FUNCTION IF EXISTS get_value;
81 SELECT COLUMN_NAME, MD5(COLUMN_DEFAULT), LENGTH(COLUMN_DEFAULT) FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='bug23037';
82@@ -1536,7 +1533,6 @@
83 USER_PRIVILEGES information_schema.USER_PRIVILEGES 1
84 USER_STATISTICS information_schema.USER_STATISTICS 1
85 VIEWS information_schema.VIEWS 1
86-XTRADB_ENHANCEMENTS information_schema.XTRADB_ENHANCEMENTS 1
87 create table t1(f1 int);
88 create view v1 as select f1+1 as a from t1;
89 create table t2 (f1 int, f2 int);
90
91=== modified file 'Percona-Server/mysql-test/r/information_schema_db.result'
92--- Percona-Server/mysql-test/r/information_schema_db.result 2011-11-24 02:00:56 +0000
93+++ Percona-Server/mysql-test/r/information_schema_db.result 2012-06-15 06:06:23 +0000
94@@ -45,7 +45,7 @@
95 INNODB_RSEG
96 INNODB_LOCKS
97 INNODB_BUFFER_POOL_PAGES
98-XTRADB_ENHANCEMENTS
99+INNODB_TABLE_STATS
100 INNODB_TRX
101 XTRADB_ADMIN_COMMAND
102 INNODB_LOCK_WAITS
103@@ -58,7 +58,6 @@
104 INNODB_SYS_INDEXES
105 INNODB_BUFFER_POOL_PAGES_BLOB
106 INNODB_CMPMEM_RESET
107-INNODB_TABLE_STATS
108 show tables from INFORMATION_SCHEMA like 'T%';
109 Tables_in_information_schema (T%)
110 TABLES
111
112=== modified file 'Percona-Server/mysql-test/r/mysqlshow.result'
113--- Percona-Server/mysql-test/r/mysqlshow.result 2011-11-24 02:00:56 +0000
114+++ Percona-Server/mysql-test/r/mysqlshow.result 2012-06-15 06:06:23 +0000
115@@ -119,7 +119,7 @@
116 | INNODB_RSEG |
117 | INNODB_LOCKS |
118 | INNODB_BUFFER_POOL_PAGES |
119-| XTRADB_ENHANCEMENTS |
120+| INNODB_TABLE_STATS |
121 | INNODB_TRX |
122 | XTRADB_ADMIN_COMMAND |
123 | INNODB_LOCK_WAITS |
124@@ -132,7 +132,6 @@
125 | INNODB_SYS_INDEXES |
126 | INNODB_BUFFER_POOL_PAGES_BLOB |
127 | INNODB_CMPMEM_RESET |
128-| INNODB_TABLE_STATS |
129 +---------------------------------------+
130 Database: INFORMATION_SCHEMA
131 +---------------------------------------+
132@@ -178,7 +177,7 @@
133 | INNODB_RSEG |
134 | INNODB_LOCKS |
135 | INNODB_BUFFER_POOL_PAGES |
136-| XTRADB_ENHANCEMENTS |
137+| INNODB_TABLE_STATS |
138 | INNODB_TRX |
139 | XTRADB_ADMIN_COMMAND |
140 | INNODB_LOCK_WAITS |
141@@ -191,7 +190,6 @@
142 | INNODB_SYS_INDEXES |
143 | INNODB_BUFFER_POOL_PAGES_BLOB |
144 | INNODB_CMPMEM_RESET |
145-| INNODB_TABLE_STATS |
146 +---------------------------------------+
147 Wildcard: inf_rmation_schema
148 +--------------------+
149
150=== added file 'Percona-Server/mysql-test/suite/innodb_plugin/r/percona_skip_innodb_i_s.result'
151--- Percona-Server/mysql-test/suite/innodb_plugin/r/percona_skip_innodb_i_s.result 1970-01-01 00:00:00 +0000
152+++ Percona-Server/mysql-test/suite/innodb_plugin/r/percona_skip_innodb_i_s.result 2012-06-15 06:06:23 +0000
153@@ -0,0 +1,93 @@
154+SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA='INFORMATION_SCHEMA' AND TABLE_NAME LIKE 'INNODB%' ORDER BY TABLE_NAME;
155+TABLE_NAME
156+INNODB_BUFFER_POOL_PAGES
157+INNODB_BUFFER_POOL_PAGES_BLOB
158+INNODB_BUFFER_POOL_PAGES_INDEX
159+INNODB_CMP
160+INNODB_CMPMEM
161+INNODB_CMPMEM_RESET
162+INNODB_CMP_RESET
163+INNODB_INDEX_STATS
164+INNODB_LOCKS
165+INNODB_LOCK_WAITS
166+INNODB_RSEG
167+INNODB_SYS_INDEXES
168+INNODB_SYS_STATS
169+INNODB_SYS_TABLES
170+INNODB_TABLE_STATS
171+INNODB_TRX
172+SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA='INFORMATION_SCHEMA' AND TABLE_NAME LIKE 'XTRADB%' ORDER BY TABLE_NAME;
173+TABLE_NAME
174+XTRADB_ADMIN_COMMAND
175+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX;
176+index_id space_id page_no n_recs data_size hashed access_time modified dirty old lru_position fix_count flush_type
177+Warnings:
178+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX but the InnoDB storage engine is not installed
179+SELECT * FROM INFORMATION_SCHEMA.INNODB_RSEG;
180+rseg_id space_id zip_size page_no max_size curr_size
181+Warnings:
182+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_RSEG but the InnoDB storage engine is not installed
183+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMP;
184+page_size compress_ops compress_ops_ok compress_time uncompress_ops uncompress_time
185+Warnings:
186+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_CMP but the InnoDB storage engine is not installed
187+SELECT * FROM INFORMATION_SCHEMA.INNODB_TRX;
188+trx_id trx_state trx_started trx_requested_lock_id trx_wait_started trx_weight trx_mysql_thread_id trx_query
189+Warnings:
190+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_TRX but the InnoDB storage engine is not installed
191+SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS;
192+requesting_trx_id requested_lock_id blocking_trx_id blocking_lock_id
193+Warnings:
194+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_LOCK_WAITS but the InnoDB storage engine is not installed
195+SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCKS;
196+lock_id lock_trx_id lock_mode lock_type lock_table lock_index lock_space lock_page lock_rec lock_data
197+Warnings:
198+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_LOCKS but the InnoDB storage engine is not installed
199+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMP_RESET;
200+page_size compress_ops compress_ops_ok compress_time uncompress_ops uncompress_time
201+Warnings:
202+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_CMP_RESET but the InnoDB storage engine is not installed
203+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES;
204+page_type space_id page_no lru_position fix_count flush_type
205+Warnings:
206+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES but the InnoDB storage engine is not installed
207+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES;
208+SCHEMA NAME ID N_COLS TYPE MIX_ID MIX_LEN CLUSTER_NAME SPACE
209+Warnings:
210+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_SYS_TABLES but the InnoDB storage engine is not installed
211+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX;
212+index_id space_id page_no n_recs data_size hashed access_time modified dirty old lru_position fix_count flush_type
213+Warnings:
214+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX but the InnoDB storage engine is not installed
215+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMPMEM;
216+page_size pages_used pages_free relocation_ops relocation_time
217+Warnings:
218+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_CMPMEM but the InnoDB storage engine is not installed
219+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_BLOB;
220+space_id page_no compressed part_len next_page_no lru_position fix_count flush_type
221+Warnings:
222+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_BLOB but the InnoDB storage engine is not installed
223+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMPMEM_RESET;
224+page_size pages_used pages_free relocation_ops relocation_time
225+Warnings:
226+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_CMPMEM_RESET but the InnoDB storage engine is not installed
227+SELECT * FROM INFORMATION_SCHEMA.INNODB_TABLE_STATS;
228+table_schema table_name rows clust_size other_size modified
229+Warnings:
230+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_TABLE_STATS but the InnoDB storage engine is not installed
231+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_STATS;
232+INDEX_ID KEY_COLS DIFF_VALS NON_NULL_VALS
233+Warnings:
234+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_SYS_STATS but the InnoDB storage engine is not installed
235+SELECT * FROM INFORMATION_SCHEMA.INNODB_INDEX_STATS;
236+table_schema table_name index_name fields row_per_keys index_size leaf_pages
237+Warnings:
238+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_INDEX_STATS but the InnoDB storage engine is not installed
239+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_INDEXES;
240+TABLE_ID ID NAME N_FIELDS TYPE SPACE PAGE_NO
241+Warnings:
242+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.INNODB_SYS_INDEXES but the InnoDB storage engine is not installed
243+SELECT * FROM INFORMATION_SCHEMA.XTRADB_ADMIN_COMMAND;
244+result_message
245+Warnings:
246+Warning 1012 InnoDB: SELECTing from INFORMATION_SCHEMA.XTRADB_ADMIN_COMMAND but the InnoDB storage engine is not installed
247
248=== added file 'Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s-master.opt'
249--- Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s-master.opt 1970-01-01 00:00:00 +0000
250+++ Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s-master.opt 2012-06-15 06:06:23 +0000
251@@ -0,0 +1,1 @@
252+--skip-innodb
253
254=== added file 'Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s.test'
255--- Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s.test 1970-01-01 00:00:00 +0000
256+++ Percona-Server/mysql-test/suite/innodb_plugin/t/percona_skip_innodb_i_s.test 2012-06-15 06:06:23 +0000
257@@ -0,0 +1,21 @@
258+# we just test that we don't crash. The SELECT below is to ensure we update the test if we add I_S tables for INNODB or XTRADB
259+SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA='INFORMATION_SCHEMA' AND TABLE_NAME LIKE 'INNODB%' ORDER BY TABLE_NAME;
260+SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA='INFORMATION_SCHEMA' AND TABLE_NAME LIKE 'XTRADB%' ORDER BY TABLE_NAME;
261+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX;
262+SELECT * FROM INFORMATION_SCHEMA.INNODB_RSEG;
263+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMP;
264+SELECT * FROM INFORMATION_SCHEMA.INNODB_TRX;
265+SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCK_WAITS;
266+SELECT * FROM INFORMATION_SCHEMA.INNODB_LOCKS;
267+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMP_RESET;
268+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES;
269+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES;
270+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_INDEX;
271+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMPMEM;
272+SELECT * FROM INFORMATION_SCHEMA.INNODB_BUFFER_POOL_PAGES_BLOB;
273+SELECT * FROM INFORMATION_SCHEMA.INNODB_CMPMEM_RESET;
274+SELECT * FROM INFORMATION_SCHEMA.INNODB_TABLE_STATS;
275+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_STATS;
276+SELECT * FROM INFORMATION_SCHEMA.INNODB_INDEX_STATS;
277+SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_INDEXES;
278+SELECT * FROM INFORMATION_SCHEMA.XTRADB_ADMIN_COMMAND;
279
280=== modified file 'Percona-Server/storage/innodb_plugin/Makefile.am'
281--- Percona-Server/storage/innodb_plugin/Makefile.am 2011-11-24 02:00:02 +0000
282+++ Percona-Server/storage/innodb_plugin/Makefile.am 2012-06-15 06:06:23 +0000
283@@ -226,7 +226,6 @@
284 include/ut0vec.h \
285 include/ut0vec.ic \
286 include/ut0wqueue.h \
287- handler/innodb_patch_info.h \
288 mem/mem0dbg.c
289
290 EXTRA_LIBRARIES= libinnobase.a
291
292=== modified file 'Percona-Server/storage/innodb_plugin/handler/ha_innodb.cc'
293--- Percona-Server/storage/innodb_plugin/handler/ha_innodb.cc 2012-05-09 04:14:12 +0000
294+++ Percona-Server/storage/innodb_plugin/handler/ha_innodb.cc 2012-06-15 06:06:23 +0000
295@@ -12224,8 +12224,7 @@
296 i_s_innodb_admin_command,
297 i_s_innodb_sys_tables,
298 i_s_innodb_sys_indexes,
299-i_s_innodb_sys_stats,
300-i_s_innodb_patches
301+i_s_innodb_sys_stats
302 mysql_declare_plugin_end;
303
304 /** @brief Initialize the default value of innodb_commit_concurrency.
305
306=== modified file 'Percona-Server/storage/innodb_plugin/handler/i_s.cc'
307--- Percona-Server/storage/innodb_plugin/handler/i_s.cc 2011-11-24 16:33:30 +0000
308+++ Percona-Server/storage/innodb_plugin/handler/i_s.cc 2012-06-15 06:06:23 +0000
309@@ -32,7 +32,6 @@
310 #include <mysys_err.h>
311 #include <my_sys.h>
312 #include "i_s.h"
313-#include "innodb_patch_info.h"
314 #include <mysql/plugin.h>
315
316 extern "C" {
317@@ -224,168 +223,11 @@
318 return(ret);
319 }
320
321-/* Fields of the dynamic table INFORMATION_SCHEMA.innodb_patches */
322-static ST_FIELD_INFO innodb_patches_fields_info[] =
323-{
324-#define IDX_PATCH_NAME 0
325- {STRUCT_FLD(field_name, "name"),
326- STRUCT_FLD(field_length, 255),
327- STRUCT_FLD(field_type, MYSQL_TYPE_STRING),
328- STRUCT_FLD(value, 0),
329- STRUCT_FLD(field_flags, 0),
330- STRUCT_FLD(old_name, ""),
331- STRUCT_FLD(open_method, SKIP_OPEN_TABLE)},
332-
333-#define IDX_PATCH_DESCR 1
334- {STRUCT_FLD(field_name, "description"),
335- STRUCT_FLD(field_length, 255),
336- STRUCT_FLD(field_type, MYSQL_TYPE_STRING),
337- STRUCT_FLD(value, 0),
338- STRUCT_FLD(field_flags, 0),
339- STRUCT_FLD(old_name, ""),
340- STRUCT_FLD(open_method, SKIP_OPEN_TABLE)},
341-
342-#define IDX_PATCH_COMMENT 2
343- {STRUCT_FLD(field_name, "comment"),
344- STRUCT_FLD(field_length, 100),
345- STRUCT_FLD(field_type, MYSQL_TYPE_STRING),
346- STRUCT_FLD(value, 0),
347- STRUCT_FLD(field_flags, 0),
348- STRUCT_FLD(old_name, ""),
349- STRUCT_FLD(open_method, SKIP_OPEN_TABLE)},
350-
351-#define IDX_PATCH_LINK 3
352- {STRUCT_FLD(field_name, "link"),
353- STRUCT_FLD(field_length, 255),
354- STRUCT_FLD(field_type, MYSQL_TYPE_STRING),
355- STRUCT_FLD(value, 0),
356- STRUCT_FLD(field_flags, 0),
357- STRUCT_FLD(old_name, ""),
358- STRUCT_FLD(open_method, SKIP_OPEN_TABLE)},
359-
360- END_OF_ST_FIELD_INFO
361-};
362-
363 static struct st_mysql_information_schema i_s_info =
364 {
365 MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION
366 };
367
368-/***********************************************************************
369-Fill the dynamic table information_schema.innodb_patches */
370-static
371-int
372-innodb_patches_fill(
373-/*=============*/
374- /* out: 0 on success, 1 on failure */
375- THD* thd, /* in: thread */
376- TABLE_LIST* tables, /* in/out: tables to fill */
377- COND* cond) /* in: condition (ignored) */
378-{
379- TABLE* table = (TABLE *) tables->table;
380- int status = 0;
381- int i;
382- Field** fields;
383-
384-
385- DBUG_ENTER("innodb_patches_fill");
386- fields = table->field;
387-
388- /* deny access to non-superusers */
389- if (check_global_access(thd, PROCESS_ACL)) {
390-
391- DBUG_RETURN(0);
392- }
393-
394- RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
395-
396- for (i = 0; innodb_enhancements[i].file; i++) {
397-
398- field_store_string(fields[0],innodb_enhancements[i].file);
399- field_store_string(fields[1],innodb_enhancements[i].name);
400- field_store_string(fields[2],innodb_enhancements[i].comment);
401- field_store_string(fields[3],innodb_enhancements[i].link);
402-
403- if (schema_table_store_record(thd, table)) {
404- status = 1;
405- break;
406- }
407-
408- }
409-
410-
411- DBUG_RETURN(status);
412-}
413-
414-/***********************************************************************
415-Bind the dynamic table information_schema.innodb_patches. */
416-static
417-int
418-innodb_patches_init(
419-/*=========*/
420- /* out: 0 on success */
421- void* p) /* in/out: table schema object */
422-{
423- DBUG_ENTER("innodb_patches_init");
424- ST_SCHEMA_TABLE* schema = (ST_SCHEMA_TABLE*) p;
425-
426- schema->fields_info = innodb_patches_fields_info;
427- schema->fill_table = innodb_patches_fill;
428-
429- DBUG_RETURN(0);
430-}
431-
432-
433-UNIV_INTERN struct st_mysql_plugin i_s_innodb_patches =
434-{
435- /* the plugin type (a MYSQL_XXX_PLUGIN value) */
436- /* int */
437- STRUCT_FLD(type, MYSQL_INFORMATION_SCHEMA_PLUGIN),
438-
439- /* pointer to type-specific plugin descriptor */
440- /* void* */
441- STRUCT_FLD(info, &i_s_info),
442-
443- /* plugin name */
444- /* const char* */
445- STRUCT_FLD(name, "XTRADB_ENHANCEMENTS"),
446-
447- /* plugin author (for SHOW PLUGINS) */
448- /* const char* */
449- STRUCT_FLD(author, "Percona"),
450-
451- /* general descriptive text (for SHOW PLUGINS) */
452- /* const char* */
453- STRUCT_FLD(descr, "Enhancements applied to InnoDB plugin"),
454-
455- /* the plugin license (PLUGIN_LICENSE_XXX) */
456- /* int */
457- STRUCT_FLD(license, PLUGIN_LICENSE_GPL),
458-
459- /* the function to invoke when plugin is loaded */
460- /* int (*)(void*); */
461- STRUCT_FLD(init, innodb_patches_init),
462-
463- /* the function to invoke when plugin is unloaded */
464- /* int (*)(void*); */
465- STRUCT_FLD(deinit, i_s_common_deinit),
466-
467- /* plugin version (for SHOW PLUGINS) */
468- /* unsigned int */
469- STRUCT_FLD(version, INNODB_VERSION_SHORT),
470-
471- /* struct st_mysql_show_var* */
472- STRUCT_FLD(status_vars, NULL),
473-
474- /* struct st_mysql_sys_var** */
475- STRUCT_FLD(system_vars, NULL),
476-
477- /* reserved for dependency checking */
478- /* void* */
479- STRUCT_FLD(__reserved1, NULL)
480-};
481-
482-
483 static ST_FIELD_INFO i_s_innodb_buffer_pool_pages_fields_info[] =
484 {
485 {STRUCT_FLD(field_name, "page_type"),
486@@ -1956,6 +1798,8 @@
487
488 DBUG_ENTER("i_s_cmp_fill_low");
489
490+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
491+
492 /* deny access to non-superusers */
493 if (check_global_access(thd, PROCESS_ACL)) {
494
495@@ -2224,6 +2068,8 @@
496
497 DBUG_ENTER("i_s_cmpmem_fill_low");
498
499+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
500+
501 /* deny access to non-superusers */
502 if (check_global_access(thd, PROCESS_ACL)) {
503
504@@ -2512,6 +2358,8 @@
505
506 DBUG_ENTER("i_s_innodb_rseg_fill");
507
508+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
509+
510 /* deny access to non-superusers */
511 if (check_global_access(thd, PROCESS_ACL)) {
512
513@@ -2645,6 +2493,8 @@
514
515 DBUG_ENTER("i_s_innodb_admin_command_fill");
516
517+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
518+
519 /* deny access to non-superusers */
520 if (check_global_access(thd, PROCESS_ACL)) {
521 DBUG_RETURN(0);
522@@ -2902,6 +2752,8 @@
523
524 DBUG_ENTER("i_s_innodb_table_stats_fill");
525
526+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
527+
528 /* deny access to non-superusers */
529 if (check_global_access(thd, PROCESS_ACL)) {
530 DBUG_RETURN(0);
531@@ -2965,6 +2817,8 @@
532
533 DBUG_ENTER("i_s_innodb_index_stats_fill");
534
535+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
536+
537 /* deny access to non-superusers */
538 if (check_global_access(thd, PROCESS_ACL)) {
539 DBUG_RETURN(0);
540@@ -3612,6 +3466,8 @@
541
542 DBUG_ENTER("i_s_innodb_schema_table_fill");
543
544+ RETURN_IF_INNODB_NOT_STARTED(tables->schema_table_name);
545+
546 /* deny access to non-superusers */
547 if (check_global_access(thd, PROCESS_ACL)) {
548 DBUG_RETURN(0);
549
550=== modified file 'Percona-Server/storage/innodb_plugin/handler/i_s.h'
551--- Percona-Server/storage/innodb_plugin/handler/i_s.h 2011-11-24 02:00:45 +0000
552+++ Percona-Server/storage/innodb_plugin/handler/i_s.h 2012-06-15 06:06:23 +0000
553@@ -36,7 +36,6 @@
554 extern struct st_mysql_plugin i_s_innodb_cmp_reset;
555 extern struct st_mysql_plugin i_s_innodb_cmpmem;
556 extern struct st_mysql_plugin i_s_innodb_cmpmem_reset;
557-extern struct st_mysql_plugin i_s_innodb_patches;
558 extern struct st_mysql_plugin i_s_innodb_rseg;
559 extern struct st_mysql_plugin i_s_innodb_table_stats;
560 extern struct st_mysql_plugin i_s_innodb_index_stats;
561
562=== removed file 'Percona-Server/storage/innodb_plugin/handler/innodb_patch_info.h'
563--- Percona-Server/storage/innodb_plugin/handler/innodb_patch_info.h 2011-11-24 02:00:45 +0000
564+++ Percona-Server/storage/innodb_plugin/handler/innodb_patch_info.h 1970-01-01 00:00:00 +0000
565@@ -1,51 +0,0 @@
566-/* Copyright (C) 2002-2006 MySQL AB
567-
568- This program is free software; you can redistribute it and/or modify
569- it under the terms of the GNU General Public License as published by
570- the Free Software Foundation; version 2 of the License.
571-
572- This program is distributed in the hope that it will be useful,
573- but WITHOUT ANY WARRANTY; without even the implied warranty of
574- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
575- GNU General Public License for more details.
576-
577- You should have received a copy of the GNU General Public License
578- along with this program; if not, write to the Free Software
579- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
580-
581-#ifdef USE_PRAGMA_INTERFACE
582-#pragma interface /* gcc class implementation */
583-#endif
584-
585-struct innodb_enhancement {
586- const char *file;
587- const char *name;
588- const char *comment;
589- const char *link;
590-}innodb_enhancements[] = {
591-{"xtradb_show_enhancements","I_S.XTRADB_ENHANCEMENTS","","http://www.percona.com/docs/wiki/percona-xtradb"},
592-{"innodb_show_status","Improvements to SHOW INNODB STATUS","Memory information and lock info fixes","http://www.percona.com/docs/wiki/percona-xtradb"},
593-{"innodb_io","Improvements to InnoDB IO","","http://www.percona.com/docs/wiki/percona-xtradb"},
594-{"innodb_opt_lru_count","Fix of buffer_pool mutex","Decreases contention on buffer_pool mutex on LRU operations","http://www.percona.com/docs/wiki/percona-xtradb"},
595-{"innodb_buffer_pool_pages","Information of buffer pool content","","http://www.percona.com/docs/wiki/percona-xtradb"},
596-{"innodb_expand_undo_slots","expandable maximum number of undo slots","from 1024 (default) to about 4000","http://www.percona.com/docs/wiki/percona-xtradb"},
597-{"innodb_extra_rseg","allow to create extra rollback segments","When create new db, the new parameter allows to create more rollback segments","http://www.percona.com/docs/wiki/percona-xtradb"},
598-{"innodb_overwrite_relay_log_info","overwrite relay-log.info when slave recovery","Building as plugin, it is not used.","http://www.percona.com/docs/wiki/percona-xtradb:innodb_overwrite_relay_log_info"},
599-{"innodb_thread_concurrency_timer_based","use InnoDB timer based concurrency throttling (backport from MySQL 5.4.0)","",""},
600-{"innodb_expand_import","convert .ibd file automatically when import tablespace","the files are generated by xtrabackup export mode.","http://www.percona.com/docs/wiki/percona-xtradb"},
601-{"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},
602-{"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
603-{"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},
604-{"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
605-{"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
606-{"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
607-{"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},
608-{"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},
609-{"innodb_lru_dump_restore","Dump and restore command for content of buffer pool","","http://www.percona.com/docs/wiki/percona-xtradb"},
610-{"innodb_separate_doublewrite","Add option 'innodb_doublewrite_file' to separate doublewrite dedicated tablespace","","http://www.percona.com/docs/wiki/percona-xtradb"},
611-{"innodb_pass_corrupt_table","Treat tables as corrupt instead of crash, when meet corrupt blocks","","http://www.percona.com/docs/wiki/percona-xtradb"},
612-{"innodb_fast_checksum","Using the checksum on 32bit-unit calculation","incompatible for unpatched ver.","http://www.percona.com/docs/wiki/percona-xtradb"},
613-{"innodb_files_extend","allow >4GB transaction log files, and can vary universal page size of datafiles","incompatible for unpatched ver.","http://www.percona.com/docs/wiki/percona-xtradb"},
614-{"innodb_sys_tables_sys_indexes","Expose InnoDB SYS_TABLES and SYS_INDEXES schema tables","","http://www.percona.com/docs/wiki/percona-xtradb"},
615-{NULL, NULL, NULL, NULL}
616-};

Subscribers

People subscribed via source and target branches