Achieving reliable consensus. (#60)

* Remove considering stage when voting and considering lcl.

* Stage sync , lcl sync  and candidate set changes.

* Implemented ledger close time resolution and fixed ledger retrieval issues.

* Code cleanup and added more comments on reliability changes.

* Added further comments and  clenup.
This commit is contained in:
Asanka Indrajith
2019-11-25 07:40:22 -05:00
committed by GitHub
parent 684a6bb18f
commit bebdace519
10 changed files with 267 additions and 137 deletions

View File

@@ -166,6 +166,9 @@ const p2p::history_response create_history_response_from_msg(const History_Respo
if (msg.hist_ledgers())
hr.hist_ledgers = flatbuf_historyledgermap_to_historyledgermap(msg.hist_ledgers());
if (msg.error())
hr.error = (p2p::LEDGER_RESPONSE_ERROR)msg.error();
return hr;
}
@@ -318,7 +321,8 @@ void create_msg_from_history_response(flatbuffers::FlatBufferBuilder &container_
flatbuffers::Offset<History_Response_Message> hrmsg =
CreateHistory_Response_Message(
builder,
historyledgermap_to_flatbuf_historyledgermap(builder, hr.hist_ledgers));
historyledgermap_to_flatbuf_historyledgermap(builder, hr.hist_ledgers),
(Ledger_Response_Error)hr.error);
flatbuffers::Offset<Content> message = CreateContent(builder, Message_History_Response_Message, hrmsg.Union());
builder.Finish(message); // Finished building message content to get serialised content.