Documentation
¶
Overview ¶
Package mdns provides a multicast dns registry
Index ¶
- Constants
- Variables
- func Provide(datas map[string]any, _ *types.Components, logger log.Logger, ...) (registry.Type, error)
- func WithDomain(domain string) registry.Option
- type Config
- type Registry
- func (m *Registry) Deregister(_ context.Context, node registry.ServiceNode) error
- func (m *Registry) GetService(ctx context.Context, namespace, region, name string, schemes []string) ([]registry.ServiceNode, error)
- func (m *Registry) ListServices(ctx context.Context, namespace, region string, schemes []string) ([]registry.ServiceNode, error)
- func (m *Registry) Register(_ context.Context, serviceNode registry.ServiceNode) error
- func (m *Registry) Start(ctx context.Context) error
- func (m *Registry) Stop(ctx context.Context) error
- func (m *Registry) String() string
- func (m *Registry) Type() string
- func (m *Registry) Watch(ctx context.Context, opts ...registry.WatchOption) (registry.Watcher, error)
Constants ¶
View Source
const Name = "mdns"
Name provides the name of this registry.
Variables ¶
View Source
var (
DefaultDomain = "orb"
)
Defaults.
Functions ¶
Types ¶
type Config ¶
type Config struct { registry.Config `yaml:",inline"` Domain string `json:"domain,omitempty" yaml:"domain,omitempty"` }
Config provides configuration for the mDNS registry.
type Registry ¶
Registry implements the registry interface. It runs a MDNS service registry.
func New ¶
New creates a new mdns registry. This functions should rarely be called manually. To create a new registry use ProvideRegistryMDNS.
func (*Registry) Deregister ¶
Deregister a service from the registry.
func (*Registry) GetService ¶
func (m *Registry) GetService(ctx context.Context, namespace, region, name string, schemes []string) ([]registry.ServiceNode, error)
GetService fetches a service from the registry.
func (*Registry) ListServices ¶
func (m *Registry) ListServices(ctx context.Context, namespace, region string, schemes []string) ([]registry.ServiceNode, error)
ListServices fetches all services in the registry.
Directories
¶
Path | Synopsis |
---|---|
Package client provides utility functions for the mdns registry.
|
Package client provides utility functions for the mdns registry. |
Package dns provides mdns dns utilities.
|
Package dns provides mdns dns utilities. |
Package server provides an MDNS server.
|
Package server provides an MDNS server. |
Package util provides utilities.
|
Package util provides utilities. |
Package zone provides mDNS zone utilities.
|
Package zone provides mDNS zone utilities. |
Click to show internal directories.
Click to hide internal directories.