Documentation
¶
Index ¶
- func ParsePublicKeysFromStrings(pubKeys []string) (keys.PublicKeys, error)
- type ClientCache
- func (c *ClientCache) Get(address string) (client.Client, error)
- func (c *ClientCache) GetHeader(task *audit.Task, node *netmap.Node, id *object.ID, relay bool) (*object.Object, error)
- func (c *ClientCache) GetRangeHash(task *audit.Task, node *netmap.Node, id *object.ID, rng *object.Range) ([]byte, error)
- func (c *ClientCache) GetSG(task *audit.Task, id *object.ID) (*storagegroup.StorageGroup, error)
- type ContractProcessor
- type Server
- func (s *Server) AlphabetIndex() int
- func (s *Server) EpochCounter() uint64
- func (s *Server) InitAndVoteForSidechainValidator(validators keys.PublicKeys) error
- func (s *Server) InnerRingIndex() int
- func (s *Server) InnerRingSize() int
- func (s *Server) IsActive() bool
- func (s *Server) IsAlphabet() bool
- func (s *Server) ResetEpochTimer() error
- func (s *Server) SetEpochCounter(val uint64)
- func (s *Server) Start(ctx context.Context, intError chan<- error) error
- func (s *Server) Stop()
- func (s *Server) VoteForSidechainValidator(validators keys.PublicKeys) error
- func (s *Server) WriteReport(r *audit.Report) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParsePublicKeysFromStrings ¶ added in v0.13.0
func ParsePublicKeysFromStrings(pubKeys []string) (keys.PublicKeys, error)
ParsePublicKeysFromStrings returns slice of neo public keys from slice of hex encoded strings.
Types ¶
type ClientCache ¶ added in v0.14.0
type ClientCache struct {
// contains filtered or unexported fields
}
func (*ClientCache) Get ¶ added in v0.14.0
func (c *ClientCache) Get(address string) (client.Client, error)
func (*ClientCache) GetHeader ¶ added in v0.14.0
func (c *ClientCache) GetHeader(task *audit.Task, node *netmap.Node, id *object.ID, relay bool) (*object.Object, error)
GetHeader requests node from the container under audit to return object header by id.
func (*ClientCache) GetRangeHash ¶ added in v0.14.0
func (c *ClientCache) GetRangeHash(task *audit.Task, node *netmap.Node, id *object.ID, rng *object.Range) ([]byte, error)
GetRangeHash requests node from the container under audit to return Tillich-Zemor hash of the payload range of the object with specified identifier.
func (*ClientCache) GetSG ¶ added in v0.14.0
func (c *ClientCache) GetSG(task *audit.Task, id *object.ID) (*storagegroup.StorageGroup, error)
GetSG polls the container from audit task to get the object by id. Returns storage groups structure from received object.
type ContractProcessor ¶
type ContractProcessor interface { ListenerParsers() []event.ParserInfo ListenerHandlers() []event.HandlerInfo TimersHandlers() []event.HandlerInfo }
ContractProcessor interface defines functions for binding event producers such as event.Listener and Timers with contract processor.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is the inner ring application structure, that contains all event processors, shared variables and event handlers.
func (*Server) AlphabetIndex ¶ added in v0.18.0
AlphabetIndex is a getter for a global index of node in alphabet list. Negative index means that node is not in the alphabet list.
func (*Server) EpochCounter ¶
EpochCounter is a getter for a global epoch counter.
func (*Server) InitAndVoteForSidechainValidator ¶ added in v0.13.0
func (s *Server) InitAndVoteForSidechainValidator(validators keys.PublicKeys) error
InitAndVoteForSidechainValidator is a public function to use outside of inner ring daemon execution. It initialize inner ring structure with data from blockchain and then calls vote method on alphabet contracts.
func (*Server) InnerRingIndex ¶ added in v0.18.0
InnerRingIndex is a getter for a global index of node in inner ring list. Negative index means that node is not in the inner ring list.
func (*Server) InnerRingSize ¶ added in v0.14.0
InnerRingSize is a getter for a global size of inner ring list. This value paired with inner ring index.
func (*Server) IsAlphabet ¶ added in v0.18.0
IsAlphabet is a getter for a global alphabet flag state.
func (*Server) ResetEpochTimer ¶ added in v0.15.0
ResetEpochTimer resets block timer that produces events to update epoch counter in netmap contract. Used to synchronize this even production based on block with notification of last epoch.
func (*Server) SetEpochCounter ¶
SetEpochCounter is a setter for contract processors to update global epoch counter.
func (*Server) VoteForSidechainValidator ¶ added in v0.18.0
func (s *Server) VoteForSidechainValidator(validators keys.PublicKeys) error
VoteForSidechainValidator calls vote method on alphabet contracts with provided list of keys.