discovery

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 10, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Getter

type Getter func() [][]byte

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

func NewRegistry

func NewRegistry(nc *nats.Conn) *Registry

func (*Registry) Discover

func (s *Registry) Discover(ctx context.Context, subj string, instanceID string, getData func() []byte) error

Discover universal method listens for subj messages and responses back to the reply subject

func (*Registry) Lookup

func (s *Registry) Lookup(replySubject, subj string, minDur time.Duration, maxDur time.Duration) ([]*modulepb.DiscoveryNode, error)

func (*Registry) LookupComponents

func (s *Registry) LookupComponents(ctx context.Context, workspaceID string) ([]*modulepb.DiscoveryNode, error)

func (*Registry) LookupFlows

func (s *Registry) LookupFlows(ctx context.Context, workspaceID string) ([]*modulepb.DiscoveryNode, error)

func (*Registry) LookupModules

func (s *Registry) LookupModules(ctx context.Context, serverID string) ([]*modulepb.DiscoveryNode, error)

func (*Registry) LookupNodes

func (s *Registry) LookupNodes(flowID string) ([]*modulepb.DiscoveryNode, error)

func (*Registry) LookupServers

func (s *Registry) LookupServers(ctx context.Context, workspaceID string) ([]*modulepb.DiscoveryNode, error)

func (*Registry) SetLogger

func (s *Registry) SetLogger(l zerolog.Logger) *Registry

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳