Documentation ¶
Overview ¶
Package event contains data structures that are attached to events in the relay. Though many of these events are triggered on-chain, that is not an inherent requirement of structures in this package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DKGResultSubmission ¶
type DKGResultSubmission struct { MemberIndex uint32 GroupPublicKey []byte Misbehaved []byte BlockNumber uint64 }
DKGResultSubmission represents a DKG result submission event. It is emitted after a submitted DKG result is positively validated on the chain. It contains the index of the member who submitted the result and a final public key of the group.
type EntryGenerated ¶
EntryGenerated indicates that new relay entry has ben generated by threshold relay. This event is intended to be used by threshold relay consumers.
type EntrySubmitted ¶
type EntrySubmitted struct {
BlockNumber uint64
}
EntrySubmitted indicates that valid relay entry has been submitted to the chain for the currently processed relay request. This event is intended to be used by operators for tracking entry generation and submission progress.
type GroupRegistration ¶
GroupRegistration represents an event of registering a new group with the given public key.
type GroupSelectionStart ¶
GroupSelectionStart represents a group selection start event.
type GroupSelectionTrack ¶
GroupSelectionTrack is used to track a start for group selection after GroupSelectionStarted event is received. It is used to ensure that the process execution is not duplicated, i.e. when the client receives the same event multiple times. When event is received, it should be added in this struct. When a group selection process completes (no matter if it succeeded or failed), it should be removed from this struct.
func (*GroupSelectionTrack) Add ¶
func (gst *GroupSelectionTrack) Add(entry string) bool
Add inserts a new entry into a map that reflects whether a new group selection has already started using an entry as a seed.
func (*GroupSelectionTrack) Remove ¶
func (gst *GroupSelectionTrack) Remove(entry string)
Remove clears a map from an entry that was used to start a group selection.
type GroupTicketSubmission ¶
GroupTicketSubmission represents a group selection ticket submission event.
type RelayRequestTrack ¶
RelayRequestTrack is used to track requests for new entries after RelayEntryRequested event is received. It is used to ensure that the process execution is not duplicated, i.e. when the client receives the same event multiple times. When event is received, it should be added in this struct. When a new entry generation process completes (no matter if it succeeded or failed), it should be removed from this struct.
func (*RelayRequestTrack) Add ¶
func (rrt *RelayRequestTrack) Add(previousEntry string) bool
Add inserts a previous entry into a map that reflects whether a new relay entry has already been requested.
func (*RelayRequestTrack) Remove ¶
func (rrt *RelayRequestTrack) Remove(previousEntry string)
Remove clears a map from a previous entry.