From 61e08b7d141b2217d684133ecae823722f1c0bf0 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Raynaud Date: Thu, 22 May 2025 16:38:47 +0200 Subject: [PATCH 1/3] Fix typos in n2c local message notification --- CIP-0137/README.md | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/CIP-0137/README.md b/CIP-0137/README.md index 7e3a698ac5..dc21214af2 100644 --- a/CIP-0137/README.md +++ b/CIP-0137/README.md @@ -444,7 +444,6 @@ stateDiagram-v2 | StBusy | MsgRejectMessage | reason | StIdle | | StIdle | MsgDone | | StDone | - ##### CDDL Encoding Specification ```cddl @@ -500,10 +499,10 @@ The protocol follows a simple request-response pattern: #### State machine -| Agency | | -| ----------------- | -------------- | -| Client has Agency | StIdle | -| Server has Agency | StBusy, StDone | +| Agency | | +| ----------------- | ---------------------------------------- | +| Client has Agency | StIdle | +| Server has Agency | StBusyNonBlocking,StBusyBlocking, StDone | ```mermaid stateDiagram-v2 @@ -556,7 +555,7 @@ localMessageNotificationMessage / msgClientDone / msgServerDone -msgRequestMessages = [0, isBlocking, ackedMessages] +msgRequestMessages = [0, isBlocking] msgReplyMessagesNonBlocking = [1, messages, hasMore] msgReplyMessagesBlocking = [2, messages] msgClientDone = [3] @@ -579,7 +578,6 @@ message = [ hasMore = false / true isBlocking = false / true -ackedMessages = * messageId messages = [* message] ``` @@ -687,15 +685,15 @@ the KES key. - [x] Write a "formal" specification of the protocols along with vectors/conformance checker for protocol's structure and state machine logic. - [x] Write an architecture document extending this CIP with more technical details about the implementation. - - See [here](https://github.com/IntersectMBO/ouroboros-network/wiki/Decentralized-Message-Queue-(DMQ)-Implementation-Overview) + - See [here]() - [x] Validate protocol behaviour with all relevant parties (Network and Node teams). - [x] Make the current Cardano Network Diffusion Layer general and reusable so a new, separate Mithril Diffusion Layer can be instantiated. - - See [here](https://github.com/IntersectMBO/ouroboros-network/wiki/Reusable-Diffusion-Investigation) and [here](https://github.com/IntersectMBO/ouroboros-network/pull/5016) + - See [here](https://github.com/IntersectMBO/ouroboros-network/wiki/Reusable-Diffusion-Investigation) and [here](https://github.com/IntersectMBO/ouroboros-network/pull/5016) - [ ] Implement DMQ Node that is able to run general diffusion (i.e. without the mini-protocols). - - See [here](https://github.com/IntersectMBO/ouroboros-network/pull/5109) + - See [here](https://github.com/IntersectMBO/ouroboros-network/pull/5109) - [ ] Implement the n2n and n2c mini-protocols: - - [ ] DMQ Node - - [ ] Pallas Library (TxPipe) + - [ ] DMQ Node + - [ ] Pallas Library (TxPipe) - [ ] Implement the n2c mini-protocols in Mithril signer and aggregator nodes. ## References From e0a126a4297a6b94ad8648a8183b2bba6f00d41c Mon Sep 17 00:00:00 2001 From: Jean-Philippe Raynaud Date: Thu, 22 May 2025 16:39:48 +0200 Subject: [PATCH 2/3] Update implementation plan --- CIP-0137/README.md | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/CIP-0137/README.md b/CIP-0137/README.md index dc21214af2..18790f87cd 100644 --- a/CIP-0137/README.md +++ b/CIP-0137/README.md @@ -692,9 +692,15 @@ the KES key. - [ ] Implement DMQ Node that is able to run general diffusion (i.e. without the mini-protocols). - See [here](https://github.com/IntersectMBO/ouroboros-network/pull/5109) - [ ] Implement the n2n and n2c mini-protocols: - - [ ] DMQ Node - - [ ] Pallas Library (TxPipe) -- [ ] Implement the n2c mini-protocols in Mithril signer and aggregator nodes. + - [ ] Haskell DMQ Node: + - [ ] n2c mini-protocols + - [ ] n2n mini-protocols + - [ ] Pallas Library (TxPipe): + - [x] n2c mini-protocols + - [ ] n2n mini-protocols +- [x] Implement the n2c mini-protocols in Mithril nodes: + - [x] Mithril signer + - [x] Mithril aggregator ## References From 1c77ecfc46b9bffdb706e3285e972f323112f3b3 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Raynaud Date: Mon, 7 Jul 2025 12:43:56 +0200 Subject: [PATCH 3/3] Add missing KES period in DMQ message --- CIP-0137/README.md | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/CIP-0137/README.md b/CIP-0137/README.md index 18790f87cd..fc03bae64c 100644 --- a/CIP-0137/README.md +++ b/CIP-0137/README.md @@ -152,18 +152,20 @@ stateDiagram-v2 24 messageSizeInBytes = word32 25 kesSignature = bstr 26 operationalCertificate = bstr -27 blockNumber = word32 -28 ttl = word16 -29 -30 message = [ -31 messageId, -32 messageBody, -33 blockNumber, -34 ttl, -35 kesSignature, -36 operationalCertificate -37 ] -38 +27 kesPeriod = word32 +28 blockNumber = word32 +29 ttl = word16 +30 +31 message = [ +32 messageId, +33 messageBody, +34 blockNumber, +35 ttl, +36 kesSignature, +37 operationalCertificate, +38 kesPeriod +39 ] +40 ``` #### Inbound side and outbound side implementation @@ -304,10 +306,11 @@ The following tables gather figures about expected network load in the case of * | ttl | 2 B | 2 B | | kesSignature | 448 B | 448 B | | operationalCertificate | 304 B | 304 B | +| kesPeriod | 4 B | 4 B | | Message | Lower bound | Upper bound | | ------- | ----------- | ----------- | -| total | 1,150 B | 2,790 B | +| total | 1,154 B | 2,794 B | For a total of **3,100** Cardano SPOs on the `mainnet`, on an average **50%** of them will be eligible to send signatures (i.e. will win at least one lottery in the Mithril protocol). This means that if the full Cardano stake distribution is involved in the Mithril protocol, only **1,550** signers will send signatures at each round: