Parallel ledger loader & I/O performance improvements:

- Only duplicate records from archive to writable during online_delete.
- Log duration of nodestore reads.
- Include nodestore counters in perf_log output.
- Remove gratuitous nodestore activity counting.
- Report initial sync duration in server_info and perfLog.
- Report state_accounting in perfLog.
- Make state_accounting durations more accurate.
- Parallel ledger loader.
- Config parameter to load ledgers on start.
This commit is contained in:
Mark Travis
2021-12-14 17:08:59 -08:00
committed by Nik Bougalis
parent 5a4654a0da
commit 7c12f01358
28 changed files with 245 additions and 89 deletions

View File

@@ -49,10 +49,11 @@ class PerfLog_test : public beast::unit_test::suite
struct Fixture
{
Application& app_;
beast::Journal j_;
bool stopSignaled{false};
explicit Fixture(beast::Journal j) : j_(j)
explicit Fixture(Application& app, beast::Journal j) : app_(app), j_(j)
{
}
@@ -103,7 +104,7 @@ class PerfLog_test : public beast::unit_test::suite
perf::PerfLog::Setup const setup{
withFile == WithFile::no ? "" : logFile(), logInterval()};
return perf::make_PerfLog(
setup, j_, [this]() { return signalStop(); });
setup, app_, j_, [this]() { return signalStop(); });
}
// Block until the log file has grown in size, indicating that the
@@ -192,7 +193,7 @@ public:
{
// Verify a PerfLog creates its file when constructed.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
BEAST_EXPECT(!exists(fixture.logFile()));
auto perfLog{fixture.perfLog(WithFile::yes)};
@@ -204,7 +205,7 @@ public:
// Create a file where PerfLog wants to put its directory.
// Make sure that PerfLog tries to shutdown the server since it
// can't open its file.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
if (!BEAST_EXPECT(!exists(fixture.logDir())))
return;
@@ -238,7 +239,7 @@ public:
// Put a write protected file where PerfLog wants to write its
// file. Make sure that PerfLog tries to shutdown the server
// since it can't open its file.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
if (!BEAST_EXPECT(!exists(fixture.logDir())))
return;
@@ -297,7 +298,7 @@ public:
{
// Exercise the rpc interfaces of PerfLog.
// Start up the PerfLog that we'll use for testing.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
auto perfLog{fixture.perfLog(withFile)};
perfLog->start();
@@ -502,7 +503,7 @@ public:
// Exercise the jobs interfaces of PerfLog.
// Start up the PerfLog that we'll use for testing.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
auto perfLog{fixture.perfLog(withFile)};
perfLog->start();
@@ -849,7 +850,7 @@ public:
// the PerLog behaves as well as possible if an invalid ID is passed.
// Start up the PerfLog that we'll use for testing.
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
auto perfLog{fixture.perfLog(withFile)};
perfLog->start();
@@ -989,7 +990,7 @@ public:
// the interface and see that it doesn't crash.
using namespace boost::filesystem;
Fixture fixture{j_};
Fixture fixture{env_.app(), j_};
BEAST_EXPECT(!exists(fixture.logDir()));
auto perfLog{fixture.perfLog(withFile)};