From 16cc5b7ec826a83ecd397158ae5db3601b6dbe4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Henry?= Date: Wed, 8 Nov 2017 13:53:23 +0100 Subject: [PATCH] Shell: add more timeout in the prevalidator --- src/node/shell/prevalidator.ml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/node/shell/prevalidator.ml b/src/node/shell/prevalidator.ml index f37ce025c..ab159f1ae 100644 --- a/src/node/shell/prevalidator.ml +++ b/src/node/shell/prevalidator.ml @@ -243,6 +243,7 @@ let create net_db = ops in let fetch op = Distributed_db.Operation.fetch + ~timeout:10. (* TODO allow to adjust the constant ... *) net_db ~peer:gid op () >>= fun _op -> push_to_worker (`Handle op) ; Lwt.return_unit @@ -252,7 +253,10 @@ let create net_db = unknown_ops ; List.iter (fun op -> Lwt.ignore_result - (Distributed_db.Operation.fetch net_db ~peer:gid op ())) + (Distributed_db.Operation.fetch + (* TODO allow to adjust the constant ... *) + ~timeout:10. + net_db ~peer:gid op ())) known_ops ; Lwt.return_unit | `Handle op ->