From 219adc765716dc4c6664a811523241b8df9b5529 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Mon, 8 May 2023 22:21:41 -0400 Subject: [PATCH] Rename uid to intent --- processor/messages/src/lib.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/processor/messages/src/lib.rs b/processor/messages/src/lib.rs index ee2634fb..2831f8ff 100644 --- a/processor/messages/src/lib.rs +++ b/processor/messages/src/lib.rs @@ -219,14 +219,14 @@ const TYPE_COORDINATOR_UID: u8 = 4; const TYPE_SUBSTRATE_UID: u8 = 5; impl CoordinatorMessage { - /// A unique ID for this message, which should be unique across the validator's entire system, + /// The intent for this message, which should be unique across the validator's entire system, /// including all of its processors. /// /// This doesn't use H(msg.serialize()) as it's meant to be unique to intent, not unique to /// values. While the values should be consistent per intent, that assumption isn't required /// here. // TODO: Should this use borsh intead of bincode? - pub fn uid(&self) -> Vec { + pub fn intent(&self) -> Vec { match self { CoordinatorMessage::KeyGen(msg) => { // Unique since key gen ID embeds the validator set and attempt @@ -293,13 +293,13 @@ impl CoordinatorMessage { } impl ProcessorMessage { - /// A unique ID for this message, which should be unique across the validator's entire system, + /// The intent for this message, which should be unique across the validator's entire system, /// including all of its processors. /// /// This doesn't use H(msg.serialize()) as it's meant to be unique to intent, not unique to /// values. While the values should be consistent per intent, that assumption isn't required /// here. - pub fn uid(&self) -> Vec { + pub fn intent(&self) -> Vec { match self { ProcessorMessage::KeyGen(msg) => { let (sub, id) = match msg {