mirror of
https://github.com/MariaDB/server.git
synced 2025-02-02 03:51:50 +01:00
3e90f0d86c
Part of postreview fixes added. mysql-test/r/maria.result: Added variable to control log directory syncs. storage/maria/ha_maria.cc: Added variable to control log directory syncs. storage/maria/ma_loghandler.h: Added variable to control log directory syncs. storage/maria/ma_loghandler_lsn.h: postreview fix storage/maria/unittest/Makefile.am: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_first_lsn-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_max_lsn-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_multigroup-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_multithread-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_noflush-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_pagecache-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_test_loghandler_purge-t.c: New file with logrecord descriptors for tests. storage/maria/unittest/ma_loghandler_examples.c: New BitKeeper file ``storage/maria/unittest/ma_loghandler_examples.c''
52 lines
1.9 KiB
C
52 lines
1.9 KiB
C
/* TODO: copyright */
|
|
|
|
#include "../maria_def.h"
|
|
|
|
static LOG_DESC INIT_LOGREC_FIXED_RECORD_0LSN_EXAMPLE=
|
|
{LOGRECTYPE_FIXEDLENGTH, 6, 6, NULL, NULL, NULL, 0,
|
|
"fixed0example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
static LOG_DESC INIT_LOGREC_VARIABLE_RECORD_0LSN_EXAMPLE=
|
|
{LOGRECTYPE_VARIABLE_LENGTH, 0, 9, NULL, NULL, NULL, 0,
|
|
"variable0example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
static LOG_DESC INIT_LOGREC_FIXED_RECORD_1LSN_EXAMPLE=
|
|
{LOGRECTYPE_PSEUDOFIXEDLENGTH, 7, 7, NULL, NULL, NULL, 1,
|
|
"fixed1example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
static LOG_DESC INIT_LOGREC_VARIABLE_RECORD_1LSN_EXAMPLE=
|
|
{LOGRECTYPE_VARIABLE_LENGTH, 0, 12, NULL, NULL, NULL, 1,
|
|
"variable1example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
static LOG_DESC INIT_LOGREC_FIXED_RECORD_2LSN_EXAMPLE=
|
|
{LOGRECTYPE_PSEUDOFIXEDLENGTH, 23, 23, NULL, NULL, NULL, 2,
|
|
"fixed2example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
static LOG_DESC INIT_LOGREC_VARIABLE_RECORD_2LSN_EXAMPLE=
|
|
{LOGRECTYPE_VARIABLE_LENGTH, 0, 19, NULL, NULL, NULL, 2,
|
|
"variable2example", LOGREC_NOT_LAST_IN_GROUP, NULL, NULL};
|
|
|
|
|
|
void example_loghandler_init()
|
|
{
|
|
int i;
|
|
log_record_type_descriptor[LOGREC_FIXED_RECORD_0LSN_EXAMPLE]=
|
|
INIT_LOGREC_FIXED_RECORD_0LSN_EXAMPLE;
|
|
log_record_type_descriptor[LOGREC_VARIABLE_RECORD_0LSN_EXAMPLE]=
|
|
INIT_LOGREC_VARIABLE_RECORD_0LSN_EXAMPLE;
|
|
log_record_type_descriptor[LOGREC_FIXED_RECORD_1LSN_EXAMPLE]=
|
|
INIT_LOGREC_FIXED_RECORD_1LSN_EXAMPLE;
|
|
log_record_type_descriptor[LOGREC_VARIABLE_RECORD_1LSN_EXAMPLE]=
|
|
INIT_LOGREC_VARIABLE_RECORD_1LSN_EXAMPLE;
|
|
log_record_type_descriptor[LOGREC_FIXED_RECORD_2LSN_EXAMPLE]=
|
|
INIT_LOGREC_FIXED_RECORD_2LSN_EXAMPLE;
|
|
log_record_type_descriptor[LOGREC_VARIABLE_RECORD_2LSN_EXAMPLE]=
|
|
INIT_LOGREC_VARIABLE_RECORD_2LSN_EXAMPLE;
|
|
for (i= LOGREC_VARIABLE_RECORD_2LSN_EXAMPLE + 1;
|
|
i < LOGREC_NUMBER_OF_TYPES;
|
|
i++)
|
|
log_record_type_descriptor[i].class= LOGRECTYPE_NOT_ALLOWED;
|
|
}
|
|
|
|
|
|
|