| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Ouroboros.Consensus.Storage.LeiosDB.Impl.SQLite.Tooling
Description
Offline maintenance of a LeiosDB partition file, for internal tooling.
These open the file directly, not through a
LeiosDbHandle, so they
must not run against a file that a node has open.
Synopsis
- truncateLeiosDbAfterSlot ∷ HasCallStack ⇒ FilePath → SlotNo → IO ()
- vacuumLeiosDb ∷ HasCallStack ⇒ FilePath → IO ()
Documentation
truncateLeiosDbAfterSlot ∷ HasCallStack ⇒ FilePath → SlotNo → IO () Source #
Delete the EBs announced after the given slot.
For internal tooling. Works for both the volatile and the immutable partition files.
vacuumLeiosDb ∷ HasCallStack ⇒ FilePath → IO () Source #
Shrink a LeiosDb file to the space its rows need.
A delete frees pages inside the file without returning them to the filesystem. This rewrites the file, so it needs free space of about the size of the file. For internal tooling.