mirror of
https://github.com/MariaDB/server.git
synced 2025-01-22 14:54:20 +01:00
add big ydb lock. addresses #7
git-svn-id: file:///svn/tokudb@1670 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
0ac7cfc8e4
commit
94be297db1
4 changed files with 511 additions and 273 deletions
|
@ -4,7 +4,9 @@
|
|||
#ident "Copyright (c) 2007 Tokutek Inc. All rights reserved."
|
||||
|
||||
#include <sys/types.h>
|
||||
#ifndef _XOPEN_SOURCE
|
||||
#define _XOPEN_SOURCE 500
|
||||
#endif
|
||||
#define _FILE_OFFSET_BITS 64
|
||||
|
||||
typedef struct brt *BRT;
|
||||
|
|
|
@ -6,7 +6,7 @@ LIBNAME=libdb
|
|||
# OPTFLAGS = -O2
|
||||
CFLAGS = -W -Wall -Werror -g -fPIC $(OPTFLAGS)
|
||||
CPPFLAGS = -I../include -I../newbrt
|
||||
CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE
|
||||
CPPFLAGS += -D_GNU_SOURCE -D_THREAD_SAFE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE
|
||||
|
||||
|
||||
ifeq ($(OSX),OSX)
|
||||
|
|
|
@ -32,6 +32,44 @@ struct __toku_db_internal {
|
|||
int associate_is_immutable; // If this DB is a secondary then this field indicates that the index never changes due to updates.
|
||||
};
|
||||
|
||||
#if DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1
|
||||
typedef void (*toku_env_errcall_t)(const char *, char *);
|
||||
#elif DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 3
|
||||
typedef void (*toku_env_errcall_t)(const DB_ENV *, const char *, const char *);
|
||||
#else
|
||||
#error
|
||||
#endif
|
||||
|
||||
struct __toku_db_env_internal {
|
||||
int is_panicked;
|
||||
int ref_count;
|
||||
u_int32_t open_flags;
|
||||
int open_mode;
|
||||
toku_env_errcall_t errcall;
|
||||
void *errfile;
|
||||
const char *errpfx;
|
||||
char *dir; /* A malloc'd copy of the directory. */
|
||||
char *tmp_dir;
|
||||
char *lg_dir;
|
||||
char **data_dirs;
|
||||
u_int32_t n_data_dirs;
|
||||
//void (*noticecall)(DB_ENV *, db_notices);
|
||||
unsigned long cachetable_size;
|
||||
CACHETABLE cachetable;
|
||||
TOKULOGGER logger;
|
||||
};
|
||||
|
||||
struct __toku_db_txn_internal {
|
||||
//TXNID txnid64; /* A sixty-four bit txn id. */
|
||||
TOKUTXN tokutxn;
|
||||
DB_TXN *parent;
|
||||
};
|
||||
|
||||
struct __toku_dbc_internal {
|
||||
BRT_CURSOR c;
|
||||
DB_TXN *txn;
|
||||
};
|
||||
|
||||
typedef struct __toku_lock_tree {
|
||||
DB* db;
|
||||
//Some Red Black tree
|
||||
|
@ -868,4 +906,6 @@ DUPSORT db
|
|||
+++++
|
||||
*/
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue