Safe Haskell | None |
---|---|
Language | Haskell2010 |
Ouroboros.Consensus.MiniProtocol.ChainSync.Server
Contents
Synopsis
- data Tip b
- chainSyncBlockServerFollower ∷ ChainDB m blk → ResourceRegistry m → m (Follower m blk (WithPoint blk (Serialised blk)))
- chainSyncBlocksServer ∷ ∀ m blk. (IOLike m, HasHeader (Header blk)) ⇒ Tracer m (TraceChainSyncServerEvent blk) → ChainDB m blk → Follower m blk (WithPoint blk (Serialised blk)) → ChainSyncServer (Serialised blk) (Point blk) (Tip blk) m ()
- chainSyncHeaderServerFollower ∷ ChainDB m blk → ChainType → ResourceRegistry m → m (Follower m blk (WithPoint blk (SerialisedHeader blk)))
- chainSyncHeadersServer ∷ ∀ m blk. (IOLike m, HasHeader (Header blk)) ⇒ Tracer m (TraceChainSyncServerEvent blk) → ChainDB m blk → Follower m blk (WithPoint blk (SerialisedHeader blk)) → ChainSyncServer (SerialisedHeader blk) (Point blk) (Tip blk) m ()
- data BlockingType
- data TraceChainSyncServerEvent blk = TraceChainSyncServerUpdate (Tip blk) (ChainUpdate blk (Point blk)) BlockingType Enclosing
Documentation
Used in chain-sync protocol to advertise the tip of the server's chain.
Instances
StandardHash b ⇒ Eq (Tip b) | |
StandardHash b ⇒ Show (Tip b) | |
Generic (Tip b) | |
StandardHash b ⇒ NoThunks (Tip b) | |
Condense (HeaderHash b) ⇒ Condense (Tip b) Source # | |
ShowProxy b ⇒ ShowProxy (Tip b ∷ Type) | |
type Rep (Tip b) | |
Defined in Ouroboros.Network.Block type Rep (Tip b) = D1 ('MetaData "Tip" "Ouroboros.Network.Block" "ouroboros-network-api-0.1.0.0-inplace" 'False) (C1 ('MetaCons "TipGenesis" 'PrefixI 'False) (U1 ∷ Type → Type) :+: C1 ('MetaCons "Tip" 'PrefixI 'False) (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SlotNo) :*: (S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 (HeaderHash b)) :*: S1 ('MetaSel ('Nothing ∷ Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 BlockNo)))) |
chainSyncBlockServerFollower ∷ ChainDB m blk → ResourceRegistry m → m (Follower m blk (WithPoint blk (Serialised blk))) Source #
chainSyncBlocksServer ∷ ∀ m blk. (IOLike m, HasHeader (Header blk)) ⇒ Tracer m (TraceChainSyncServerEvent blk) → ChainDB m blk → Follower m blk (WithPoint blk (Serialised blk)) → ChainSyncServer (Serialised blk) (Point blk) (Tip blk) m () Source #
Chain Sync Server for blocks for a given a ChainDB
.
The local node-to-client protocol uses the chain sync mini-protocol with chains of full blocks (rather than a header / body split).
chainSyncHeaderServerFollower ∷ ChainDB m blk → ChainType → ResourceRegistry m → m (Follower m blk (WithPoint blk (SerialisedHeader blk))) Source #
chainSyncHeadersServer ∷ ∀ m blk. (IOLike m, HasHeader (Header blk)) ⇒ Tracer m (TraceChainSyncServerEvent blk) → ChainDB m blk → Follower m blk (WithPoint blk (SerialisedHeader blk)) → ChainSyncServer (SerialisedHeader blk) (Point blk) (Tip blk) m () Source #
Chain Sync Server for block headers for a given a ChainDB
.
The node-to-node protocol uses the chain sync mini-protocol with chain headers (and fetches blocks separately with the block fetch mini-protocol).
Trace events
data BlockingType Source #
Whether reading a ChainSync server update instruction was blocking or non-blocking.
Constructors
Blocking | |
NonBlocking |
Instances
Eq BlockingType Source # | |
Defined in Ouroboros.Consensus.MiniProtocol.ChainSync.Server Methods (==) ∷ BlockingType → BlockingType → Bool Source # (/=) ∷ BlockingType → BlockingType → Bool Source # | |
Ord BlockingType Source # | |
Defined in Ouroboros.Consensus.MiniProtocol.ChainSync.Server Methods compare ∷ BlockingType → BlockingType → Ordering Source # (<) ∷ BlockingType → BlockingType → Bool Source # (<=) ∷ BlockingType → BlockingType → Bool Source # (>) ∷ BlockingType → BlockingType → Bool Source # (>=) ∷ BlockingType → BlockingType → Bool Source # | |
Show BlockingType Source # | |
data TraceChainSyncServerEvent blk Source #
Events traced by the Chain Sync Server.
Constructors
TraceChainSyncServerUpdate | Send a |
Fields
|
Instances
StandardHash blk ⇒ Eq (TraceChainSyncServerEvent blk) Source # | |
Defined in Ouroboros.Consensus.MiniProtocol.ChainSync.Server Methods (==) ∷ TraceChainSyncServerEvent blk → TraceChainSyncServerEvent blk → Bool Source # (/=) ∷ TraceChainSyncServerEvent blk → TraceChainSyncServerEvent blk → Bool Source # | |
StandardHash blk ⇒ Show (TraceChainSyncServerEvent blk) Source # | |