[Groonga-mysql-commit] mroonga/mroonga [fix-for-visual-studio] Add version string to system variables. refs #1157, 1158

Back to archive index

Kentoku null+****@clear*****
Thu Oct 4 10:31:46 JST 2012


Kentoku	2011-11-08 00:24:41 +0900 (Tue, 08 Nov 2011)

  New Revision: 96ca7c05b1b727ca1d882b982cab0c17c4cef3e6
  https://github.com/mroonga/mroonga/commit/96ca7c05b1b727ca1d882b982cab0c17c4cef3e6

  Log:
    Add version string to system variables. refs #1157,1158

  Modified files:
    ha_mroonga.cc

  Modified: ha_mroonga.cc (+18 -0)
===================================================================
--- ha_mroonga.cc    2011-11-07 18:05:31 +0900 (6b0b4b4)
+++ ha_mroonga.cc    2011-11-08 00:24:41 +0900 (7f30834)
@@ -113,6 +113,8 @@ static bool mrn_logfile_opened = false;
 grn_log_level mrn_log_level_default = GRN_LOG_DEFAULT_LEVEL;
 ulong mrn_log_level = (ulong) mrn_log_level_default;
 char *mrn_default_parser;
+static char *mrn_libgroonga_version = (char *) grn_get_version();
+static char *mrn_version = MRN_VERSION;
 
 static void mrn_logger_func(int level, const char *time, const char *title,
                             const char *msg, const char *location,
@@ -257,11 +259,27 @@ static bool mrn_dry_write(THD *thd)
   DBUG_RETURN(dry_write_p);
 }
 
+static MYSQL_SYSVAR_STR(libgroonga_version, mrn_libgroonga_version,
+                        PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_READONLY,
+                        "The version of libgroonga",
+                        NULL,
+                        NULL,
+                        grn_get_version());
+
+static MYSQL_SYSVAR_STR(version, mrn_version,
+                        PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_READONLY,
+                        "The version of groonga storage engine",
+                        NULL,
+                        NULL,
+                        MRN_VERSION);
+
 struct st_mysql_sys_var *mrn_system_variables[] =
 {
   MYSQL_SYSVAR(log_level),
   MYSQL_SYSVAR(default_parser),
   MYSQL_SYSVAR(dry_write),
+  MYSQL_SYSVAR(libgroonga_version),
+  MYSQL_SYSVAR(version),
   NULL
 };
 
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-mysql-commit mailing list
Back to archive index