StateSnapshot::StateSnapshot(Application& app, HistoryArchiveState const& state)
    : mApp(app)
    , mLocalState(state)
    , mSnapDir(app.getTmpDirManager().tmpDir("snapshot"))
    , mLedgerSnapFile(std::make_shared<FileTransferInfo>(
          mSnapDir, HISTORY_FILE_TYPE_LEDGER, mLocalState.currentLedger))

    , mTransactionSnapFile(std::make_shared<FileTransferInfo>(
          mSnapDir, HISTORY_FILE_TYPE_TRANSACTIONS, mLocalState.currentLedger))

    , mTransactionResultSnapFile(std::make_shared<FileTransferInfo>(
          mSnapDir, HISTORY_FILE_TYPE_RESULTS, mLocalState.currentLedger))

    , mSCPHistorySnapFile(std::make_shared<FileTransferInfo>(
          mSnapDir, HISTORY_FILE_TYPE_SCP, mLocalState.currentLedger))

{
    makeLive();
}
Пример #2
0
 __attribute__((always_inline)) T produce_register_pressure() const {
   return makeLive() * consumeLiveValues(d1);
 }