ouroboros-consensus
Safe HaskellNone
LanguageHaskell2010

Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

Synopsis

Documentation

class NoThunks (Resources m backend) ⇒ Backend (m ∷ TypeType) backend blk where Source #

Operations needed to open and operate a LedgerDB V2

Associated Types

data Args (m ∷ TypeType) backend Source #

The Arguments that will be used initially to create the Resources.

data Resources (m ∷ TypeType) backend Source #

The Resources that will be stored in the LedgerDB environment and given to the handle operations.

data Trace backend Source #

A trace dependent on the particular backend.

Methods

mkResourcesProxy blk → Tracer m LedgerDBV2TraceArgs m backend → SomeHasFS m → WithTempRegistry fState m (Resources m backend) Source #

Transform Args into Resources, with some context made up of LedgerDbArgs.

releaseResourcesProxy blk → Resources m backend → m () Source #

Release the acquired resources.

createAndPopulateStateRefFromGenesisTracer m LedgerDBV2TraceResources m backend → ExtLedgerState blk ValuesMK → m (StateRef m ExtLedgerState blk) Source #

Create a new handle from the given Genesis state.

openStateRefFromSnapshotTracer m LedgerDBV2TraceCodecConfig blk → SomeHasFS m → Resources m backend → DiskSnapshotExceptT (SnapshotFailure blk) m (StateRef m ExtLedgerState blk, RealPoint blk) Source #

Create a new handle from a snapshot.

snapshotManagerProxy blk → Resources m backend → CodecConfig blk → Tracer m (TraceSnapshotEvent blk) → SomeHasFS m → SnapshotManager m blk (StateRef m ExtLedgerState blk) Source #

Instantiate the SnapshotManager for this backend.

data family Args (m ∷ TypeType) backend Source #

The Arguments that will be used initially to create the Resources.

Instances

Instances details
data Args m Mem Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data Args m Mem = InMemArgs

data family Trace backend Source #

A trace dependent on the particular backend.

Instances

Instances details
Show (Trace Mem) Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

Methods

showsPrecIntTrace MemShowS #

showTrace MemString #

showList ∷ [Trace Mem] → ShowS #

newtype Trace Mem Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

newtype Trace Mem = NoTrace Void

data Mem Source #

Instances

Instances details
(IOLike m, LedgerDbSerialiseConstraints blk, LedgerSupportsProtocol blk, CanUpgradeLedgerTables LedgerState blk) ⇒ Backend m Mem blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

Associated Types

data Args m Mem 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data Args m Mem = InMemArgs
newtype Resources m Mem 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

newtype Trace Mem 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

newtype Trace Mem = NoTrace Void
IOLike m ⇒ StreamingBackend m Mem l blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

Associated Types

data YieldArgs m Mem l blk 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data SinkArgs m Mem l blk 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data SinkArgs m Mem l blk = SinkInMemory Int (TxIn blk → Encoding) (TxOut blk → Encoding) (SomeHasFS m) DiskSnapshot

Methods

yieldProxy MemYieldArgs m Mem l blk → Yield m l blk Source #

releaseYieldArgsYieldArgs m Mem l blk → m () Source #

sinkProxy MemSinkArgs m Mem l blk → Sink m l blk Source #

releaseSinkArgsSinkArgs m Mem l blk → m () Source #

Show (Trace Mem) Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

Methods

showsPrecIntTrace MemShowS #

showTrace MemString #

showList ∷ [Trace Mem] → ShowS #

NoThunks (Resources m Mem) Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

newtype Trace Mem Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

newtype Trace Mem = NoTrace Void
data SinkArgs m Mem l blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data SinkArgs m Mem l blk = SinkInMemory Int (TxIn blk → Encoding) (TxOut blk → Encoding) (SomeHasFS m) DiskSnapshot
data YieldArgs m Mem l blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data Args m Mem Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data Args m Mem = InMemArgs
newtype Resources m Mem Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data family YieldArgs (m ∷ TypeType) backend (l ∷ Type → (TypeTypeType) → Type) blk Source #

Instances

Instances details
data YieldArgs m Mem l blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data family SinkArgs (m ∷ TypeType) backend (l ∷ Type → (TypeTypeType) → Type) blk Source #

Instances

Instances details
data SinkArgs m Mem l blk Source # 
Instance details

Defined in Ouroboros.Consensus.Storage.LedgerDB.V2.InMemory

data SinkArgs m Mem l blk = SinkInMemory Int (TxIn blk → Encoding) (TxOut blk → Encoding) (SomeHasFS m) DiskSnapshot

mkInMemoryArgs ∷ ∀ (m ∷ TypeType) blk a. (IOLike m, LedgerDbSerialiseConstraints blk, LedgerSupportsProtocol blk, CanUpgradeLedgerTables LedgerState blk) ⇒ a → (LedgerDbBackendArgs m blk, a) Source #

Create arguments for initializing the LedgerDB using the InMemory backend.