discovery

package
v0.0.0-...-e9de818 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FetchRegistry

func FetchRegistry(name string) ([]string, error)

func FetchRegistryWithPort

func FetchRegistryWithPort(name string) ([]string, error)

func GetHosts

func GetHosts() []string

func GetOtherHosts

func GetOtherHosts() []string

Types

type ServerRegistry

type ServerRegistry struct {
	Name   string `json:"name"`
	Ip     string `json:"ip"`
	Port   int    `json:"port"`
	Weight int    `json:"weight"`
	SDHost string
	// contains filtered or unexported fields
}

func NewRegistry

func NewRegistry(svrName, ip, sdUrl string, port int) *ServerRegistry

func NewServerRegistry

func NewServerRegistry() *ServerRegistry

func (*ServerRegistry) SetWeight

func (s *ServerRegistry) SetWeight(w int)

func (*ServerRegistry) Stop

func (s *ServerRegistry) Stop()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL