From 17acde27adc5bd06a4aaef5782d1e20af4280166 Mon Sep 17 00:00:00 2001 From: Edward Wertz <123979964+edward-swirldslabs@users.noreply.github.com> Date: Thu, 14 Dec 2023 09:32:59 -0600 Subject: [PATCH] HIP-830 Updating Description for Accuracy (#842) Signed-off-by: Edward Wertz --- HIP/hip-830.md | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/HIP/hip-830.md b/HIP/hip-830.md index 0df221f7f..8a8019230 100644 --- a/HIP/hip-830.md +++ b/HIP/hip-830.md @@ -9,7 +9,7 @@ status: Council Review last-call-date-time: 2023-12-04T07:00:00Z created: 2023-10-25 discussions-to: https://github.com/hashgraph/hedera-improvement-proposal/discussions/827 -updated: 2023-12-06 +updated: 2023-12-13 --- ## Abstract @@ -20,7 +20,7 @@ This HIP proposes several changes to the event serialization format. to consensus at the time the event was created. This value is used to determine if the event is ancient or not. It is also used to look up the correct consensus roster for validating the event's signature. 2. Represent references to parent events as `EventDescriptors`. EventDescriptors combine the existing data about each - parent (hash, creator, generation) and the birthRound into a single data structure. + parent and the birthRound into a single data structure: EventDescriptor(hash, creator, generation, birthRound). 3. Allow for multiple other parents. 4. Reduce `EventUnhashedData` to just the event's signature. @@ -41,14 +41,20 @@ An EventDescriptor is a 4-tuple: 3. `generation` - The generation of the event. (1 + the max of the event's parents' generations) 4. `birthRound` - 1 + the latest round to reach consensus on the node when the event was created. -The EventDescriptor is the minimal amount of information needed to identify an event: its hash, which node created -it, and generation and birthRound to determine when an event has become ancient. This encapsulation of metadata -simplifies the event structure. +The EventDescriptor is the information that an event must store about each parent event, for use when the parent event +is not in memory. + +The parent EventDescriptors are used in the following ways: + +* To determine the generation of this event +* To determine which events are its parents +* To determine whether a given parent is needed before this one can be added to the hashgraph +* To determine whether to create an edge in the hashgraph connecting it to each parent ### Multiple Other Parents Allowing events to have multiple other parents will open up new algorithms for choosing parents from other nodes. -This is expected to help lower the average time it takes an event to reach consensus. +This is expected to help lower the average time it takes an event to reach consensus. ### Signature As Unhashed Metadata (Gossip Only) @@ -220,8 +226,8 @@ have not changed may be omitted. ### Event Serialization Formats After HIP-830 -The `EventDescriptor` is a new data structure to encapsulate parent event metadata. The definition of the serialized -data structure is provided here before it is used in the `EventHashedData` object. +The `EventDescriptor` is a new data structure to encapsulate parent event metadata. The definition of the serialized +data structure is provided here before it is used in the `EventHashedData` object. ``` +------------------------------------------------------------------------+ @@ -241,7 +247,7 @@ data structure is provided here before it is used in the `EventHashedData` objec +------------+---------+---------------------------------+---------------+ ``` -The `EventHashedData` contains all the data that is hashed to create the signature in the `GossipEvent`. +The `EventHashedData` contains all the data that is hashed to create the signature in the `GossipEvent`. ``` +--------------------------------------------------------------------------------------------------+ @@ -267,8 +273,8 @@ The `EventHashedData` contains all the data that is hashed to create the signatu +------------+-----------------------+---------------------------------------------+---------------+ ``` -The `GossipEvent` object contains the `EventHashedData` and the signature of the event. After the event is Gossiped, -the signature is checked against the consensus roster that was effective for the round when the event was created. +The `GossipEvent` object contains the `EventHashedData` and the signature of the event. After the event is Gossiped, +the signature is checked against the consensus roster that was effective for the round when the event was created. ``` +--------------------------------------------------------------------------------------------------+ @@ -286,8 +292,8 @@ the signature is checked against the consensus roster that was effective for the +------------+-----------------------+---------------------------------------------+---------------+ ``` -The `DetailedConsensusEvent` contains the `EventHashedData`, the signature of the event, and the `ConsensusData` -that was generated when the event came to consensus. +The `DetailedConsensusEvent` contains the `EventHashedData`, the signature of the event, and the `ConsensusData` +that was generated when the event came to consensus. ``` +--------------------------------------------------------------------------------------------------+