Documentation ¶
Index ¶
Constants ¶
const (
// AccessDenied indicates that the user does not have permission to perform the operation
AccessDenied = "access denied"
)
Variables ¶
This section is empty.
Functions ¶
func WithErrorHandler ¶
func WithErrorHandler(value fab.ErrorHandler) coptions.Opt
WithErrorHandler sets the error handler
func WithRefreshInterval ¶
WithRefreshInterval sets the interval in which the peer cache is refreshed
Types ¶
type ChannelService ¶
type ChannelService struct {
// contains filtered or unexported fields
}
ChannelService implements a dynamic Discovery Service that queries Fabric's Discovery service for information about the peers that are currently joined to the given channel.
func NewChannelService ¶
func NewChannelService(ctx contextAPI.Client, membership fab.ChannelMembership, channelID string, opts ...coptions.Opt) (*ChannelService, error)
NewChannelService creates a Discovery Service to query the list of member peers on a given channel.
type DiscoveryClient ¶
type DiscoveryClient interface {
Send(ctx context.Context, req *discclient.Request, targets ...fab.PeerConfig) ([]fabdiscovery.Response, error)
}
DiscoveryClient is the client to the discovery service
type DiscoveryError ¶
type DiscoveryError error
DiscoveryError is an error originating at the Discovery service
type LocalProvider ¶
type LocalProvider struct {
// contains filtered or unexported fields
}
LocalProvider implements a local Dynamic Discovery LocalProvider that queries Fabric's Discovery service for information about the peers that are in the local MSP.
func NewLocalProvider ¶
func NewLocalProvider(config fab.EndpointConfig, opts ...coptions.Opt) *LocalProvider
NewLocalProvider creates a new local dynamic discovery provider
func (*LocalProvider) Close ¶
func (p *LocalProvider) Close()
Close will close the cache and all services contained by the cache.
func (*LocalProvider) CloseContext ¶
func (p *LocalProvider) CloseContext(ctx fab.ClientContext)
CloseContext frees resources and caches for the given context.
func (*LocalProvider) CreateLocalDiscoveryService ¶
func (p *LocalProvider) CreateLocalDiscoveryService(mspID string) (fab.DiscoveryService, error)
CreateLocalDiscoveryService returns a local discovery service
type LocalService ¶
type LocalService struct {
// contains filtered or unexported fields
}
LocalService implements a dynamic Discovery Service that queries Fabric's Discovery service for the peers that are in the local MSP.
func (*LocalService) Initialize ¶
func (s *LocalService) Initialize(ctx contextAPI.Local) error
Initialize initializes the service with local context