From 18804d0532126ee58f3e4a7e3d86eb8d5cfa4d4b Mon Sep 17 00:00:00 2001 From: mjalalzai <33738574+MForensic@users.noreply.github.com> Date: Tue, 21 Mar 2023 00:00:53 -0700 Subject: [PATCH] timeout --- carnot/spec.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/carnot/spec.md b/carnot/spec.md index b23b15d..c819133 100644 --- a/carnot/spec.md +++ b/carnot/spec.md @@ -133,6 +133,7 @@ Participants in the protocol are expected to mainting the following data in addi CURRENT_VIEW: View LOCAL_HIGH_QC: Qc LATEST_COMMITTED_VIEW: View +HIGH_COMMITTED_QC:Qc # This is not needed for consensus but actually helps a lot for any node fallen behind to catchup. COLLECTION: Q? ``` @@ -364,7 +365,16 @@ Func receive(newView) { ### Timeout ```python def timeout(): - raise NotImplementedError + if (member_of_internal_com() AND not member_of_root()) OR member_of_leaf: + let timeoutMsg = create_newView(CURRENT_VIEW,HIGH_QC,HIGH_COMMITTED_QC, TIMEOUT_QC) + send(timeoutMsg, parent_committee()) + + + if member_of_root(): + let timeoutMsg = create_newView(CURRENT_VIEW,HIGH_QC,HIGH_COMMITTED_QC, TIMEOUT_QC) + send(timeoutMsg,root_committee()) # Need to be discussed. It can only be sent to the next leader but since the RB needs agreement to generate the seed for the leader+overlay, therefore newView is sent to the root_committee(). + + ```