Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Coordinator ¶
type Coordinator struct {
CoordinatorTimeout time.Duration
TssTimeout time.Duration
InitiatePeriod time.Duration
// contains filtered or unexported fields
}
func NewCoordinator ¶
func NewCoordinator( host host.Host, communication comm.Communication, electorFactory *elector.CoordinatorElectorFactory, ) *Coordinator
func (*Coordinator) Execute ¶
func (c *Coordinator) Execute(ctx context.Context, tssProcesses []TssProcess, resultChn chan interface{}, coordinator peer.ID) error
Execute calculates process leader and coordinates party readiness and start the tss processes. Array of processes can be passed if all the processes have to have the same peer subset and the result of all of them is needed. The processes should have an unique session ID for each one.
type SubsetError ¶
func (*SubsetError) Error ¶
func (se *SubsetError) Error() string
type TssProcess ¶
type TssProcess interface {
Run(ctx context.Context, coordinator bool, resultChn chan interface{}, params []byte) error
Stop()
Ready(readyPeers []peer.ID, excludedPeers []peer.ID) (bool, error)
Retryable() bool
StartParams(readyPeers []peer.ID) []byte
SessionID() string
ValidCoordinators() []peer.ID
}
Click to show internal directories.
Click to hide internal directories.