Documentation ¶
Index ¶
Constants ¶
View Source
const ( GRPC = "GRPC" HTTP = "HTTP" )
View Source
const (
ConsulResolver = "consul"
)
Variables ¶
This section is empty.
Functions ¶
func InitConsulGRPCResolver ¶
func InitConsulGRPCResolver()
Types ¶
type ConsulRegister ¶
type ConsulRegister struct { Address string ServerName string Tag []string Port int DeregisterCriticalServiceAfter time.Duration Interval time.Duration K8sHostName string ProductName string RunVersion string // contains filtered or unexported fields }
ConsulRegister consul service register
func NewConsulRegister ¶
func NewConsulRegister(serverType, serverName, runVersion string) *ConsulRegister
NewConsulRegister create a new consul register
func (*ConsulRegister) Register ¶
func (r *ConsulRegister) Register() error
Register register service
Click to show internal directories.
Click to hide internal directories.