Commit e65963f3 authored by Yoni Fogel's avatar Yoni Fogel

closes #5204 Call loader once during indexer create instead of N times

Loader can already handle N dbs

git-svn-id: file:///svn/toku/tokudb@46165 c7de825b-a66e-492c-adef-691d508d4ae1
parent b79fce44
......@@ -200,9 +200,9 @@ toku_indexer_create_indexer(DB_ENV *env,
// underlying FT, then those transactions can do dummy operations on the FT
// while the DB gets redirected back to an empty dictionary
//
for (int i = 0; i < N; i++) {
{
DB_LOADER* loader = NULL;
rval = env->create_loader(env, txn, &loader, dest_dbs[i], 1, &dest_dbs[i], NULL, NULL, DB_PRELOCKED_WRITE | LOADER_USE_PUTS);
rval = env->create_loader(env, txn, &loader, NULL, N, &dest_dbs[0], NULL, NULL, DB_PRELOCKED_WRITE | LOADER_USE_PUTS);
if (rval) {
goto create_exit;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment