Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data DiskPolicy = DiskPolicy {}
- data DiskPolicyArgs = DiskPolicyArgs SnapshotInterval NumOfDiskSnapshots
- data NumOfDiskSnapshots
- data SnapshotInterval
- data TimeSinceLast time
- = NoSnapshotTakenYet
- | TimeSinceLast time
- defaultDiskPolicyArgs ∷ DiskPolicyArgs
- mkDiskPolicy ∷ SecurityParam → DiskPolicyArgs → DiskPolicy
Documentation
data DiskPolicy Source #
On-disk policy
We only write ledger states that are older than k
blocks to disk (that is,
snapshots that are guaranteed valid). The on-disk policy determines how often
we write to disk and how many checkpoints we keep.
DiskPolicy | |
|
Instances
data NumOfDiskSnapshots Source #
Number of snapshots to be stored on disk. This is either the default value
as determined by the DiskPolicy, or it is provided by the user. See the
DiskPolicy
documentation for more information.
Instances
Generic NumOfDiskSnapshots Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy type Rep NumOfDiskSnapshots ∷ Type → Type # | |
Show NumOfDiskSnapshots Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy showsPrec ∷ Int → NumOfDiskSnapshots → ShowS # show ∷ NumOfDiskSnapshots → String # showList ∷ [NumOfDiskSnapshots] → ShowS # | |
Eq NumOfDiskSnapshots Source # | |
type Rep NumOfDiskSnapshots Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy type Rep NumOfDiskSnapshots = D1 ('MetaData "NumOfDiskSnapshots" "Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy" "ouroboros-consensus-0.21.0.0-inplace" 'False) (C1 ('MetaCons "DefaultNumOfDiskSnapshots" 'PrefixI 'False) (U1 ∷ Type → Type) :+: C1 ('MetaCons "RequestedNumOfDiskSnapshots" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Word))) |
data SnapshotInterval Source #
Length of time, requested by the user, that has to pass after which a snapshot is taken. It can be:
- either explicitly provided by user in seconds
- or default value can be requested - the specific DiskPolicy determines
what that is exactly, see
mkDiskPolicy
as an example
Instances
Generic SnapshotInterval Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy type Rep SnapshotInterval ∷ Type → Type # from ∷ SnapshotInterval → Rep SnapshotInterval x # to ∷ Rep SnapshotInterval x → SnapshotInterval # | |
Show SnapshotInterval Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy showsPrec ∷ Int → SnapshotInterval → ShowS # show ∷ SnapshotInterval → String # showList ∷ [SnapshotInterval] → ShowS # | |
Eq SnapshotInterval Source # | |
type Rep SnapshotInterval Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy type Rep SnapshotInterval = D1 ('MetaData "SnapshotInterval" "Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy" "ouroboros-consensus-0.21.0.0-inplace" 'False) (C1 ('MetaCons "DefaultSnapshotInterval" 'PrefixI 'False) (U1 ∷ Type → Type) :+: C1 ('MetaCons "RequestedSnapshotInterval" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 DiffTime))) |
data TimeSinceLast time Source #
Instances
Functor TimeSinceLast Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy fmap ∷ (a → b) → TimeSinceLast a → TimeSinceLast b # (<$) ∷ a → TimeSinceLast b → TimeSinceLast a # | |
Show time ⇒ Show (TimeSinceLast time) Source # | |
Defined in Ouroboros.Consensus.Storage.LedgerDB.DiskPolicy showsPrec ∷ Int → TimeSinceLast time → ShowS # show ∷ TimeSinceLast time → String # showList ∷ [TimeSinceLast time] → ShowS # |
defaultDiskPolicyArgs ∷ DiskPolicyArgs Source #
Default on-disk policy arguments suitable to use with cardano-node