Skip to content

Commit

Permalink
Add note about eviction
Browse files Browse the repository at this point in the history
  • Loading branch information
2opremio committed Sep 5, 2023
1 parent 6e1f270 commit 35abf5b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/soroban-rpc/internal/ingest/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,10 @@ func (s *Service) evictLedgerEntries(tx db.WriteTx, ledgerCloseMeta xdr.LedgerCl
keysToEvict := make([]xdr.LedgerKey, len(ledgerCloseMeta.V2.EvictedTemporaryLedgerKeys)+len(ledgerCloseMeta.V2.EvictedPersistentLedgerEntries))
l := copy(keysToEvict, ledgerCloseMeta.V2.EvictedTemporaryLedgerKeys)
for i, entry := range ledgerCloseMeta.V2.EvictedPersistentLedgerEntries {
// TODO: we probably shouldn't be deleting evicted persistent ledger entries cold turkey.
// Otherwise preflighting will fail for restoreFootprint.
// For restoreFootPrint we need to confirm that the entry existed and its size (for the resource estimation).
// so maybe we should store that.
key, err := entry.LedgerKey()
if err != nil {
return err
Expand Down

0 comments on commit 35abf5b

Please sign in to comment.