package tezos-p2p-services

  1. Overview
  2. Docs

The configurable constants used by the p2p layer as maximum, with their encoding and default values.

type t = {
  1. connection_timeout : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

    Maximum time allowed to the establishment of a connection.

    *)
  2. authentication_timeout : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

    Delay granted to a peer to perform authentication.

    *)
  3. greylist_timeout : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

    GC delay for the greylists tables.

    *)
  4. maintenance_idle_time : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

    How long to wait at most before running a maintenance loop.

    *)
  5. min_connections : int;
    (*

    Strict minimum number of connections (triggers an urgent maintenance)

    *)
  6. expected_connections : int;
    (*

    Targeted number of connections to reach when bootstrapping / maintaining

    *)
  7. max_connections : int;
    (*

    Maximum number of connections (exceeding peers are disconnected)

    *)
  8. backlog : int;
    (*

    Argument of Lwt_unix.accept.

    *)
  9. max_incoming_connections : int;
    (*

    Maximum not-yet-authenticated incoming connections.

    *)
  10. max_download_speed : int option;
    (*

    Hard-limit in the number of bytes received per second.

    *)
  11. max_upload_speed : int option;
    (*

    Hard-limit in the number of bytes sent per second.

    *)
  12. read_buffer_size : int;
    (*

    Size in bytes of the buffer passed to Lwt_unix.read.

    *)
  13. read_queue_size : int option;
  14. write_queue_size : int option;
  15. incoming_app_message_queue_size : int option;
  16. incoming_message_queue_size : int option;
  17. outgoing_message_queue_size : int option;
    (*

    Various bounds for internal queues.

    *)
  18. max_known_peer_ids : (int * int) option;
  19. max_known_points : (int * int) option;
    (*

    Optional limitation of internal hashtables (max, target)

    *)
  20. peer_greylist_size : int;
    (*

    The number of peer_ids kept in the peer_id greylist.

    *)
  21. ip_greylist_size_in_kilobytes : int;
    (*

    The size of the IP address greylist in kilobytes.

    *)
  22. ip_greylist_cleanup_delay : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

    The time an IP address is kept in the greylist.

    *)
  23. swap_linger : Tezos_base.TzPervasives.Time.System.Span.t;
    (*

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

    *)
  24. binary_chunks_size : int option;
    (*

    Size (in bytes) of binary blocks that are sent to other peers. Default value is 64 kB. Max value is 64kB.

    *)
}

Network capacities

val default : t
val encoding : t Tezos_base.TzPervasives.Data_encoding.t
OCaml

Innovation. Community. Security.