← Back to team overview

maria-developers team mailing list archive

Rev 2734: Maria WL#61 in file:///Users/bell/maria/bzr/work-maria-5.2-engine/

 

At file:///Users/bell/maria/bzr/work-maria-5.2-engine/

------------------------------------------------------------
revno: 2734
revision-id: sanja@xxxxxxxxxxxx-20100215074703-tqcssnpbf43grygo
parent: psergey@xxxxxxxxxxxx-20091202142609-18bp41q8mejxl47t
committer: sanja@xxxxxxxxxxxx
branch nick: work-maria-5.2-engine
timestamp: Mon 2010-02-15 09:47:03 +0200
message:
  Maria WL#61
  
  Interface for maria extensions.
  Additional information about plugins (maturity and string version) interface for maria extensions.
=== modified file 'CMakeLists.txt'
--- a/CMakeLists.txt	2009-10-03 19:24:13 +0000
+++ b/CMakeLists.txt	2010-02-15 07:47:03 +0000
@@ -251,6 +251,7 @@
 
         IF (ENGINE_BUILD_TYPE STREQUAL "STATIC") 
           SET (mysql_plugin_defs  "${mysql_plugin_defs},builtin_${PLUGIN_NAME}_plugin")
+          SET (mariadb_extra_plugin_defs  "${mariadb_extra_plugin_defs},builtin_mariadb_${PLUGIN_NAME}_plugin")
           SET (MYSQLD_STATIC_ENGINE_LIBS ${MYSQLD_STATIC_ENGINE_LIBS} ${PLUGIN_NAME})
           SET (STORAGE_ENGINE_DEFS "${STORAGE_ENGINE_DEFS} -DWITH_${ENGINE}_STORAGE_ENGINE")
           SET (WITH_${ENGINE}_STORAGE_ENGINE TRUE)
@@ -269,6 +270,7 @@
 IF(NOT WITHOUT_PARTITION_STORAGE_ENGINE)
   SET (STORAGE_ENGINE_DEFS "${STORAGE_ENGINE_DEFS} -DWITH_PARTITION_STORAGE_ENGINE")
   SET (mysql_plugin_defs  "${mysql_plugin_defs},builtin_partition_plugin")
+  SET (mariadb_extra_plugin_defs  "${mariadb_extra_plugin_defs},builtin_mariadb_partition_plugin")
 ENDIF(NOT WITHOUT_PARTITION_STORAGE_ENGINE)
 
 # Special handling for tmp tables with the maria engine

=== modified file 'config/ac-macros/plugins.m4'
--- a/config/ac-macros/plugins.m4	2009-04-25 10:05:32 +0000
+++ b/config/ac-macros/plugins.m4	2010-02-15 07:47:03 +0000
@@ -461,6 +461,7 @@
        ])
       ])
       mysql_plugin_defs="$mysql_plugin_defs, [builtin_]$2[_plugin]"
+      mariadb_extra_plugin_defs="$mariadb_extra_plugin_defs, [builtin_mariadb_]$2[_plugin]"
       [with_plugin_]$2=yes
       AC_MSG_RESULT([yes])
       m4_ifdef([$11],[

=== modified file 'configure.in'
--- a/configure.in	2009-11-12 04:31:28 +0000
+++ b/configure.in	2010-02-15 07:47:03 +0000
@@ -2842,6 +2842,7 @@
 AC_SUBST(mysql_plugin_dirs)
 AC_SUBST(mysql_plugin_libs)
 AC_SUBST(mysql_plugin_defs)
+AC_SUBST(mariadb_extra_plugin_defs)
 
 
 # Now that sql_client_dirs and sql_server_dirs are stable, determine the union.

=== modified file 'include/mysql/plugin.h'
--- a/include/mysql/plugin.h	2009-09-07 20:50:10 +0000
+++ b/include/mysql/plugin.h	2010-02-15 07:47:03 +0000
@@ -65,7 +65,10 @@
   Plugin API. Common for all plugin types.
 */
 
+/* MySQL plugin interface version */
 #define MYSQL_PLUGIN_INTERFACE_VERSION 0x0100
+/* MariaDB extentsion interface version */
+#define MARIAEXT_PLUGIN_INTERFACE_VERSION 0x0100
 
 /*
   The allowable types of plugins
@@ -86,6 +89,21 @@
 #define PLUGIN_LICENSE_GPL_STRING "GPL"
 #define PLUGIN_LICENSE_BSD_STRING "BSD"
 
+/* definitions of code maturity for plugins */
+#define PLUGIN_MATURITY_UNKNOWN 0
+#define PLUGIN_MATURITY_TEST 1
+#define PLUGIN_MATURITY_ALPHA 2
+#define PLUGIN_MATURITY_BETA 3
+#define PLUGIN_MATURITY_GAMMA 4
+#define PLUGIN_MATURITY_RELEASE 5
+
+#define PLUGIN_MATURITY_UNKNOWN_STR "Unknown"
+#define PLUGIN_MATURITY_TEST_STR "Test"
+#define PLUGIN_MATURITY_ALPHA_STR "Alpha"
+#define PLUGIN_MATURITY_BETA_STR "Beta"
+#define PLUGIN_MATURITY_GAMMA_STR "Gamma"
+#define PLUGIN_MATURITY_RELEASE_STR "Release"
+
 /*
   Macros for beginning and ending plugin declarations.  Between
   mysql_declare_plugin and mysql_declare_plugin_end there should
@@ -94,15 +112,29 @@
 
 
 #ifndef MYSQL_DYNAMIC_PLUGIN
+
 #define __MYSQL_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS)                   \
 int VERSION= MYSQL_PLUGIN_INTERFACE_VERSION;                                  \
 int PSIZE= sizeof(struct st_mysql_plugin);                                    \
 struct st_mysql_plugin DECLS[]= {
+
+#define __MARIAEXT_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS)                \
+int VERSION= MARIAEXT_PLUGIN_INTERFACE_VERSION;                                \
+int PSIZE= sizeof(struct st_mariaext_plugin);                                 \
+struct st_mariaext_plugin DECLS[]= {
+
 #else
+
 #define __MYSQL_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS)                   \
 MYSQL_PLUGIN_EXPORT int _mysql_plugin_interface_version_= MYSQL_PLUGIN_INTERFACE_VERSION;         \
 MYSQL_PLUGIN_EXPORT int _mysql_sizeof_struct_st_plugin_= sizeof(struct st_mysql_plugin);          \
 MYSQL_PLUGIN_EXPORT struct st_mysql_plugin _mysql_plugin_declarations_[]= {
+
+#define __MARIAEXT_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS)                \
+MYSQL_PLUGIN_EXPORT int _mariaext_plugin_interface_version_= MARIAEXT_PLUGIN_INTERFACE_VERSION;   \
+MYSQL_PLUGIN_EXPORT int _mariaext_sizeof_struct_st_plugin_= sizeof(struct st_mariaext_plugin);    \
+MYSQL_PLUGIN_EXPORT struct st_mariaext_plugin _mariaext_plugin_declarations_[]= {
+
 #endif
 
 #define mysql_declare_plugin(NAME) \
@@ -111,7 +143,14 @@
                  builtin_ ## NAME ## _sizeof_struct_st_plugin, \
                  builtin_ ## NAME ## _plugin)
 
+#define mariaext_declare_plugin(NAME) \
+__MARIAEXT_DECLARE_PLUGIN(NAME, \
+                 builtin_mariadb_ ## NAME ## _plugin_interface_version, \
+                 builtin_mariadb_ ## NAME ## _sizeof_struct_st_plugin, \
+                 builtin_mariadb_ ## NAME ## _plugin)
+
 #define mysql_declare_plugin_end ,{0,0,0,0,0,0,0,0,0,0,0,0}}
+#define mariaext_declare_plugin_end ,{0,0}}
 
 /*
   declarations for SHOW STATUS support in plugins
@@ -407,6 +446,16 @@
   void * __reserved1;   /* reserved for dependency checking             */
 };
 
+/*
+  MariaDB extension for plugins declaration structure.
+*/
+
+struct st_mariaext_plugin
+{
+  const char *version_info;  /* plugin version string */
+  int maturity;              /* HA_PLUGIN_MATURITY_XXX */
+};
+
 /*************************************************************************
   API for Full-text parser plugin. (MYSQL_FTPARSER_PLUGIN)
 */

=== modified file 'include/mysql/plugin.h.pp'
--- a/include/mysql/plugin.h.pp	2008-10-10 15:28:41 +0000
+++ b/include/mysql/plugin.h.pp	2010-02-15 07:47:03 +0000
@@ -46,6 +46,11 @@
   struct st_mysql_sys_var **system_vars;
   void * __reserved1;
 };
+struct st_mariaext_plugin
+{
+  const char *version_info;
+  int maturity;
+};
 enum enum_ftparser_mode
 {
   MYSQL_FTPARSER_SIMPLE_MODE= 0,

=== modified file 'mysql-test/r/information_schema.result'
--- a/mysql-test/r/information_schema.result	2009-10-19 17:14:48 +0000
+++ b/mysql-test/r/information_schema.result	2010-02-15 07:47:03 +0000
@@ -1175,7 +1175,7 @@
 group by column_type order by num;
 column_type	group_concat(table_schema, '.', table_name)	num
 varchar(27)	information_schema.COLUMNS	1
-varchar(7)	information_schema.ROUTINES,information_schema.VIEWS	2
+varchar(7)	information_schema.PLUGINS,information_schema.ROUTINES,information_schema.VIEWS	3
 varchar(20)	information_schema.FILES,information_schema.FILES,information_schema.PLUGINS,information_schema.PLUGINS,information_schema.PLUGINS,information_schema.PROFILING	6
 create table t1(f1 char(1) not null, f2 char(9) not null)
 default character set utf8;

=== modified file 'plugin/daemon_example/daemon_example.cc'
--- a/plugin/daemon_example/daemon_example.cc	2007-06-27 14:49:12 +0000
+++ b/plugin/daemon_example/daemon_example.cc	2010-02-15 07:47:03 +0000
@@ -200,3 +200,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(daemon_example)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_TEST        /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'plugin/fulltext/plugin_example.c'
--- a/plugin/fulltext/plugin_example.c	2007-04-26 19:26:04 +0000
+++ b/plugin/fulltext/plugin_example.c	2010-02-15 07:47:03 +0000
@@ -270,4 +270,10 @@
   NULL
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(ftexample)
+{
+  "0.01",                     /* string version */
+  PLUGIN_MATURITY_TEST        /* maturity */
+}
+mariaext_declare_plugin_end;
 

=== modified file 'sql/ha_ndbcluster.cc'
--- a/sql/ha_ndbcluster.cc	2009-09-07 20:50:10 +0000
+++ b/sql/ha_ndbcluster.cc	2010-02-15 07:47:03 +0000
@@ -10561,5 +10561,11 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(ndbcluster)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_BETA        /* maturity */
+}
+mariaext_declare_plugin_end;
 
 #endif

=== modified file 'sql/ha_partition.cc'
--- a/sql/ha_partition.cc	2009-11-12 04:31:28 +0000
+++ b/sql/ha_partition.cc	2010-02-15 07:47:03 +0000
@@ -6510,5 +6510,11 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(partition)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;
 
 #endif

=== modified file 'sql/log.cc'
--- a/sql/log.cc	2009-11-12 04:31:28 +0000
+++ b/sql/log.cc	2010-02-15 07:47:03 +0000
@@ -5795,3 +5795,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(binlog)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'sql/sql_builtin.cc.in'
--- a/sql/sql_builtin.cc.in	2006-12-31 01:29:11 +0000
+++ b/sql/sql_builtin.cc.in	2010-02-15 07:47:03 +0000
@@ -16,6 +16,7 @@
 #include <mysql/plugin.h>
 
 typedef struct st_mysql_plugin builtin_plugin[];
+typedef struct st_mariaext_plugin builtin_mariadb_plugin[];
 
 extern builtin_plugin 
   builtin_binlog_plugin@mysql_plugin_defs@;
@@ -25,3 +26,10 @@
   builtin_binlog_plugin@mysql_plugin_defs@,(struct st_mysql_plugin *)0
 };
 
+extern builtin_mariadb_plugin
+  builtin_mariadb_binlog_plugin@mariadb_extra_plugin_defs@;
+
+struct st_mariaext_plugin *mysqld_bltnmexts[]=
+{
+  builtin_mariadb_binlog_plugin@mariadb_extra_plugin_defs@,(struct st_mariaext_plugin *)0
+};

=== modified file 'sql/sql_plugin.cc'
--- a/sql/sql_plugin.cc	2009-11-12 04:31:28 +0000
+++ b/sql/sql_plugin.cc	2010-02-15 07:47:03 +0000
@@ -28,6 +28,9 @@
 #endif
 
 extern struct st_mysql_plugin *mysqld_builtins[];
+extern struct st_mariaext_plugin *mysqld_bltnmexts[];
+static st_mariaext_plugin no_mariaext[2]= {{"Unknown", 0}, {0, 0}};
+static st_mariaext_plugin *empty_mariaext= no_mariaext;
 
 /**
   @note The order of the enumeration is critical.
@@ -82,6 +85,14 @@
                    "_mysql_sizeof_struct_st_plugin_";
 static const char *plugin_declarations_sym= "_mysql_plugin_declarations_";
 static int min_plugin_interface_version= MYSQL_PLUGIN_INTERFACE_VERSION & ~0xFF;
+static const char *mariaext_plugin_interface_version_sym=
+                   "_mariaext_plugin_interface_version_";
+static const char *mariaext_sizeof_st_plugin_sym=
+                   "_mariaext_sizeof_struct_st_plugin_";
+static const char *mariaext_plugin_declarations_sym=
+                   "_mariaext_plugin_declarations_";
+static int min_mariaext_plugin_interface_version=
+                   MARIAEXT_PLUGIN_INTERFACE_VERSION & ~0xFF;
 #endif
 
 /* Note that 'int version' must be the first field of every plugin
@@ -352,6 +363,7 @@
   char dlpath[FN_REFLEN];
   uint plugin_dir_len, dummy_errors, dlpathlen;
   struct st_plugin_dl *tmp, plugin_dl;
+  struct st_mariaext_plugin *mariaext= no_mariaext;
   void *sym;
   DBUG_ENTER("plugin_dl_add");
   plugin_dir_len= strlen(opt_plugin_dir);
@@ -507,6 +519,15 @@
     files_charset_info, dl->str, dl->length, system_charset_info,
     &dummy_errors);
   plugin_dl.dl.str[plugin_dl.dl.length]= 0;
+
+  if ((sym= dlsym(plugin_dl.handle, mariaext_plugin_interface_version_sym)) &&
+      (*(int *)sym == MARIAEXT_PLUGIN_INTERFACE_VERSION) &&
+      (sym= dlsym(plugin_dl.handle, mariaext_plugin_declarations_sym)))
+  {
+    mariaext= (struct st_mariaext_plugin *) sym;
+  }
+  plugin_dl.mariaext= mariaext;
+
   /* Add this dll to array */
   if (! (tmp= plugin_dl_insert_or_reuse(&plugin_dl)))
   {
@@ -719,6 +740,7 @@
 {
   struct st_plugin_int tmp;
   struct st_mysql_plugin *plugin;
+  struct st_mariaext_plugin *ext, *mariaext;
   DBUG_ENTER("plugin_add");
   if (plugin_find_internal(name, MYSQL_ANY_PLUGIN))
   {
@@ -732,9 +754,22 @@
   bzero((char*) &tmp, sizeof(tmp));
   if (! (tmp.plugin_dl= plugin_dl_add(dl, report)))
     DBUG_RETURN(TRUE);
+
   /* Find plugin by name */
-  for (plugin= tmp.plugin_dl->plugins; plugin->info; plugin++)
+  for (plugin= tmp.plugin_dl->plugins, ext= tmp.plugin_dl->mariaext;
+       plugin->info;
+       plugin++, ext++)
   {
+    mariaext= ext;
+    if (!ext->version_info)
+    {
+      /*
+        Plugin didn't have any mariadb extensions; Use default one and
+        reset counter to do same for next internal plugin.
+      */
+      mariaext= empty_mariaext;
+      ext--;
+    }
     uint name_len= strlen(plugin->name);
     if (plugin->type >= 0 && plugin->type < MYSQL_MAX_PLUGIN_TYPE_NUM &&
         ! my_strnncoll(system_charset_info,
@@ -759,6 +794,7 @@
         goto err;
       }
       tmp.plugin= plugin;
+      tmp.mariaext= mariaext;
       tmp.name.str= (char *)plugin->name;
       tmp.name.length= name_len;
       tmp.ref_count= 0;
@@ -1121,7 +1157,9 @@
   uint i;
   bool is_myisam;
   struct st_mysql_plugin **builtins;
+  struct st_mariaext_plugin **bltnmexts;
   struct st_mysql_plugin *plugin;
+  struct st_mariaext_plugin *ext, *mariaext;
   struct st_plugin_int tmp, *plugin_ptr, **reap;
   MEM_ROOT tmp_root;
   bool reaped_mandatory_plugin= FALSE;
@@ -1160,10 +1198,29 @@
   /*
     First we register builtin plugins
   */
-  for (builtins= mysqld_builtins; *builtins; builtins++)
+  for (builtins= mysqld_builtins, bltnmexts= mysqld_bltnmexts;
+       *builtins;
+       builtins++, bltnmexts++)
   {
-    for (plugin= *builtins; plugin->info; plugin++)
+    /* extensions should be the same numbers as static plugins) */
+    DBUG_ASSERT(*bltnmexts);
+    for (plugin= *builtins, ext= *bltnmexts;
+         plugin->info;
+         plugin++, ext++)
     {
+
+      /* in case if plugin describe less extensions then plugins */
+      mariaext= ext;
+      if (!ext->version_info)
+      {
+        /*
+          Plugin didn't have any mariadb extensions; Use default one and
+          reset counter to do same for next internal plugin.
+        */
+         mariaext= empty_mariaext;
+         ext--;
+      }
+
       if (opt_ignore_builtin_innodb &&
           !my_strnncoll(&my_charset_latin1, (const uchar*) plugin->name,
                         6, (const uchar*) "InnoDB", 6))
@@ -1186,6 +1243,7 @@
 #endif
       bzero(&tmp, sizeof(tmp));
       tmp.plugin= plugin;
+      tmp.mariaext= mariaext;
       tmp.name.str= (char *)plugin->name;
       tmp.name.length= strlen(plugin->name);
       tmp.state= 0;

=== modified file 'sql/sql_plugin.h'
--- a/sql/sql_plugin.h	2009-05-14 12:03:33 +0000
+++ b/sql/sql_plugin.h	2010-02-15 07:47:03 +0000
@@ -63,6 +63,7 @@
   LEX_STRING dl;
   void *handle;
   struct st_mysql_plugin *plugins;
+  struct st_mariaext_plugin *mariaext;
   int version;
   uint ref_count;            /* number of plugins loaded from the library */
 };
@@ -74,6 +75,7 @@
   LEX_STRING name;
   struct st_mysql_plugin *plugin;
   struct st_plugin_dl *plugin_dl;
+  struct st_mariaext_plugin *mariaext;
   uint state;
   uint ref_count;               /* number of threads using the plugin */
   void *data;                   /* plugin type specific, e.g. handlerton */
@@ -95,6 +97,7 @@
 #define plugin_name(pi) (&((pi)->name))
 #define plugin_state(pi) ((pi)->state)
 #define plugin_equals(p1,p2) ((p1) == (p2))
+#define plugin_ext(pi) ((pi)->mariaext)
 #else
 typedef struct st_plugin_int **plugin_ref;
 #define plugin_decl(pi) ((pi)[0]->plugin)
@@ -103,6 +106,8 @@
 #define plugin_name(pi) (&((pi)[0]->name))
 #define plugin_state(pi) ((pi)[0]->state)
 #define plugin_equals(p1,p2) ((p1) && (p2) && (p1)[0] == (p2)[0])
+#define plugin_ext(pi) ((pi)[0]->mariaext)
+
 #endif
 
 typedef int (*plugin_type_init)(struct st_plugin_int *);

=== modified file 'sql/sql_show.cc'
--- a/sql/sql_show.cc	2009-11-12 04:31:28 +0000
+++ b/sql/sql_show.cc	2010-02-15 07:47:03 +0000
@@ -94,12 +94,21 @@
   return my_snprintf(buf, buf_length, "%d.%d", version>>8,version&0xff);
 }
 
+static const LEX_STRING maturity_name[]={
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_UNKNOWN_STR) },
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_TEST_STR) },
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_ALPHA_STR) },
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_BETA_STR) },
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_GAMMA_STR) },
+  { C_STRING_WITH_LEN(PLUGIN_MATURITY_RELEASE_STR) }};
+
 static my_bool show_plugins(THD *thd, plugin_ref plugin,
                             void *arg)
 {
   TABLE *table= (TABLE*) arg;
   struct st_mysql_plugin *plug= plugin_decl(plugin);
   struct st_plugin_dl *plugin_dl= plugin_dlib(plugin);
+  struct st_mariaext_plugin *mariaext= plugin_ext(plugin);
   CHARSET_INFO *cs= system_charset_info;
   char version_buf[20];
 
@@ -186,6 +195,26 @@
   }
   table->field[9]->set_notnull();
 
+  if ((uint) mariaext->maturity <= PLUGIN_MATURITY_RELEASE)
+     table->field[10]->store(maturity_name[mariaext->maturity].str,
+                             maturity_name[mariaext->maturity].length,
+                             cs);
+   else
+   {
+     DBUG_ASSERT(0);
+     table->field[10]->store("Unknown", 7, cs);
+   }
+   table->field[10]->set_notnull();
+
+  if (mariaext->version_info)
+  {
+    table->field[11]->store(mariaext->version_info,
+                            strlen(mariaext->version_info), cs);
+    table->field[11]->set_notnull();
+  }
+  else
+    table->field[11]->set_null();
+
   return schema_table_store_record(thd, table);
 }
 
@@ -6990,6 +7019,8 @@
   {"PLUGIN_AUTHOR", NAME_CHAR_LEN, MYSQL_TYPE_STRING, 0, 1, 0, SKIP_OPEN_TABLE},
   {"PLUGIN_DESCRIPTION", 65535, MYSQL_TYPE_STRING, 0, 1, 0, SKIP_OPEN_TABLE},
   {"PLUGIN_LICENSE", 80, MYSQL_TYPE_STRING, 0, 1, "License", SKIP_OPEN_TABLE},
+  {"PLUGIN_MATURITY", 7, MYSQL_TYPE_STRING, 0, 1, 0, SKIP_OPEN_TABLE},
+  {"PLUGIN_AUTH_VERSION", 80, MYSQL_TYPE_STRING, 0, 1, 0, SKIP_OPEN_TABLE},
   {0, 0, MYSQL_TYPE_STRING, 0, 0, 0, SKIP_OPEN_TABLE}
 };
 

=== modified file 'storage/archive/ha_archive.cc'
--- a/storage/archive/ha_archive.cc	2009-09-07 20:50:10 +0000
+++ b/storage/archive/ha_archive.cc	2010-02-15 07:47:03 +0000
@@ -1642,4 +1642,10 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(archive)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;
 

=== modified file 'storage/blackhole/ha_blackhole.cc'
--- a/storage/blackhole/ha_blackhole.cc	2008-11-10 20:21:49 +0000
+++ b/storage/blackhole/ha_blackhole.cc	2010-02-15 07:47:03 +0000
@@ -369,3 +369,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(blackhole)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/csv/ha_tina.cc'
--- a/storage/csv/ha_tina.cc	2009-04-25 10:05:32 +0000
+++ b/storage/csv/ha_tina.cc	2010-02-15 07:47:03 +0000
@@ -1636,4 +1636,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
-
+mariaext_declare_plugin(csv)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/example/ha_example.cc'
--- a/storage/example/ha_example.cc	2008-02-24 13:12:17 +0000
+++ b/storage/example/ha_example.cc	2010-02-15 07:47:03 +0000
@@ -906,3 +906,9 @@
   NULL                                          /* config options */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(example)
+{
+  "0.1",                      /* string version */
+  PLUGIN_MATURITY_TEST        /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/federated/ha_federated.cc'
--- a/storage/federated/ha_federated.cc	2009-09-07 20:50:10 +0000
+++ b/storage/federated/ha_federated.cc	2010-02-15 07:47:03 +0000
@@ -3379,3 +3379,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(federated)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_BETA        /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/federatedx/ha_federatedx.cc'
--- a/storage/federatedx/ha_federatedx.cc	2009-11-03 11:08:09 +0000
+++ b/storage/federatedx/ha_federatedx.cc	2010-02-15 07:47:03 +0000
@@ -3485,9 +3485,15 @@
   PLUGIN_LICENSE_GPL,
   federatedx_db_init, /* Plugin Init */
   federatedx_done, /* Plugin Deinit */
-  0x0100 /* 1.0 */,
+  0x0200 /* 2.0 */,
   NULL,                       /* status variables                */
   NULL,                       /* system variables                */
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(federated)
+{
+  "2.0",                      /* string version */
+  PLUGIN_MATURITY_BETA        /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/heap/ha_heap.cc'
--- a/storage/heap/ha_heap.cc	2009-09-07 20:50:10 +0000
+++ b/storage/heap/ha_heap.cc	2010-02-15 07:47:03 +0000
@@ -767,3 +767,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(heap)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/ibmdb2i/ha_ibmdb2i.cc'
--- a/storage/ibmdb2i/ha_ibmdb2i.cc	2009-07-08 09:10:01 +0000
+++ b/storage/ibmdb2i/ha_ibmdb2i.cc	2010-02-15 07:47:03 +0000
@@ -3357,3 +3357,9 @@
   NULL                                          /* config options */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(ibmdb2i)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_UNKNOWN     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/innobase/handler/ha_innodb.cc'
--- a/storage/innobase/handler/ha_innodb.cc	2009-10-16 22:57:48 +0000
+++ b/storage/innobase/handler/ha_innodb.cc	2010-02-15 07:47:03 +0000
@@ -8684,6 +8684,12 @@
   NULL /* reserved */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(innobase)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;
 
 /** @brief Initialize the default value of innodb_commit_concurrency.
 

=== modified file 'storage/innodb_plugin/handler/ha_innodb.cc'
--- a/storage/innodb_plugin/handler/ha_innodb.cc	2009-08-04 08:02:48 +0000
+++ b/storage/innodb_plugin/handler/ha_innodb.cc	2010-02-15 07:47:03 +0000
@@ -10032,6 +10032,12 @@
 i_s_innodb_cmpmem,
 i_s_innodb_cmpmem_reset
 mysql_declare_plugin_end;
+mariaext_declare_plugin(innodb_plugin)
+{
+  INNODB_VERSION_STR,         /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;
 
 /** @brief Initialize the default value of innodb_commit_concurrency.
 

=== modified file 'storage/maria/ha_maria.cc'
--- a/storage/maria/ha_maria.cc	2009-10-26 11:35:42 +0000
+++ b/storage/maria/ha_maria.cc	2010-02-15 07:47:03 +0000
@@ -3346,9 +3346,15 @@
   PLUGIN_LICENSE_GPL,
   ha_maria_init,              /* Plugin Init                     */
   NULL,                       /* Plugin Deinit                   */
-  0x0100,                     /* 1.0                             */
+  0x0105,                     /* 1.5                             */
   status_variables,           /* status variables                */
   system_variables,           /* system variables                */
   NULL
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(maria)
+{
+  "1.5",                      /* string version */
+  PLUGIN_MATURITY_GAMMA       /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/myisam/ha_myisam.cc'
--- a/storage/myisam/ha_myisam.cc	2009-10-17 19:12:28 +0000
+++ b/storage/myisam/ha_myisam.cc	2010-02-15 07:47:03 +0000
@@ -2183,6 +2183,12 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(myisam)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;
 
 
 #ifdef HAVE_QUERY_CACHE

=== modified file 'storage/myisammrg/ha_myisammrg.cc'
--- a/storage/myisammrg/ha_myisammrg.cc	2009-10-15 21:38:29 +0000
+++ b/storage/myisammrg/ha_myisammrg.cc	2010-02-15 07:47:03 +0000
@@ -1289,3 +1289,9 @@
   NULL                        /* config options                  */
 }
 mysql_declare_plugin_end;
+mariaext_declare_plugin(myisammrg)
+{
+  "1.0",                      /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+}
+mariaext_declare_plugin_end;

=== modified file 'storage/pbxt/src/ha_pbxt.cc'
--- a/storage/pbxt/src/ha_pbxt.cc	2009-09-03 06:15:03 +0000
+++ b/storage/pbxt/src/ha_pbxt.cc	2010-02-15 07:47:03 +0000
@@ -5507,6 +5507,18 @@
 drizzle_declare_plugin_end;
 #else
 mysql_declare_plugin_end;
+#ifdef MARIADB_BASE_VERSION
+mariaext_declare_plugin(pbxt)
+{ /* PBXT */
+  "1.0.09g RC3",              /* string version */
+  PLUGIN_MATURITY_GAMMA       /* maturity */
+},
+{ /* PBXT_STATISTICS */
+  "1.0.09g RC3",              /* string version */
+  PLUGIN_MATURITY_GAMMA       /* maturity */
+}
+mariaext_declare_plugin_end;
+#endif
 #endif
 
 #if defined(XT_WIN) && defined(XT_COREDUMP)

=== modified file 'storage/xtradb/handler/ha_innodb.cc'
--- a/storage/xtradb/handler/ha_innodb.cc	2009-10-16 22:57:48 +0000
+++ b/storage/xtradb/handler/ha_innodb.cc	2010-02-15 07:47:03 +0000
@@ -10540,6 +10540,69 @@
 i_s_innodb_index_stats,
 i_s_innodb_patches
 mysql_declare_plugin_end;
+mariaext_declare_plugin(innobase)
+{ /* InnoDB */
+  INNODB_VERSION_STR,         /* string version */
+  PLUGIN_MATURITY_RELEASE     /* maturity */
+},
+{ /* INNODB_RSEG */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_BUFFER_POOL_PAGES */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_BUFFER_POOL_PAGES_INDEX */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_BUFFER_POOL_PAGES_BLOB */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_TRX */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_LOCKS */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_LOCK_WAITS */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_CMP */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_CMP_RESET */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_CMPMEM */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_CMPMEM_RESET */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_TABLE_STATS */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* INNODB_INDEX_STATS */
+  "1.0",
+  PLUGIN_MATURITY_RELEASE
+},
+{ /* XTRADB_ENHANCEMENTS */
+  INNODB_VERSION_STR,
+  PLUGIN_MATURITY_RELEASE
+}
+mariaext_declare_plugin_end;
+
 
 /** @brief Initialize the default value of innodb_commit_concurrency.