Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
4fe10086
Commit
4fe10086
authored
Dec 01, 2010
by
Rich Prohaska
Committed by
Yoni Fogel
Apr 16, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#3054 fix closes[t:3054]
git-svn-id:
file:///svn/toku/tokudb@26088
c7de825b-a66e-492c-adef-691d508d4ae1
parent
f3701dcc
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
newbrt/logformat.c
newbrt/logformat.c
+3
-0
src/ydb.c
src/ydb.c
+3
-3
No files found.
newbrt/logformat.c
View file @
4fe10086
...
...
@@ -332,6 +332,9 @@ generate_log_writer (void) {
fprintf
(
cf
,
"static u_int64_t toku_lsn_increment=1;
\n
void toku_set_lsn_increment (uint64_t incr) { assert(incr>0 && incr< (16LL<<32)); toku_lsn_increment=incr; }
\n
"
);
generate_get_timestamp
();
DO_LOGTYPES
(
lt
,
{
fprintf
(
hf
,
"static const size_t toku_log_%s_overhead = (+4+1+8"
,
lt
->
name
);
DO_FIELDS
(
ft
,
lt
,
fprintf
(
hf
,
"+%lu"
,
sizeof
(
ft
->
type
)));
fprintf
(
hf
,
"+8);
\n
"
);
fprintf2
(
cf
,
hf
,
"int toku_log_%s (TOKULOGGER logger, LSN *lsnp, int do_fsync"
,
lt
->
name
);
DO_FIELDS
(
ft
,
lt
,
fprintf2
(
cf
,
hf
,
", %s %s"
,
ft
->
type
,
ft
->
name
));
fprintf
(
hf
,
");
\n
"
);
...
...
src/ydb.c
View file @
4fe10086
...
...
@@ -33,6 +33,7 @@ const char *toku_copyright_string = "Copyright (c) 2007-2009 Tokutek Inc. All r
#include "indexer.h"
#include "ydb_load.h"
#include "brtloader.h"
#include "log_header.h"
#ifdef TOKUTRACE
#define DB_ENV_CREATE_FUN db_env_create_toku10
...
...
@@ -3890,9 +3891,8 @@ log_del_multiple(DB_TXN *txn, DB *src_db, const DBT *key, const DBT *val, uint32
if
(
num_dbs
>
0
)
{
TOKUTXN
ttxn
=
db_txn_struct_i
(
txn
)
->
tokutxn
;
BRT
src_brt
=
src_db
?
src_db
->
i
->
brt
:
NULL
;
const
uint32_t
log_entry_overhead
=
24
;
// rough approximation of the log entry overhead for deletes
uint32_t
del_multiple_size
=
key
->
size
+
val
->
size
+
log_entry_overhead
;
uint32_t
del_single_sizes
=
sum_size
(
num_dbs
,
keys
,
log_entry_overhead
);
uint32_t
del_multiple_size
=
key
->
size
+
val
->
size
+
num_dbs
*
sizeof
(
uint32_t
)
+
toku_log_enq_delete_multiple_overhead
;
uint32_t
del_single_sizes
=
sum_size
(
num_dbs
,
keys
,
toku_log_enq_delete_any_overhead
);
if
(
del_single_sizes
<
del_multiple_size
)
{
for
(
uint32_t
i
=
0
;
r
==
0
&&
i
<
num_dbs
;
i
++
)
r
=
log_del_single
(
txn
,
brts
[
i
],
&
keys
[
i
]);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment