Commit 85a4931c authored by Zardosht Kasheff's avatar Zardosht Kasheff Committed by Yoni Fogel

[t:4920], remove ydb lock from indexer->close and indexer->abort

git-svn-id: file:///svn/toku/tokudb@44161 c7de825b-a66e-492c-adef-691d508d4ae1
parent c613d420
......@@ -329,8 +329,6 @@ close_indexer(DB_INDEXER *indexer) {
int r = 0;
(void) __sync_fetch_and_sub(&STATUS_VALUE(INDEXER_CURRENT), 1);
toku_ydb_lock();
{
// Mark txn as needing a checkpoint.
// (This will cause a local checkpoint of created index files, which is necessary
// because these files are not necessarily on disk and all the operations
......@@ -348,8 +346,6 @@ close_indexer(DB_INDEXER *indexer) {
// Disassociate the indexer from the hot db and free_indexer
disassociate_indexer_from_hot_dbs(indexer);
free_indexer(indexer);
}
toku_ydb_unlock();
if ( r == 0 ) {
(void) __sync_fetch_and_add(&STATUS_VALUE(INDEXER_CLOSE), 1);
......@@ -363,14 +359,9 @@ static int
abort_indexer(DB_INDEXER *indexer) {
(void) __sync_fetch_and_sub(&STATUS_VALUE(INDEXER_CURRENT), 1);
(void) __sync_fetch_and_add(&STATUS_VALUE(INDEXER_ABORT), 1);
toku_ydb_lock();
{
// Disassociate the indexer from the hot db and free_indexer
disassociate_indexer_from_hot_dbs(indexer);
free_indexer(indexer);
}
toku_ydb_unlock();
return 0;
}
......
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