@@ -178,20 +178,6 @@ LedgerManagerImpl::setState(State s)
178
178
{
179
179
mApp .getCatchupManager ().logAndUpdateCatchupStatus (true );
180
180
}
181
-
182
- if (mState == LM_CATCHING_UP_STATE && !mStartCatchup )
183
- {
184
- mStartCatchup = std::make_unique<VirtualClock::time_point>(
185
- mApp .getClock ().now ());
186
- }
187
- else if (mState == LM_SYNCED_STATE && mStartCatchup )
188
- {
189
- std::chrono::nanoseconds duration =
190
- mApp .getClock ().now () - *mStartCatchup ;
191
- mCatchupDuration .Update (duration);
192
- CLOG_DEBUG (Perf, " Caught up to the network in {} seconds" ,
193
- std::chrono::duration<double >(duration).count ());
194
- }
195
181
}
196
182
}
197
183
@@ -397,30 +383,6 @@ LedgerManagerImpl::loadLastKnownLedger(bool restoreBucketlist)
397
383
}
398
384
}
399
385
400
- bool
401
- LedgerManagerImpl::rebuildingInMemoryState ()
402
- {
403
- return mRebuildInMemoryState ;
404
- }
405
-
406
- void
407
- LedgerManagerImpl::setupInMemoryStateRebuild ()
408
- {
409
- if (!mRebuildInMemoryState )
410
- {
411
- LedgerHeader lh;
412
- HistoryArchiveState has;
413
- auto & ps = mApp .getPersistentState ();
414
- ps.setState (PersistentState::kLastClosedLedger ,
415
- binToHex (xdrSha256 (lh)));
416
- ps.setState (PersistentState::kHistoryArchiveState , has.toString ());
417
- ps.setState (PersistentState::kLastSCPData , " " );
418
- ps.setState (PersistentState::kLastSCPDataXDR , " " );
419
- ps.setState (PersistentState::kLedgerUpgrades , " " );
420
- mRebuildInMemoryState = true ;
421
- }
422
- }
423
-
424
386
Database&
425
387
LedgerManagerImpl::getDatabase ()
426
388
{
0 commit comments