Shell: preliminary work for ack_cfg exchange
This commit is contained in:
parent
1f6302bf36
commit
a8e607a5a9
@ -72,8 +72,8 @@ let peer_metadata_cfg : _ P2p.peer_meta_config = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let connection_metadata_cfg : _ P2p.conn_meta_config = {
|
let connection_metadata_cfg : _ P2p.conn_meta_config = {
|
||||||
conn_meta_encoding = Peer_metadata.encoding ;
|
conn_meta_encoding = Connection_metadata.encoding ;
|
||||||
conn_meta_value = fun _ -> () ;
|
conn_meta_value = fun _ -> { disable_mempool = false ; private_node = false} ;
|
||||||
}
|
}
|
||||||
|
|
||||||
let init_p2p p2p_params =
|
let init_p2p p2p_params =
|
||||||
|
@ -7,5 +7,20 @@
|
|||||||
(* *)
|
(* *)
|
||||||
(**************************************************************************)
|
(**************************************************************************)
|
||||||
|
|
||||||
type t = unit
|
type t = {
|
||||||
let encoding = Data_encoding.empty
|
disable_mempool : bool ;
|
||||||
|
private_node : bool ;
|
||||||
|
}
|
||||||
|
|
||||||
|
let encoding =
|
||||||
|
let open Data_encoding in
|
||||||
|
(conv
|
||||||
|
(fun { disable_mempool ; private_node } ->
|
||||||
|
disable_mempool , private_node)
|
||||||
|
(fun (disable_mempool , private_node) ->
|
||||||
|
{ disable_mempool ; private_node }))
|
||||||
|
(obj2
|
||||||
|
(req "disable_mempool" bool)
|
||||||
|
(req "private_node" bool))
|
||||||
|
|
||||||
|
let pp _ppf _ = ()
|
||||||
|
@ -9,5 +9,10 @@
|
|||||||
|
|
||||||
(** All the metadata associated to a running connection. *)
|
(** All the metadata associated to a running connection. *)
|
||||||
|
|
||||||
type t = unit (* TODO *)
|
type t = {
|
||||||
|
disable_mempool : bool ;
|
||||||
|
private_node : bool ;
|
||||||
|
}
|
||||||
|
|
||||||
val encoding: t Data_encoding.t
|
val encoding: t Data_encoding.t
|
||||||
|
val pp: Format.formatter -> t -> unit
|
||||||
|
Loading…
Reference in New Issue
Block a user