Documentation ¶
Index ¶
- func Decide(D map[string][][]byte)
- type Carrier
- func (c *Carrier) Broadcast(message message.Message)
- func (c *Carrier) BroadcastWorker()
- func (c *Carrier) CheckAcceptedHashStoreAndDecide()
- func (c *Carrier) DecodeNestedSMRDecisions(conn net.Conn)
- func (c *Carrier) ExecuteBroadcast(message message.Message)
- func (c *Carrier) ForwardMode() bool
- func (c *Carrier) GetAddress() string
- func (c *Carrier) GetCarrierToCarrierAddress() string
- func (c *Carrier) GetClientToCarrierAddress() string
- func (c *Carrier) GetDecisionAddress() string
- func (c *Carrier) GetID() string
- func (c *Carrier) GetKyberPK() kyber.Point
- func (c *Carrier) GetKyberSK() kyber.Scalar
- func (c *Carrier) GetMempoolThreshold() int
- func (c *Carrier) GetPKFromID(senderID string) (kyber.Point, error)
- func (c *Carrier) GetStringPK() string
- func (c *Carrier) GetStringSK() string
- func (c *Carrier) GetSuite() pairing.Suite
- func (c *Carrier) GetTsxSize() int
- func (c *Carrier) HandleCarrierConn(conn net.Conn)
- func (c *Carrier) HandleClientConn(conn net.Conn)
- func (c *Carrier) HandleEchoMessage(rawMessage message.Message) error
- func (c *Carrier) HandleIncomingConnections(l *net.TCPListener, handler func(conn net.Conn))
- func (c *Carrier) HandleInitMessage(rawMessage message.Message) error
- func (c *Carrier) HandleNestedSMRDecision(N superblock.SuperBlockSummary)
- func (c *Carrier) HandleRequestMessage(rawMessage message.Message) error
- func (c *Carrier) HandleResolveMessage(rawMessage message.Message) error
- func (c *Carrier) LaunchWorkerPool(poolSize int, task func())
- func (c *Carrier) Logger()
- func (c *Carrier) NestedPropose(P superblock.SuperBlockSummary) error
- func (c *Carrier) Sign(h string) string
- func (c *Carrier) Start() *sync.WaitGroup
- func (c *Carrier) StartListener(address string) (*net.TCPListener, error)
- func (c *Carrier) Stop()
- func (c *Carrier) Verify(h string, s util.Signature) error
- type Conn
- type Listeners
- type Locks
- type Stores
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Carrier ¶
type Carrier struct { Counter uint64 Config *util.Config Listeners Listeners Stores Stores Locks Locks NodeConn *net.TCPConn Node *remote.Node Neighbours map[string]*remote.Neighbour // Registry of message handlers. Argument must be one of the enum types MessageHandlers map[message.Type]func(message.Message) error Suite *pairing.SuiteBn256 F int N int Wg *sync.WaitGroup Quit chan bool BroadcastDispenser chan message.Message SbsCounter int }
func NewCarrier ¶
func (*Carrier) BroadcastWorker ¶
func (c *Carrier) BroadcastWorker()
func (*Carrier) CheckAcceptedHashStoreAndDecide ¶
func (c *Carrier) CheckAcceptedHashStoreAndDecide()
func (*Carrier) DecodeNestedSMRDecisions ¶
func (*Carrier) ExecuteBroadcast ¶
For communicating with carriers
func (*Carrier) ForwardMode ¶
func (*Carrier) GetAddress ¶
func (*Carrier) GetCarrierToCarrierAddress ¶
func (*Carrier) GetClientToCarrierAddress ¶
func (*Carrier) GetDecisionAddress ¶
func (*Carrier) GetKyberPK ¶
func (c *Carrier) GetKyberPK() kyber.Point
func (*Carrier) GetKyberSK ¶
func (c *Carrier) GetKyberSK() kyber.Scalar
func (*Carrier) GetMempoolThreshold ¶
func (*Carrier) GetPKFromID ¶
func (*Carrier) GetStringPK ¶
func (*Carrier) GetStringSK ¶
func (*Carrier) GetTsxSize ¶
func (*Carrier) HandleCarrierConn ¶
func (*Carrier) HandleClientConn ¶
func (*Carrier) HandleEchoMessage ¶
func (*Carrier) HandleIncomingConnections ¶
func (c *Carrier) HandleIncomingConnections(l *net.TCPListener, handler func(conn net.Conn))
func (*Carrier) HandleInitMessage ¶
func (*Carrier) HandleNestedSMRDecision ¶
func (c *Carrier) HandleNestedSMRDecision(N superblock.SuperBlockSummary)
HandleNestedSMRDecision assumes that N is safe and correct
func (*Carrier) HandleRequestMessage ¶
func (*Carrier) HandleResolveMessage ¶
func (*Carrier) LaunchWorkerPool ¶
func (*Carrier) NestedPropose ¶
func (c *Carrier) NestedPropose(P superblock.SuperBlockSummary) error
func (*Carrier) Start ¶
Start listening to client requests Forward client requests We are not waiting for listeners to stop but I think it's fine
func (*Carrier) StartListener ¶
func (c *Carrier) StartListener(address string) (*net.TCPListener, error)
type Conn ¶
Conn is a new wrapper around net.Conn The idea is to implement a reliable connection that will detect errors and attempt to reconnect if the connection breaks down.
func (*Conn) RunSinkConsumer ¶
func (c *Conn) RunSinkConsumer()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.