Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitGossipService ¶
InitGossipService initialize gossip service
func InitGossipServiceCustomDeliveryFactory ¶
func InitGossipServiceCustomDeliveryFactory(identity []byte, endpoint string, s *grpc.Server, factory DeliveryServiceFactory, bootPeers ...string)
InitGossipService initialize gossip service with customize delivery factory implementation, might be useful for testing and mocking purposes
Types ¶
type Config ¶
type Config interface { // ChainID returns the chainID for this channel ChainID() string // AnchorPeers should return the current list of anchor peers AnchorPeers() []*peer.AnchorPeer // Sequence should return the sequence number of the current configuration Sequence() uint64 }
Config enumerates the configuration methods required by gossip
type ConfigProcessor ¶
type ConfigProcessor interface { // ProcessConfig should be invoked whenever a channel's configuration is initialized or updated ProcessConfigUpdate(config Config) }
ConfigProcessor receives config updates
type DeliveryServiceFactory ¶
type DeliveryServiceFactory interface { // Returns an instance of delivery client Service(g GossipService) (deliverclient.DeliverService, error) }
DeliveryServiceFactory factory to create and initialize delivery service instance
type GossipService ¶
type GossipService interface { gossip.Gossip // NewConfigEventer creates a ConfigProcessor which the configtx.Manager can ultimately route config updates to NewConfigEventer() ConfigProcessor // InitializeChannel allocates the state provider and should be invoked once per channel per execution InitializeChannel(chainID string, committer committer.Committer) // GetBlock returns block for given chain GetBlock(chainID string, index uint64) *common.Block // AddPayload appends message payload to for given chain AddPayload(chainID string, payload *proto.Payload) error }
GossipService encapsulates gossip and state capabilities into single interface
func GetGossipService ¶
func GetGossipService() GossipService
GetGossipService returns an instance of gossip service
Click to show internal directories.
Click to hide internal directories.