Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data P2P
-
data
InitializationTracer
ntnAddr ntcAddr
- = RunServer ( NonEmpty ntnAddr)
- | RunLocalServer ntcAddr
- | UsingSystemdSocket ntcAddr
- | CreateSystemdSocketForSnocketPath ntcAddr
- | CreatedLocalSocket ntcAddr
- | ConfiguringLocalSocket ntcAddr FileDescriptor
- | ListeningLocalSocket ntcAddr FileDescriptor
- | LocalSocketUp ntcAddr FileDescriptor
- | CreatingServerSocket ntnAddr
- | ConfiguringServerSocket ntnAddr
- | ListeningServerSocket ntnAddr
- | ServerSocketUp ntnAddr
- | UnsupportedLocalSystemdSocket ntnAddr
- | UnsupportedReadySocketCase
- | DiffusionErrored SomeException
-
data
Tracers
ntnAddr ntnVersion ntcAddr ntcVersion m =
Tracers
{
- dtMuxTracer :: Tracer m ( WithMuxBearer ( ConnectionId ntnAddr) MuxTrace )
- dtHandshakeTracer :: Tracer m ( HandshakeTr ntnAddr ntnVersion)
- dtLocalMuxTracer :: Tracer m ( WithMuxBearer ( ConnectionId ntcAddr) MuxTrace )
- dtLocalHandshakeTracer :: Tracer m ( HandshakeTr ntcAddr ntcVersion)
- dtDiffusionInitializationTracer :: Tracer m ( InitializationTracer ntnAddr ntcAddr)
- dtLedgerPeersTracer :: Tracer m TraceLedgerPeers
- nullTracers :: Applicative m => Tracers ntnAddr ntnVersion ntcAddr ntcVersion m
- data ExtraTracers (p2p :: P2P ) where
- data Failure ntnAddr
-
data
Arguments
ntnFd ntnAddr ntcFd ntcAddr =
Arguments
{
- daIPv4Address :: Maybe ( Either ntnFd ntnAddr)
- daIPv6Address :: Maybe ( Either ntnFd ntnAddr)
- daLocalAddress :: Maybe ( Either ntcFd ntcAddr)
- daAcceptedConnectionsLimit :: AcceptedConnectionsLimit
- daMode :: DiffusionMode
-
data
ExtraArguments
(p2p ::
P2P
) m
where
- P2PArguments :: ArgumentsExtra m -> ExtraArguments ' P2P m
- NonP2PArguments :: ArgumentsExtra -> ExtraArguments ' NonP2P m
-
data
Applications
ntnAddr ntnVersion ntnVersionData ntcAddr ntcVersion ntcVersionData m =
Applications
{
- daApplicationInitiatorMode :: Versions ntnVersion ntnVersionData ( OuroborosBundle InitiatorMode ntnAddr ByteString m () Void )
- daApplicationInitiatorResponderMode :: Versions ntnVersion ntnVersionData ( OuroborosBundle InitiatorResponderMode ntnAddr ByteString m () ())
- daLocalResponderApplication :: Versions ntcVersion ntcVersionData ( OuroborosApplication ResponderMode ntcAddr ByteString m Void ())
- daLedgerPeersCtx :: LedgerPeersConsensusInterface m
-
data
ExtraApplications
(p2p ::
P2P
) ntnAddr m
where
- P2PApplications :: ApplicationsExtra ntnAddr m -> ExtraApplications ' P2P ntnAddr m
- NonP2PApplications :: ApplicationsExtra -> ExtraApplications ' NonP2P ntnAddr m
- run :: forall (p2p :: P2P ). Tracers RemoteAddress NodeToNodeVersion LocalAddress NodeToClientVersion IO -> ExtraTracers p2p -> Arguments Socket RemoteAddress LocalSocket LocalAddress -> ExtraArguments p2p IO -> Applications RemoteAddress NodeToNodeVersion NodeToNodeVersionData LocalAddress NodeToClientVersion NodeToClientVersionData IO -> ExtraApplications p2p RemoteAddress IO -> IO ()
- type AbstractTransitionTrace peerAddr = TransitionTrace' peerAddr AbstractState
Common API
data InitializationTracer ntnAddr ntcAddr Source #
RunServer ( NonEmpty ntnAddr) | |
RunLocalServer ntcAddr | |
UsingSystemdSocket ntcAddr | |
CreateSystemdSocketForSnocketPath ntcAddr | |
CreatedLocalSocket ntcAddr | |
ConfiguringLocalSocket ntcAddr FileDescriptor | |
ListeningLocalSocket ntcAddr FileDescriptor | |
LocalSocketUp ntcAddr FileDescriptor | |
CreatingServerSocket ntnAddr | |
ConfiguringServerSocket ntnAddr | |
ListeningServerSocket ntnAddr | |
ServerSocketUp ntnAddr | |
UnsupportedLocalSystemdSocket ntnAddr | |
UnsupportedReadySocketCase | |
DiffusionErrored SomeException |
Instances
( Show ntnAddr, Show ntcAddr) => Show ( InitializationTracer ntnAddr ntcAddr) Source # | |
Defined in Ouroboros.Network.Diffusion.Common |
data Tracers ntnAddr ntnVersion ntcAddr ntcVersion m Source #
Common DiffusionTracers interface between P2P and NonP2P
Tracers | |
|
nullTracers :: Applicative m => Tracers ntnAddr ntnVersion ntcAddr ntcVersion m Source #
data ExtraTracers (p2p :: P2P ) where Source #
Tracers which depend on p2p mode.
Instances
Eq ntnAddr => Eq ( Failure ntnAddr) Source # | |
Show ntnAddr => Show ( Failure ntnAddr) Source # | |
( Typeable ntnAddr, Show ntnAddr) => Exception ( Failure ntnAddr) Source # | |
Defined in Ouroboros.Network.Diffusion.Common toException :: Failure ntnAddr -> SomeException Source # fromException :: SomeException -> Maybe ( Failure ntnAddr) Source # displayException :: Failure ntnAddr -> String Source # |
data Arguments ntnFd ntnAddr ntcFd ntcAddr Source #
Common DiffusionArguments interface between P2P and NonP2P
Arguments | |
|
data ExtraArguments (p2p :: P2P ) m where Source #
Diffusion arguments which depend on p2p mode.
P2PArguments :: ArgumentsExtra m -> ExtraArguments ' P2P m | |
NonP2PArguments :: ArgumentsExtra -> ExtraArguments ' NonP2P m |
data Applications ntnAddr ntnVersion ntnVersionData ntcAddr ntcVersion ntcVersionData m Source #
Common DiffusionArguments interface between P2P and NonP2P
TODO: we need initiator only mode for blockchain explorer or a similar application, there's no reason why one should run a node-to-node server for it.
Applications | |
|
data ExtraApplications (p2p :: P2P ) ntnAddr m where Source #
Application data which depend on p2p mode.
P2PApplications :: ApplicationsExtra ntnAddr m -> ExtraApplications ' P2P ntnAddr m | |
NonP2PApplications :: ApplicationsExtra -> ExtraApplications ' NonP2P ntnAddr m |
Run data diffusion
run :: forall (p2p :: P2P ). Tracers RemoteAddress NodeToNodeVersion LocalAddress NodeToClientVersion IO -> ExtraTracers p2p -> Arguments Socket RemoteAddress LocalSocket LocalAddress -> ExtraArguments p2p IO -> Applications RemoteAddress NodeToNodeVersion NodeToNodeVersionData LocalAddress NodeToClientVersion NodeToClientVersionData IO -> ExtraApplications p2p RemoteAddress IO -> IO () Source #
Re-exports
type AbstractTransitionTrace peerAddr = TransitionTrace' peerAddr AbstractState Source #