Only emit SignTranaction once

Due to the ordered message-queue, there's no benefit to multiple emissions as
there's no risk a completion will be missed. If it has yet to be read, sending
another which only be read after isn't helpful.

Simplifies code a decent bit.
This commit is contained in:
Luke Parker
2023-07-30 06:44:55 -04:00
parent 3d91fd88a3
commit e010d66c5d
3 changed files with 64 additions and 65 deletions

View File

@@ -79,12 +79,18 @@ When the `t` validators who first published `SignPreprocess` transactions have
published `SignShare` transactions, a `sign::ProcessorMessage::Shares` with the
relevant shares is sent to the processor.
### Sign Completed
`SignCompleted` is created when a processor sends the coordinator
`sign::ProcessorMessage::Completed`. As soon as 34% of validators send
`Completed`, the signing protocol is no longer further attempted.
## Re-attempts
The key generation and signing protocols, whether batch or transaction, may
fail if a validator goes offline or takes too long to respond. Accordingly,
the tributary will schedule re-attempts. These are communicated with
`key_gen::CoordinatorMessage::GenerateKey`,
Key generation protocols may fail if a validator is malicious. Signing
protocols, whether batch or transaction, may fail if a validator goes offline or
takes too long to respond. Accordingly, the tributary will schedule re-attempts.
These are communicated with `key_gen::CoordinatorMessage::GenerateKey`,
`coordinator::CoordinatorMessage::BatchReattempt`, and
`sign::CoordinatorMessage::Reattempt`.