ouroboros-network
Safe HaskellNone
LanguageHaskell2010

Ouroboros.Network.Diffusion

Synopsis

Common API

data P2P Source #

Promoted data types.

Constructors

P2P 
NonP2P 

data DiffusionTracer ntnAddr ntcAddr Source #

The DiffusionTracer logs

  • diffusion initialisation messages
  • terminal errors thrown by diffusion

Instances

Instances details
(Show ntcAddr, Show ntnAddr) => Show (DiffusionTracer ntnAddr ntcAddr) Source # 
Instance details

Defined in Ouroboros.Network.Diffusion.Common

Methods

showsPrec :: Int -> DiffusionTracer ntnAddr ntcAddr -> ShowS #

show :: DiffusionTracer ntnAddr ntcAddr -> String #

showList :: [DiffusionTracer ntnAddr ntcAddr] -> ShowS #

data Tracers ntnAddr ntnVersion ntcAddr ntcVersion (m :: Type -> Type) Source #

Common DiffusionTracers interface between P2P and NonP2P

Constructors

Tracers 

Fields

nullTracers :: forall (m :: Type -> Type) ntnAddr ntnVersion ntcAddr ntcVersion. Applicative m => Tracers ntnAddr ntnVersion ntcAddr ntcVersion m Source #

data Failure where Source #

Constructors

UnsupportedReadySocket :: Failure 
UnexpectedIPv4Address :: forall ntnAddr. (Show ntnAddr, Typeable ntnAddr) => ntnAddr -> Failure 
UnexpectedIPv6Address :: forall ntnAddr. (Show ntnAddr, Typeable ntnAddr) => ntnAddr -> Failure 
NoSocket :: Failure 
DiffusionError :: SomeException -> Failure 

data Arguments (m :: Type -> Type) ntnFd ntnAddr ntcFd ntcAddr Source #

Common DiffusionArguments interface between P2P and NonP2P

Constructors

Arguments 

Fields

data ExtraArguments (p2p :: P2P) (m :: Type -> Type) where Source #

Diffusion arguments which depend on p2p mode.

Constructors

P2PArguments :: forall (m :: Type -> Type). ArgumentsExtra m -> ExtraArguments 'P2P m 
NonP2PArguments :: forall (m :: Type -> Type). ArgumentsExtra -> ExtraArguments 'NonP2P m 

data Applications ntnAddr ntnVersion ntnVersionData ntcAddr ntcVersion ntcVersionData (m :: Type -> Type) a Source #

Versioned mini-protocol bundles run on a negotiated connection.

Constructors

Applications 

Fields

data ExtraApplications (p2p :: P2P) ntnAddr (m :: Type -> Type) a where Source #

Application data which depend on p2p mode.

Constructors

P2PApplications :: forall ntnAddr (m :: Type -> Type) a. ApplicationsExtra ntnAddr m a -> ExtraApplications 'P2P ntnAddr m a 
NonP2PApplications :: forall ntnAddr (m :: Type -> Type) a. ApplicationsExtra -> ExtraApplications 'NonP2P ntnAddr m a 

Run data diffusion

Re-exports

data PublicPeerSelectionState peeraddr Source #

Public PeerSelectionState that can be accessed by Peer Sharing mechanisms without any problem.

This data type should not expose too much information and keep only essential data needed for computing the peer sharing request result