summaryrefslogtreecommitdiff
path: root/sql/ha_innodb.cc
diff options
context:
space:
mode:
authorunknown <brian@zim.(none)>2006-08-22 16:24:12 -0700
committerunknown <brian@zim.(none)>2006-08-22 16:24:12 -0700
commit977cd20a70d0d4ca9058d2b287baf12c64dc19fa (patch)
treed9b86be7b64fbabbe0a221783f850077ca7ce8ad /sql/ha_innodb.cc
parentcfafd45807807370ae01beadf5ad4a133ef6d402 (diff)
downloadmariadb-git-977cd20a70d0d4ca9058d2b287baf12c64dc19fa.tar.gz
This changest:
Plugins now when compiled or not compiled work correctly with status variables. Status variables from plugins now set their own names (removed bit where plugin name was pre-appended this broke Innodb and Cluster) A few Makefile cleanups. sql/ha_innodb.cc: Cleanup to make status variables directly in engine sql/ha_ndbcluster.cc: Engine interface now has variables for status sql/handler.cc: handler now makes sure to init status variables sql/mysqld.cc: Removed status variable hacks sql/sql_delete.cc: Removed include file that was not required storage/myisam/Makefile.am: Cleaned up line lengths and addded additional include to not install. storage/myisam/ha_myisam.cc: Removed double plugin include
Diffstat (limited to 'sql/ha_innodb.cc')
-rw-r--r--sql/ha_innodb.cc22
1 files changed, 16 insertions, 6 deletions
diff --git a/sql/ha_innodb.cc b/sql/ha_innodb.cc
index 00a92e05ffb..41e211dd6d8 100644
--- a/sql/ha_innodb.cc
+++ b/sql/ha_innodb.cc
@@ -42,8 +42,6 @@ have disables the InnoDB inlining in this file. */
#define MAX_ULONG_BIT ((ulong) 1 << (sizeof(ulong)*8-1))
-#ifdef WITH_INNOBASE_STORAGE_ENGINE
-
#include "ha_innodb.h"
pthread_mutex_t innobase_share_mutex, /* to protect innobase_open_files */
@@ -311,7 +309,8 @@ SHOW_VAR innodb_status_variables[]= {
(char*) &export_vars.innodb_rows_read, SHOW_LONG},
{"rows_updated",
(char*) &export_vars.innodb_rows_updated, SHOW_LONG},
- {NullS, NullS, SHOW_LONG}};
+ {NullS, NullS, SHOW_LONG}
+};
/* General functions */
@@ -7599,6 +7598,19 @@ bool ha_innobase::check_if_incompatible_data(
return COMPATIBLE_DATA_YES;
}
+static int show_innodb_vars(THD *thd, SHOW_VAR *var, char *buff)
+{
+ innodb_export_status();
+ var->type= SHOW_ARRAY;
+ var->value= (char *) &innodb_status_variables;
+ return 0;
+}
+
+SHOW_VAR innodb_status_variables_export[]= {
+ {"Innodb", (char*) &show_innodb_vars, SHOW_FUNC},
+ {NullS, NullS, SHOW_LONG}
+};
+
struct st_mysql_storage_engine innobase_storage_engine=
{ MYSQL_HANDLERTON_INTERFACE_VERSION, &innobase_hton};
@@ -7612,9 +7624,7 @@ mysql_declare_plugin(innobase)
innobase_init, /* Plugin Init */
NULL, /* Plugin Deinit */
0x0100 /* 1.0 */,
- 0
+ innodb_status_variables_export
}
mysql_declare_plugin_end;
-#endif
-