mirror of
https://codeberg.org/anoncontributorxmr/monero.git
synced 2024-12-25 22:57:46 +00:00
blockchain_utilities: Pass expected number of blocks when starting batch
This commit is contained in:
parent
6e170c8b78
commit
699e4b3f65
2 changed files with 4 additions and 4 deletions
|
@ -236,7 +236,7 @@ int main(int argc, char* argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
if (opt_batch)
|
if (opt_batch)
|
||||||
blockchain->batch_start();
|
blockchain->batch_start(db_batch_size);
|
||||||
uint64_t i = 0;
|
uint64_t i = 0;
|
||||||
for (i = start_block; i < end_block + 1; ++i)
|
for (i = start_block; i < end_block + 1; ++i)
|
||||||
{
|
{
|
||||||
|
@ -277,7 +277,7 @@ int main(int argc, char* argv[])
|
||||||
std::cout << "\r \r";
|
std::cout << "\r \r";
|
||||||
std::cout << "[- batch commit at height " << i + 1 << " -]" << ENDL;
|
std::cout << "[- batch commit at height " << i + 1 << " -]" << ENDL;
|
||||||
blockchain->batch_stop();
|
blockchain->batch_stop();
|
||||||
blockchain->batch_start();
|
blockchain->batch_start(db_batch_size);
|
||||||
std::cout << ENDL;
|
std::cout << ENDL;
|
||||||
blockchain->show_stats();
|
blockchain->show_stats();
|
||||||
}
|
}
|
||||||
|
|
|
@ -254,7 +254,7 @@ int import_from_file(FakeCore& simple_core, std::string& import_file_path, uint6
|
||||||
}
|
}
|
||||||
|
|
||||||
if (use_batch)
|
if (use_batch)
|
||||||
simple_core.batch_start();
|
simple_core.batch_start(db_batch_size);
|
||||||
|
|
||||||
LOG_PRINT_L0("Reading blockchain from bootstrap file...");
|
LOG_PRINT_L0("Reading blockchain from bootstrap file...");
|
||||||
std::cout << ENDL;
|
std::cout << ENDL;
|
||||||
|
@ -482,7 +482,7 @@ int import_from_file(FakeCore& simple_core, std::string& import_file_path, uint6
|
||||||
// zero-based height
|
// zero-based height
|
||||||
std::cout << ENDL << "[- batch commit at height " << h-1 << " -]" << ENDL;
|
std::cout << ENDL << "[- batch commit at height " << h-1 << " -]" << ENDL;
|
||||||
simple_core.batch_stop();
|
simple_core.batch_stop();
|
||||||
simple_core.batch_start();
|
simple_core.batch_start(db_batch_size);
|
||||||
std::cout << ENDL;
|
std::cout << ENDL;
|
||||||
#if !defined(BLOCKCHAIN_DB) || (BLOCKCHAIN_DB == DB_LMDB)
|
#if !defined(BLOCKCHAIN_DB) || (BLOCKCHAIN_DB == DB_LMDB)
|
||||||
simple_core.m_storage.get_db().show_stats();
|
simple_core.m_storage.get_db().show_stats();
|
||||||
|
|
Loading…
Reference in a new issue