tezos-p2p

Tezos: library for a pool of P2P connections
Library tezos-p2p
type ('msg, 'peer, 'conn) config = {
swap_linger : Tezos_base.TzPervasives.Time.System.Span.t;(*

Peer swapping does not occur more than once during a timespan of swap_linger.

*)
pool : ( 'msg, 'peer, 'conn ) P2p_pool.t;
log : Tezos_base.TzPervasives.P2p_connection.P2p_event.t -> unit;
connect : Tezos_base.TzPervasives.P2p_point.Id.t -> ( 'msg, 'peer, 'conn ) P2p_conn.t Tezos_base.TzPervasives.tzresult Lwt.t;
mutable latest_accepted_swap : Tezos_base.TzPervasives.Time.System.t;
mutable latest_successful_swap : Tezos_base.TzPervasives.Time.System.t;
}

The config type contains "global" values and configuration option used by the default answerer, known when setting up the connection handler in P2p

val create_default : ( 'msg, 'peer, 'conn ) config -> 'msg P2p_answerer.t
val create_private : unit -> 'msg P2p_answerer.t