From e5a323e107767ceb5106b85d077d4ac9d2d37778 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Tue, 9 Apr 2013 15:45:31 +0200 Subject: single table discovery: handlerton::discover_table() method. fixes for need_full_discover_for_existence mode --- storage/archive/azlib.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'storage/archive/azlib.h') diff --git a/storage/archive/azlib.h b/storage/archive/azlib.h index 29a6329fb0a..05fc299e581 100644 --- a/storage/archive/azlib.h +++ b/storage/archive/azlib.h @@ -331,8 +331,8 @@ extern int azclose(azio_stream *file); error number (see function gzerror below). */ -extern int azwrite_frm (azio_stream *s, char *blob, unsigned int length); -extern int azread_frm (azio_stream *s, char *blob); +extern int azwrite_frm (azio_stream *s, uchar *blob, unsigned int length); +extern int azread_frm (azio_stream *s, uchar *blob); extern int azwrite_comment (azio_stream *s, char *blob, unsigned int length); extern int azread_comment (azio_stream *s, char *blob); -- cgit v1.2.1 From e06cb31719ce31fb1cd7944d1de86d4de9e3eca6 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Tue, 9 Apr 2013 15:57:09 +0200 Subject: CREATE TABLE and frm-less discovering engines. Now CREATE TABLE does not write the frm file on disk, if the engine can discover it --- storage/archive/azlib.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'storage/archive/azlib.h') diff --git a/storage/archive/azlib.h b/storage/archive/azlib.h index 05fc299e581..09f61afcd28 100644 --- a/storage/archive/azlib.h +++ b/storage/archive/azlib.h @@ -331,7 +331,7 @@ extern int azclose(azio_stream *file); error number (see function gzerror below). */ -extern int azwrite_frm (azio_stream *s, uchar *blob, unsigned int length); +extern int azwrite_frm (azio_stream *s, const uchar *blob, unsigned int length); extern int azread_frm (azio_stream *s, uchar *blob); extern int azwrite_comment (azio_stream *s, char *blob, unsigned int length); extern int azread_comment (azio_stream *s, char *blob); -- cgit v1.2.1 From 02c712aa546df8d6e9c285e6adc95309925673e3 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Tue, 9 Apr 2013 16:18:33 +0200 Subject: * frm extra2 segment. * persistent table versions in the extra2 * ha_archive::frm_compare using TABLE_SHARE::tabledef_version * distinguish between "important" and "optional" extra2 frm values * write engine-defined attributes (aka "table options") to extra2, not to extra, but still read from the old location, if they're found there. --- storage/archive/azlib.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'storage/archive/azlib.h') diff --git a/storage/archive/azlib.h b/storage/archive/azlib.h index 09f61afcd28..2971705b2f1 100644 --- a/storage/archive/azlib.h +++ b/storage/archive/azlib.h @@ -198,6 +198,7 @@ extern "C" { #define AZ_BUFSIZE_READ 32768 #define AZ_BUFSIZE_WRITE 16384 +#define AZ_FRMVER_LEN 16 /* same as MY_UUID_SIZE in 10.0.2 */ typedef struct azio_stream { z_stream stream; @@ -227,6 +228,8 @@ typedef struct azio_stream { unsigned char dirty; /* State of file */ unsigned int frm_start_pos; /* Position for start of FRM */ unsigned int frm_length; /* Position for start of FRM */ + unsigned char frmver[AZ_FRMVER_LEN]; + unsigned int frmver_length; unsigned int comment_start_pos; /* Position for start of comment */ unsigned int comment_length; /* Position for start of comment */ } azio_stream; -- cgit v1.2.1